diff --git a/stripe/__init__.py b/stripe/__init__.py
index 3adcb0282..2c8348462 100644
--- a/stripe/__init__.py
+++ b/stripe/__init__.py
@@ -222,6 +222,7 @@ def set_app_info(
forwarding as forwarding,
identity as identity,
issuing as issuing,
+ params as params,
radar as radar,
reporting as reporting,
sigma as sigma,
diff --git a/stripe/_account.py b/stripe/_account.py
index fbaf003f5..43a1d062b 100644
--- a/stripe/_account.py
+++ b/stripe/_account.py
@@ -8,18 +8,11 @@
from stripe._nested_resource_class_methods import nested_resource_class_methods
from stripe._oauth import OAuth
from stripe._person import Person
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, Union, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._bank_account import BankAccount
@@ -28,6 +21,53 @@
from stripe._file import File
from stripe._login_link import LoginLink
from stripe._tax_id import TaxId
+ from stripe.params._account_create_external_account_params import (
+ AccountCreateExternalAccountParams,
+ )
+ from stripe.params._account_create_login_link_params import (
+ AccountCreateLoginLinkParams,
+ )
+ from stripe.params._account_create_params import AccountCreateParams
+ from stripe.params._account_create_person_params import (
+ AccountCreatePersonParams,
+ )
+ from stripe.params._account_delete_external_account_params import (
+ AccountDeleteExternalAccountParams,
+ )
+ from stripe.params._account_delete_params import AccountDeleteParams
+ from stripe.params._account_delete_person_params import (
+ AccountDeletePersonParams,
+ )
+ from stripe.params._account_list_capabilities_params import (
+ AccountListCapabilitiesParams,
+ )
+ from stripe.params._account_list_external_accounts_params import (
+ AccountListExternalAccountsParams,
+ )
+ from stripe.params._account_list_params import AccountListParams
+ from stripe.params._account_list_persons_params import (
+ AccountListPersonsParams,
+ )
+ from stripe.params._account_modify_capability_params import (
+ AccountModifyCapabilityParams,
+ )
+ from stripe.params._account_modify_external_account_params import (
+ AccountModifyExternalAccountParams,
+ )
+ from stripe.params._account_modify_person_params import (
+ AccountModifyPersonParams,
+ )
+ from stripe.params._account_persons_params import AccountPersonsParams
+ from stripe.params._account_reject_params import AccountRejectParams
+ from stripe.params._account_retrieve_capability_params import (
+ AccountRetrieveCapabilityParams,
+ )
+ from stripe.params._account_retrieve_external_account_params import (
+ AccountRetrieveExternalAccountParams,
+ )
+ from stripe.params._account_retrieve_person_params import (
+ AccountRetrievePersonParams,
+ )
@nested_resource_class_methods("capability")
@@ -1346,3164 +1386,6 @@ class TosAcceptance(StripeObject):
The user agent of the browser from which the account representative accepted their service agreement
"""
- class CreateExternalAccountParams(RequestOptions):
- default_for_currency: NotRequired[bool]
- """
- When set to true, or if this is the first external account added in this currency, this account becomes the default external account for its currency.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- external_account: Union[
- str,
- "Account.CreateExternalAccountParamsCard",
- "Account.CreateExternalAccountParamsBankAccount",
- "Account.CreateExternalAccountParamsCardToken",
- ]
- """
- A token, like the ones returned by [Stripe.js](https://stripe.com/docs/js) or a dictionary containing a user's external account details (with the options shown below). Please refer to full [documentation](https://stripe.com/docs/api/external_accounts) instead.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class CreateExternalAccountParamsBankAccount(TypedDict):
- object: Literal["bank_account"]
- account_holder_name: NotRequired[str]
- """
- The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object.
- """
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
- """
- account_number: str
- """
- The account number for the bank account, in string form. Must be a checking account.
- """
- country: str
- """
- The country in which the bank account is located.
- """
- currency: NotRequired[str]
- """
- The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts)
- """
- routing_number: NotRequired[str]
- """
- The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
- """
-
- class CreateExternalAccountParamsCard(TypedDict):
- object: Literal["card"]
- address_city: NotRequired[str]
- address_country: NotRequired[str]
- address_line1: NotRequired[str]
- address_line2: NotRequired[str]
- address_state: NotRequired[str]
- address_zip: NotRequired[str]
- currency: NotRequired[str]
- cvc: NotRequired[str]
- exp_month: int
- exp_year: int
- name: NotRequired[str]
- number: str
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- """
-
- class CreateExternalAccountParamsCardToken(TypedDict):
- object: Literal["card"]
- currency: NotRequired[str]
- token: str
-
- class CreateLoginLinkParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(RequestOptions):
- account_token: NotRequired[str]
- """
- An [account token](https://stripe.com/docs/api#create_account_token), used to securely provide details to the account.
- """
- business_profile: NotRequired["Account.CreateParamsBusinessProfile"]
- """
- Business information about the account.
- """
- business_type: NotRequired[
- Literal["company", "government_entity", "individual", "non_profit"]
- ]
- """
- The business type. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
- """
- capabilities: NotRequired["Account.CreateParamsCapabilities"]
- """
- Each key of the dictionary represents a capability, and each capability
- maps to its settings (for example, whether it has been requested or not). Each
- capability is inactive until you have provided its specific
- requirements and Stripe has verified them. An account might have some
- of its requested capabilities be active and some be inactive.
-
- Required when [account.controller.stripe_dashboard.type](https://docs.stripe.com/api/accounts/create#create_account-controller-dashboard-type)
- is `none`, which includes Custom accounts.
- """
- company: NotRequired["Account.CreateParamsCompany"]
- """
- Information about the company or business. This field is available for any `business_type`. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
- """
- controller: NotRequired["Account.CreateParamsController"]
- """
- A hash of configuration describing the account controller's attributes.
- """
- country: NotRequired[str]
- """
- The country in which the account holder resides, or in which the business is legally established. This should be an ISO 3166-1 alpha-2 country code. For example, if you are in the United States and the business for which you're creating an account is legally represented in Canada, you would use `CA` as the country for the account being created. Available countries include [Stripe's global markets](https://stripe.com/global) as well as countries where [cross-border payouts](https://stripe.com/docs/connect/cross-border-payouts) are supported.
- """
- default_currency: NotRequired[str]
- """
- Three-letter ISO currency code representing the default currency for the account. This must be a currency that [Stripe supports in the account's country](https://docs.stripe.com/payouts).
- """
- documents: NotRequired["Account.CreateParamsDocuments"]
- """
- Documents that may be submitted to satisfy various informational requests.
- """
- email: NotRequired[str]
- """
- The email address of the account holder. This is only to make the account easier to identify to you. If [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, Stripe doesn't email the account without your consent.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- external_account: NotRequired[
- "str|Account.CreateParamsBankAccount|Account.CreateParamsCard|Account.CreateParamsCardToken"
- ]
- """
- A card or bank account to attach to the account for receiving [payouts](https://docs.stripe.com/connect/bank-debit-card-payouts) (you won't be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](https://docs.stripe.com/js), or a dictionary, as documented in the `external_account` parameter for [bank account](https://docs.stripe.com/api#account_create_bank_account) creation.
-
- By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the [bank account](https://docs.stripe.com/api#account_create_bank_account) or [card creation](https://docs.stripe.com/api#account_create_card) APIs. After you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
- """
- groups: NotRequired["Account.CreateParamsGroups"]
- """
- A hash of account group type to tokens. These are account groups this account should be added to.
- """
- individual: NotRequired["Account.CreateParamsIndividual"]
- """
- Information about the person represented by the account. This field is null unless `business_type` is set to `individual`. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- settings: NotRequired["Account.CreateParamsSettings"]
- """
- Options for customizing how the account functions within Stripe.
- """
- tos_acceptance: NotRequired["Account.CreateParamsTosAcceptance"]
- """
- Details on the account's acceptance of the [Stripe Services Agreement](https://docs.stripe.com/connect/updating-accounts#tos-acceptance). This property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts. This property defaults to a `full` service agreement when empty.
- """
- type: NotRequired[Literal["custom", "express", "standard"]]
- """
- The type of Stripe account to create. May be one of `custom`, `express` or `standard`.
- """
-
- class CreateParamsBankAccount(TypedDict):
- object: Literal["bank_account"]
- account_holder_name: NotRequired[str]
- """
- The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object.
- """
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
- """
- account_number: str
- """
- The account number for the bank account, in string form. Must be a checking account.
- """
- country: str
- """
- The country in which the bank account is located.
- """
- currency: NotRequired[str]
- """
- The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts)
- """
- routing_number: NotRequired[str]
- """
- The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
- """
-
- class CreateParamsBusinessProfile(TypedDict):
- annual_revenue: NotRequired[
- "Account.CreateParamsBusinessProfileAnnualRevenue"
- ]
- """
- The applicant's gross annual revenue for its preceding fiscal year.
- """
- estimated_worker_count: NotRequired[int]
- """
- An estimated upper bound of employees, contractors, vendors, etc. currently working for the business.
- """
- mcc: NotRequired[str]
- """
- [The merchant category code for the account](https://docs.stripe.com/connect/setting-mcc). MCCs are used to classify businesses based on the goods or services they provide.
- """
- minority_owned_business_designation: NotRequired[
- List[
- Literal[
- "lgbtqi_owned_business",
- "minority_owned_business",
- "none_of_these_apply",
- "prefer_not_to_answer",
- "women_owned_business",
- ]
- ]
- ]
- """
- Whether the business is a minority-owned, women-owned, and/or LGBTQI+ -owned business.
- """
- monthly_estimated_revenue: NotRequired[
- "Account.CreateParamsBusinessProfileMonthlyEstimatedRevenue"
- ]
- """
- An estimate of the monthly revenue of the business. Only accepted for accounts in Brazil and India.
- """
- name: NotRequired[str]
- """
- The customer-facing business name.
- """
- product_description: NotRequired[str]
- """
- Internal-only description of the product sold by, or service provided by, the business. Used by Stripe for risk and underwriting purposes.
- """
- support_address: NotRequired[
- "Account.CreateParamsBusinessProfileSupportAddress"
- ]
- """
- A publicly available mailing address for sending support issues to.
- """
- support_email: NotRequired[str]
- """
- A publicly available email address for sending support issues to.
- """
- support_phone: NotRequired[str]
- """
- A publicly available phone number to call with support issues.
- """
- support_url: NotRequired["Literal['']|str"]
- """
- A publicly available website for handling support issues.
- """
- url: NotRequired[str]
- """
- The business's publicly available website.
- """
-
- class CreateParamsBusinessProfileAnnualRevenue(TypedDict):
- amount: int
- """
- A non-negative integer representing the amount in the [smallest currency unit](https://docs.stripe.com/currencies#zero-decimal).
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- fiscal_year_end: str
- """
- The close-out date of the preceding fiscal year in ISO 8601 format. E.g. 2023-12-31 for the 31st of December, 2023.
- """
-
- class CreateParamsBusinessProfileMonthlyEstimatedRevenue(TypedDict):
- amount: int
- """
- A non-negative integer representing how much to charge in the [smallest currency unit](https://docs.stripe.com/currencies#zero-decimal).
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class CreateParamsBusinessProfileSupportAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsCapabilities(TypedDict):
- acss_debit_payments: NotRequired[
- "Account.CreateParamsCapabilitiesAcssDebitPayments"
- ]
- """
- The acss_debit_payments capability.
- """
- affirm_payments: NotRequired[
- "Account.CreateParamsCapabilitiesAffirmPayments"
- ]
- """
- The affirm_payments capability.
- """
- afterpay_clearpay_payments: NotRequired[
- "Account.CreateParamsCapabilitiesAfterpayClearpayPayments"
- ]
- """
- The afterpay_clearpay_payments capability.
- """
- alma_payments: NotRequired[
- "Account.CreateParamsCapabilitiesAlmaPayments"
- ]
- """
- The alma_payments capability.
- """
- amazon_pay_payments: NotRequired[
- "Account.CreateParamsCapabilitiesAmazonPayPayments"
- ]
- """
- The amazon_pay_payments capability.
- """
- au_becs_debit_payments: NotRequired[
- "Account.CreateParamsCapabilitiesAuBecsDebitPayments"
- ]
- """
- The au_becs_debit_payments capability.
- """
- bacs_debit_payments: NotRequired[
- "Account.CreateParamsCapabilitiesBacsDebitPayments"
- ]
- """
- The bacs_debit_payments capability.
- """
- bancontact_payments: NotRequired[
- "Account.CreateParamsCapabilitiesBancontactPayments"
- ]
- """
- The bancontact_payments capability.
- """
- bank_transfer_payments: NotRequired[
- "Account.CreateParamsCapabilitiesBankTransferPayments"
- ]
- """
- The bank_transfer_payments capability.
- """
- billie_payments: NotRequired[
- "Account.CreateParamsCapabilitiesBilliePayments"
- ]
- """
- The billie_payments capability.
- """
- blik_payments: NotRequired[
- "Account.CreateParamsCapabilitiesBlikPayments"
- ]
- """
- The blik_payments capability.
- """
- boleto_payments: NotRequired[
- "Account.CreateParamsCapabilitiesBoletoPayments"
- ]
- """
- The boleto_payments capability.
- """
- card_issuing: NotRequired[
- "Account.CreateParamsCapabilitiesCardIssuing"
- ]
- """
- The card_issuing capability.
- """
- card_payments: NotRequired[
- "Account.CreateParamsCapabilitiesCardPayments"
- ]
- """
- The card_payments capability.
- """
- cartes_bancaires_payments: NotRequired[
- "Account.CreateParamsCapabilitiesCartesBancairesPayments"
- ]
- """
- The cartes_bancaires_payments capability.
- """
- cashapp_payments: NotRequired[
- "Account.CreateParamsCapabilitiesCashappPayments"
- ]
- """
- The cashapp_payments capability.
- """
- crypto_payments: NotRequired[
- "Account.CreateParamsCapabilitiesCryptoPayments"
- ]
- """
- The crypto_payments capability.
- """
- eps_payments: NotRequired[
- "Account.CreateParamsCapabilitiesEpsPayments"
- ]
- """
- The eps_payments capability.
- """
- fpx_payments: NotRequired[
- "Account.CreateParamsCapabilitiesFpxPayments"
- ]
- """
- The fpx_payments capability.
- """
- gb_bank_transfer_payments: NotRequired[
- "Account.CreateParamsCapabilitiesGbBankTransferPayments"
- ]
- """
- The gb_bank_transfer_payments capability.
- """
- giropay_payments: NotRequired[
- "Account.CreateParamsCapabilitiesGiropayPayments"
- ]
- """
- The giropay_payments capability.
- """
- grabpay_payments: NotRequired[
- "Account.CreateParamsCapabilitiesGrabpayPayments"
- ]
- """
- The grabpay_payments capability.
- """
- ideal_payments: NotRequired[
- "Account.CreateParamsCapabilitiesIdealPayments"
- ]
- """
- The ideal_payments capability.
- """
- india_international_payments: NotRequired[
- "Account.CreateParamsCapabilitiesIndiaInternationalPayments"
- ]
- """
- The india_international_payments capability.
- """
- jcb_payments: NotRequired[
- "Account.CreateParamsCapabilitiesJcbPayments"
- ]
- """
- The jcb_payments capability.
- """
- jp_bank_transfer_payments: NotRequired[
- "Account.CreateParamsCapabilitiesJpBankTransferPayments"
- ]
- """
- The jp_bank_transfer_payments capability.
- """
- kakao_pay_payments: NotRequired[
- "Account.CreateParamsCapabilitiesKakaoPayPayments"
- ]
- """
- The kakao_pay_payments capability.
- """
- klarna_payments: NotRequired[
- "Account.CreateParamsCapabilitiesKlarnaPayments"
- ]
- """
- The klarna_payments capability.
- """
- konbini_payments: NotRequired[
- "Account.CreateParamsCapabilitiesKonbiniPayments"
- ]
- """
- The konbini_payments capability.
- """
- kr_card_payments: NotRequired[
- "Account.CreateParamsCapabilitiesKrCardPayments"
- ]
- """
- The kr_card_payments capability.
- """
- legacy_payments: NotRequired[
- "Account.CreateParamsCapabilitiesLegacyPayments"
- ]
- """
- The legacy_payments capability.
- """
- link_payments: NotRequired[
- "Account.CreateParamsCapabilitiesLinkPayments"
- ]
- """
- The link_payments capability.
- """
- mb_way_payments: NotRequired[
- "Account.CreateParamsCapabilitiesMbWayPayments"
- ]
- """
- The mb_way_payments capability.
- """
- mobilepay_payments: NotRequired[
- "Account.CreateParamsCapabilitiesMobilepayPayments"
- ]
- """
- The mobilepay_payments capability.
- """
- multibanco_payments: NotRequired[
- "Account.CreateParamsCapabilitiesMultibancoPayments"
- ]
- """
- The multibanco_payments capability.
- """
- mx_bank_transfer_payments: NotRequired[
- "Account.CreateParamsCapabilitiesMxBankTransferPayments"
- ]
- """
- The mx_bank_transfer_payments capability.
- """
- naver_pay_payments: NotRequired[
- "Account.CreateParamsCapabilitiesNaverPayPayments"
- ]
- """
- The naver_pay_payments capability.
- """
- nz_bank_account_becs_debit_payments: NotRequired[
- "Account.CreateParamsCapabilitiesNzBankAccountBecsDebitPayments"
- ]
- """
- The nz_bank_account_becs_debit_payments capability.
- """
- oxxo_payments: NotRequired[
- "Account.CreateParamsCapabilitiesOxxoPayments"
- ]
- """
- The oxxo_payments capability.
- """
- p24_payments: NotRequired[
- "Account.CreateParamsCapabilitiesP24Payments"
- ]
- """
- The p24_payments capability.
- """
- pay_by_bank_payments: NotRequired[
- "Account.CreateParamsCapabilitiesPayByBankPayments"
- ]
- """
- The pay_by_bank_payments capability.
- """
- payco_payments: NotRequired[
- "Account.CreateParamsCapabilitiesPaycoPayments"
- ]
- """
- The payco_payments capability.
- """
- paynow_payments: NotRequired[
- "Account.CreateParamsCapabilitiesPaynowPayments"
- ]
- """
- The paynow_payments capability.
- """
- pix_payments: NotRequired[
- "Account.CreateParamsCapabilitiesPixPayments"
- ]
- """
- The pix_payments capability.
- """
- promptpay_payments: NotRequired[
- "Account.CreateParamsCapabilitiesPromptpayPayments"
- ]
- """
- The promptpay_payments capability.
- """
- revolut_pay_payments: NotRequired[
- "Account.CreateParamsCapabilitiesRevolutPayPayments"
- ]
- """
- The revolut_pay_payments capability.
- """
- samsung_pay_payments: NotRequired[
- "Account.CreateParamsCapabilitiesSamsungPayPayments"
- ]
- """
- The samsung_pay_payments capability.
- """
- satispay_payments: NotRequired[
- "Account.CreateParamsCapabilitiesSatispayPayments"
- ]
- """
- The satispay_payments capability.
- """
- sepa_bank_transfer_payments: NotRequired[
- "Account.CreateParamsCapabilitiesSepaBankTransferPayments"
- ]
- """
- The sepa_bank_transfer_payments capability.
- """
- sepa_debit_payments: NotRequired[
- "Account.CreateParamsCapabilitiesSepaDebitPayments"
- ]
- """
- The sepa_debit_payments capability.
- """
- sofort_payments: NotRequired[
- "Account.CreateParamsCapabilitiesSofortPayments"
- ]
- """
- The sofort_payments capability.
- """
- swish_payments: NotRequired[
- "Account.CreateParamsCapabilitiesSwishPayments"
- ]
- """
- The swish_payments capability.
- """
- tax_reporting_us_1099_k: NotRequired[
- "Account.CreateParamsCapabilitiesTaxReportingUs1099K"
- ]
- """
- The tax_reporting_us_1099_k capability.
- """
- tax_reporting_us_1099_misc: NotRequired[
- "Account.CreateParamsCapabilitiesTaxReportingUs1099Misc"
- ]
- """
- The tax_reporting_us_1099_misc capability.
- """
- transfers: NotRequired["Account.CreateParamsCapabilitiesTransfers"]
- """
- The transfers capability.
- """
- treasury: NotRequired["Account.CreateParamsCapabilitiesTreasury"]
- """
- The treasury capability.
- """
- twint_payments: NotRequired[
- "Account.CreateParamsCapabilitiesTwintPayments"
- ]
- """
- The twint_payments capability.
- """
- us_bank_account_ach_payments: NotRequired[
- "Account.CreateParamsCapabilitiesUsBankAccountAchPayments"
- ]
- """
- The us_bank_account_ach_payments capability.
- """
- us_bank_transfer_payments: NotRequired[
- "Account.CreateParamsCapabilitiesUsBankTransferPayments"
- ]
- """
- The us_bank_transfer_payments capability.
- """
- zip_payments: NotRequired[
- "Account.CreateParamsCapabilitiesZipPayments"
- ]
- """
- The zip_payments capability.
- """
-
- class CreateParamsCapabilitiesAcssDebitPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesAffirmPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesAfterpayClearpayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesAlmaPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesAmazonPayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesAuBecsDebitPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesBacsDebitPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesBancontactPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesBilliePayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesBlikPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesBoletoPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesCardIssuing(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesCardPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesCartesBancairesPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesCashappPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesCryptoPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesEpsPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesFpxPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesGbBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesGiropayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesGrabpayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesIdealPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesIndiaInternationalPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesJcbPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesJpBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesKakaoPayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesKlarnaPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesKonbiniPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesKrCardPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesLegacyPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesLinkPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesMbWayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesMobilepayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesMultibancoPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesMxBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesNaverPayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesNzBankAccountBecsDebitPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesOxxoPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesP24Payments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesPayByBankPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesPaycoPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesPaynowPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesPixPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesPromptpayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesRevolutPayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesSamsungPayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesSatispayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesSepaBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesSepaDebitPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesSofortPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesSwishPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesTaxReportingUs1099K(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesTaxReportingUs1099Misc(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesTransfers(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesTreasury(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesTwintPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesUsBankAccountAchPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesUsBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesZipPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCard(TypedDict):
- object: Literal["card"]
- address_city: NotRequired[str]
- address_country: NotRequired[str]
- address_line1: NotRequired[str]
- address_line2: NotRequired[str]
- address_state: NotRequired[str]
- address_zip: NotRequired[str]
- currency: NotRequired[str]
- cvc: NotRequired[str]
- exp_month: int
- exp_year: int
- name: NotRequired[str]
- number: str
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- """
- default_for_currency: NotRequired[bool]
-
- class CreateParamsCardToken(TypedDict):
- object: Literal["card"]
- currency: NotRequired[str]
- token: str
-
- class CreateParamsCompany(TypedDict):
- address: NotRequired["Account.CreateParamsCompanyAddress"]
- """
- The company's primary address.
- """
- address_kana: NotRequired["Account.CreateParamsCompanyAddressKana"]
- """
- The Kana variation of the company's primary address (Japan only).
- """
- address_kanji: NotRequired["Account.CreateParamsCompanyAddressKanji"]
- """
- The Kanji variation of the company's primary address (Japan only).
- """
- directors_provided: NotRequired[bool]
- """
- Whether the company's directors have been provided. Set this Boolean to `true` after creating all the company's directors with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.director` requirement. This value is not automatically set to `true` after creating directors, so it needs to be updated to indicate all directors have been provided.
- """
- directorship_declaration: NotRequired[
- "Account.CreateParamsCompanyDirectorshipDeclaration"
- ]
- """
- This hash is used to attest that the directors information provided to Stripe is both current and correct.
- """
- executives_provided: NotRequired[bool]
- """
- Whether the company's executives have been provided. Set this Boolean to `true` after creating all the company's executives with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.executive` requirement.
- """
- export_license_id: NotRequired[str]
- """
- The export license ID number of the company, also referred as Import Export Code (India only).
- """
- export_purpose_code: NotRequired[str]
- """
- The purpose code to use for export transactions (India only).
- """
- name: NotRequired[str]
- """
- The company's legal name.
- """
- name_kana: NotRequired[str]
- """
- The Kana variation of the company's legal name (Japan only).
- """
- name_kanji: NotRequired[str]
- """
- The Kanji variation of the company's legal name (Japan only).
- """
- owners_provided: NotRequired[bool]
- """
- Whether the company's owners have been provided. Set this Boolean to `true` after creating all the company's owners with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.owner` requirement.
- """
- ownership_declaration: NotRequired[
- "Account.CreateParamsCompanyOwnershipDeclaration"
- ]
- """
- This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
- """
- ownership_exemption_reason: NotRequired[
- "Literal['']|Literal['qualified_entity_exceeds_ownership_threshold', 'qualifies_as_financial_institution']"
- ]
- """
- This value is used to determine if a business is exempt from providing ultimate beneficial owners. See [this support article](https://support.stripe.com/questions/exemption-from-providing-ownership-details) and [changelog](https://docs.stripe.com/changelog/acacia/2025-01-27/ownership-exemption-reason-accounts-api) for more details.
- """
- phone: NotRequired[str]
- """
- The company's phone number (used for verification).
- """
- registration_date: NotRequired[
- "Literal['']|Account.CreateParamsCompanyRegistrationDate"
- ]
- """
- When the business was incorporated or registered.
- """
- registration_number: NotRequired[str]
- """
- The identification number given to a company when it is registered or incorporated, if distinct from the identification number used for filing taxes. (Examples are the CIN for companies and LLP IN for partnerships in India, and the Company Registration Number in Hong Kong).
- """
- structure: NotRequired[
- "Literal['']|Literal['free_zone_establishment', 'free_zone_llc', 'government_instrumentality', 'governmental_unit', 'incorporated_non_profit', 'incorporated_partnership', 'limited_liability_partnership', 'llc', 'multi_member_llc', 'private_company', 'private_corporation', 'private_partnership', 'public_company', 'public_corporation', 'public_partnership', 'registered_charity', 'single_member_llc', 'sole_establishment', 'sole_proprietorship', 'tax_exempt_government_instrumentality', 'unincorporated_association', 'unincorporated_non_profit', 'unincorporated_partnership']"
- ]
- """
- The category identifying the legal structure of the company or legal entity. See [Business structure](https://docs.stripe.com/connect/identity-verification#business-structure) for more details. Pass an empty string to unset this value.
- """
- tax_id: NotRequired[str]
- """
- The business ID number of the company, as appropriate for the company's country. (Examples are an Employer ID Number in the U.S., a Business Number in Canada, or a Company Number in the UK.)
- """
- tax_id_registrar: NotRequired[str]
- """
- The jurisdiction in which the `tax_id` is registered (Germany-based companies only).
- """
- vat_id: NotRequired[str]
- """
- The VAT number of the company.
- """
- verification: NotRequired["Account.CreateParamsCompanyVerification"]
- """
- Information on the verification state of the company.
- """
-
- class CreateParamsCompanyAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsCompanyAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsCompanyAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsCompanyDirectorshipDeclaration(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the directorship declaration attestation was made.
- """
- ip: NotRequired[str]
- """
- The IP address from which the directorship declaration attestation was made.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the directorship declaration attestation was made.
- """
-
- class CreateParamsCompanyOwnershipDeclaration(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the beneficial owner attestation was made.
- """
- ip: NotRequired[str]
- """
- The IP address from which the beneficial owner attestation was made.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the beneficial owner attestation was made.
- """
-
- class CreateParamsCompanyRegistrationDate(TypedDict):
- day: int
- """
- The day of registration, between 1 and 31.
- """
- month: int
- """
- The month of registration, between 1 and 12.
- """
- year: int
- """
- The four-digit year of registration.
- """
-
- class CreateParamsCompanyVerification(TypedDict):
- document: NotRequired[
- "Account.CreateParamsCompanyVerificationDocument"
- ]
- """
- A document verifying the business.
- """
-
- class CreateParamsCompanyVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsController(TypedDict):
- fees: NotRequired["Account.CreateParamsControllerFees"]
- """
- A hash of configuration for who pays Stripe fees for product usage on this account.
- """
- losses: NotRequired["Account.CreateParamsControllerLosses"]
- """
- A hash of configuration for products that have negative balance liability, and whether Stripe or a Connect application is responsible for them.
- """
- requirement_collection: NotRequired[Literal["application", "stripe"]]
- """
- A value indicating responsibility for collecting updated information when requirements on the account are due or change. Defaults to `stripe`.
- """
- stripe_dashboard: NotRequired[
- "Account.CreateParamsControllerStripeDashboard"
- ]
- """
- A hash of configuration for Stripe-hosted dashboards.
- """
-
- class CreateParamsControllerFees(TypedDict):
- payer: NotRequired[Literal["account", "application"]]
- """
- A value indicating the responsible payer of Stripe fees on this account. Defaults to `account`. Learn more about [fee behavior on connected accounts](https://docs.stripe.com/connect/direct-charges-fee-payer-behavior).
- """
-
- class CreateParamsControllerLosses(TypedDict):
- payments: NotRequired[Literal["application", "stripe"]]
- """
- A value indicating who is liable when this account can't pay back negative balances resulting from payments. Defaults to `stripe`.
- """
-
- class CreateParamsControllerStripeDashboard(TypedDict):
- type: NotRequired[Literal["express", "full", "none"]]
- """
- Whether this account should have access to the full Stripe Dashboard (`full`), to the Express Dashboard (`express`), or to no Stripe-hosted dashboard (`none`). Defaults to `full`.
- """
-
- class CreateParamsDocuments(TypedDict):
- bank_account_ownership_verification: NotRequired[
- "Account.CreateParamsDocumentsBankAccountOwnershipVerification"
- ]
- """
- One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the account's primary active bank account that displays the last 4 digits of the account number, either a statement or a check.
- """
- company_license: NotRequired[
- "Account.CreateParamsDocumentsCompanyLicense"
- ]
- """
- One or more documents that demonstrate proof of a company's license to operate.
- """
- company_memorandum_of_association: NotRequired[
- "Account.CreateParamsDocumentsCompanyMemorandumOfAssociation"
- ]
- """
- One or more documents showing the company's Memorandum of Association.
- """
- company_ministerial_decree: NotRequired[
- "Account.CreateParamsDocumentsCompanyMinisterialDecree"
- ]
- """
- (Certain countries only) One or more documents showing the ministerial decree legalizing the company's establishment.
- """
- company_registration_verification: NotRequired[
- "Account.CreateParamsDocumentsCompanyRegistrationVerification"
- ]
- """
- One or more documents that demonstrate proof of a company's registration with the appropriate local authorities.
- """
- company_tax_id_verification: NotRequired[
- "Account.CreateParamsDocumentsCompanyTaxIdVerification"
- ]
- """
- One or more documents that demonstrate proof of a company's tax ID.
- """
- proof_of_address: NotRequired[
- "Account.CreateParamsDocumentsProofOfAddress"
- ]
- """
- One or more documents that demonstrate proof of address.
- """
- proof_of_registration: NotRequired[
- "Account.CreateParamsDocumentsProofOfRegistration"
- ]
- """
- One or more documents showing the company's proof of registration with the national business registry.
- """
- proof_of_ultimate_beneficial_ownership: NotRequired[
- "Account.CreateParamsDocumentsProofOfUltimateBeneficialOwnership"
- ]
- """
- One or more documents that demonstrate proof of ultimate beneficial ownership.
- """
-
- class CreateParamsDocumentsBankAccountOwnershipVerification(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsCompanyLicense(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsCompanyMemorandumOfAssociation(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsCompanyMinisterialDecree(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsCompanyRegistrationVerification(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsCompanyTaxIdVerification(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsProofOfAddress(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsProofOfRegistration(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsProofOfUltimateBeneficialOwnership(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsGroups(TypedDict):
- payments_pricing: NotRequired["Literal['']|str"]
- """
- The group the account is in to determine their payments pricing, and null if the account is on customized pricing. [See the Platform pricing tool documentation](https://stripe.com/docs/connect/platform-pricing-tools) for details.
- """
-
- class CreateParamsIndividual(TypedDict):
- address: NotRequired["Account.CreateParamsIndividualAddress"]
- """
- The individual's primary address.
- """
- address_kana: NotRequired["Account.CreateParamsIndividualAddressKana"]
- """
- The Kana variation of the individual's primary address (Japan only).
- """
- address_kanji: NotRequired[
- "Account.CreateParamsIndividualAddressKanji"
- ]
- """
- The Kanji variation of the individual's primary address (Japan only).
- """
- dob: NotRequired["Literal['']|Account.CreateParamsIndividualDob"]
- """
- The individual's date of birth.
- """
- email: NotRequired[str]
- """
- The individual's email address.
- """
- first_name: NotRequired[str]
- """
- The individual's first name.
- """
- first_name_kana: NotRequired[str]
- """
- The Kana variation of the individual's first name (Japan only).
- """
- first_name_kanji: NotRequired[str]
- """
- The Kanji variation of the individual's first name (Japan only).
- """
- full_name_aliases: NotRequired["Literal['']|List[str]"]
- """
- A list of alternate names or aliases that the individual is known by.
- """
- gender: NotRequired[str]
- """
- The individual's gender
- """
- id_number: NotRequired[str]
- """
- The government-issued ID number of the individual, as appropriate for the representative's country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in Canada). Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- id_number_secondary: NotRequired[str]
- """
- The government-issued secondary ID number of the individual, as appropriate for the representative's country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- last_name: NotRequired[str]
- """
- The individual's last name.
- """
- last_name_kana: NotRequired[str]
- """
- The Kana variation of the individual's last name (Japan only).
- """
- last_name_kanji: NotRequired[str]
- """
- The Kanji variation of the individual's last name (Japan only).
- """
- maiden_name: NotRequired[str]
- """
- The individual's maiden name.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- phone: NotRequired[str]
- """
- The individual's phone number.
- """
- political_exposure: NotRequired[Literal["existing", "none"]]
- """
- Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
- """
- registered_address: NotRequired[
- "Account.CreateParamsIndividualRegisteredAddress"
- ]
- """
- The individual's registered address.
- """
- relationship: NotRequired["Account.CreateParamsIndividualRelationship"]
- """
- Describes the person's relationship to the account.
- """
- ssn_last_4: NotRequired[str]
- """
- The last four digits of the individual's Social Security Number (U.S. only).
- """
- verification: NotRequired["Account.CreateParamsIndividualVerification"]
- """
- The individual's verification document information.
- """
-
- class CreateParamsIndividualAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsIndividualAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsIndividualAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsIndividualDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsIndividualRegisteredAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsIndividualRelationship(TypedDict):
- director: NotRequired[bool]
- """
- Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
- """
- executive: NotRequired[bool]
- """
- Whether the person has significant responsibility to control, manage, or direct the organization.
- """
- owner: NotRequired[bool]
- """
- Whether the person is an owner of the account's legal entity.
- """
- percent_ownership: NotRequired["Literal['']|float"]
- """
- The percent owned by the person of the account's legal entity.
- """
- title: NotRequired[str]
- """
- The person's title (e.g., CEO, Support Engineer).
- """
-
- class CreateParamsIndividualVerification(TypedDict):
- additional_document: NotRequired[
- "Account.CreateParamsIndividualVerificationAdditionalDocument"
- ]
- """
- A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
- """
- document: NotRequired[
- "Account.CreateParamsIndividualVerificationDocument"
- ]
- """
- An identifying document, either a passport or local ID card.
- """
-
- class CreateParamsIndividualVerificationAdditionalDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsIndividualVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsSettings(TypedDict):
- bacs_debit_payments: NotRequired[
- "Account.CreateParamsSettingsBacsDebitPayments"
- ]
- """
- Settings specific to Bacs Direct Debit.
- """
- branding: NotRequired["Account.CreateParamsSettingsBranding"]
- """
- Settings used to apply the account's branding to email receipts, invoices, Checkout, and other products.
- """
- card_issuing: NotRequired["Account.CreateParamsSettingsCardIssuing"]
- """
- Settings specific to the account's use of the Card Issuing product.
- """
- card_payments: NotRequired["Account.CreateParamsSettingsCardPayments"]
- """
- Settings specific to card charging on the account.
- """
- invoices: NotRequired["Account.CreateParamsSettingsInvoices"]
- """
- Settings specific to the account's use of Invoices.
- """
- payments: NotRequired["Account.CreateParamsSettingsPayments"]
- """
- Settings that apply across payment methods for charging on the account.
- """
- payouts: NotRequired["Account.CreateParamsSettingsPayouts"]
- """
- Settings specific to the account's payouts.
- """
- treasury: NotRequired["Account.CreateParamsSettingsTreasury"]
- """
- Settings specific to the account's Treasury FinancialAccounts.
- """
-
- class CreateParamsSettingsBacsDebitPayments(TypedDict):
- display_name: NotRequired[str]
- """
- The Bacs Direct Debit Display Name for this account. For payments made with Bacs Direct Debit, this name appears on the mandate as the statement descriptor. Mobile banking apps display it as the name of the business. To use custom branding, set the Bacs Direct Debit Display Name during or right after creation. Custom branding incurs an additional monthly fee for the platform. If you don't set the display name before requesting Bacs capability, it's automatically set as "Stripe" and the account is onboarded to Stripe branding, which is free.
- """
-
- class CreateParamsSettingsBranding(TypedDict):
- icon: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) An icon for the account. Must be square and at least 128px x 128px.
- """
- logo: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A logo for the account that will be used in Checkout instead of the icon and without the account's name next to it if provided. Must be at least 128px x 128px.
- """
- primary_color: NotRequired[str]
- """
- A CSS hex color value representing the primary branding color for this account.
- """
- secondary_color: NotRequired[str]
- """
- A CSS hex color value representing the secondary branding color for this account.
- """
-
- class CreateParamsSettingsCardIssuing(TypedDict):
- tos_acceptance: NotRequired[
- "Account.CreateParamsSettingsCardIssuingTosAcceptance"
- ]
- """
- Details on the account's acceptance of the [Stripe Issuing Terms and Disclosures](https://docs.stripe.com/issuing/connect/tos_acceptance).
- """
-
- class CreateParamsSettingsCardIssuingTosAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the account representative accepted the service agreement.
- """
- ip: NotRequired[str]
- """
- The IP address from which the account representative accepted the service agreement.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the account representative accepted the service agreement.
- """
-
- class CreateParamsSettingsCardPayments(TypedDict):
- decline_on: NotRequired[
- "Account.CreateParamsSettingsCardPaymentsDeclineOn"
- ]
- """
- Automatically declines certain charge types regardless of whether the card issuer accepted or declined the charge.
- """
- statement_descriptor_prefix: NotRequired[str]
- """
- The default text that appears on credit card statements when a charge is made. This field prefixes any dynamic `statement_descriptor` specified on the charge. `statement_descriptor_prefix` is useful for maximizing descriptor space for the dynamic portion.
- """
- statement_descriptor_prefix_kana: NotRequired["Literal['']|str"]
- """
- The Kana variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kana` specified on the charge. `statement_descriptor_prefix_kana` is useful for maximizing descriptor space for the dynamic portion.
- """
- statement_descriptor_prefix_kanji: NotRequired["Literal['']|str"]
- """
- The Kanji variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kanji` specified on the charge. `statement_descriptor_prefix_kanji` is useful for maximizing descriptor space for the dynamic portion.
- """
-
- class CreateParamsSettingsCardPaymentsDeclineOn(TypedDict):
- avs_failure: NotRequired[bool]
- """
- Whether Stripe automatically declines charges with an incorrect ZIP or postal code. This setting only applies when a ZIP or postal code is provided and they fail bank verification.
- """
- cvc_failure: NotRequired[bool]
- """
- Whether Stripe automatically declines charges with an incorrect CVC. This setting only applies when a CVC is provided and it fails bank verification.
- """
-
- class CreateParamsSettingsInvoices(TypedDict):
- hosted_payment_method_save: NotRequired[
- Literal["always", "never", "offer"]
- ]
- """
- Whether payment methods should be saved when a payment is completed for a one-time invoices on a hosted invoice page.
- """
-
- class CreateParamsSettingsPayments(TypedDict):
- statement_descriptor: NotRequired[str]
- """
- The default text that appears on statements for non-card charges outside of Japan. For card charges, if you don't set a `statement_descriptor_prefix`, this text is also used as the statement descriptor prefix. In that case, if concatenating the statement descriptor suffix causes the combined statement descriptor to exceed 22 characters, we truncate the `statement_descriptor` text to limit the full descriptor to 22 characters. For more information about statement descriptors and their requirements, see the [account settings documentation](https://docs.stripe.com/get-started/account/statement-descriptors).
- """
- statement_descriptor_kana: NotRequired[str]
- """
- The Kana variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
- """
- statement_descriptor_kanji: NotRequired[str]
- """
- The Kanji variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
- """
-
- class CreateParamsSettingsPayouts(TypedDict):
- debit_negative_balances: NotRequired[bool]
- """
- A Boolean indicating whether Stripe should try to reclaim negative balances from an attached bank account. For details, see [Understanding Connect Account Balances](https://docs.stripe.com/connect/account-balances).
- """
- schedule: NotRequired["Account.CreateParamsSettingsPayoutsSchedule"]
- """
- Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](https://docs.stripe.com/connect/bank-transfers#payout-information) documentation.
- """
- statement_descriptor: NotRequired[str]
- """
- The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
- """
-
- class CreateParamsSettingsPayoutsSchedule(TypedDict):
- delay_days: NotRequired["Literal['minimum']|int"]
- """
- The number of days charge funds are held before being paid out. May also be set to `minimum`, representing the lowest available value for the account country. Default is `minimum`. The `delay_days` parameter remains at the last configured value if `interval` is `manual`. [Learn more about controlling payout delay days](https://docs.stripe.com/connect/manage-payout-schedule).
- """
- interval: NotRequired[Literal["daily", "manual", "monthly", "weekly"]]
- """
- How frequently available funds are paid out. One of: `daily`, `manual`, `weekly`, or `monthly`. Default is `daily`.
- """
- monthly_anchor: NotRequired[int]
- """
- The day of the month when available funds are paid out, specified as a number between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly`.
- """
- monthly_payout_days: NotRequired[List[int]]
- """
- The days of the month when available funds are paid out, specified as an array of numbers between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly` and `monthly_anchor` is not set.
- """
- weekly_anchor: NotRequired[
- Literal[
- "friday",
- "monday",
- "saturday",
- "sunday",
- "thursday",
- "tuesday",
- "wednesday",
- ]
- ]
- """
- The day of the week when available funds are paid out, specified as `monday`, `tuesday`, etc. Required and applicable only if `interval` is `weekly`.
- """
- weekly_payout_days: NotRequired[
- List[
- Literal["friday", "monday", "thursday", "tuesday", "wednesday"]
- ]
- ]
- """
- The days of the week when available funds are paid out, specified as an array, e.g., [`monday`, `tuesday`]. Required and applicable only if `interval` is `weekly`.
- """
-
- class CreateParamsSettingsTreasury(TypedDict):
- tos_acceptance: NotRequired[
- "Account.CreateParamsSettingsTreasuryTosAcceptance"
- ]
- """
- Details on the account's acceptance of the Stripe Treasury Services Agreement.
- """
-
- class CreateParamsSettingsTreasuryTosAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the account representative accepted the service agreement.
- """
- ip: NotRequired[str]
- """
- The IP address from which the account representative accepted the service agreement.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the account representative accepted the service agreement.
- """
-
- class CreateParamsTosAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the account representative accepted their service agreement.
- """
- ip: NotRequired[str]
- """
- The IP address from which the account representative accepted their service agreement.
- """
- service_agreement: NotRequired[str]
- """
- The user's service agreement type.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the account representative accepted their service agreement.
- """
-
- class CreatePersonParams(RequestOptions):
- additional_tos_acceptances: NotRequired[
- "Account.CreatePersonParamsAdditionalTosAcceptances"
- ]
- """
- Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.
- """
- address: NotRequired["Account.CreatePersonParamsAddress"]
- """
- The person's address.
- """
- address_kana: NotRequired["Account.CreatePersonParamsAddressKana"]
- """
- The Kana variation of the person's address (Japan only).
- """
- address_kanji: NotRequired["Account.CreatePersonParamsAddressKanji"]
- """
- The Kanji variation of the person's address (Japan only).
- """
- dob: NotRequired["Literal['']|Account.CreatePersonParamsDob"]
- """
- The person's date of birth.
- """
- documents: NotRequired["Account.CreatePersonParamsDocuments"]
- """
- Documents that may be submitted to satisfy various informational requests.
- """
- email: NotRequired[str]
- """
- The person's email address.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- first_name: NotRequired[str]
- """
- The person's first name.
- """
- first_name_kana: NotRequired[str]
- """
- The Kana variation of the person's first name (Japan only).
- """
- first_name_kanji: NotRequired[str]
- """
- The Kanji variation of the person's first name (Japan only).
- """
- full_name_aliases: NotRequired["Literal['']|List[str]"]
- """
- A list of alternate names or aliases that the person is known by.
- """
- gender: NotRequired[str]
- """
- The person's gender (International regulations require either "male" or "female").
- """
- id_number: NotRequired[str]
- """
- The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- id_number_secondary: NotRequired[str]
- """
- The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- last_name: NotRequired[str]
- """
- The person's last name.
- """
- last_name_kana: NotRequired[str]
- """
- The Kana variation of the person's last name (Japan only).
- """
- last_name_kanji: NotRequired[str]
- """
- The Kanji variation of the person's last name (Japan only).
- """
- maiden_name: NotRequired[str]
- """
- The person's maiden name.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nationality: NotRequired[str]
- """
- The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or "XX" if unavailable.
- """
- person_token: NotRequired[str]
- """
- A [person token](https://docs.stripe.com/connect/account-tokens), used to securely provide details to the person.
- """
- phone: NotRequired[str]
- """
- The person's phone number.
- """
- political_exposure: NotRequired[Literal["existing", "none"]]
- """
- Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
- """
- registered_address: NotRequired[
- "Account.CreatePersonParamsRegisteredAddress"
- ]
- """
- The person's registered address.
- """
- relationship: NotRequired["Account.CreatePersonParamsRelationship"]
- """
- The relationship that this person has with the account's legal entity.
- """
- ssn_last_4: NotRequired[str]
- """
- The last four digits of the person's Social Security number (U.S. only).
- """
- us_cfpb_data: NotRequired["Account.CreatePersonParamsUsCfpbData"]
- """
- Demographic data related to the person.
- """
- verification: NotRequired["Account.CreatePersonParamsVerification"]
- """
- The person's verification status.
- """
-
- class CreatePersonParamsAdditionalTosAcceptances(TypedDict):
- account: NotRequired[
- "Account.CreatePersonParamsAdditionalTosAcceptancesAccount"
- ]
- """
- Details on the legal guardian's acceptance of the main Stripe service agreement.
- """
-
- class CreatePersonParamsAdditionalTosAcceptancesAccount(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the account representative accepted the service agreement.
- """
- ip: NotRequired[str]
- """
- The IP address from which the account representative accepted the service agreement.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the account representative accepted the service agreement.
- """
-
- class CreatePersonParamsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreatePersonParamsAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreatePersonParamsAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreatePersonParamsDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreatePersonParamsDocuments(TypedDict):
- company_authorization: NotRequired[
- "Account.CreatePersonParamsDocumentsCompanyAuthorization"
- ]
- """
- One or more documents that demonstrate proof that this person is authorized to represent the company.
- """
- passport: NotRequired["Account.CreatePersonParamsDocumentsPassport"]
- """
- One or more documents showing the person's passport page with photo and personal data.
- """
- visa: NotRequired["Account.CreatePersonParamsDocumentsVisa"]
- """
- One or more documents showing the person's visa required for living in the country where they are residing.
- """
-
- class CreatePersonParamsDocumentsCompanyAuthorization(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreatePersonParamsDocumentsPassport(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreatePersonParamsDocumentsVisa(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreatePersonParamsRegisteredAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreatePersonParamsRelationship(TypedDict):
- authorizer: NotRequired[bool]
- """
- Whether the person is the authorizer of the account's representative.
- """
- director: NotRequired[bool]
- """
- Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
- """
- executive: NotRequired[bool]
- """
- Whether the person has significant responsibility to control, manage, or direct the organization.
- """
- legal_guardian: NotRequired[bool]
- """
- Whether the person is the legal guardian of the account's representative.
- """
- owner: NotRequired[bool]
- """
- Whether the person is an owner of the account's legal entity.
- """
- percent_ownership: NotRequired["Literal['']|float"]
- """
- The percent owned by the person of the account's legal entity.
- """
- representative: NotRequired[bool]
- """
- Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
- """
- title: NotRequired[str]
- """
- The person's title (e.g., CEO, Support Engineer).
- """
-
- class CreatePersonParamsUsCfpbData(TypedDict):
- ethnicity_details: NotRequired[
- "Account.CreatePersonParamsUsCfpbDataEthnicityDetails"
- ]
- """
- The persons ethnicity details
- """
- race_details: NotRequired[
- "Account.CreatePersonParamsUsCfpbDataRaceDetails"
- ]
- """
- The persons race details
- """
- self_identified_gender: NotRequired[str]
- """
- The persons self-identified gender
- """
-
- class CreatePersonParamsUsCfpbDataEthnicityDetails(TypedDict):
- ethnicity: NotRequired[
- List[
- Literal[
- "cuban",
- "hispanic_or_latino",
- "mexican",
- "not_hispanic_or_latino",
- "other_hispanic_or_latino",
- "prefer_not_to_answer",
- "puerto_rican",
- ]
- ]
- ]
- """
- The persons ethnicity
- """
- ethnicity_other: NotRequired[str]
- """
- Please specify your origin, when other is selected.
- """
-
- class CreatePersonParamsUsCfpbDataRaceDetails(TypedDict):
- race: NotRequired[
- List[
- Literal[
- "african_american",
- "american_indian_or_alaska_native",
- "asian",
- "asian_indian",
- "black_or_african_american",
- "chinese",
- "ethiopian",
- "filipino",
- "guamanian_or_chamorro",
- "haitian",
- "jamaican",
- "japanese",
- "korean",
- "native_hawaiian",
- "native_hawaiian_or_other_pacific_islander",
- "nigerian",
- "other_asian",
- "other_black_or_african_american",
- "other_pacific_islander",
- "prefer_not_to_answer",
- "samoan",
- "somali",
- "vietnamese",
- "white",
- ]
- ]
- ]
- """
- The persons race.
- """
- race_other: NotRequired[str]
- """
- Please specify your race, when other is selected.
- """
-
- class CreatePersonParamsVerification(TypedDict):
- additional_document: NotRequired[
- "Account.CreatePersonParamsVerificationAdditionalDocument"
- ]
- """
- A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
- """
- document: NotRequired["Account.CreatePersonParamsVerificationDocument"]
- """
- An identifying document, either a passport or local ID card.
- """
-
- class CreatePersonParamsVerificationAdditionalDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreatePersonParamsVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class DeleteExternalAccountParams(RequestOptions):
- pass
-
- class DeleteParams(RequestOptions):
- pass
-
- class DeletePersonParams(RequestOptions):
- pass
-
- class ListCapabilitiesParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListExternalAccountsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- object: NotRequired[Literal["bank_account", "card"]]
- """
- Filter external accounts according to a particular object type.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["Account.ListParamsCreated|int"]
- """
- Only return connected accounts that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListPersonsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- relationship: NotRequired["Account.ListPersonsParamsRelationship"]
- """
- Filters on the list of people returned based on the person's relationship to the account's company.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListPersonsParamsRelationship(TypedDict):
- authorizer: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are authorizers of the account's representative.
- """
- director: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are directors of the account's company.
- """
- executive: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are executives of the account's company.
- """
- legal_guardian: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are legal guardians of the account's representative.
- """
- owner: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are owners of the account's company.
- """
- representative: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are the representative of the account's company.
- """
-
- class ModifyCapabilityParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- requested: NotRequired[bool]
- """
- 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. Some capabilities are permanent after they've been requested. Attempting to remove a permanent capability returns an error.
- """
-
- class ModifyExternalAccountParams(RequestOptions):
- account_holder_name: NotRequired[str]
- """
- The name of the person or business that owns the bank account.
- """
- account_holder_type: NotRequired[
- "Literal['']|Literal['company', 'individual']"
- ]
- """
- The type of entity that holds the account. This can be either `individual` or `company`.
- """
- account_type: NotRequired[
- Literal["checking", "futsu", "savings", "toza"]
- ]
- """
- The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`.
- """
- address_city: NotRequired[str]
- """
- City/District/Suburb/Town/Village.
- """
- address_country: NotRequired[str]
- """
- Billing address country, if provided when creating card.
- """
- address_line1: NotRequired[str]
- """
- Address line 1 (Street address/PO Box/Company name).
- """
- address_line2: NotRequired[str]
- """
- Address line 2 (Apartment/Suite/Unit/Building).
- """
- address_state: NotRequired[str]
- """
- State/County/Province/Region.
- """
- address_zip: NotRequired[str]
- """
- ZIP or postal code.
- """
- default_for_currency: NotRequired[bool]
- """
- When set to true, this becomes the default external account for its currency.
- """
- documents: NotRequired["Account.ModifyExternalAccountParamsDocuments"]
- """
- Documents that may be submitted to satisfy various informational requests.
- """
- exp_month: NotRequired[str]
- """
- Two digit number representing the card's expiration month.
- """
- exp_year: NotRequired[str]
- """
- Four digit number representing the card's expiration year.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- Cardholder name.
- """
-
- class ModifyExternalAccountParamsDocuments(TypedDict):
- bank_account_ownership_verification: NotRequired[
- "Account.ModifyExternalAccountParamsDocumentsBankAccountOwnershipVerification"
- ]
- """
- One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the bank account that displays the last 4 digits of the account number, either a statement or a check.
- """
-
- class ModifyExternalAccountParamsDocumentsBankAccountOwnershipVerification(
- TypedDict,
- ):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class ModifyPersonParams(RequestOptions):
- additional_tos_acceptances: NotRequired[
- "Account.ModifyPersonParamsAdditionalTosAcceptances"
- ]
- """
- Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.
- """
- address: NotRequired["Account.ModifyPersonParamsAddress"]
- """
- The person's address.
- """
- address_kana: NotRequired["Account.ModifyPersonParamsAddressKana"]
- """
- The Kana variation of the person's address (Japan only).
- """
- address_kanji: NotRequired["Account.ModifyPersonParamsAddressKanji"]
- """
- The Kanji variation of the person's address (Japan only).
- """
- dob: NotRequired["Literal['']|Account.ModifyPersonParamsDob"]
- """
- The person's date of birth.
- """
- documents: NotRequired["Account.ModifyPersonParamsDocuments"]
- """
- Documents that may be submitted to satisfy various informational requests.
- """
- email: NotRequired[str]
- """
- The person's email address.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- first_name: NotRequired[str]
- """
- The person's first name.
- """
- first_name_kana: NotRequired[str]
- """
- The Kana variation of the person's first name (Japan only).
- """
- first_name_kanji: NotRequired[str]
- """
- The Kanji variation of the person's first name (Japan only).
- """
- full_name_aliases: NotRequired["Literal['']|List[str]"]
- """
- A list of alternate names or aliases that the person is known by.
- """
- gender: NotRequired[str]
- """
- The person's gender (International regulations require either "male" or "female").
- """
- id_number: NotRequired[str]
- """
- The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- id_number_secondary: NotRequired[str]
- """
- The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- last_name: NotRequired[str]
- """
- The person's last name.
- """
- last_name_kana: NotRequired[str]
- """
- The Kana variation of the person's last name (Japan only).
- """
- last_name_kanji: NotRequired[str]
- """
- The Kanji variation of the person's last name (Japan only).
- """
- maiden_name: NotRequired[str]
- """
- The person's maiden name.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nationality: NotRequired[str]
- """
- The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or "XX" if unavailable.
- """
- person_token: NotRequired[str]
- """
- A [person token](https://docs.stripe.com/connect/account-tokens), used to securely provide details to the person.
- """
- phone: NotRequired[str]
- """
- The person's phone number.
- """
- political_exposure: NotRequired[Literal["existing", "none"]]
- """
- Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
- """
- registered_address: NotRequired[
- "Account.ModifyPersonParamsRegisteredAddress"
- ]
- """
- The person's registered address.
- """
- relationship: NotRequired["Account.ModifyPersonParamsRelationship"]
- """
- The relationship that this person has with the account's legal entity.
- """
- ssn_last_4: NotRequired[str]
- """
- The last four digits of the person's Social Security number (U.S. only).
- """
- us_cfpb_data: NotRequired["Account.ModifyPersonParamsUsCfpbData"]
- """
- Demographic data related to the person.
- """
- verification: NotRequired["Account.ModifyPersonParamsVerification"]
- """
- The person's verification status.
- """
-
- class ModifyPersonParamsAdditionalTosAcceptances(TypedDict):
- account: NotRequired[
- "Account.ModifyPersonParamsAdditionalTosAcceptancesAccount"
- ]
- """
- Details on the legal guardian's acceptance of the main Stripe service agreement.
- """
-
- class ModifyPersonParamsAdditionalTosAcceptancesAccount(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the account representative accepted the service agreement.
- """
- ip: NotRequired[str]
- """
- The IP address from which the account representative accepted the service agreement.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the account representative accepted the service agreement.
- """
-
- class ModifyPersonParamsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ModifyPersonParamsAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class ModifyPersonParamsAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class ModifyPersonParamsDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class ModifyPersonParamsDocuments(TypedDict):
- company_authorization: NotRequired[
- "Account.ModifyPersonParamsDocumentsCompanyAuthorization"
- ]
- """
- One or more documents that demonstrate proof that this person is authorized to represent the company.
- """
- passport: NotRequired["Account.ModifyPersonParamsDocumentsPassport"]
- """
- One or more documents showing the person's passport page with photo and personal data.
- """
- visa: NotRequired["Account.ModifyPersonParamsDocumentsVisa"]
- """
- One or more documents showing the person's visa required for living in the country where they are residing.
- """
-
- class ModifyPersonParamsDocumentsCompanyAuthorization(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class ModifyPersonParamsDocumentsPassport(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class ModifyPersonParamsDocumentsVisa(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class ModifyPersonParamsRegisteredAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ModifyPersonParamsRelationship(TypedDict):
- authorizer: NotRequired[bool]
- """
- Whether the person is the authorizer of the account's representative.
- """
- director: NotRequired[bool]
- """
- Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
- """
- executive: NotRequired[bool]
- """
- Whether the person has significant responsibility to control, manage, or direct the organization.
- """
- legal_guardian: NotRequired[bool]
- """
- Whether the person is the legal guardian of the account's representative.
- """
- owner: NotRequired[bool]
- """
- Whether the person is an owner of the account's legal entity.
- """
- percent_ownership: NotRequired["Literal['']|float"]
- """
- The percent owned by the person of the account's legal entity.
- """
- representative: NotRequired[bool]
- """
- Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
- """
- title: NotRequired[str]
- """
- The person's title (e.g., CEO, Support Engineer).
- """
-
- class ModifyPersonParamsUsCfpbData(TypedDict):
- ethnicity_details: NotRequired[
- "Account.ModifyPersonParamsUsCfpbDataEthnicityDetails"
- ]
- """
- The persons ethnicity details
- """
- race_details: NotRequired[
- "Account.ModifyPersonParamsUsCfpbDataRaceDetails"
- ]
- """
- The persons race details
- """
- self_identified_gender: NotRequired[str]
- """
- The persons self-identified gender
- """
-
- class ModifyPersonParamsUsCfpbDataEthnicityDetails(TypedDict):
- ethnicity: NotRequired[
- List[
- Literal[
- "cuban",
- "hispanic_or_latino",
- "mexican",
- "not_hispanic_or_latino",
- "other_hispanic_or_latino",
- "prefer_not_to_answer",
- "puerto_rican",
- ]
- ]
- ]
- """
- The persons ethnicity
- """
- ethnicity_other: NotRequired[str]
- """
- Please specify your origin, when other is selected.
- """
-
- class ModifyPersonParamsUsCfpbDataRaceDetails(TypedDict):
- race: NotRequired[
- List[
- Literal[
- "african_american",
- "american_indian_or_alaska_native",
- "asian",
- "asian_indian",
- "black_or_african_american",
- "chinese",
- "ethiopian",
- "filipino",
- "guamanian_or_chamorro",
- "haitian",
- "jamaican",
- "japanese",
- "korean",
- "native_hawaiian",
- "native_hawaiian_or_other_pacific_islander",
- "nigerian",
- "other_asian",
- "other_black_or_african_american",
- "other_pacific_islander",
- "prefer_not_to_answer",
- "samoan",
- "somali",
- "vietnamese",
- "white",
- ]
- ]
- ]
- """
- The persons race.
- """
- race_other: NotRequired[str]
- """
- Please specify your race, when other is selected.
- """
-
- class ModifyPersonParamsVerification(TypedDict):
- additional_document: NotRequired[
- "Account.ModifyPersonParamsVerificationAdditionalDocument"
- ]
- """
- A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
- """
- document: NotRequired["Account.ModifyPersonParamsVerificationDocument"]
- """
- An identifying document, either a passport or local ID card.
- """
-
- class ModifyPersonParamsVerificationAdditionalDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class ModifyPersonParamsVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class PersonsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- relationship: NotRequired["Account.PersonsParamsRelationship"]
- """
- Filters on the list of people returned based on the person's relationship to the account's company.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class PersonsParamsRelationship(TypedDict):
- authorizer: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are authorizers of the account's representative.
- """
- director: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are directors of the account's company.
- """
- executive: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are executives of the account's company.
- """
- legal_guardian: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are legal guardians of the account's representative.
- """
- owner: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are owners of the account's company.
- """
- representative: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are the representative of the account's company.
- """
-
- class RejectParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- reason: str
- """
- The reason for rejecting the account. Can be `fraud`, `terms_of_service`, or `other`.
- """
-
- class RetrieveCapabilityParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveExternalAccountParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrievePersonParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
business_profile: Optional[BusinessProfile]
"""
Business information about the account.
@@ -4590,7 +1472,7 @@ class RetrievePersonParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["Account.CreateParams"]) -> "Account":
+ def create(cls, **params: Unpack["AccountCreateParams"]) -> "Account":
"""
With [Connect](https://docs.stripe.com/docs/connect), you can create Stripe accounts for your users.
To do this, you'll first need to [register your platform](https://dashboard.stripe.com/account/applications/settings).
@@ -4610,7 +1492,7 @@ def create(cls, **params: Unpack["Account.CreateParams"]) -> "Account":
@classmethod
async def create_async(
- cls, **params: Unpack["Account.CreateParams"]
+ cls, **params: Unpack["AccountCreateParams"]
) -> "Account":
"""
With [Connect](https://docs.stripe.com/docs/connect), you can create Stripe accounts for your users.
@@ -4631,7 +1513,7 @@ async def create_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["Account.DeleteParams"]
+ cls, sid: str, **params: Unpack["AccountDeleteParams"]
) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can delete accounts you manage.
@@ -4654,9 +1536,7 @@ def _cls_delete(
@overload
@staticmethod
- def delete(
- sid: str, **params: Unpack["Account.DeleteParams"]
- ) -> "Account":
+ def delete(sid: str, **params: Unpack["AccountDeleteParams"]) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can delete accounts you manage.
@@ -4669,7 +1549,7 @@ def delete(
...
@overload
- def delete(self, **params: Unpack["Account.DeleteParams"]) -> "Account":
+ def delete(self, **params: Unpack["AccountDeleteParams"]) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can delete accounts you manage.
@@ -4683,7 +1563,7 @@ def delete(self, **params: Unpack["Account.DeleteParams"]) -> "Account":
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.DeleteParams"]
+ self, **params: Unpack["AccountDeleteParams"]
) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can delete accounts you manage.
@@ -4702,7 +1582,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["Account.DeleteParams"]
+ cls, sid: str, **params: Unpack["AccountDeleteParams"]
) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can delete accounts you manage.
@@ -4726,7 +1606,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["Account.DeleteParams"]
+ sid: str, **params: Unpack["AccountDeleteParams"]
) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can delete accounts you manage.
@@ -4741,7 +1621,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["Account.DeleteParams"]
+ self, **params: Unpack["AccountDeleteParams"]
) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can delete accounts you manage.
@@ -4756,7 +1636,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.DeleteParams"]
+ self, **params: Unpack["AccountDeleteParams"]
) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can delete accounts you manage.
@@ -4775,7 +1655,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["Account.ListParams"]
+ cls, **params: Unpack["AccountListParams"]
) -> ListObject["Account"]:
"""
Returns a list of accounts connected to your platform via [Connect](https://docs.stripe.com/docs/connect). If you're not a platform, the list is empty.
@@ -4795,7 +1675,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Account.ListParams"]
+ cls, **params: Unpack["AccountListParams"]
) -> ListObject["Account"]:
"""
Returns a list of accounts connected to your platform via [Connect](https://docs.stripe.com/docs/connect). If you're not a platform, the list is empty.
@@ -4815,7 +1695,7 @@ async def list_async(
@classmethod
def _cls_persons(
- cls, account: str, **params: Unpack["Account.PersonsParams"]
+ 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.
@@ -4834,7 +1714,7 @@ def _cls_persons(
@overload
@staticmethod
def persons(
- account: str, **params: Unpack["Account.PersonsParams"]
+ 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.
@@ -4843,7 +1723,7 @@ def persons(
@overload
def persons(
- self, **params: Unpack["Account.PersonsParams"]
+ self, **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.
@@ -4852,7 +1732,7 @@ def persons(
@class_method_variant("_cls_persons")
def persons( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.PersonsParams"]
+ self, **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.
@@ -4870,7 +1750,7 @@ def persons( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_persons_async(
- cls, account: str, **params: Unpack["Account.PersonsParams"]
+ 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.
@@ -4889,7 +1769,7 @@ async def _cls_persons_async(
@overload
@staticmethod
async def persons_async(
- account: str, **params: Unpack["Account.PersonsParams"]
+ 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.
@@ -4898,7 +1778,7 @@ async def persons_async(
@overload
async def persons_async(
- self, **params: Unpack["Account.PersonsParams"]
+ self, **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.
@@ -4907,7 +1787,7 @@ async def persons_async(
@class_method_variant("_cls_persons_async")
async def persons_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.PersonsParams"]
+ self, **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.
@@ -4925,7 +1805,7 @@ async def persons_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_reject(
- cls, account: str, **params: Unpack["Account.RejectParams"]
+ cls, account: str, **params: Unpack["AccountRejectParams"]
) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can reject accounts that you have flagged as suspicious.
@@ -4946,7 +1826,7 @@ def _cls_reject(
@overload
@staticmethod
def reject(
- account: str, **params: Unpack["Account.RejectParams"]
+ account: str, **params: Unpack["AccountRejectParams"]
) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can reject accounts that you have flagged as suspicious.
@@ -4956,7 +1836,7 @@ def reject(
...
@overload
- def reject(self, **params: Unpack["Account.RejectParams"]) -> "Account":
+ def reject(self, **params: Unpack["AccountRejectParams"]) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can reject accounts that you have flagged as suspicious.
@@ -4966,7 +1846,7 @@ def reject(self, **params: Unpack["Account.RejectParams"]) -> "Account":
@class_method_variant("_cls_reject")
def reject( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.RejectParams"]
+ self, **params: Unpack["AccountRejectParams"]
) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can reject accounts that you have flagged as suspicious.
@@ -4986,7 +1866,7 @@ def reject( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_reject_async(
- cls, account: str, **params: Unpack["Account.RejectParams"]
+ cls, account: str, **params: Unpack["AccountRejectParams"]
) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can reject accounts that you have flagged as suspicious.
@@ -5007,7 +1887,7 @@ async def _cls_reject_async(
@overload
@staticmethod
async def reject_async(
- account: str, **params: Unpack["Account.RejectParams"]
+ account: str, **params: Unpack["AccountRejectParams"]
) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can reject accounts that you have flagged as suspicious.
@@ -5018,7 +1898,7 @@ async def reject_async(
@overload
async def reject_async(
- self, **params: Unpack["Account.RejectParams"]
+ self, **params: Unpack["AccountRejectParams"]
) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can reject accounts that you have flagged as suspicious.
@@ -5029,7 +1909,7 @@ async def reject_async(
@class_method_variant("_cls_reject_async")
async def reject_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.RejectParams"]
+ self, **params: Unpack["AccountRejectParams"]
) -> "Account":
"""
With [Connect](https://docs.stripe.com/connect), you can reject accounts that you have flagged as suspicious.
@@ -5099,7 +1979,7 @@ def serialize(self, previous):
@classmethod
def list_capabilities(
- cls, account: str, **params: Unpack["Account.ListCapabilitiesParams"]
+ 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.
@@ -5117,7 +1997,7 @@ def list_capabilities(
@classmethod
async def list_capabilities_async(
- cls, account: str, **params: Unpack["Account.ListCapabilitiesParams"]
+ 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.
@@ -5138,7 +2018,7 @@ def retrieve_capability(
cls,
account: str,
capability: str,
- **params: Unpack["Account.RetrieveCapabilityParams"],
+ **params: Unpack["AccountRetrieveCapabilityParams"],
) -> "Capability":
"""
Retrieves information about the specified Account Capability.
@@ -5160,7 +2040,7 @@ async def retrieve_capability_async(
cls,
account: str,
capability: str,
- **params: Unpack["Account.RetrieveCapabilityParams"],
+ **params: Unpack["AccountRetrieveCapabilityParams"],
) -> "Capability":
"""
Retrieves information about the specified Account Capability.
@@ -5182,7 +2062,7 @@ def modify_capability(
cls,
account: str,
capability: str,
- **params: Unpack["Account.ModifyCapabilityParams"],
+ **params: Unpack["AccountModifyCapabilityParams"],
) -> "Capability":
"""
Updates an existing Account Capability. Request or remove a capability by updating its requested parameter.
@@ -5204,7 +2084,7 @@ async def modify_capability_async(
cls,
account: str,
capability: str,
- **params: Unpack["Account.ModifyCapabilityParams"],
+ **params: Unpack["AccountModifyCapabilityParams"],
) -> "Capability":
"""
Updates an existing Account Capability. Request or remove a capability by updating its requested parameter.
@@ -5226,7 +2106,7 @@ def delete_external_account(
cls,
account: str,
id: str,
- **params: Unpack["Account.DeleteExternalAccountParams"],
+ **params: Unpack["AccountDeleteExternalAccountParams"],
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -5247,7 +2127,7 @@ async def delete_external_account_async(
cls,
account: str,
id: str,
- **params: Unpack["Account.DeleteExternalAccountParams"],
+ **params: Unpack["AccountDeleteExternalAccountParams"],
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -5268,7 +2148,7 @@ def retrieve_external_account(
cls,
account: str,
id: str,
- **params: Unpack["Account.RetrieveExternalAccountParams"],
+ **params: Unpack["AccountRetrieveExternalAccountParams"],
) -> Union["BankAccount", "Card"]:
"""
Retrieve a specified external account for a given account.
@@ -5289,7 +2169,7 @@ async def retrieve_external_account_async(
cls,
account: str,
id: str,
- **params: Unpack["Account.RetrieveExternalAccountParams"],
+ **params: Unpack["AccountRetrieveExternalAccountParams"],
) -> Union["BankAccount", "Card"]:
"""
Retrieve a specified external account for a given account.
@@ -5310,7 +2190,7 @@ def modify_external_account(
cls,
account: str,
id: str,
- **params: Unpack["Account.ModifyExternalAccountParams"],
+ **params: Unpack["AccountModifyExternalAccountParams"],
) -> Union["BankAccount", "Card"]:
"""
Updates the metadata, account holder name, account holder type of a bank account belonging to
@@ -5338,7 +2218,7 @@ async def modify_external_account_async(
cls,
account: str,
id: str,
- **params: Unpack["Account.ModifyExternalAccountParams"],
+ **params: Unpack["AccountModifyExternalAccountParams"],
) -> Union["BankAccount", "Card"]:
"""
Updates the metadata, account holder name, account holder type of a bank account belonging to
@@ -5365,7 +2245,7 @@ async def modify_external_account_async(
def list_external_accounts(
cls,
account: str,
- **params: Unpack["Account.ListExternalAccountsParams"],
+ **params: Unpack["AccountListExternalAccountsParams"],
) -> ListObject[Union["BankAccount", "Card"]]:
"""
List external accounts for an account.
@@ -5385,7 +2265,7 @@ def list_external_accounts(
async def list_external_accounts_async(
cls,
account: str,
- **params: Unpack["Account.ListExternalAccountsParams"],
+ **params: Unpack["AccountListExternalAccountsParams"],
) -> ListObject[Union["BankAccount", "Card"]]:
"""
List external accounts for an account.
@@ -5405,7 +2285,7 @@ async def list_external_accounts_async(
def create_external_account(
cls,
account: str,
- **params: Unpack["Account.CreateExternalAccountParams"],
+ **params: Unpack["AccountCreateExternalAccountParams"],
) -> Union["BankAccount", "Card"]:
"""
Create an external account for a given account.
@@ -5425,7 +2305,7 @@ def create_external_account(
async def create_external_account_async(
cls,
account: str,
- **params: Unpack["Account.CreateExternalAccountParams"],
+ **params: Unpack["AccountCreateExternalAccountParams"],
) -> Union["BankAccount", "Card"]:
"""
Create an external account for a given account.
@@ -5443,7 +2323,7 @@ async def create_external_account_async(
@classmethod
def create_login_link(
- cls, account: str, **params: Unpack["Account.CreateLoginLinkParams"]
+ cls, account: str, **params: Unpack["AccountCreateLoginLinkParams"]
) -> "LoginLink":
"""
Creates a login link for a connected account to access the Express Dashboard.
@@ -5463,7 +2343,7 @@ def create_login_link(
@classmethod
async def create_login_link_async(
- cls, account: str, **params: Unpack["Account.CreateLoginLinkParams"]
+ cls, account: str, **params: Unpack["AccountCreateLoginLinkParams"]
) -> "LoginLink":
"""
Creates a login link for a connected account to access the Express Dashboard.
@@ -5486,7 +2366,7 @@ def delete_person(
cls,
account: str,
person: str,
- **params: Unpack["Account.DeletePersonParams"],
+ **params: Unpack["AccountDeletePersonParams"],
) -> "Person":
"""
Deletes an existing person's relationship to the account's legal entity. Any person with a relationship for an account can be deleted through the API, except if the person is the account_opener. If your integration is using the executive parameter, you cannot delete the only verified executive on file.
@@ -5507,7 +2387,7 @@ async def delete_person_async(
cls,
account: str,
person: str,
- **params: Unpack["Account.DeletePersonParams"],
+ **params: Unpack["AccountDeletePersonParams"],
) -> "Person":
"""
Deletes an existing person's relationship to the account's legal entity. Any person with a relationship for an account can be deleted through the API, except if the person is the account_opener. If your integration is using the executive parameter, you cannot delete the only verified executive on file.
@@ -5528,7 +2408,7 @@ def retrieve_person(
cls,
account: str,
person: str,
- **params: Unpack["Account.RetrievePersonParams"],
+ **params: Unpack["AccountRetrievePersonParams"],
) -> "Person":
"""
Retrieves an existing person.
@@ -5549,7 +2429,7 @@ async def retrieve_person_async(
cls,
account: str,
person: str,
- **params: Unpack["Account.RetrievePersonParams"],
+ **params: Unpack["AccountRetrievePersonParams"],
) -> "Person":
"""
Retrieves an existing person.
@@ -5570,7 +2450,7 @@ def modify_person(
cls,
account: str,
person: str,
- **params: Unpack["Account.ModifyPersonParams"],
+ **params: Unpack["AccountModifyPersonParams"],
) -> "Person":
"""
Updates an existing person.
@@ -5591,7 +2471,7 @@ async def modify_person_async(
cls,
account: str,
person: str,
- **params: Unpack["Account.ModifyPersonParams"],
+ **params: Unpack["AccountModifyPersonParams"],
) -> "Person":
"""
Updates an existing person.
@@ -5609,7 +2489,7 @@ async def modify_person_async(
@classmethod
def list_persons(
- cls, account: str, **params: Unpack["Account.ListPersonsParams"]
+ 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.
@@ -5627,7 +2507,7 @@ def list_persons(
@classmethod
async def list_persons_async(
- cls, account: str, **params: Unpack["Account.ListPersonsParams"]
+ 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.
@@ -5645,7 +2525,7 @@ async def list_persons_async(
@classmethod
def create_person(
- cls, account: str, **params: Unpack["Account.CreatePersonParams"]
+ cls, account: str, **params: Unpack["AccountCreatePersonParams"]
) -> "Person":
"""
Creates a new person.
@@ -5663,7 +2543,7 @@ def create_person(
@classmethod
async def create_person_async(
- cls, account: str, **params: Unpack["Account.CreatePersonParams"]
+ 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 56080f053..0c8b36a07 100644
--- a/stripe/_account_capability_service.py
+++ b/stripe/_account_capability_service.py
@@ -5,39 +5,26 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._account_capability_list_params import (
+ AccountCapabilityListParams,
+ )
+ from stripe.params._account_capability_retrieve_params import (
+ AccountCapabilityRetrieveParams,
+ )
+ from stripe.params._account_capability_update_params import (
+ AccountCapabilityUpdateParams,
+ )
-class AccountCapabilityService(StripeService):
- class ListParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- requested: NotRequired[bool]
- """
- 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. Some capabilities are permanent after they've been requested. Attempting to remove a permanent capability returns an error.
- """
+class AccountCapabilityService(StripeService):
def list(
self,
account: str,
- params: Optional["AccountCapabilityService.ListParams"] = None,
+ params: Optional["AccountCapabilityListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Capability]:
"""
@@ -59,7 +46,7 @@ def list(
async def list_async(
self,
account: str,
- params: Optional["AccountCapabilityService.ListParams"] = None,
+ params: Optional["AccountCapabilityListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Capability]:
"""
@@ -82,7 +69,7 @@ def retrieve(
self,
account: str,
capability: str,
- params: Optional["AccountCapabilityService.RetrieveParams"] = None,
+ params: Optional["AccountCapabilityRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Capability:
"""
@@ -106,7 +93,7 @@ async def retrieve_async(
self,
account: str,
capability: str,
- params: Optional["AccountCapabilityService.RetrieveParams"] = None,
+ params: Optional["AccountCapabilityRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Capability:
"""
@@ -130,7 +117,7 @@ def update(
self,
account: str,
capability: str,
- params: Optional["AccountCapabilityService.UpdateParams"] = None,
+ params: Optional["AccountCapabilityUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Capability:
"""
@@ -154,7 +141,7 @@ async def update_async(
self,
account: str,
capability: str,
- params: Optional["AccountCapabilityService.UpdateParams"] = None,
+ 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 d5c145e2b..0c357796a 100644
--- a/stripe/_account_external_account_service.py
+++ b/stripe/_account_external_account_service.py
@@ -6,207 +6,33 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, Union, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, Union, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._account_external_account_create_params import (
+ AccountExternalAccountCreateParams,
+ )
+ from stripe.params._account_external_account_delete_params import (
+ AccountExternalAccountDeleteParams,
+ )
+ from stripe.params._account_external_account_list_params import (
+ AccountExternalAccountListParams,
+ )
+ from stripe.params._account_external_account_retrieve_params import (
+ AccountExternalAccountRetrieveParams,
+ )
+ from stripe.params._account_external_account_update_params import (
+ AccountExternalAccountUpdateParams,
+ )
-class AccountExternalAccountService(StripeService):
- class CreateParams(TypedDict):
- default_for_currency: NotRequired[bool]
- """
- When set to true, or if this is the first external account added in this currency, this account becomes the default external account for its currency.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- external_account: Union[
- str,
- "AccountExternalAccountService.CreateParamsCard",
- "AccountExternalAccountService.CreateParamsBankAccount",
- "AccountExternalAccountService.CreateParamsCardToken",
- ]
- """
- A token, like the ones returned by [Stripe.js](https://stripe.com/docs/js) or a dictionary containing a user's external account details (with the options shown below). Please refer to full [documentation](https://stripe.com/docs/api/external_accounts) instead.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class CreateParamsBankAccount(TypedDict):
- object: Literal["bank_account"]
- account_holder_name: NotRequired[str]
- """
- The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object.
- """
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
- """
- account_number: str
- """
- The account number for the bank account, in string form. Must be a checking account.
- """
- country: str
- """
- The country in which the bank account is located.
- """
- currency: NotRequired[str]
- """
- The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts)
- """
- routing_number: NotRequired[str]
- """
- The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
- """
-
- class CreateParamsCard(TypedDict):
- object: Literal["card"]
- address_city: NotRequired[str]
- address_country: NotRequired[str]
- address_line1: NotRequired[str]
- address_line2: NotRequired[str]
- address_state: NotRequired[str]
- address_zip: NotRequired[str]
- currency: NotRequired[str]
- cvc: NotRequired[str]
- exp_month: int
- exp_year: int
- name: NotRequired[str]
- number: str
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- """
-
- class CreateParamsCardToken(TypedDict):
- object: Literal["card"]
- currency: NotRequired[str]
- token: str
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- object: NotRequired[Literal["bank_account", "card"]]
- """
- Filter external accounts according to a particular object type.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name of the person or business that owns the bank account.
- """
- account_holder_type: NotRequired[
- "Literal['']|Literal['company', 'individual']"
- ]
- """
- The type of entity that holds the account. This can be either `individual` or `company`.
- """
- account_type: NotRequired[
- Literal["checking", "futsu", "savings", "toza"]
- ]
- """
- The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`.
- """
- address_city: NotRequired[str]
- """
- City/District/Suburb/Town/Village.
- """
- address_country: NotRequired[str]
- """
- Billing address country, if provided when creating card.
- """
- address_line1: NotRequired[str]
- """
- Address line 1 (Street address/PO Box/Company name).
- """
- address_line2: NotRequired[str]
- """
- Address line 2 (Apartment/Suite/Unit/Building).
- """
- address_state: NotRequired[str]
- """
- State/County/Province/Region.
- """
- address_zip: NotRequired[str]
- """
- ZIP or postal code.
- """
- default_for_currency: NotRequired[bool]
- """
- When set to true, this becomes the default external account for its currency.
- """
- documents: NotRequired[
- "AccountExternalAccountService.UpdateParamsDocuments"
- ]
- """
- Documents that may be submitted to satisfy various informational requests.
- """
- exp_month: NotRequired[str]
- """
- Two digit number representing the card's expiration month.
- """
- exp_year: NotRequired[str]
- """
- Four digit number representing the card's expiration year.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- Cardholder name.
- """
-
- class UpdateParamsDocuments(TypedDict):
- bank_account_ownership_verification: NotRequired[
- "AccountExternalAccountService.UpdateParamsDocumentsBankAccountOwnershipVerification"
- ]
- """
- One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the bank account that displays the last 4 digits of the account number, either a statement or a check.
- """
-
- class UpdateParamsDocumentsBankAccountOwnershipVerification(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
+class AccountExternalAccountService(StripeService):
def delete(
self,
account: str,
id: str,
- params: Optional["AccountExternalAccountService.DeleteParams"] = None,
+ params: Optional["AccountExternalAccountDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Union[BankAccount, Card]:
"""
@@ -230,7 +56,7 @@ async def delete_async(
self,
account: str,
id: str,
- params: Optional["AccountExternalAccountService.DeleteParams"] = None,
+ params: Optional["AccountExternalAccountDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Union[BankAccount, Card]:
"""
@@ -254,9 +80,7 @@ def retrieve(
self,
account: str,
id: str,
- params: Optional[
- "AccountExternalAccountService.RetrieveParams"
- ] = None,
+ params: Optional["AccountExternalAccountRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Union[BankAccount, Card]:
"""
@@ -280,9 +104,7 @@ async def retrieve_async(
self,
account: str,
id: str,
- params: Optional[
- "AccountExternalAccountService.RetrieveParams"
- ] = None,
+ params: Optional["AccountExternalAccountRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Union[BankAccount, Card]:
"""
@@ -306,7 +128,7 @@ def update(
self,
account: str,
id: str,
- params: Optional["AccountExternalAccountService.UpdateParams"] = None,
+ params: Optional["AccountExternalAccountUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Union[BankAccount, Card]:
"""
@@ -337,7 +159,7 @@ async def update_async(
self,
account: str,
id: str,
- params: Optional["AccountExternalAccountService.UpdateParams"] = None,
+ params: Optional["AccountExternalAccountUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Union[BankAccount, Card]:
"""
@@ -367,7 +189,7 @@ async def update_async(
def list(
self,
account: str,
- params: Optional["AccountExternalAccountService.ListParams"] = None,
+ params: Optional["AccountExternalAccountListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Union[BankAccount, Card]]:
"""
@@ -389,7 +211,7 @@ def list(
async def list_async(
self,
account: str,
- params: Optional["AccountExternalAccountService.ListParams"] = None,
+ params: Optional["AccountExternalAccountListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Union[BankAccount, Card]]:
"""
@@ -411,7 +233,7 @@ async def list_async(
def create(
self,
account: str,
- params: "AccountExternalAccountService.CreateParams",
+ params: "AccountExternalAccountCreateParams",
options: Optional[RequestOptions] = None,
) -> Union[BankAccount, Card]:
"""
@@ -433,7 +255,7 @@ def create(
async def create_async(
self,
account: str,
- params: "AccountExternalAccountService.CreateParams",
+ params: "AccountExternalAccountCreateParams",
options: Optional[RequestOptions] = None,
) -> Union[BankAccount, Card]:
"""
diff --git a/stripe/_account_link.py b/stripe/_account_link.py
index 8af6f1bb7..15043e9ee 100644
--- a/stripe/_account_link.py
+++ b/stripe/_account_link.py
@@ -1,9 +1,13 @@
# -*- coding: utf-8 -*-
# File generated from our OpenAPI spec
from stripe._createable_api_resource import CreateableAPIResource
-from stripe._request_options import RequestOptions
-from typing import ClassVar, List, cast
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing import ClassVar, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._account_link_create_params import (
+ AccountLinkCreateParams,
+ )
class AccountLink(CreateableAPIResource["AccountLink"]):
@@ -15,51 +19,6 @@ class AccountLink(CreateableAPIResource["AccountLink"]):
"""
OBJECT_NAME: ClassVar[Literal["account_link"]] = "account_link"
-
- class CreateParams(RequestOptions):
- account: str
- """
- The identifier of the account to create an account link for.
- """
- collect: NotRequired[Literal["currently_due", "eventually_due"]]
- """
- The collect parameter is deprecated. Use `collection_options` instead.
- """
- collection_options: NotRequired[
- "AccountLink.CreateParamsCollectionOptions"
- ]
- """
- Specifies the requirements that Stripe collects from connected accounts in the Connect Onboarding flow.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- refresh_url: NotRequired[str]
- """
- The URL the user will be redirected to if the account link is expired, has been previously-visited, or is otherwise invalid. The URL you specify should attempt to generate a new account link with the same parameters used to create the original account link, then redirect the user to the new account link's URL so they can continue with Connect Onboarding. If a new account link cannot be generated or the redirect fails you should display a useful error to the user.
- """
- return_url: NotRequired[str]
- """
- The URL that the user will be redirected to upon leaving or completing the linked flow.
- """
- type: Literal["account_onboarding", "account_update"]
- """
- The type of account link the user is requesting.
-
- You can create Account Links of type `account_update` only for connected accounts where your platform is responsible for collecting requirements, including Custom accounts. You can't create them for accounts that have access to a Stripe-hosted Dashboard. If you use [Connect embedded components](https://docs.stripe.com/connect/get-started-connect-embedded-components), you can include components that allow your connected accounts to update their own information. For an account without Stripe-hosted Dashboard access where Stripe is liable for negative balances, you must use embedded components.
- """
-
- class CreateParamsCollectionOptions(TypedDict):
- fields: NotRequired[Literal["currently_due", "eventually_due"]]
- """
- Specifies whether the platform collects only currently_due requirements (`currently_due`) or both currently_due and eventually_due requirements (`eventually_due`). If you don't specify `collection_options`, the default value is `currently_due`.
- """
- future_requirements: NotRequired[Literal["include", "omit"]]
- """
- Specifies whether the platform collects future_requirements in addition to requirements in Connect Onboarding. The default value is `omit`.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -79,7 +38,7 @@ class CreateParamsCollectionOptions(TypedDict):
@classmethod
def create(
- cls, **params: Unpack["AccountLink.CreateParams"]
+ cls, **params: Unpack["AccountLinkCreateParams"]
) -> "AccountLink":
"""
Creates an AccountLink object that includes a single-use Stripe URL that the platform can redirect their user to in order to take them through the Connect Onboarding flow.
@@ -95,7 +54,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["AccountLink.CreateParams"]
+ cls, **params: Unpack["AccountLinkCreateParams"]
) -> "AccountLink":
"""
Creates an AccountLink object that includes a single-use Stripe URL that the platform can redirect their user to in order to take them through the Connect Onboarding flow.
diff --git a/stripe/_account_link_service.py b/stripe/_account_link_service.py
index 95283cc79..58bdf3321 100644
--- a/stripe/_account_link_service.py
+++ b/stripe/_account_link_service.py
@@ -3,58 +3,19 @@
from stripe._account_link import AccountLink
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._account_link_create_params import (
+ AccountLinkCreateParams,
+ )
-class AccountLinkService(StripeService):
- class CreateParams(TypedDict):
- account: str
- """
- The identifier of the account to create an account link for.
- """
- collect: NotRequired[Literal["currently_due", "eventually_due"]]
- """
- The collect parameter is deprecated. Use `collection_options` instead.
- """
- collection_options: NotRequired[
- "AccountLinkService.CreateParamsCollectionOptions"
- ]
- """
- Specifies the requirements that Stripe collects from connected accounts in the Connect Onboarding flow.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- refresh_url: NotRequired[str]
- """
- The URL the user will be redirected to if the account link is expired, has been previously-visited, or is otherwise invalid. The URL you specify should attempt to generate a new account link with the same parameters used to create the original account link, then redirect the user to the new account link's URL so they can continue with Connect Onboarding. If a new account link cannot be generated or the redirect fails you should display a useful error to the user.
- """
- return_url: NotRequired[str]
- """
- The URL that the user will be redirected to upon leaving or completing the linked flow.
- """
- type: Literal["account_onboarding", "account_update"]
- """
- The type of account link the user is requesting.
-
- You can create Account Links of type `account_update` only for connected accounts where your platform is responsible for collecting requirements, including Custom accounts. You can't create them for accounts that have access to a Stripe-hosted Dashboard. If you use [Connect embedded components](https://docs.stripe.com/connect/get-started-connect-embedded-components), you can include components that allow your connected accounts to update their own information. For an account without Stripe-hosted Dashboard access where Stripe is liable for negative balances, you must use embedded components.
- """
-
- class CreateParamsCollectionOptions(TypedDict):
- fields: NotRequired[Literal["currently_due", "eventually_due"]]
- """
- Specifies whether the platform collects only currently_due requirements (`currently_due`) or both currently_due and eventually_due requirements (`eventually_due`). If you don't specify `collection_options`, the default value is `currently_due`.
- """
- future_requirements: NotRequired[Literal["include", "omit"]]
- """
- Specifies whether the platform collects future_requirements in addition to requirements in Connect Onboarding. The default value is `omit`.
- """
+class AccountLinkService(StripeService):
def create(
self,
- params: "AccountLinkService.CreateParams",
+ params: "AccountLinkCreateParams",
options: Optional[RequestOptions] = None,
) -> AccountLink:
"""
@@ -73,7 +34,7 @@ def create(
async def create_async(
self,
- params: "AccountLinkService.CreateParams",
+ params: "AccountLinkCreateParams",
options: Optional[RequestOptions] = None,
) -> AccountLink:
"""
diff --git a/stripe/_account_login_link_service.py b/stripe/_account_login_link_service.py
index 5a17f9369..d0019a683 100644
--- a/stripe/_account_login_link_service.py
+++ b/stripe/_account_login_link_service.py
@@ -4,21 +4,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._account_login_link_create_params import (
+ AccountLoginLinkCreateParams,
+ )
-class AccountLoginLinkService(StripeService):
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class AccountLoginLinkService(StripeService):
def create(
self,
account: str,
- params: Optional["AccountLoginLinkService.CreateParams"] = None,
+ params: Optional["AccountLoginLinkCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> LoginLink:
"""
@@ -42,7 +41,7 @@ def create(
async def create_async(
self,
account: str,
- params: Optional["AccountLoginLinkService.CreateParams"] = None,
+ params: Optional["AccountLoginLinkCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> LoginLink:
"""
diff --git a/stripe/_account_person_service.py b/stripe/_account_person_service.py
index 563336706..9cb020b61 100644
--- a/stripe/_account_person_service.py
+++ b/stripe/_account_person_service.py
@@ -5,1001 +5,33 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._account_person_create_params import (
+ AccountPersonCreateParams,
+ )
+ from stripe.params._account_person_delete_params import (
+ AccountPersonDeleteParams,
+ )
+ from stripe.params._account_person_list_params import (
+ AccountPersonListParams,
+ )
+ from stripe.params._account_person_retrieve_params import (
+ AccountPersonRetrieveParams,
+ )
+ from stripe.params._account_person_update_params import (
+ AccountPersonUpdateParams,
+ )
class AccountPersonService(StripeService):
- class CreateParams(TypedDict):
- additional_tos_acceptances: NotRequired[
- "AccountPersonService.CreateParamsAdditionalTosAcceptances"
- ]
- """
- Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.
- """
- address: NotRequired["AccountPersonService.CreateParamsAddress"]
- """
- The person's address.
- """
- address_kana: NotRequired[
- "AccountPersonService.CreateParamsAddressKana"
- ]
- """
- The Kana variation of the person's address (Japan only).
- """
- address_kanji: NotRequired[
- "AccountPersonService.CreateParamsAddressKanji"
- ]
- """
- The Kanji variation of the person's address (Japan only).
- """
- dob: NotRequired["Literal['']|AccountPersonService.CreateParamsDob"]
- """
- The person's date of birth.
- """
- documents: NotRequired["AccountPersonService.CreateParamsDocuments"]
- """
- Documents that may be submitted to satisfy various informational requests.
- """
- email: NotRequired[str]
- """
- The person's email address.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- first_name: NotRequired[str]
- """
- The person's first name.
- """
- first_name_kana: NotRequired[str]
- """
- The Kana variation of the person's first name (Japan only).
- """
- first_name_kanji: NotRequired[str]
- """
- The Kanji variation of the person's first name (Japan only).
- """
- full_name_aliases: NotRequired["Literal['']|List[str]"]
- """
- A list of alternate names or aliases that the person is known by.
- """
- gender: NotRequired[str]
- """
- The person's gender (International regulations require either "male" or "female").
- """
- id_number: NotRequired[str]
- """
- The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- id_number_secondary: NotRequired[str]
- """
- The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- last_name: NotRequired[str]
- """
- The person's last name.
- """
- last_name_kana: NotRequired[str]
- """
- The Kana variation of the person's last name (Japan only).
- """
- last_name_kanji: NotRequired[str]
- """
- The Kanji variation of the person's last name (Japan only).
- """
- maiden_name: NotRequired[str]
- """
- The person's maiden name.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nationality: NotRequired[str]
- """
- The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or "XX" if unavailable.
- """
- person_token: NotRequired[str]
- """
- A [person token](https://docs.stripe.com/connect/account-tokens), used to securely provide details to the person.
- """
- phone: NotRequired[str]
- """
- The person's phone number.
- """
- political_exposure: NotRequired[Literal["existing", "none"]]
- """
- Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
- """
- registered_address: NotRequired[
- "AccountPersonService.CreateParamsRegisteredAddress"
- ]
- """
- The person's registered address.
- """
- relationship: NotRequired[
- "AccountPersonService.CreateParamsRelationship"
- ]
- """
- The relationship that this person has with the account's legal entity.
- """
- ssn_last_4: NotRequired[str]
- """
- The last four digits of the person's Social Security number (U.S. only).
- """
- us_cfpb_data: NotRequired[
- "AccountPersonService.CreateParamsUsCfpbData"
- ]
- """
- Demographic data related to the person.
- """
- verification: NotRequired[
- "AccountPersonService.CreateParamsVerification"
- ]
- """
- The person's verification status.
- """
-
- class CreateParamsAdditionalTosAcceptances(TypedDict):
- account: NotRequired[
- "AccountPersonService.CreateParamsAdditionalTosAcceptancesAccount"
- ]
- """
- Details on the legal guardian's acceptance of the main Stripe service agreement.
- """
-
- class CreateParamsAdditionalTosAcceptancesAccount(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the account representative accepted the service agreement.
- """
- ip: NotRequired[str]
- """
- The IP address from which the account representative accepted the service agreement.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the account representative accepted the service agreement.
- """
-
- class CreateParamsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsDocuments(TypedDict):
- company_authorization: NotRequired[
- "AccountPersonService.CreateParamsDocumentsCompanyAuthorization"
- ]
- """
- One or more documents that demonstrate proof that this person is authorized to represent the company.
- """
- passport: NotRequired[
- "AccountPersonService.CreateParamsDocumentsPassport"
- ]
- """
- One or more documents showing the person's passport page with photo and personal data.
- """
- visa: NotRequired["AccountPersonService.CreateParamsDocumentsVisa"]
- """
- One or more documents showing the person's visa required for living in the country where they are residing.
- """
-
- class CreateParamsDocumentsCompanyAuthorization(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsPassport(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsVisa(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsRegisteredAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsRelationship(TypedDict):
- authorizer: NotRequired[bool]
- """
- Whether the person is the authorizer of the account's representative.
- """
- director: NotRequired[bool]
- """
- Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
- """
- executive: NotRequired[bool]
- """
- Whether the person has significant responsibility to control, manage, or direct the organization.
- """
- legal_guardian: NotRequired[bool]
- """
- Whether the person is the legal guardian of the account's representative.
- """
- owner: NotRequired[bool]
- """
- Whether the person is an owner of the account's legal entity.
- """
- percent_ownership: NotRequired["Literal['']|float"]
- """
- The percent owned by the person of the account's legal entity.
- """
- representative: NotRequired[bool]
- """
- Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
- """
- title: NotRequired[str]
- """
- The person's title (e.g., CEO, Support Engineer).
- """
-
- class CreateParamsUsCfpbData(TypedDict):
- ethnicity_details: NotRequired[
- "AccountPersonService.CreateParamsUsCfpbDataEthnicityDetails"
- ]
- """
- The persons ethnicity details
- """
- race_details: NotRequired[
- "AccountPersonService.CreateParamsUsCfpbDataRaceDetails"
- ]
- """
- The persons race details
- """
- self_identified_gender: NotRequired[str]
- """
- The persons self-identified gender
- """
-
- class CreateParamsUsCfpbDataEthnicityDetails(TypedDict):
- ethnicity: NotRequired[
- List[
- Literal[
- "cuban",
- "hispanic_or_latino",
- "mexican",
- "not_hispanic_or_latino",
- "other_hispanic_or_latino",
- "prefer_not_to_answer",
- "puerto_rican",
- ]
- ]
- ]
- """
- The persons ethnicity
- """
- ethnicity_other: NotRequired[str]
- """
- Please specify your origin, when other is selected.
- """
-
- class CreateParamsUsCfpbDataRaceDetails(TypedDict):
- race: NotRequired[
- List[
- Literal[
- "african_american",
- "american_indian_or_alaska_native",
- "asian",
- "asian_indian",
- "black_or_african_american",
- "chinese",
- "ethiopian",
- "filipino",
- "guamanian_or_chamorro",
- "haitian",
- "jamaican",
- "japanese",
- "korean",
- "native_hawaiian",
- "native_hawaiian_or_other_pacific_islander",
- "nigerian",
- "other_asian",
- "other_black_or_african_american",
- "other_pacific_islander",
- "prefer_not_to_answer",
- "samoan",
- "somali",
- "vietnamese",
- "white",
- ]
- ]
- ]
- """
- The persons race.
- """
- race_other: NotRequired[str]
- """
- Please specify your race, when other is selected.
- """
-
- class CreateParamsVerification(TypedDict):
- additional_document: NotRequired[
- "AccountPersonService.CreateParamsVerificationAdditionalDocument"
- ]
- """
- A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
- """
- document: NotRequired[
- "AccountPersonService.CreateParamsVerificationDocument"
- ]
- """
- An identifying document, either a passport or local ID card.
- """
-
- class CreateParamsVerificationAdditionalDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- relationship: NotRequired[
- "AccountPersonService.ListParamsRelationship"
- ]
- """
- Filters on the list of people returned based on the person's relationship to the account's company.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsRelationship(TypedDict):
- authorizer: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are authorizers of the account's representative.
- """
- director: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are directors of the account's company.
- """
- executive: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are executives of the account's company.
- """
- legal_guardian: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are legal guardians of the account's representative.
- """
- owner: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are owners of the account's company.
- """
- representative: NotRequired[bool]
- """
- A filter on the list of people returned based on whether these people are the representative of the account's company.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- additional_tos_acceptances: NotRequired[
- "AccountPersonService.UpdateParamsAdditionalTosAcceptances"
- ]
- """
- Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.
- """
- address: NotRequired["AccountPersonService.UpdateParamsAddress"]
- """
- The person's address.
- """
- address_kana: NotRequired[
- "AccountPersonService.UpdateParamsAddressKana"
- ]
- """
- The Kana variation of the person's address (Japan only).
- """
- address_kanji: NotRequired[
- "AccountPersonService.UpdateParamsAddressKanji"
- ]
- """
- The Kanji variation of the person's address (Japan only).
- """
- dob: NotRequired["Literal['']|AccountPersonService.UpdateParamsDob"]
- """
- The person's date of birth.
- """
- documents: NotRequired["AccountPersonService.UpdateParamsDocuments"]
- """
- Documents that may be submitted to satisfy various informational requests.
- """
- email: NotRequired[str]
- """
- The person's email address.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- first_name: NotRequired[str]
- """
- The person's first name.
- """
- first_name_kana: NotRequired[str]
- """
- The Kana variation of the person's first name (Japan only).
- """
- first_name_kanji: NotRequired[str]
- """
- The Kanji variation of the person's first name (Japan only).
- """
- full_name_aliases: NotRequired["Literal['']|List[str]"]
- """
- A list of alternate names or aliases that the person is known by.
- """
- gender: NotRequired[str]
- """
- The person's gender (International regulations require either "male" or "female").
- """
- id_number: NotRequired[str]
- """
- The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- id_number_secondary: NotRequired[str]
- """
- The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- last_name: NotRequired[str]
- """
- The person's last name.
- """
- last_name_kana: NotRequired[str]
- """
- The Kana variation of the person's last name (Japan only).
- """
- last_name_kanji: NotRequired[str]
- """
- The Kanji variation of the person's last name (Japan only).
- """
- maiden_name: NotRequired[str]
- """
- The person's maiden name.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nationality: NotRequired[str]
- """
- The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or "XX" if unavailable.
- """
- person_token: NotRequired[str]
- """
- A [person token](https://docs.stripe.com/connect/account-tokens), used to securely provide details to the person.
- """
- phone: NotRequired[str]
- """
- The person's phone number.
- """
- political_exposure: NotRequired[Literal["existing", "none"]]
- """
- Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
- """
- registered_address: NotRequired[
- "AccountPersonService.UpdateParamsRegisteredAddress"
- ]
- """
- The person's registered address.
- """
- relationship: NotRequired[
- "AccountPersonService.UpdateParamsRelationship"
- ]
- """
- The relationship that this person has with the account's legal entity.
- """
- ssn_last_4: NotRequired[str]
- """
- The last four digits of the person's Social Security number (U.S. only).
- """
- us_cfpb_data: NotRequired[
- "AccountPersonService.UpdateParamsUsCfpbData"
- ]
- """
- Demographic data related to the person.
- """
- verification: NotRequired[
- "AccountPersonService.UpdateParamsVerification"
- ]
- """
- The person's verification status.
- """
-
- class UpdateParamsAdditionalTosAcceptances(TypedDict):
- account: NotRequired[
- "AccountPersonService.UpdateParamsAdditionalTosAcceptancesAccount"
- ]
- """
- Details on the legal guardian's acceptance of the main Stripe service agreement.
- """
-
- class UpdateParamsAdditionalTosAcceptancesAccount(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the account representative accepted the service agreement.
- """
- ip: NotRequired[str]
- """
- The IP address from which the account representative accepted the service agreement.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the account representative accepted the service agreement.
- """
-
- class UpdateParamsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class UpdateParamsAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class UpdateParamsDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class UpdateParamsDocuments(TypedDict):
- company_authorization: NotRequired[
- "AccountPersonService.UpdateParamsDocumentsCompanyAuthorization"
- ]
- """
- One or more documents that demonstrate proof that this person is authorized to represent the company.
- """
- passport: NotRequired[
- "AccountPersonService.UpdateParamsDocumentsPassport"
- ]
- """
- One or more documents showing the person's passport page with photo and personal data.
- """
- visa: NotRequired["AccountPersonService.UpdateParamsDocumentsVisa"]
- """
- One or more documents showing the person's visa required for living in the country where they are residing.
- """
-
- class UpdateParamsDocumentsCompanyAuthorization(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class UpdateParamsDocumentsPassport(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class UpdateParamsDocumentsVisa(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class UpdateParamsRegisteredAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsRelationship(TypedDict):
- authorizer: NotRequired[bool]
- """
- Whether the person is the authorizer of the account's representative.
- """
- director: NotRequired[bool]
- """
- Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
- """
- executive: NotRequired[bool]
- """
- Whether the person has significant responsibility to control, manage, or direct the organization.
- """
- legal_guardian: NotRequired[bool]
- """
- Whether the person is the legal guardian of the account's representative.
- """
- owner: NotRequired[bool]
- """
- Whether the person is an owner of the account's legal entity.
- """
- percent_ownership: NotRequired["Literal['']|float"]
- """
- The percent owned by the person of the account's legal entity.
- """
- representative: NotRequired[bool]
- """
- Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
- """
- title: NotRequired[str]
- """
- The person's title (e.g., CEO, Support Engineer).
- """
-
- class UpdateParamsUsCfpbData(TypedDict):
- ethnicity_details: NotRequired[
- "AccountPersonService.UpdateParamsUsCfpbDataEthnicityDetails"
- ]
- """
- The persons ethnicity details
- """
- race_details: NotRequired[
- "AccountPersonService.UpdateParamsUsCfpbDataRaceDetails"
- ]
- """
- The persons race details
- """
- self_identified_gender: NotRequired[str]
- """
- The persons self-identified gender
- """
-
- class UpdateParamsUsCfpbDataEthnicityDetails(TypedDict):
- ethnicity: NotRequired[
- List[
- Literal[
- "cuban",
- "hispanic_or_latino",
- "mexican",
- "not_hispanic_or_latino",
- "other_hispanic_or_latino",
- "prefer_not_to_answer",
- "puerto_rican",
- ]
- ]
- ]
- """
- The persons ethnicity
- """
- ethnicity_other: NotRequired[str]
- """
- Please specify your origin, when other is selected.
- """
-
- class UpdateParamsUsCfpbDataRaceDetails(TypedDict):
- race: NotRequired[
- List[
- Literal[
- "african_american",
- "american_indian_or_alaska_native",
- "asian",
- "asian_indian",
- "black_or_african_american",
- "chinese",
- "ethiopian",
- "filipino",
- "guamanian_or_chamorro",
- "haitian",
- "jamaican",
- "japanese",
- "korean",
- "native_hawaiian",
- "native_hawaiian_or_other_pacific_islander",
- "nigerian",
- "other_asian",
- "other_black_or_african_american",
- "other_pacific_islander",
- "prefer_not_to_answer",
- "samoan",
- "somali",
- "vietnamese",
- "white",
- ]
- ]
- ]
- """
- The persons race.
- """
- race_other: NotRequired[str]
- """
- Please specify your race, when other is selected.
- """
-
- class UpdateParamsVerification(TypedDict):
- additional_document: NotRequired[
- "AccountPersonService.UpdateParamsVerificationAdditionalDocument"
- ]
- """
- A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
- """
- document: NotRequired[
- "AccountPersonService.UpdateParamsVerificationDocument"
- ]
- """
- An identifying document, either a passport or local ID card.
- """
-
- class UpdateParamsVerificationAdditionalDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class UpdateParamsVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
def delete(
self,
account: str,
person: str,
- params: Optional["AccountPersonService.DeleteParams"] = None,
+ params: Optional["AccountPersonDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Person:
"""
@@ -1023,7 +55,7 @@ async def delete_async(
self,
account: str,
person: str,
- params: Optional["AccountPersonService.DeleteParams"] = None,
+ params: Optional["AccountPersonDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Person:
"""
@@ -1047,7 +79,7 @@ def retrieve(
self,
account: str,
person: str,
- params: Optional["AccountPersonService.RetrieveParams"] = None,
+ params: Optional["AccountPersonRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Person:
"""
@@ -1071,7 +103,7 @@ async def retrieve_async(
self,
account: str,
person: str,
- params: Optional["AccountPersonService.RetrieveParams"] = None,
+ params: Optional["AccountPersonRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Person:
"""
@@ -1095,7 +127,7 @@ def update(
self,
account: str,
person: str,
- params: Optional["AccountPersonService.UpdateParams"] = None,
+ params: Optional["AccountPersonUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Person:
"""
@@ -1119,7 +151,7 @@ async def update_async(
self,
account: str,
person: str,
- params: Optional["AccountPersonService.UpdateParams"] = None,
+ params: Optional["AccountPersonUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Person:
"""
@@ -1142,7 +174,7 @@ async def update_async(
def list(
self,
account: str,
- params: Optional["AccountPersonService.ListParams"] = None,
+ params: Optional["AccountPersonListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Person]:
"""
@@ -1164,7 +196,7 @@ def list(
async def list_async(
self,
account: str,
- params: Optional["AccountPersonService.ListParams"] = None,
+ params: Optional["AccountPersonListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Person]:
"""
@@ -1186,7 +218,7 @@ async def list_async(
def create(
self,
account: str,
- params: Optional["AccountPersonService.CreateParams"] = None,
+ params: Optional["AccountPersonCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Person:
"""
@@ -1208,7 +240,7 @@ def create(
async def create_async(
self,
account: str,
- params: Optional["AccountPersonService.CreateParams"] = None,
+ params: Optional["AccountPersonCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Person:
"""
diff --git a/stripe/_account_service.py b/stripe/_account_service.py
index 5a8cce49b..526056251 100644
--- a/stripe/_account_service.py
+++ b/stripe/_account_service.py
@@ -11,8 +11,19 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._account_create_params import AccountCreateParams
+ from stripe.params._account_delete_params import AccountDeleteParams
+ from stripe.params._account_list_params import AccountListParams
+ from stripe.params._account_reject_params import AccountRejectParams
+ from stripe.params._account_retrieve_current_params import (
+ AccountRetrieveCurrentParams,
+ )
+ from stripe.params._account_retrieve_params import AccountRetrieveParams
+ from stripe.params._account_update_params import AccountUpdateParams
class AccountService(StripeService):
@@ -23,3840 +34,10 @@ def __init__(self, requestor):
self.login_links = AccountLoginLinkService(self._requestor)
self.persons = AccountPersonService(self._requestor)
- class CreateParams(TypedDict):
- account_token: NotRequired[str]
- """
- An [account token](https://stripe.com/docs/api#create_account_token), used to securely provide details to the account.
- """
- business_profile: NotRequired[
- "AccountService.CreateParamsBusinessProfile"
- ]
- """
- Business information about the account.
- """
- business_type: NotRequired[
- Literal["company", "government_entity", "individual", "non_profit"]
- ]
- """
- The business type. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
- """
- capabilities: NotRequired["AccountService.CreateParamsCapabilities"]
- """
- Each key of the dictionary represents a capability, and each capability
- maps to its settings (for example, whether it has been requested or not). Each
- capability is inactive until you have provided its specific
- requirements and Stripe has verified them. An account might have some
- of its requested capabilities be active and some be inactive.
-
- Required when [account.controller.stripe_dashboard.type](https://docs.stripe.com/api/accounts/create#create_account-controller-dashboard-type)
- is `none`, which includes Custom accounts.
- """
- company: NotRequired["AccountService.CreateParamsCompany"]
- """
- Information about the company or business. This field is available for any `business_type`. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
- """
- controller: NotRequired["AccountService.CreateParamsController"]
- """
- A hash of configuration describing the account controller's attributes.
- """
- country: NotRequired[str]
- """
- The country in which the account holder resides, or in which the business is legally established. This should be an ISO 3166-1 alpha-2 country code. For example, if you are in the United States and the business for which you're creating an account is legally represented in Canada, you would use `CA` as the country for the account being created. Available countries include [Stripe's global markets](https://stripe.com/global) as well as countries where [cross-border payouts](https://stripe.com/docs/connect/cross-border-payouts) are supported.
- """
- default_currency: NotRequired[str]
- """
- Three-letter ISO currency code representing the default currency for the account. This must be a currency that [Stripe supports in the account's country](https://docs.stripe.com/payouts).
- """
- documents: NotRequired["AccountService.CreateParamsDocuments"]
- """
- Documents that may be submitted to satisfy various informational requests.
- """
- email: NotRequired[str]
- """
- The email address of the account holder. This is only to make the account easier to identify to you. If [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, Stripe doesn't email the account without your consent.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- external_account: NotRequired[
- "str|AccountService.CreateParamsBankAccount|AccountService.CreateParamsCard|AccountService.CreateParamsCardToken"
- ]
- """
- A card or bank account to attach to the account for receiving [payouts](https://docs.stripe.com/connect/bank-debit-card-payouts) (you won't be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](https://docs.stripe.com/js), or a dictionary, as documented in the `external_account` parameter for [bank account](https://docs.stripe.com/api#account_create_bank_account) creation.
-
- By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the [bank account](https://docs.stripe.com/api#account_create_bank_account) or [card creation](https://docs.stripe.com/api#account_create_card) APIs. After you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
- """
- groups: NotRequired["AccountService.CreateParamsGroups"]
- """
- A hash of account group type to tokens. These are account groups this account should be added to.
- """
- individual: NotRequired["AccountService.CreateParamsIndividual"]
- """
- Information about the person represented by the account. This field is null unless `business_type` is set to `individual`. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- settings: NotRequired["AccountService.CreateParamsSettings"]
- """
- Options for customizing how the account functions within Stripe.
- """
- tos_acceptance: NotRequired["AccountService.CreateParamsTosAcceptance"]
- """
- Details on the account's acceptance of the [Stripe Services Agreement](https://docs.stripe.com/connect/updating-accounts#tos-acceptance). This property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts. This property defaults to a `full` service agreement when empty.
- """
- type: NotRequired[Literal["custom", "express", "standard"]]
- """
- The type of Stripe account to create. May be one of `custom`, `express` or `standard`.
- """
-
- class CreateParamsBankAccount(TypedDict):
- object: Literal["bank_account"]
- account_holder_name: NotRequired[str]
- """
- The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object.
- """
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
- """
- account_number: str
- """
- The account number for the bank account, in string form. Must be a checking account.
- """
- country: str
- """
- The country in which the bank account is located.
- """
- currency: NotRequired[str]
- """
- The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts)
- """
- routing_number: NotRequired[str]
- """
- The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
- """
-
- class CreateParamsBusinessProfile(TypedDict):
- annual_revenue: NotRequired[
- "AccountService.CreateParamsBusinessProfileAnnualRevenue"
- ]
- """
- The applicant's gross annual revenue for its preceding fiscal year.
- """
- estimated_worker_count: NotRequired[int]
- """
- An estimated upper bound of employees, contractors, vendors, etc. currently working for the business.
- """
- mcc: NotRequired[str]
- """
- [The merchant category code for the account](https://docs.stripe.com/connect/setting-mcc). MCCs are used to classify businesses based on the goods or services they provide.
- """
- minority_owned_business_designation: NotRequired[
- List[
- Literal[
- "lgbtqi_owned_business",
- "minority_owned_business",
- "none_of_these_apply",
- "prefer_not_to_answer",
- "women_owned_business",
- ]
- ]
- ]
- """
- Whether the business is a minority-owned, women-owned, and/or LGBTQI+ -owned business.
- """
- monthly_estimated_revenue: NotRequired[
- "AccountService.CreateParamsBusinessProfileMonthlyEstimatedRevenue"
- ]
- """
- An estimate of the monthly revenue of the business. Only accepted for accounts in Brazil and India.
- """
- name: NotRequired[str]
- """
- The customer-facing business name.
- """
- product_description: NotRequired[str]
- """
- Internal-only description of the product sold by, or service provided by, the business. Used by Stripe for risk and underwriting purposes.
- """
- support_address: NotRequired[
- "AccountService.CreateParamsBusinessProfileSupportAddress"
- ]
- """
- A publicly available mailing address for sending support issues to.
- """
- support_email: NotRequired[str]
- """
- A publicly available email address for sending support issues to.
- """
- support_phone: NotRequired[str]
- """
- A publicly available phone number to call with support issues.
- """
- support_url: NotRequired["Literal['']|str"]
- """
- A publicly available website for handling support issues.
- """
- url: NotRequired[str]
- """
- The business's publicly available website.
- """
-
- class CreateParamsBusinessProfileAnnualRevenue(TypedDict):
- amount: int
- """
- A non-negative integer representing the amount in the [smallest currency unit](https://docs.stripe.com/currencies#zero-decimal).
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- fiscal_year_end: str
- """
- The close-out date of the preceding fiscal year in ISO 8601 format. E.g. 2023-12-31 for the 31st of December, 2023.
- """
-
- class CreateParamsBusinessProfileMonthlyEstimatedRevenue(TypedDict):
- amount: int
- """
- A non-negative integer representing how much to charge in the [smallest currency unit](https://docs.stripe.com/currencies#zero-decimal).
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class CreateParamsBusinessProfileSupportAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsCapabilities(TypedDict):
- acss_debit_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesAcssDebitPayments"
- ]
- """
- The acss_debit_payments capability.
- """
- affirm_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesAffirmPayments"
- ]
- """
- The affirm_payments capability.
- """
- afterpay_clearpay_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesAfterpayClearpayPayments"
- ]
- """
- The afterpay_clearpay_payments capability.
- """
- alma_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesAlmaPayments"
- ]
- """
- The alma_payments capability.
- """
- amazon_pay_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesAmazonPayPayments"
- ]
- """
- The amazon_pay_payments capability.
- """
- au_becs_debit_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesAuBecsDebitPayments"
- ]
- """
- The au_becs_debit_payments capability.
- """
- bacs_debit_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesBacsDebitPayments"
- ]
- """
- The bacs_debit_payments capability.
- """
- bancontact_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesBancontactPayments"
- ]
- """
- The bancontact_payments capability.
- """
- bank_transfer_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesBankTransferPayments"
- ]
- """
- The bank_transfer_payments capability.
- """
- billie_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesBilliePayments"
- ]
- """
- The billie_payments capability.
- """
- blik_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesBlikPayments"
- ]
- """
- The blik_payments capability.
- """
- boleto_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesBoletoPayments"
- ]
- """
- The boleto_payments capability.
- """
- card_issuing: NotRequired[
- "AccountService.CreateParamsCapabilitiesCardIssuing"
- ]
- """
- The card_issuing capability.
- """
- card_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesCardPayments"
- ]
- """
- The card_payments capability.
- """
- cartes_bancaires_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesCartesBancairesPayments"
- ]
- """
- The cartes_bancaires_payments capability.
- """
- cashapp_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesCashappPayments"
- ]
- """
- The cashapp_payments capability.
- """
- crypto_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesCryptoPayments"
- ]
- """
- The crypto_payments capability.
- """
- eps_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesEpsPayments"
- ]
- """
- The eps_payments capability.
- """
- fpx_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesFpxPayments"
- ]
- """
- The fpx_payments capability.
- """
- gb_bank_transfer_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesGbBankTransferPayments"
- ]
- """
- The gb_bank_transfer_payments capability.
- """
- giropay_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesGiropayPayments"
- ]
- """
- The giropay_payments capability.
- """
- grabpay_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesGrabpayPayments"
- ]
- """
- The grabpay_payments capability.
- """
- ideal_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesIdealPayments"
- ]
- """
- The ideal_payments capability.
- """
- india_international_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesIndiaInternationalPayments"
- ]
- """
- The india_international_payments capability.
- """
- jcb_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesJcbPayments"
- ]
- """
- The jcb_payments capability.
- """
- jp_bank_transfer_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesJpBankTransferPayments"
- ]
- """
- The jp_bank_transfer_payments capability.
- """
- kakao_pay_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesKakaoPayPayments"
- ]
- """
- The kakao_pay_payments capability.
- """
- klarna_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesKlarnaPayments"
- ]
- """
- The klarna_payments capability.
- """
- konbini_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesKonbiniPayments"
- ]
- """
- The konbini_payments capability.
- """
- kr_card_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesKrCardPayments"
- ]
- """
- The kr_card_payments capability.
- """
- legacy_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesLegacyPayments"
- ]
- """
- The legacy_payments capability.
- """
- link_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesLinkPayments"
- ]
- """
- The link_payments capability.
- """
- mb_way_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesMbWayPayments"
- ]
- """
- The mb_way_payments capability.
- """
- mobilepay_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesMobilepayPayments"
- ]
- """
- The mobilepay_payments capability.
- """
- multibanco_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesMultibancoPayments"
- ]
- """
- The multibanco_payments capability.
- """
- mx_bank_transfer_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesMxBankTransferPayments"
- ]
- """
- The mx_bank_transfer_payments capability.
- """
- naver_pay_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesNaverPayPayments"
- ]
- """
- The naver_pay_payments capability.
- """
- nz_bank_account_becs_debit_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesNzBankAccountBecsDebitPayments"
- ]
- """
- The nz_bank_account_becs_debit_payments capability.
- """
- oxxo_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesOxxoPayments"
- ]
- """
- The oxxo_payments capability.
- """
- p24_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesP24Payments"
- ]
- """
- The p24_payments capability.
- """
- pay_by_bank_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesPayByBankPayments"
- ]
- """
- The pay_by_bank_payments capability.
- """
- payco_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesPaycoPayments"
- ]
- """
- The payco_payments capability.
- """
- paynow_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesPaynowPayments"
- ]
- """
- The paynow_payments capability.
- """
- pix_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesPixPayments"
- ]
- """
- The pix_payments capability.
- """
- promptpay_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesPromptpayPayments"
- ]
- """
- The promptpay_payments capability.
- """
- revolut_pay_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesRevolutPayPayments"
- ]
- """
- The revolut_pay_payments capability.
- """
- samsung_pay_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesSamsungPayPayments"
- ]
- """
- The samsung_pay_payments capability.
- """
- satispay_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesSatispayPayments"
- ]
- """
- The satispay_payments capability.
- """
- sepa_bank_transfer_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesSepaBankTransferPayments"
- ]
- """
- The sepa_bank_transfer_payments capability.
- """
- sepa_debit_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesSepaDebitPayments"
- ]
- """
- The sepa_debit_payments capability.
- """
- sofort_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesSofortPayments"
- ]
- """
- The sofort_payments capability.
- """
- swish_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesSwishPayments"
- ]
- """
- The swish_payments capability.
- """
- tax_reporting_us_1099_k: NotRequired[
- "AccountService.CreateParamsCapabilitiesTaxReportingUs1099K"
- ]
- """
- The tax_reporting_us_1099_k capability.
- """
- tax_reporting_us_1099_misc: NotRequired[
- "AccountService.CreateParamsCapabilitiesTaxReportingUs1099Misc"
- ]
- """
- The tax_reporting_us_1099_misc capability.
- """
- transfers: NotRequired[
- "AccountService.CreateParamsCapabilitiesTransfers"
- ]
- """
- The transfers capability.
- """
- treasury: NotRequired[
- "AccountService.CreateParamsCapabilitiesTreasury"
- ]
- """
- The treasury capability.
- """
- twint_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesTwintPayments"
- ]
- """
- The twint_payments capability.
- """
- us_bank_account_ach_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesUsBankAccountAchPayments"
- ]
- """
- The us_bank_account_ach_payments capability.
- """
- us_bank_transfer_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesUsBankTransferPayments"
- ]
- """
- The us_bank_transfer_payments capability.
- """
- zip_payments: NotRequired[
- "AccountService.CreateParamsCapabilitiesZipPayments"
- ]
- """
- The zip_payments capability.
- """
-
- class CreateParamsCapabilitiesAcssDebitPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesAffirmPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesAfterpayClearpayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesAlmaPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesAmazonPayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesAuBecsDebitPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesBacsDebitPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesBancontactPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesBilliePayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesBlikPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesBoletoPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesCardIssuing(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesCardPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesCartesBancairesPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesCashappPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesCryptoPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesEpsPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesFpxPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesGbBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesGiropayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesGrabpayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesIdealPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesIndiaInternationalPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesJcbPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesJpBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesKakaoPayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesKlarnaPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesKonbiniPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesKrCardPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesLegacyPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesLinkPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesMbWayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesMobilepayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesMultibancoPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesMxBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesNaverPayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesNzBankAccountBecsDebitPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesOxxoPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesP24Payments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesPayByBankPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesPaycoPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesPaynowPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesPixPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesPromptpayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesRevolutPayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesSamsungPayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesSatispayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesSepaBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesSepaDebitPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesSofortPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesSwishPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesTaxReportingUs1099K(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesTaxReportingUs1099Misc(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesTransfers(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesTreasury(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesTwintPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesUsBankAccountAchPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesUsBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCapabilitiesZipPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class CreateParamsCard(TypedDict):
- object: Literal["card"]
- address_city: NotRequired[str]
- address_country: NotRequired[str]
- address_line1: NotRequired[str]
- address_line2: NotRequired[str]
- address_state: NotRequired[str]
- address_zip: NotRequired[str]
- currency: NotRequired[str]
- cvc: NotRequired[str]
- exp_month: int
- exp_year: int
- name: NotRequired[str]
- number: str
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- """
- default_for_currency: NotRequired[bool]
-
- class CreateParamsCardToken(TypedDict):
- object: Literal["card"]
- currency: NotRequired[str]
- token: str
-
- class CreateParamsCompany(TypedDict):
- address: NotRequired["AccountService.CreateParamsCompanyAddress"]
- """
- The company's primary address.
- """
- address_kana: NotRequired[
- "AccountService.CreateParamsCompanyAddressKana"
- ]
- """
- The Kana variation of the company's primary address (Japan only).
- """
- address_kanji: NotRequired[
- "AccountService.CreateParamsCompanyAddressKanji"
- ]
- """
- The Kanji variation of the company's primary address (Japan only).
- """
- directors_provided: NotRequired[bool]
- """
- Whether the company's directors have been provided. Set this Boolean to `true` after creating all the company's directors with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.director` requirement. This value is not automatically set to `true` after creating directors, so it needs to be updated to indicate all directors have been provided.
- """
- directorship_declaration: NotRequired[
- "AccountService.CreateParamsCompanyDirectorshipDeclaration"
- ]
- """
- This hash is used to attest that the directors information provided to Stripe is both current and correct.
- """
- executives_provided: NotRequired[bool]
- """
- Whether the company's executives have been provided. Set this Boolean to `true` after creating all the company's executives with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.executive` requirement.
- """
- export_license_id: NotRequired[str]
- """
- The export license ID number of the company, also referred as Import Export Code (India only).
- """
- export_purpose_code: NotRequired[str]
- """
- The purpose code to use for export transactions (India only).
- """
- name: NotRequired[str]
- """
- The company's legal name.
- """
- name_kana: NotRequired[str]
- """
- The Kana variation of the company's legal name (Japan only).
- """
- name_kanji: NotRequired[str]
- """
- The Kanji variation of the company's legal name (Japan only).
- """
- owners_provided: NotRequired[bool]
- """
- Whether the company's owners have been provided. Set this Boolean to `true` after creating all the company's owners with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.owner` requirement.
- """
- ownership_declaration: NotRequired[
- "AccountService.CreateParamsCompanyOwnershipDeclaration"
- ]
- """
- This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
- """
- ownership_exemption_reason: NotRequired[
- "Literal['']|Literal['qualified_entity_exceeds_ownership_threshold', 'qualifies_as_financial_institution']"
- ]
- """
- This value is used to determine if a business is exempt from providing ultimate beneficial owners. See [this support article](https://support.stripe.com/questions/exemption-from-providing-ownership-details) and [changelog](https://docs.stripe.com/changelog/acacia/2025-01-27/ownership-exemption-reason-accounts-api) for more details.
- """
- phone: NotRequired[str]
- """
- The company's phone number (used for verification).
- """
- registration_date: NotRequired[
- "Literal['']|AccountService.CreateParamsCompanyRegistrationDate"
- ]
- """
- When the business was incorporated or registered.
- """
- registration_number: NotRequired[str]
- """
- The identification number given to a company when it is registered or incorporated, if distinct from the identification number used for filing taxes. (Examples are the CIN for companies and LLP IN for partnerships in India, and the Company Registration Number in Hong Kong).
- """
- structure: NotRequired[
- "Literal['']|Literal['free_zone_establishment', 'free_zone_llc', 'government_instrumentality', 'governmental_unit', 'incorporated_non_profit', 'incorporated_partnership', 'limited_liability_partnership', 'llc', 'multi_member_llc', 'private_company', 'private_corporation', 'private_partnership', 'public_company', 'public_corporation', 'public_partnership', 'registered_charity', 'single_member_llc', 'sole_establishment', 'sole_proprietorship', 'tax_exempt_government_instrumentality', 'unincorporated_association', 'unincorporated_non_profit', 'unincorporated_partnership']"
- ]
- """
- The category identifying the legal structure of the company or legal entity. See [Business structure](https://docs.stripe.com/connect/identity-verification#business-structure) for more details. Pass an empty string to unset this value.
- """
- tax_id: NotRequired[str]
- """
- The business ID number of the company, as appropriate for the company's country. (Examples are an Employer ID Number in the U.S., a Business Number in Canada, or a Company Number in the UK.)
- """
- tax_id_registrar: NotRequired[str]
- """
- The jurisdiction in which the `tax_id` is registered (Germany-based companies only).
- """
- vat_id: NotRequired[str]
- """
- The VAT number of the company.
- """
- verification: NotRequired[
- "AccountService.CreateParamsCompanyVerification"
- ]
- """
- Information on the verification state of the company.
- """
-
- class CreateParamsCompanyAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsCompanyAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsCompanyAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsCompanyDirectorshipDeclaration(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the directorship declaration attestation was made.
- """
- ip: NotRequired[str]
- """
- The IP address from which the directorship declaration attestation was made.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the directorship declaration attestation was made.
- """
-
- class CreateParamsCompanyOwnershipDeclaration(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the beneficial owner attestation was made.
- """
- ip: NotRequired[str]
- """
- The IP address from which the beneficial owner attestation was made.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the beneficial owner attestation was made.
- """
-
- class CreateParamsCompanyRegistrationDate(TypedDict):
- day: int
- """
- The day of registration, between 1 and 31.
- """
- month: int
- """
- The month of registration, between 1 and 12.
- """
- year: int
- """
- The four-digit year of registration.
- """
-
- class CreateParamsCompanyVerification(TypedDict):
- document: NotRequired[
- "AccountService.CreateParamsCompanyVerificationDocument"
- ]
- """
- A document verifying the business.
- """
-
- class CreateParamsCompanyVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsController(TypedDict):
- fees: NotRequired["AccountService.CreateParamsControllerFees"]
- """
- A hash of configuration for who pays Stripe fees for product usage on this account.
- """
- losses: NotRequired["AccountService.CreateParamsControllerLosses"]
- """
- A hash of configuration for products that have negative balance liability, and whether Stripe or a Connect application is responsible for them.
- """
- requirement_collection: NotRequired[Literal["application", "stripe"]]
- """
- A value indicating responsibility for collecting updated information when requirements on the account are due or change. Defaults to `stripe`.
- """
- stripe_dashboard: NotRequired[
- "AccountService.CreateParamsControllerStripeDashboard"
- ]
- """
- A hash of configuration for Stripe-hosted dashboards.
- """
-
- class CreateParamsControllerFees(TypedDict):
- payer: NotRequired[Literal["account", "application"]]
- """
- A value indicating the responsible payer of Stripe fees on this account. Defaults to `account`. Learn more about [fee behavior on connected accounts](https://docs.stripe.com/connect/direct-charges-fee-payer-behavior).
- """
-
- class CreateParamsControllerLosses(TypedDict):
- payments: NotRequired[Literal["application", "stripe"]]
- """
- A value indicating who is liable when this account can't pay back negative balances resulting from payments. Defaults to `stripe`.
- """
-
- class CreateParamsControllerStripeDashboard(TypedDict):
- type: NotRequired[Literal["express", "full", "none"]]
- """
- Whether this account should have access to the full Stripe Dashboard (`full`), to the Express Dashboard (`express`), or to no Stripe-hosted dashboard (`none`). Defaults to `full`.
- """
-
- class CreateParamsDocuments(TypedDict):
- bank_account_ownership_verification: NotRequired[
- "AccountService.CreateParamsDocumentsBankAccountOwnershipVerification"
- ]
- """
- One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the account's primary active bank account that displays the last 4 digits of the account number, either a statement or a check.
- """
- company_license: NotRequired[
- "AccountService.CreateParamsDocumentsCompanyLicense"
- ]
- """
- One or more documents that demonstrate proof of a company's license to operate.
- """
- company_memorandum_of_association: NotRequired[
- "AccountService.CreateParamsDocumentsCompanyMemorandumOfAssociation"
- ]
- """
- One or more documents showing the company's Memorandum of Association.
- """
- company_ministerial_decree: NotRequired[
- "AccountService.CreateParamsDocumentsCompanyMinisterialDecree"
- ]
- """
- (Certain countries only) One or more documents showing the ministerial decree legalizing the company's establishment.
- """
- company_registration_verification: NotRequired[
- "AccountService.CreateParamsDocumentsCompanyRegistrationVerification"
- ]
- """
- One or more documents that demonstrate proof of a company's registration with the appropriate local authorities.
- """
- company_tax_id_verification: NotRequired[
- "AccountService.CreateParamsDocumentsCompanyTaxIdVerification"
- ]
- """
- One or more documents that demonstrate proof of a company's tax ID.
- """
- proof_of_address: NotRequired[
- "AccountService.CreateParamsDocumentsProofOfAddress"
- ]
- """
- One or more documents that demonstrate proof of address.
- """
- proof_of_registration: NotRequired[
- "AccountService.CreateParamsDocumentsProofOfRegistration"
- ]
- """
- One or more documents showing the company's proof of registration with the national business registry.
- """
- proof_of_ultimate_beneficial_ownership: NotRequired[
- "AccountService.CreateParamsDocumentsProofOfUltimateBeneficialOwnership"
- ]
- """
- One or more documents that demonstrate proof of ultimate beneficial ownership.
- """
-
- class CreateParamsDocumentsBankAccountOwnershipVerification(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsCompanyLicense(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsCompanyMemorandumOfAssociation(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsCompanyMinisterialDecree(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsCompanyRegistrationVerification(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsCompanyTaxIdVerification(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsProofOfAddress(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsProofOfRegistration(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsDocumentsProofOfUltimateBeneficialOwnership(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsGroups(TypedDict):
- payments_pricing: NotRequired["Literal['']|str"]
- """
- The group the account is in to determine their payments pricing, and null if the account is on customized pricing. [See the Platform pricing tool documentation](https://stripe.com/docs/connect/platform-pricing-tools) for details.
- """
-
- class CreateParamsIndividual(TypedDict):
- address: NotRequired["AccountService.CreateParamsIndividualAddress"]
- """
- The individual's primary address.
- """
- address_kana: NotRequired[
- "AccountService.CreateParamsIndividualAddressKana"
- ]
- """
- The Kana variation of the individual's primary address (Japan only).
- """
- address_kanji: NotRequired[
- "AccountService.CreateParamsIndividualAddressKanji"
- ]
- """
- The Kanji variation of the individual's primary address (Japan only).
- """
- dob: NotRequired[
- "Literal['']|AccountService.CreateParamsIndividualDob"
- ]
- """
- The individual's date of birth.
- """
- email: NotRequired[str]
- """
- The individual's email address.
- """
- first_name: NotRequired[str]
- """
- The individual's first name.
- """
- first_name_kana: NotRequired[str]
- """
- The Kana variation of the individual's first name (Japan only).
- """
- first_name_kanji: NotRequired[str]
- """
- The Kanji variation of the individual's first name (Japan only).
- """
- full_name_aliases: NotRequired["Literal['']|List[str]"]
- """
- A list of alternate names or aliases that the individual is known by.
- """
- gender: NotRequired[str]
- """
- The individual's gender
- """
- id_number: NotRequired[str]
- """
- The government-issued ID number of the individual, as appropriate for the representative's country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in Canada). Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- id_number_secondary: NotRequired[str]
- """
- The government-issued secondary ID number of the individual, as appropriate for the representative's country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- last_name: NotRequired[str]
- """
- The individual's last name.
- """
- last_name_kana: NotRequired[str]
- """
- The Kana variation of the individual's last name (Japan only).
- """
- last_name_kanji: NotRequired[str]
- """
- The Kanji variation of the individual's last name (Japan only).
- """
- maiden_name: NotRequired[str]
- """
- The individual's maiden name.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- phone: NotRequired[str]
- """
- The individual's phone number.
- """
- political_exposure: NotRequired[Literal["existing", "none"]]
- """
- Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
- """
- registered_address: NotRequired[
- "AccountService.CreateParamsIndividualRegisteredAddress"
- ]
- """
- The individual's registered address.
- """
- relationship: NotRequired[
- "AccountService.CreateParamsIndividualRelationship"
- ]
- """
- Describes the person's relationship to the account.
- """
- ssn_last_4: NotRequired[str]
- """
- The last four digits of the individual's Social Security Number (U.S. only).
- """
- verification: NotRequired[
- "AccountService.CreateParamsIndividualVerification"
- ]
- """
- The individual's verification document information.
- """
-
- class CreateParamsIndividualAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsIndividualAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsIndividualAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsIndividualDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsIndividualRegisteredAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsIndividualRelationship(TypedDict):
- director: NotRequired[bool]
- """
- Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
- """
- executive: NotRequired[bool]
- """
- Whether the person has significant responsibility to control, manage, or direct the organization.
- """
- owner: NotRequired[bool]
- """
- Whether the person is an owner of the account's legal entity.
- """
- percent_ownership: NotRequired["Literal['']|float"]
- """
- The percent owned by the person of the account's legal entity.
- """
- title: NotRequired[str]
- """
- The person's title (e.g., CEO, Support Engineer).
- """
-
- class CreateParamsIndividualVerification(TypedDict):
- additional_document: NotRequired[
- "AccountService.CreateParamsIndividualVerificationAdditionalDocument"
- ]
- """
- A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
- """
- document: NotRequired[
- "AccountService.CreateParamsIndividualVerificationDocument"
- ]
- """
- An identifying document, either a passport or local ID card.
- """
-
- class CreateParamsIndividualVerificationAdditionalDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsIndividualVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsSettings(TypedDict):
- bacs_debit_payments: NotRequired[
- "AccountService.CreateParamsSettingsBacsDebitPayments"
- ]
- """
- Settings specific to Bacs Direct Debit.
- """
- branding: NotRequired["AccountService.CreateParamsSettingsBranding"]
- """
- Settings used to apply the account's branding to email receipts, invoices, Checkout, and other products.
- """
- card_issuing: NotRequired[
- "AccountService.CreateParamsSettingsCardIssuing"
- ]
- """
- Settings specific to the account's use of the Card Issuing product.
- """
- card_payments: NotRequired[
- "AccountService.CreateParamsSettingsCardPayments"
- ]
- """
- Settings specific to card charging on the account.
- """
- invoices: NotRequired["AccountService.CreateParamsSettingsInvoices"]
- """
- Settings specific to the account's use of Invoices.
- """
- payments: NotRequired["AccountService.CreateParamsSettingsPayments"]
- """
- Settings that apply across payment methods for charging on the account.
- """
- payouts: NotRequired["AccountService.CreateParamsSettingsPayouts"]
- """
- Settings specific to the account's payouts.
- """
- treasury: NotRequired["AccountService.CreateParamsSettingsTreasury"]
- """
- Settings specific to the account's Treasury FinancialAccounts.
- """
-
- class CreateParamsSettingsBacsDebitPayments(TypedDict):
- display_name: NotRequired[str]
- """
- The Bacs Direct Debit Display Name for this account. For payments made with Bacs Direct Debit, this name appears on the mandate as the statement descriptor. Mobile banking apps display it as the name of the business. To use custom branding, set the Bacs Direct Debit Display Name during or right after creation. Custom branding incurs an additional monthly fee for the platform. If you don't set the display name before requesting Bacs capability, it's automatically set as "Stripe" and the account is onboarded to Stripe branding, which is free.
- """
-
- class CreateParamsSettingsBranding(TypedDict):
- icon: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) An icon for the account. Must be square and at least 128px x 128px.
- """
- logo: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A logo for the account that will be used in Checkout instead of the icon and without the account's name next to it if provided. Must be at least 128px x 128px.
- """
- primary_color: NotRequired[str]
- """
- A CSS hex color value representing the primary branding color for this account.
- """
- secondary_color: NotRequired[str]
- """
- A CSS hex color value representing the secondary branding color for this account.
- """
-
- class CreateParamsSettingsCardIssuing(TypedDict):
- tos_acceptance: NotRequired[
- "AccountService.CreateParamsSettingsCardIssuingTosAcceptance"
- ]
- """
- Details on the account's acceptance of the [Stripe Issuing Terms and Disclosures](https://docs.stripe.com/issuing/connect/tos_acceptance).
- """
-
- class CreateParamsSettingsCardIssuingTosAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the account representative accepted the service agreement.
- """
- ip: NotRequired[str]
- """
- The IP address from which the account representative accepted the service agreement.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the account representative accepted the service agreement.
- """
-
- class CreateParamsSettingsCardPayments(TypedDict):
- decline_on: NotRequired[
- "AccountService.CreateParamsSettingsCardPaymentsDeclineOn"
- ]
- """
- Automatically declines certain charge types regardless of whether the card issuer accepted or declined the charge.
- """
- statement_descriptor_prefix: NotRequired[str]
- """
- The default text that appears on credit card statements when a charge is made. This field prefixes any dynamic `statement_descriptor` specified on the charge. `statement_descriptor_prefix` is useful for maximizing descriptor space for the dynamic portion.
- """
- statement_descriptor_prefix_kana: NotRequired["Literal['']|str"]
- """
- The Kana variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kana` specified on the charge. `statement_descriptor_prefix_kana` is useful for maximizing descriptor space for the dynamic portion.
- """
- statement_descriptor_prefix_kanji: NotRequired["Literal['']|str"]
- """
- The Kanji variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kanji` specified on the charge. `statement_descriptor_prefix_kanji` is useful for maximizing descriptor space for the dynamic portion.
- """
-
- class CreateParamsSettingsCardPaymentsDeclineOn(TypedDict):
- avs_failure: NotRequired[bool]
- """
- Whether Stripe automatically declines charges with an incorrect ZIP or postal code. This setting only applies when a ZIP or postal code is provided and they fail bank verification.
- """
- cvc_failure: NotRequired[bool]
- """
- Whether Stripe automatically declines charges with an incorrect CVC. This setting only applies when a CVC is provided and it fails bank verification.
- """
-
- class CreateParamsSettingsInvoices(TypedDict):
- hosted_payment_method_save: NotRequired[
- Literal["always", "never", "offer"]
- ]
- """
- Whether payment methods should be saved when a payment is completed for a one-time invoices on a hosted invoice page.
- """
-
- class CreateParamsSettingsPayments(TypedDict):
- statement_descriptor: NotRequired[str]
- """
- The default text that appears on statements for non-card charges outside of Japan. For card charges, if you don't set a `statement_descriptor_prefix`, this text is also used as the statement descriptor prefix. In that case, if concatenating the statement descriptor suffix causes the combined statement descriptor to exceed 22 characters, we truncate the `statement_descriptor` text to limit the full descriptor to 22 characters. For more information about statement descriptors and their requirements, see the [account settings documentation](https://docs.stripe.com/get-started/account/statement-descriptors).
- """
- statement_descriptor_kana: NotRequired[str]
- """
- The Kana variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
- """
- statement_descriptor_kanji: NotRequired[str]
- """
- The Kanji variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
- """
-
- class CreateParamsSettingsPayouts(TypedDict):
- debit_negative_balances: NotRequired[bool]
- """
- A Boolean indicating whether Stripe should try to reclaim negative balances from an attached bank account. For details, see [Understanding Connect Account Balances](https://docs.stripe.com/connect/account-balances).
- """
- schedule: NotRequired[
- "AccountService.CreateParamsSettingsPayoutsSchedule"
- ]
- """
- Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](https://docs.stripe.com/connect/bank-transfers#payout-information) documentation.
- """
- statement_descriptor: NotRequired[str]
- """
- The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
- """
-
- class CreateParamsSettingsPayoutsSchedule(TypedDict):
- delay_days: NotRequired["Literal['minimum']|int"]
- """
- The number of days charge funds are held before being paid out. May also be set to `minimum`, representing the lowest available value for the account country. Default is `minimum`. The `delay_days` parameter remains at the last configured value if `interval` is `manual`. [Learn more about controlling payout delay days](https://docs.stripe.com/connect/manage-payout-schedule).
- """
- interval: NotRequired[Literal["daily", "manual", "monthly", "weekly"]]
- """
- How frequently available funds are paid out. One of: `daily`, `manual`, `weekly`, or `monthly`. Default is `daily`.
- """
- monthly_anchor: NotRequired[int]
- """
- The day of the month when available funds are paid out, specified as a number between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly`.
- """
- monthly_payout_days: NotRequired[List[int]]
- """
- The days of the month when available funds are paid out, specified as an array of numbers between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly` and `monthly_anchor` is not set.
- """
- weekly_anchor: NotRequired[
- Literal[
- "friday",
- "monday",
- "saturday",
- "sunday",
- "thursday",
- "tuesday",
- "wednesday",
- ]
- ]
- """
- The day of the week when available funds are paid out, specified as `monday`, `tuesday`, etc. Required and applicable only if `interval` is `weekly`.
- """
- weekly_payout_days: NotRequired[
- List[
- Literal["friday", "monday", "thursday", "tuesday", "wednesday"]
- ]
- ]
- """
- The days of the week when available funds are paid out, specified as an array, e.g., [`monday`, `tuesday`]. Required and applicable only if `interval` is `weekly`.
- """
-
- class CreateParamsSettingsTreasury(TypedDict):
- tos_acceptance: NotRequired[
- "AccountService.CreateParamsSettingsTreasuryTosAcceptance"
- ]
- """
- Details on the account's acceptance of the Stripe Treasury Services Agreement.
- """
-
- class CreateParamsSettingsTreasuryTosAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the account representative accepted the service agreement.
- """
- ip: NotRequired[str]
- """
- The IP address from which the account representative accepted the service agreement.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the account representative accepted the service agreement.
- """
-
- class CreateParamsTosAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the account representative accepted their service agreement.
- """
- ip: NotRequired[str]
- """
- The IP address from which the account representative accepted their service agreement.
- """
- service_agreement: NotRequired[str]
- """
- The user's service agreement type.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the account representative accepted their service agreement.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- created: NotRequired["AccountService.ListParamsCreated|int"]
- """
- Only return connected accounts that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RejectParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- reason: str
- """
- The reason for rejecting the account. Can be `fraud`, `terms_of_service`, or `other`.
- """
-
- class RetrieveCurrentParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- account_token: NotRequired[str]
- """
- An [account token](https://stripe.com/docs/api#create_account_token), used to securely provide details to the account.
- """
- business_profile: NotRequired[
- "AccountService.UpdateParamsBusinessProfile"
- ]
- """
- Business information about the account.
- """
- business_type: NotRequired[
- Literal["company", "government_entity", "individual", "non_profit"]
- ]
- """
- The business type. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
- """
- capabilities: NotRequired["AccountService.UpdateParamsCapabilities"]
- """
- Each key of the dictionary represents a capability, and each capability
- maps to its settings (for example, whether it has been requested or not). Each
- capability is inactive until you have provided its specific
- requirements and Stripe has verified them. An account might have some
- of its requested capabilities be active and some be inactive.
-
- Required when [account.controller.stripe_dashboard.type](https://docs.stripe.com/api/accounts/create#create_account-controller-dashboard-type)
- is `none`, which includes Custom accounts.
- """
- company: NotRequired["AccountService.UpdateParamsCompany"]
- """
- Information about the company or business. This field is available for any `business_type`. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
- """
- default_currency: NotRequired[str]
- """
- Three-letter ISO currency code representing the default currency for the account. This must be a currency that [Stripe supports in the account's country](https://docs.stripe.com/payouts).
- """
- documents: NotRequired["AccountService.UpdateParamsDocuments"]
- """
- Documents that may be submitted to satisfy various informational requests.
- """
- email: NotRequired[str]
- """
- The email address of the account holder. This is only to make the account easier to identify to you. If [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, Stripe doesn't email the account without your consent.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- external_account: NotRequired[
- "Literal['']|str|AccountService.UpdateParamsBankAccount|AccountService.UpdateParamsCard|AccountService.UpdateParamsCardToken"
- ]
- """
- A card or bank account to attach to the account for receiving [payouts](https://docs.stripe.com/connect/bank-debit-card-payouts) (you won't be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](https://docs.stripe.com/js), or a dictionary, as documented in the `external_account` parameter for [bank account](https://docs.stripe.com/api#account_create_bank_account) creation.
-
- By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the [bank account](https://docs.stripe.com/api#account_create_bank_account) or [card creation](https://docs.stripe.com/api#account_create_card) APIs. After you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
- """
- groups: NotRequired["AccountService.UpdateParamsGroups"]
- """
- A hash of account group type to tokens. These are account groups this account should be added to.
- """
- individual: NotRequired["AccountService.UpdateParamsIndividual"]
- """
- Information about the person represented by the account. This field is null unless `business_type` is set to `individual`. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- settings: NotRequired["AccountService.UpdateParamsSettings"]
- """
- Options for customizing how the account functions within Stripe.
- """
- tos_acceptance: NotRequired["AccountService.UpdateParamsTosAcceptance"]
- """
- Details on the account's acceptance of the [Stripe Services Agreement](https://docs.stripe.com/connect/updating-accounts#tos-acceptance). This property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts. This property defaults to a `full` service agreement when empty.
- """
-
- class UpdateParamsBankAccount(TypedDict):
- object: Literal["bank_account"]
- account_holder_name: NotRequired[str]
- """
- The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object.
- """
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
- """
- account_number: str
- """
- The account number for the bank account, in string form. Must be a checking account.
- """
- country: str
- """
- The country in which the bank account is located.
- """
- currency: NotRequired[str]
- """
- The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts)
- """
- routing_number: NotRequired[str]
- """
- The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
- """
-
- class UpdateParamsBusinessProfile(TypedDict):
- annual_revenue: NotRequired[
- "AccountService.UpdateParamsBusinessProfileAnnualRevenue"
- ]
- """
- The applicant's gross annual revenue for its preceding fiscal year.
- """
- estimated_worker_count: NotRequired[int]
- """
- An estimated upper bound of employees, contractors, vendors, etc. currently working for the business.
- """
- mcc: NotRequired[str]
- """
- [The merchant category code for the account](https://docs.stripe.com/connect/setting-mcc). MCCs are used to classify businesses based on the goods or services they provide.
- """
- minority_owned_business_designation: NotRequired[
- List[
- Literal[
- "lgbtqi_owned_business",
- "minority_owned_business",
- "none_of_these_apply",
- "prefer_not_to_answer",
- "women_owned_business",
- ]
- ]
- ]
- """
- Whether the business is a minority-owned, women-owned, and/or LGBTQI+ -owned business.
- """
- monthly_estimated_revenue: NotRequired[
- "AccountService.UpdateParamsBusinessProfileMonthlyEstimatedRevenue"
- ]
- """
- An estimate of the monthly revenue of the business. Only accepted for accounts in Brazil and India.
- """
- name: NotRequired[str]
- """
- The customer-facing business name.
- """
- product_description: NotRequired[str]
- """
- Internal-only description of the product sold by, or service provided by, the business. Used by Stripe for risk and underwriting purposes.
- """
- support_address: NotRequired[
- "AccountService.UpdateParamsBusinessProfileSupportAddress"
- ]
- """
- A publicly available mailing address for sending support issues to.
- """
- support_email: NotRequired[str]
- """
- A publicly available email address for sending support issues to.
- """
- support_phone: NotRequired[str]
- """
- A publicly available phone number to call with support issues.
- """
- support_url: NotRequired["Literal['']|str"]
- """
- A publicly available website for handling support issues.
- """
- url: NotRequired[str]
- """
- The business's publicly available website.
- """
-
- class UpdateParamsBusinessProfileAnnualRevenue(TypedDict):
- amount: int
- """
- A non-negative integer representing the amount in the [smallest currency unit](https://docs.stripe.com/currencies#zero-decimal).
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- fiscal_year_end: str
- """
- The close-out date of the preceding fiscal year in ISO 8601 format. E.g. 2023-12-31 for the 31st of December, 2023.
- """
-
- class UpdateParamsBusinessProfileMonthlyEstimatedRevenue(TypedDict):
- amount: int
- """
- A non-negative integer representing how much to charge in the [smallest currency unit](https://docs.stripe.com/currencies#zero-decimal).
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class UpdateParamsBusinessProfileSupportAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsCapabilities(TypedDict):
- acss_debit_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesAcssDebitPayments"
- ]
- """
- The acss_debit_payments capability.
- """
- affirm_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesAffirmPayments"
- ]
- """
- The affirm_payments capability.
- """
- afterpay_clearpay_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesAfterpayClearpayPayments"
- ]
- """
- The afterpay_clearpay_payments capability.
- """
- alma_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesAlmaPayments"
- ]
- """
- The alma_payments capability.
- """
- amazon_pay_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesAmazonPayPayments"
- ]
- """
- The amazon_pay_payments capability.
- """
- au_becs_debit_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesAuBecsDebitPayments"
- ]
- """
- The au_becs_debit_payments capability.
- """
- bacs_debit_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesBacsDebitPayments"
- ]
- """
- The bacs_debit_payments capability.
- """
- bancontact_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesBancontactPayments"
- ]
- """
- The bancontact_payments capability.
- """
- bank_transfer_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesBankTransferPayments"
- ]
- """
- The bank_transfer_payments capability.
- """
- billie_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesBilliePayments"
- ]
- """
- The billie_payments capability.
- """
- blik_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesBlikPayments"
- ]
- """
- The blik_payments capability.
- """
- boleto_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesBoletoPayments"
- ]
- """
- The boleto_payments capability.
- """
- card_issuing: NotRequired[
- "AccountService.UpdateParamsCapabilitiesCardIssuing"
- ]
- """
- The card_issuing capability.
- """
- card_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesCardPayments"
- ]
- """
- The card_payments capability.
- """
- cartes_bancaires_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesCartesBancairesPayments"
- ]
- """
- The cartes_bancaires_payments capability.
- """
- cashapp_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesCashappPayments"
- ]
- """
- The cashapp_payments capability.
- """
- crypto_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesCryptoPayments"
- ]
- """
- The crypto_payments capability.
- """
- eps_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesEpsPayments"
- ]
- """
- The eps_payments capability.
- """
- fpx_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesFpxPayments"
- ]
- """
- The fpx_payments capability.
- """
- gb_bank_transfer_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesGbBankTransferPayments"
- ]
- """
- The gb_bank_transfer_payments capability.
- """
- giropay_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesGiropayPayments"
- ]
- """
- The giropay_payments capability.
- """
- grabpay_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesGrabpayPayments"
- ]
- """
- The grabpay_payments capability.
- """
- ideal_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesIdealPayments"
- ]
- """
- The ideal_payments capability.
- """
- india_international_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesIndiaInternationalPayments"
- ]
- """
- The india_international_payments capability.
- """
- jcb_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesJcbPayments"
- ]
- """
- The jcb_payments capability.
- """
- jp_bank_transfer_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesJpBankTransferPayments"
- ]
- """
- The jp_bank_transfer_payments capability.
- """
- kakao_pay_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesKakaoPayPayments"
- ]
- """
- The kakao_pay_payments capability.
- """
- klarna_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesKlarnaPayments"
- ]
- """
- The klarna_payments capability.
- """
- konbini_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesKonbiniPayments"
- ]
- """
- The konbini_payments capability.
- """
- kr_card_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesKrCardPayments"
- ]
- """
- The kr_card_payments capability.
- """
- legacy_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesLegacyPayments"
- ]
- """
- The legacy_payments capability.
- """
- link_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesLinkPayments"
- ]
- """
- The link_payments capability.
- """
- mb_way_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesMbWayPayments"
- ]
- """
- The mb_way_payments capability.
- """
- mobilepay_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesMobilepayPayments"
- ]
- """
- The mobilepay_payments capability.
- """
- multibanco_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesMultibancoPayments"
- ]
- """
- The multibanco_payments capability.
- """
- mx_bank_transfer_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesMxBankTransferPayments"
- ]
- """
- The mx_bank_transfer_payments capability.
- """
- naver_pay_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesNaverPayPayments"
- ]
- """
- The naver_pay_payments capability.
- """
- nz_bank_account_becs_debit_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesNzBankAccountBecsDebitPayments"
- ]
- """
- The nz_bank_account_becs_debit_payments capability.
- """
- oxxo_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesOxxoPayments"
- ]
- """
- The oxxo_payments capability.
- """
- p24_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesP24Payments"
- ]
- """
- The p24_payments capability.
- """
- pay_by_bank_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesPayByBankPayments"
- ]
- """
- The pay_by_bank_payments capability.
- """
- payco_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesPaycoPayments"
- ]
- """
- The payco_payments capability.
- """
- paynow_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesPaynowPayments"
- ]
- """
- The paynow_payments capability.
- """
- pix_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesPixPayments"
- ]
- """
- The pix_payments capability.
- """
- promptpay_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesPromptpayPayments"
- ]
- """
- The promptpay_payments capability.
- """
- revolut_pay_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesRevolutPayPayments"
- ]
- """
- The revolut_pay_payments capability.
- """
- samsung_pay_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesSamsungPayPayments"
- ]
- """
- The samsung_pay_payments capability.
- """
- satispay_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesSatispayPayments"
- ]
- """
- The satispay_payments capability.
- """
- sepa_bank_transfer_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesSepaBankTransferPayments"
- ]
- """
- The sepa_bank_transfer_payments capability.
- """
- sepa_debit_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesSepaDebitPayments"
- ]
- """
- The sepa_debit_payments capability.
- """
- sofort_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesSofortPayments"
- ]
- """
- The sofort_payments capability.
- """
- swish_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesSwishPayments"
- ]
- """
- The swish_payments capability.
- """
- tax_reporting_us_1099_k: NotRequired[
- "AccountService.UpdateParamsCapabilitiesTaxReportingUs1099K"
- ]
- """
- The tax_reporting_us_1099_k capability.
- """
- tax_reporting_us_1099_misc: NotRequired[
- "AccountService.UpdateParamsCapabilitiesTaxReportingUs1099Misc"
- ]
- """
- The tax_reporting_us_1099_misc capability.
- """
- transfers: NotRequired[
- "AccountService.UpdateParamsCapabilitiesTransfers"
- ]
- """
- The transfers capability.
- """
- treasury: NotRequired[
- "AccountService.UpdateParamsCapabilitiesTreasury"
- ]
- """
- The treasury capability.
- """
- twint_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesTwintPayments"
- ]
- """
- The twint_payments capability.
- """
- us_bank_account_ach_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesUsBankAccountAchPayments"
- ]
- """
- The us_bank_account_ach_payments capability.
- """
- us_bank_transfer_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesUsBankTransferPayments"
- ]
- """
- The us_bank_transfer_payments capability.
- """
- zip_payments: NotRequired[
- "AccountService.UpdateParamsCapabilitiesZipPayments"
- ]
- """
- The zip_payments capability.
- """
-
- class UpdateParamsCapabilitiesAcssDebitPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesAffirmPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesAfterpayClearpayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesAlmaPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesAmazonPayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesAuBecsDebitPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesBacsDebitPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesBancontactPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesBilliePayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesBlikPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesBoletoPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesCardIssuing(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesCardPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesCartesBancairesPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesCashappPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesCryptoPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesEpsPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesFpxPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesGbBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesGiropayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesGrabpayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesIdealPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesIndiaInternationalPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesJcbPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesJpBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesKakaoPayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesKlarnaPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesKonbiniPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesKrCardPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesLegacyPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesLinkPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesMbWayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesMobilepayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesMultibancoPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesMxBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesNaverPayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesNzBankAccountBecsDebitPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesOxxoPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesP24Payments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesPayByBankPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesPaycoPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesPaynowPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesPixPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesPromptpayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesRevolutPayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesSamsungPayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesSatispayPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesSepaBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesSepaDebitPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesSofortPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesSwishPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesTaxReportingUs1099K(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesTaxReportingUs1099Misc(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesTransfers(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesTreasury(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesTwintPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesUsBankAccountAchPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesUsBankTransferPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCapabilitiesZipPayments(TypedDict):
- requested: NotRequired[bool]
- """
- Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
- """
-
- class UpdateParamsCard(TypedDict):
- object: Literal["card"]
- address_city: NotRequired[str]
- address_country: NotRequired[str]
- address_line1: NotRequired[str]
- address_line2: NotRequired[str]
- address_state: NotRequired[str]
- address_zip: NotRequired[str]
- currency: NotRequired[str]
- cvc: NotRequired[str]
- exp_month: int
- exp_year: int
- name: NotRequired[str]
- number: str
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- """
- default_for_currency: NotRequired[bool]
-
- class UpdateParamsCardToken(TypedDict):
- object: Literal["card"]
- currency: NotRequired[str]
- token: str
-
- class UpdateParamsCompany(TypedDict):
- address: NotRequired["AccountService.UpdateParamsCompanyAddress"]
- """
- The company's primary address.
- """
- address_kana: NotRequired[
- "AccountService.UpdateParamsCompanyAddressKana"
- ]
- """
- The Kana variation of the company's primary address (Japan only).
- """
- address_kanji: NotRequired[
- "AccountService.UpdateParamsCompanyAddressKanji"
- ]
- """
- The Kanji variation of the company's primary address (Japan only).
- """
- directors_provided: NotRequired[bool]
- """
- Whether the company's directors have been provided. Set this Boolean to `true` after creating all the company's directors with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.director` requirement. This value is not automatically set to `true` after creating directors, so it needs to be updated to indicate all directors have been provided.
- """
- directorship_declaration: NotRequired[
- "AccountService.UpdateParamsCompanyDirectorshipDeclaration"
- ]
- """
- This hash is used to attest that the directors information provided to Stripe is both current and correct.
- """
- executives_provided: NotRequired[bool]
- """
- Whether the company's executives have been provided. Set this Boolean to `true` after creating all the company's executives with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.executive` requirement.
- """
- export_license_id: NotRequired[str]
- """
- The export license ID number of the company, also referred as Import Export Code (India only).
- """
- export_purpose_code: NotRequired[str]
- """
- The purpose code to use for export transactions (India only).
- """
- name: NotRequired[str]
- """
- The company's legal name.
- """
- name_kana: NotRequired[str]
- """
- The Kana variation of the company's legal name (Japan only).
- """
- name_kanji: NotRequired[str]
- """
- The Kanji variation of the company's legal name (Japan only).
- """
- owners_provided: NotRequired[bool]
- """
- Whether the company's owners have been provided. Set this Boolean to `true` after creating all the company's owners with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.owner` requirement.
- """
- ownership_declaration: NotRequired[
- "AccountService.UpdateParamsCompanyOwnershipDeclaration"
- ]
- """
- This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
- """
- ownership_exemption_reason: NotRequired[
- "Literal['']|Literal['qualified_entity_exceeds_ownership_threshold', 'qualifies_as_financial_institution']"
- ]
- """
- This value is used to determine if a business is exempt from providing ultimate beneficial owners. See [this support article](https://support.stripe.com/questions/exemption-from-providing-ownership-details) and [changelog](https://docs.stripe.com/changelog/acacia/2025-01-27/ownership-exemption-reason-accounts-api) for more details.
- """
- phone: NotRequired[str]
- """
- The company's phone number (used for verification).
- """
- registration_date: NotRequired[
- "Literal['']|AccountService.UpdateParamsCompanyRegistrationDate"
- ]
- registration_number: NotRequired[str]
- """
- The identification number given to a company when it is registered or incorporated, if distinct from the identification number used for filing taxes. (Examples are the CIN for companies and LLP IN for partnerships in India, and the Company Registration Number in Hong Kong).
- """
- structure: NotRequired[
- "Literal['']|Literal['free_zone_establishment', 'free_zone_llc', 'government_instrumentality', 'governmental_unit', 'incorporated_non_profit', 'incorporated_partnership', 'limited_liability_partnership', 'llc', 'multi_member_llc', 'private_company', 'private_corporation', 'private_partnership', 'public_company', 'public_corporation', 'public_partnership', 'registered_charity', 'single_member_llc', 'sole_establishment', 'sole_proprietorship', 'tax_exempt_government_instrumentality', 'unincorporated_association', 'unincorporated_non_profit', 'unincorporated_partnership']"
- ]
- """
- The category identifying the legal structure of the company or legal entity. See [Business structure](https://docs.stripe.com/connect/identity-verification#business-structure) for more details. Pass an empty string to unset this value.
- """
- tax_id: NotRequired[str]
- """
- The business ID number of the company, as appropriate for the company's country. (Examples are an Employer ID Number in the U.S., a Business Number in Canada, or a Company Number in the UK.)
- """
- tax_id_registrar: NotRequired[str]
- """
- The jurisdiction in which the `tax_id` is registered (Germany-based companies only).
- """
- vat_id: NotRequired[str]
- """
- The VAT number of the company.
- """
- verification: NotRequired[
- "AccountService.UpdateParamsCompanyVerification"
- ]
- """
- Information on the verification state of the company.
- """
-
- class UpdateParamsCompanyAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsCompanyAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class UpdateParamsCompanyAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class UpdateParamsCompanyDirectorshipDeclaration(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the directorship declaration attestation was made.
- """
- ip: NotRequired[str]
- """
- The IP address from which the directorship declaration attestation was made.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the directorship declaration attestation was made.
- """
-
- class UpdateParamsCompanyOwnershipDeclaration(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the beneficial owner attestation was made.
- """
- ip: NotRequired[str]
- """
- The IP address from which the beneficial owner attestation was made.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the beneficial owner attestation was made.
- """
-
- class UpdateParamsCompanyRegistrationDate(TypedDict):
- day: int
- """
- The day of registration, between 1 and 31.
- """
- month: int
- """
- The month of registration, between 1 and 12.
- """
- year: int
- """
- The four-digit year of registration.
- """
-
- class UpdateParamsCompanyVerification(TypedDict):
- document: NotRequired[
- "AccountService.UpdateParamsCompanyVerificationDocument"
- ]
- """
- A document verifying the business.
- """
-
- class UpdateParamsCompanyVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class UpdateParamsDocuments(TypedDict):
- bank_account_ownership_verification: NotRequired[
- "AccountService.UpdateParamsDocumentsBankAccountOwnershipVerification"
- ]
- """
- One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the account's primary active bank account that displays the last 4 digits of the account number, either a statement or a check.
- """
- company_license: NotRequired[
- "AccountService.UpdateParamsDocumentsCompanyLicense"
- ]
- """
- One or more documents that demonstrate proof of a company's license to operate.
- """
- company_memorandum_of_association: NotRequired[
- "AccountService.UpdateParamsDocumentsCompanyMemorandumOfAssociation"
- ]
- """
- One or more documents showing the company's Memorandum of Association.
- """
- company_ministerial_decree: NotRequired[
- "AccountService.UpdateParamsDocumentsCompanyMinisterialDecree"
- ]
- """
- (Certain countries only) One or more documents showing the ministerial decree legalizing the company's establishment.
- """
- company_registration_verification: NotRequired[
- "AccountService.UpdateParamsDocumentsCompanyRegistrationVerification"
- ]
- """
- One or more documents that demonstrate proof of a company's registration with the appropriate local authorities.
- """
- company_tax_id_verification: NotRequired[
- "AccountService.UpdateParamsDocumentsCompanyTaxIdVerification"
- ]
- """
- One or more documents that demonstrate proof of a company's tax ID.
- """
- proof_of_address: NotRequired[
- "AccountService.UpdateParamsDocumentsProofOfAddress"
- ]
- """
- One or more documents that demonstrate proof of address.
- """
- proof_of_registration: NotRequired[
- "AccountService.UpdateParamsDocumentsProofOfRegistration"
- ]
- """
- One or more documents showing the company's proof of registration with the national business registry.
- """
- proof_of_ultimate_beneficial_ownership: NotRequired[
- "AccountService.UpdateParamsDocumentsProofOfUltimateBeneficialOwnership"
- ]
- """
- One or more documents that demonstrate proof of ultimate beneficial ownership.
- """
-
- class UpdateParamsDocumentsBankAccountOwnershipVerification(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class UpdateParamsDocumentsCompanyLicense(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class UpdateParamsDocumentsCompanyMemorandumOfAssociation(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class UpdateParamsDocumentsCompanyMinisterialDecree(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class UpdateParamsDocumentsCompanyRegistrationVerification(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class UpdateParamsDocumentsCompanyTaxIdVerification(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class UpdateParamsDocumentsProofOfAddress(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class UpdateParamsDocumentsProofOfRegistration(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class UpdateParamsDocumentsProofOfUltimateBeneficialOwnership(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class UpdateParamsGroups(TypedDict):
- payments_pricing: NotRequired["Literal['']|str"]
- """
- The group the account is in to determine their payments pricing, and null if the account is on customized pricing. [See the Platform pricing tool documentation](https://stripe.com/docs/connect/platform-pricing-tools) for details.
- """
-
- class UpdateParamsIndividual(TypedDict):
- address: NotRequired["AccountService.UpdateParamsIndividualAddress"]
- """
- The individual's primary address.
- """
- address_kana: NotRequired[
- "AccountService.UpdateParamsIndividualAddressKana"
- ]
- """
- The Kana variation of the individual's primary address (Japan only).
- """
- address_kanji: NotRequired[
- "AccountService.UpdateParamsIndividualAddressKanji"
- ]
- """
- The Kanji variation of the individual's primary address (Japan only).
- """
- dob: NotRequired[
- "Literal['']|AccountService.UpdateParamsIndividualDob"
- ]
- """
- The individual's date of birth.
- """
- email: NotRequired[str]
- """
- The individual's email address.
- """
- first_name: NotRequired[str]
- """
- The individual's first name.
- """
- first_name_kana: NotRequired[str]
- """
- The Kana variation of the individual's first name (Japan only).
- """
- first_name_kanji: NotRequired[str]
- """
- The Kanji variation of the individual's first name (Japan only).
- """
- full_name_aliases: NotRequired["Literal['']|List[str]"]
- """
- A list of alternate names or aliases that the individual is known by.
- """
- gender: NotRequired[str]
- """
- The individual's gender
- """
- id_number: NotRequired[str]
- """
- The government-issued ID number of the individual, as appropriate for the representative's country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in Canada). Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- id_number_secondary: NotRequired[str]
- """
- The government-issued secondary ID number of the individual, as appropriate for the representative's country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- last_name: NotRequired[str]
- """
- The individual's last name.
- """
- last_name_kana: NotRequired[str]
- """
- The Kana variation of the individual's last name (Japan only).
- """
- last_name_kanji: NotRequired[str]
- """
- The Kanji variation of the individual's last name (Japan only).
- """
- maiden_name: NotRequired[str]
- """
- The individual's maiden name.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- phone: NotRequired[str]
- """
- The individual's phone number.
- """
- political_exposure: NotRequired[Literal["existing", "none"]]
- """
- Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
- """
- registered_address: NotRequired[
- "AccountService.UpdateParamsIndividualRegisteredAddress"
- ]
- """
- The individual's registered address.
- """
- relationship: NotRequired[
- "AccountService.UpdateParamsIndividualRelationship"
- ]
- """
- Describes the person's relationship to the account.
- """
- ssn_last_4: NotRequired[str]
- """
- The last four digits of the individual's Social Security Number (U.S. only).
- """
- verification: NotRequired[
- "AccountService.UpdateParamsIndividualVerification"
- ]
- """
- The individual's verification document information.
- """
-
- class UpdateParamsIndividualAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsIndividualAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class UpdateParamsIndividualAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class UpdateParamsIndividualDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class UpdateParamsIndividualRegisteredAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsIndividualRelationship(TypedDict):
- director: NotRequired[bool]
- """
- Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
- """
- executive: NotRequired[bool]
- """
- Whether the person has significant responsibility to control, manage, or direct the organization.
- """
- owner: NotRequired[bool]
- """
- Whether the person is an owner of the account's legal entity.
- """
- percent_ownership: NotRequired["Literal['']|float"]
- """
- The percent owned by the person of the account's legal entity.
- """
- title: NotRequired[str]
- """
- The person's title (e.g., CEO, Support Engineer).
- """
-
- class UpdateParamsIndividualVerification(TypedDict):
- additional_document: NotRequired[
- "AccountService.UpdateParamsIndividualVerificationAdditionalDocument"
- ]
- """
- A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
- """
- document: NotRequired[
- "AccountService.UpdateParamsIndividualVerificationDocument"
- ]
- """
- An identifying document, either a passport or local ID card.
- """
-
- class UpdateParamsIndividualVerificationAdditionalDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class UpdateParamsIndividualVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class UpdateParamsSettings(TypedDict):
- bacs_debit_payments: NotRequired[
- "AccountService.UpdateParamsSettingsBacsDebitPayments"
- ]
- """
- Settings specific to Bacs Direct Debit payments.
- """
- branding: NotRequired["AccountService.UpdateParamsSettingsBranding"]
- """
- Settings used to apply the account's branding to email receipts, invoices, Checkout, and other products.
- """
- card_issuing: NotRequired[
- "AccountService.UpdateParamsSettingsCardIssuing"
- ]
- """
- Settings specific to the account's use of the Card Issuing product.
- """
- card_payments: NotRequired[
- "AccountService.UpdateParamsSettingsCardPayments"
- ]
- """
- Settings specific to card charging on the account.
- """
- invoices: NotRequired["AccountService.UpdateParamsSettingsInvoices"]
- """
- Settings specific to the account's use of Invoices.
- """
- payments: NotRequired["AccountService.UpdateParamsSettingsPayments"]
- """
- Settings that apply across payment methods for charging on the account.
- """
- payouts: NotRequired["AccountService.UpdateParamsSettingsPayouts"]
- """
- Settings specific to the account's payouts.
- """
- treasury: NotRequired["AccountService.UpdateParamsSettingsTreasury"]
- """
- Settings specific to the account's Treasury FinancialAccounts.
- """
-
- class UpdateParamsSettingsBacsDebitPayments(TypedDict):
- display_name: NotRequired[str]
- """
- The Bacs Direct Debit Display Name for this account. For payments made with Bacs Direct Debit, this name appears on the mandate as the statement descriptor. Mobile banking apps display it as the name of the business. To use custom branding, set the Bacs Direct Debit Display Name during or right after creation. Custom branding incurs an additional monthly fee for the platform. If you don't set the display name before requesting Bacs capability, it's automatically set as "Stripe" and the account is onboarded to Stripe branding, which is free.
- """
-
- class UpdateParamsSettingsBranding(TypedDict):
- icon: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) An icon for the account. Must be square and at least 128px x 128px.
- """
- logo: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A logo for the account that will be used in Checkout instead of the icon and without the account's name next to it if provided. Must be at least 128px x 128px.
- """
- primary_color: NotRequired[str]
- """
- A CSS hex color value representing the primary branding color for this account.
- """
- secondary_color: NotRequired[str]
- """
- A CSS hex color value representing the secondary branding color for this account.
- """
-
- class UpdateParamsSettingsCardIssuing(TypedDict):
- tos_acceptance: NotRequired[
- "AccountService.UpdateParamsSettingsCardIssuingTosAcceptance"
- ]
- """
- Details on the account's acceptance of the [Stripe Issuing Terms and Disclosures](https://docs.stripe.com/issuing/connect/tos_acceptance).
- """
-
- class UpdateParamsSettingsCardIssuingTosAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the account representative accepted the service agreement.
- """
- ip: NotRequired[str]
- """
- The IP address from which the account representative accepted the service agreement.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the account representative accepted the service agreement.
- """
-
- class UpdateParamsSettingsCardPayments(TypedDict):
- decline_on: NotRequired[
- "AccountService.UpdateParamsSettingsCardPaymentsDeclineOn"
- ]
- """
- Automatically declines certain charge types regardless of whether the card issuer accepted or declined the charge.
- """
- statement_descriptor_prefix: NotRequired[str]
- """
- The default text that appears on credit card statements when a charge is made. This field prefixes any dynamic `statement_descriptor` specified on the charge. `statement_descriptor_prefix` is useful for maximizing descriptor space for the dynamic portion.
- """
- statement_descriptor_prefix_kana: NotRequired["Literal['']|str"]
- """
- The Kana variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kana` specified on the charge. `statement_descriptor_prefix_kana` is useful for maximizing descriptor space for the dynamic portion.
- """
- statement_descriptor_prefix_kanji: NotRequired["Literal['']|str"]
- """
- The Kanji variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kanji` specified on the charge. `statement_descriptor_prefix_kanji` is useful for maximizing descriptor space for the dynamic portion.
- """
-
- class UpdateParamsSettingsCardPaymentsDeclineOn(TypedDict):
- avs_failure: NotRequired[bool]
- """
- Whether Stripe automatically declines charges with an incorrect ZIP or postal code. This setting only applies when a ZIP or postal code is provided and they fail bank verification.
- """
- cvc_failure: NotRequired[bool]
- """
- Whether Stripe automatically declines charges with an incorrect CVC. This setting only applies when a CVC is provided and it fails bank verification.
- """
-
- class UpdateParamsSettingsInvoices(TypedDict):
- default_account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The list of default Account Tax IDs to automatically include on invoices. Account Tax IDs get added when an invoice is finalized.
- """
- hosted_payment_method_save: NotRequired[
- Literal["always", "never", "offer"]
- ]
- """
- Whether payment methods should be saved when a payment is completed for a one-time invoices on a hosted invoice page.
- """
-
- class UpdateParamsSettingsPayments(TypedDict):
- statement_descriptor: NotRequired[str]
- """
- The default text that appears on statements for non-card charges outside of Japan. For card charges, if you don't set a `statement_descriptor_prefix`, this text is also used as the statement descriptor prefix. In that case, if concatenating the statement descriptor suffix causes the combined statement descriptor to exceed 22 characters, we truncate the `statement_descriptor` text to limit the full descriptor to 22 characters. For more information about statement descriptors and their requirements, see the [account settings documentation](https://docs.stripe.com/get-started/account/statement-descriptors).
- """
- statement_descriptor_kana: NotRequired[str]
- """
- The Kana variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
- """
- statement_descriptor_kanji: NotRequired[str]
- """
- The Kanji variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
- """
-
- class UpdateParamsSettingsPayouts(TypedDict):
- debit_negative_balances: NotRequired[bool]
- """
- A Boolean indicating whether Stripe should try to reclaim negative balances from an attached bank account. For details, see [Understanding Connect Account Balances](https://docs.stripe.com/connect/account-balances).
- """
- schedule: NotRequired[
- "AccountService.UpdateParamsSettingsPayoutsSchedule"
- ]
- """
- Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](https://docs.stripe.com/connect/bank-transfers#payout-information) documentation.
- """
- statement_descriptor: NotRequired[str]
- """
- The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
- """
-
- class UpdateParamsSettingsPayoutsSchedule(TypedDict):
- delay_days: NotRequired["Literal['minimum']|int"]
- """
- The number of days charge funds are held before being paid out. May also be set to `minimum`, representing the lowest available value for the account country. Default is `minimum`. The `delay_days` parameter remains at the last configured value if `interval` is `manual`. [Learn more about controlling payout delay days](https://docs.stripe.com/connect/manage-payout-schedule).
- """
- interval: NotRequired[Literal["daily", "manual", "monthly", "weekly"]]
- """
- How frequently available funds are paid out. One of: `daily`, `manual`, `weekly`, or `monthly`. Default is `daily`.
- """
- monthly_anchor: NotRequired[int]
- """
- The day of the month when available funds are paid out, specified as a number between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly`.
- """
- monthly_payout_days: NotRequired[List[int]]
- """
- The days of the month when available funds are paid out, specified as an array of numbers between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly` and `monthly_anchor` is not set.
- """
- weekly_anchor: NotRequired[
- Literal[
- "friday",
- "monday",
- "saturday",
- "sunday",
- "thursday",
- "tuesday",
- "wednesday",
- ]
- ]
- """
- The day of the week when available funds are paid out, specified as `monday`, `tuesday`, etc. Required and applicable only if `interval` is `weekly`.
- """
- weekly_payout_days: NotRequired[
- List[
- Literal["friday", "monday", "thursday", "tuesday", "wednesday"]
- ]
- ]
- """
- The days of the week when available funds are paid out, specified as an array, e.g., [`monday`, `tuesday`]. Required and applicable only if `interval` is `weekly`.
- """
-
- class UpdateParamsSettingsTreasury(TypedDict):
- tos_acceptance: NotRequired[
- "AccountService.UpdateParamsSettingsTreasuryTosAcceptance"
- ]
- """
- Details on the account's acceptance of the Stripe Treasury Services Agreement.
- """
-
- class UpdateParamsSettingsTreasuryTosAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the account representative accepted the service agreement.
- """
- ip: NotRequired[str]
- """
- The IP address from which the account representative accepted the service agreement.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the account representative accepted the service agreement.
- """
-
- class UpdateParamsTosAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the account representative accepted their service agreement.
- """
- ip: NotRequired[str]
- """
- The IP address from which the account representative accepted their service agreement.
- """
- service_agreement: NotRequired[str]
- """
- The user's service agreement type.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the account representative accepted their service agreement.
- """
-
def delete(
self,
account: str,
- params: Optional["AccountService.DeleteParams"] = None,
+ params: Optional["AccountDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -3882,7 +63,7 @@ def delete(
async def delete_async(
self,
account: str,
- params: Optional["AccountService.DeleteParams"] = None,
+ params: Optional["AccountDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -3908,7 +89,7 @@ async def delete_async(
def retrieve(
self,
account: str,
- params: Optional["AccountService.RetrieveParams"] = None,
+ params: Optional["AccountRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -3928,7 +109,7 @@ def retrieve(
async def retrieve_async(
self,
account: str,
- params: Optional["AccountService.RetrieveParams"] = None,
+ params: Optional["AccountRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -3948,7 +129,7 @@ async def retrieve_async(
def update(
self,
account: str,
- params: Optional["AccountService.UpdateParams"] = None,
+ params: Optional["AccountUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -3980,7 +161,7 @@ def update(
async def update_async(
self,
account: str,
- params: Optional["AccountService.UpdateParams"] = None,
+ params: Optional["AccountUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -4011,7 +192,7 @@ async def update_async(
def retrieve_current(
self,
- params: Optional["AccountService.RetrieveCurrentParams"] = None,
+ params: Optional["AccountRetrieveCurrentParams"] = None,
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -4030,7 +211,7 @@ def retrieve_current(
async def retrieve_current_async(
self,
- params: Optional["AccountService.RetrieveCurrentParams"] = None,
+ params: Optional["AccountRetrieveCurrentParams"] = None,
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -4049,7 +230,7 @@ async def retrieve_current_async(
def list(
self,
- params: Optional["AccountService.ListParams"] = None,
+ params: Optional["AccountListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Account]:
"""
@@ -4068,7 +249,7 @@ def list(
async def list_async(
self,
- params: Optional["AccountService.ListParams"] = None,
+ params: Optional["AccountListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Account]:
"""
@@ -4087,7 +268,7 @@ async def list_async(
def create(
self,
- params: Optional["AccountService.CreateParams"] = None,
+ params: Optional["AccountCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -4111,7 +292,7 @@ def create(
async def create_async(
self,
- params: Optional["AccountService.CreateParams"] = None,
+ params: Optional["AccountCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -4136,7 +317,7 @@ async def create_async(
def reject(
self,
account: str,
- params: "AccountService.RejectParams",
+ params: "AccountRejectParams",
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -4160,7 +341,7 @@ def reject(
async def reject_async(
self,
account: str,
- params: "AccountService.RejectParams",
+ params: "AccountRejectParams",
options: Optional[RequestOptions] = None,
) -> Account:
"""
diff --git a/stripe/_account_session.py b/stripe/_account_session.py
index 092b3410c..0f338bb11 100644
--- a/stripe/_account_session.py
+++ b/stripe/_account_session.py
@@ -1,10 +1,14 @@
# -*- coding: utf-8 -*-
# File generated from our OpenAPI spec
from stripe._createable_api_resource import CreateableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
-from typing import ClassVar, List, cast
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing import ClassVar, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._account_session_create_params import (
+ AccountSessionCreateParams,
+ )
class AccountSession(CreateableAPIResource["AccountSession"]):
@@ -449,595 +453,6 @@ class Features(StripeObject):
"tax_settings": TaxSettings,
}
- class CreateParams(RequestOptions):
- account: str
- """
- The identifier of the account to create an Account Session for.
- """
- components: "AccountSession.CreateParamsComponents"
- """
- Each key of the dictionary represents an embedded component, and each embedded component maps to its configuration (e.g. whether it has been enabled or not).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParamsComponents(TypedDict):
- account_management: NotRequired[
- "AccountSession.CreateParamsComponentsAccountManagement"
- ]
- """
- Configuration for the [account management](https://docs.stripe.com/connect/supported-embedded-components/account-management/) embedded component.
- """
- account_onboarding: NotRequired[
- "AccountSession.CreateParamsComponentsAccountOnboarding"
- ]
- """
- Configuration for the [account onboarding](https://docs.stripe.com/connect/supported-embedded-components/account-onboarding/) embedded component.
- """
- balances: NotRequired["AccountSession.CreateParamsComponentsBalances"]
- """
- Configuration for the [balances](https://docs.stripe.com/connect/supported-embedded-components/balances/) embedded component.
- """
- disputes_list: NotRequired[
- "AccountSession.CreateParamsComponentsDisputesList"
- ]
- """
- Configuration for the [disputes list](https://docs.stripe.com/connect/supported-embedded-components/disputes-list/) embedded component.
- """
- documents: NotRequired[
- "AccountSession.CreateParamsComponentsDocuments"
- ]
- """
- Configuration for the [documents](https://docs.stripe.com/connect/supported-embedded-components/documents/) embedded component.
- """
- financial_account: NotRequired[
- "AccountSession.CreateParamsComponentsFinancialAccount"
- ]
- """
- Configuration for the [financial account](https://docs.stripe.com/connect/supported-embedded-components/financial-account/) embedded component.
- """
- financial_account_transactions: NotRequired[
- "AccountSession.CreateParamsComponentsFinancialAccountTransactions"
- ]
- """
- Configuration for the [financial account transactions](https://docs.stripe.com/connect/supported-embedded-components/financial-account-transactions/) embedded component.
- """
- instant_payouts_promotion: NotRequired[
- "AccountSession.CreateParamsComponentsInstantPayoutsPromotion"
- ]
- """
- Configuration for the [instant payouts promotion](https://docs.stripe.com/connect/supported-embedded-components/instant-payouts-promotion/) embedded component.
- """
- issuing_card: NotRequired[
- "AccountSession.CreateParamsComponentsIssuingCard"
- ]
- """
- Configuration for the [issuing card](https://docs.stripe.com/connect/supported-embedded-components/issuing-card/) embedded component.
- """
- issuing_cards_list: NotRequired[
- "AccountSession.CreateParamsComponentsIssuingCardsList"
- ]
- """
- Configuration for the [issuing cards list](https://docs.stripe.com/connect/supported-embedded-components/issuing-cards-list/) embedded component.
- """
- notification_banner: NotRequired[
- "AccountSession.CreateParamsComponentsNotificationBanner"
- ]
- """
- Configuration for the [notification banner](https://docs.stripe.com/connect/supported-embedded-components/notification-banner/) embedded component.
- """
- payment_details: NotRequired[
- "AccountSession.CreateParamsComponentsPaymentDetails"
- ]
- """
- Configuration for the [payment details](https://docs.stripe.com/connect/supported-embedded-components/payment-details/) embedded component.
- """
- payment_disputes: NotRequired[
- "AccountSession.CreateParamsComponentsPaymentDisputes"
- ]
- """
- Configuration for the [payment disputes](https://docs.stripe.com/connect/supported-embedded-components/payment-disputes/) embedded component.
- """
- payments: NotRequired["AccountSession.CreateParamsComponentsPayments"]
- """
- Configuration for the [payments](https://docs.stripe.com/connect/supported-embedded-components/payments/) embedded component.
- """
- payout_details: NotRequired[
- "AccountSession.CreateParamsComponentsPayoutDetails"
- ]
- """
- Configuration for the [payout details](https://docs.stripe.com/connect/supported-embedded-components/payout-details/) embedded component.
- """
- payouts: NotRequired["AccountSession.CreateParamsComponentsPayouts"]
- """
- Configuration for the [payouts](https://docs.stripe.com/connect/supported-embedded-components/payouts/) embedded component.
- """
- payouts_list: NotRequired[
- "AccountSession.CreateParamsComponentsPayoutsList"
- ]
- """
- Configuration for the [payouts list](https://docs.stripe.com/connect/supported-embedded-components/payouts-list/) embedded component.
- """
- tax_registrations: NotRequired[
- "AccountSession.CreateParamsComponentsTaxRegistrations"
- ]
- """
- Configuration for the [tax registrations](https://docs.stripe.com/connect/supported-embedded-components/tax-registrations/) embedded component.
- """
- tax_settings: NotRequired[
- "AccountSession.CreateParamsComponentsTaxSettings"
- ]
- """
- Configuration for the [tax settings](https://docs.stripe.com/connect/supported-embedded-components/tax-settings/) embedded component.
- """
-
- class CreateParamsComponentsAccountManagement(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsAccountManagementFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsAccountManagementFeatures(TypedDict):
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- external_account_collection: NotRequired[bool]
- """
- Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
- """
-
- class CreateParamsComponentsAccountOnboarding(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsAccountOnboardingFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsAccountOnboardingFeatures(TypedDict):
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- external_account_collection: NotRequired[bool]
- """
- Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
- """
-
- class CreateParamsComponentsBalances(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsBalancesFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsBalancesFeatures(TypedDict):
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- edit_payout_schedule: NotRequired[bool]
- """
- Whether to allow payout schedule to be changed. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
- """
- external_account_collection: NotRequired[bool]
- """
- Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
- """
- instant_payouts: NotRequired[bool]
- """
- Whether to allow creation of instant payouts. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
- """
- standard_payouts: NotRequired[bool]
- """
- Whether to allow creation of standard payouts. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
- """
-
- class CreateParamsComponentsDisputesList(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsDisputesListFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsDisputesListFeatures(TypedDict):
- capture_payments: NotRequired[bool]
- """
- Whether to allow capturing and cancelling payment intents. This is `true` by default.
- """
- destination_on_behalf_of_charge_management: NotRequired[bool]
- """
- Whether connected accounts can manage destination charges that are created on behalf of them. This is `false` by default.
- """
- dispute_management: NotRequired[bool]
- """
- Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This is `true` by default.
- """
- refund_management: NotRequired[bool]
- """
- Whether sending refunds is enabled. This is `true` by default.
- """
-
- class CreateParamsComponentsDocuments(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsDocumentsFeatures"
- ]
- """
- An empty list, because this embedded component has no features.
- """
-
- class CreateParamsComponentsDocumentsFeatures(TypedDict):
- pass
-
- class CreateParamsComponentsFinancialAccount(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsFinancialAccountFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsFinancialAccountFeatures(TypedDict):
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- external_account_collection: NotRequired[bool]
- """
- Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
- """
- send_money: NotRequired[bool]
- """
- Whether to allow sending money.
- """
- transfer_balance: NotRequired[bool]
- """
- Whether to allow transferring balance.
- """
-
- class CreateParamsComponentsFinancialAccountTransactions(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsFinancialAccountTransactionsFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsFinancialAccountTransactionsFeatures(
- TypedDict
- ):
- card_spend_dispute_management: NotRequired[bool]
- """
- Whether to allow card spend dispute management features.
- """
-
- class CreateParamsComponentsInstantPayoutsPromotion(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsInstantPayoutsPromotionFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsInstantPayoutsPromotionFeatures(TypedDict):
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- external_account_collection: NotRequired[bool]
- """
- Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
- """
- instant_payouts: NotRequired[bool]
- """
- Whether to allow creation of instant payouts. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
- """
-
- class CreateParamsComponentsIssuingCard(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsIssuingCardFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsIssuingCardFeatures(TypedDict):
- card_management: NotRequired[bool]
- """
- Whether to allow card management features.
- """
- card_spend_dispute_management: NotRequired[bool]
- """
- Whether to allow card spend dispute management features.
- """
- cardholder_management: NotRequired[bool]
- """
- Whether to allow cardholder management features.
- """
- spend_control_management: NotRequired[bool]
- """
- Whether to allow spend control management features.
- """
-
- class CreateParamsComponentsIssuingCardsList(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsIssuingCardsListFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsIssuingCardsListFeatures(TypedDict):
- card_management: NotRequired[bool]
- """
- Whether to allow card management features.
- """
- card_spend_dispute_management: NotRequired[bool]
- """
- Whether to allow card spend dispute management features.
- """
- cardholder_management: NotRequired[bool]
- """
- Whether to allow cardholder management features.
- """
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- spend_control_management: NotRequired[bool]
- """
- Whether to allow spend control management features.
- """
-
- class CreateParamsComponentsNotificationBanner(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsNotificationBannerFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsNotificationBannerFeatures(TypedDict):
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- external_account_collection: NotRequired[bool]
- """
- Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
- """
-
- class CreateParamsComponentsPaymentDetails(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsPaymentDetailsFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsPaymentDetailsFeatures(TypedDict):
- capture_payments: NotRequired[bool]
- """
- Whether to allow capturing and cancelling payment intents. This is `true` by default.
- """
- destination_on_behalf_of_charge_management: NotRequired[bool]
- """
- Whether connected accounts can manage destination charges that are created on behalf of them. This is `false` by default.
- """
- dispute_management: NotRequired[bool]
- """
- Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This is `true` by default.
- """
- refund_management: NotRequired[bool]
- """
- Whether sending refunds is enabled. This is `true` by default.
- """
-
- class CreateParamsComponentsPaymentDisputes(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsPaymentDisputesFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsPaymentDisputesFeatures(TypedDict):
- destination_on_behalf_of_charge_management: NotRequired[bool]
- """
- Whether connected accounts can manage destination charges that are created on behalf of them. This is `false` by default.
- """
- dispute_management: NotRequired[bool]
- """
- Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This is `true` by default.
- """
- refund_management: NotRequired[bool]
- """
- Whether sending refunds is enabled. This is `true` by default.
- """
-
- class CreateParamsComponentsPayments(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsPaymentsFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsPaymentsFeatures(TypedDict):
- capture_payments: NotRequired[bool]
- """
- Whether to allow capturing and cancelling payment intents. This is `true` by default.
- """
- destination_on_behalf_of_charge_management: NotRequired[bool]
- """
- Whether connected accounts can manage destination charges that are created on behalf of them. This is `false` by default.
- """
- dispute_management: NotRequired[bool]
- """
- Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This is `true` by default.
- """
- refund_management: NotRequired[bool]
- """
- Whether sending refunds is enabled. This is `true` by default.
- """
-
- class CreateParamsComponentsPayoutDetails(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsPayoutDetailsFeatures"
- ]
- """
- An empty list, because this embedded component has no features.
- """
-
- class CreateParamsComponentsPayoutDetailsFeatures(TypedDict):
- pass
-
- class CreateParamsComponentsPayouts(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsPayoutsFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsPayoutsFeatures(TypedDict):
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- edit_payout_schedule: NotRequired[bool]
- """
- Whether to allow payout schedule to be changed. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
- """
- external_account_collection: NotRequired[bool]
- """
- Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
- """
- instant_payouts: NotRequired[bool]
- """
- Whether to allow creation of instant payouts. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
- """
- standard_payouts: NotRequired[bool]
- """
- Whether to allow creation of standard payouts. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
- """
-
- class CreateParamsComponentsPayoutsList(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsPayoutsListFeatures"
- ]
- """
- An empty list, because this embedded component has no features.
- """
-
- class CreateParamsComponentsPayoutsListFeatures(TypedDict):
- pass
-
- class CreateParamsComponentsTaxRegistrations(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsTaxRegistrationsFeatures"
- ]
- """
- An empty list, because this embedded component has no features.
- """
-
- class CreateParamsComponentsTaxRegistrationsFeatures(TypedDict):
- pass
-
- class CreateParamsComponentsTaxSettings(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSession.CreateParamsComponentsTaxSettingsFeatures"
- ]
- """
- An empty list, because this embedded component has no features.
- """
-
- class CreateParamsComponentsTaxSettingsFeatures(TypedDict):
- pass
-
account: str
"""
The ID of the account the AccountSession was created for
@@ -1066,7 +481,7 @@ class CreateParamsComponentsTaxSettingsFeatures(TypedDict):
@classmethod
def create(
- cls, **params: Unpack["AccountSession.CreateParams"]
+ cls, **params: Unpack["AccountSessionCreateParams"]
) -> "AccountSession":
"""
Creates a AccountSession object that includes a single-use token that the platform can use on their front-end to grant client-side API access.
@@ -1082,7 +497,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["AccountSession.CreateParams"]
+ cls, **params: Unpack["AccountSessionCreateParams"]
) -> "AccountSession":
"""
Creates a AccountSession object that includes a single-use token that the platform can use on their front-end to grant client-side API access.
diff --git a/stripe/_account_session_service.py b/stripe/_account_session_service.py
index 1fa027b59..9411936d6 100644
--- a/stripe/_account_session_service.py
+++ b/stripe/_account_session_service.py
@@ -3,609 +3,19 @@
from stripe._account_session import AccountSession
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._account_session_create_params import (
+ AccountSessionCreateParams,
+ )
-class AccountSessionService(StripeService):
- class CreateParams(TypedDict):
- account: str
- """
- The identifier of the account to create an Account Session for.
- """
- components: "AccountSessionService.CreateParamsComponents"
- """
- Each key of the dictionary represents an embedded component, and each embedded component maps to its configuration (e.g. whether it has been enabled or not).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParamsComponents(TypedDict):
- account_management: NotRequired[
- "AccountSessionService.CreateParamsComponentsAccountManagement"
- ]
- """
- Configuration for the [account management](https://docs.stripe.com/connect/supported-embedded-components/account-management/) embedded component.
- """
- account_onboarding: NotRequired[
- "AccountSessionService.CreateParamsComponentsAccountOnboarding"
- ]
- """
- Configuration for the [account onboarding](https://docs.stripe.com/connect/supported-embedded-components/account-onboarding/) embedded component.
- """
- balances: NotRequired[
- "AccountSessionService.CreateParamsComponentsBalances"
- ]
- """
- Configuration for the [balances](https://docs.stripe.com/connect/supported-embedded-components/balances/) embedded component.
- """
- disputes_list: NotRequired[
- "AccountSessionService.CreateParamsComponentsDisputesList"
- ]
- """
- Configuration for the [disputes list](https://docs.stripe.com/connect/supported-embedded-components/disputes-list/) embedded component.
- """
- documents: NotRequired[
- "AccountSessionService.CreateParamsComponentsDocuments"
- ]
- """
- Configuration for the [documents](https://docs.stripe.com/connect/supported-embedded-components/documents/) embedded component.
- """
- financial_account: NotRequired[
- "AccountSessionService.CreateParamsComponentsFinancialAccount"
- ]
- """
- Configuration for the [financial account](https://docs.stripe.com/connect/supported-embedded-components/financial-account/) embedded component.
- """
- financial_account_transactions: NotRequired[
- "AccountSessionService.CreateParamsComponentsFinancialAccountTransactions"
- ]
- """
- Configuration for the [financial account transactions](https://docs.stripe.com/connect/supported-embedded-components/financial-account-transactions/) embedded component.
- """
- instant_payouts_promotion: NotRequired[
- "AccountSessionService.CreateParamsComponentsInstantPayoutsPromotion"
- ]
- """
- Configuration for the [instant payouts promotion](https://docs.stripe.com/connect/supported-embedded-components/instant-payouts-promotion/) embedded component.
- """
- issuing_card: NotRequired[
- "AccountSessionService.CreateParamsComponentsIssuingCard"
- ]
- """
- Configuration for the [issuing card](https://docs.stripe.com/connect/supported-embedded-components/issuing-card/) embedded component.
- """
- issuing_cards_list: NotRequired[
- "AccountSessionService.CreateParamsComponentsIssuingCardsList"
- ]
- """
- Configuration for the [issuing cards list](https://docs.stripe.com/connect/supported-embedded-components/issuing-cards-list/) embedded component.
- """
- notification_banner: NotRequired[
- "AccountSessionService.CreateParamsComponentsNotificationBanner"
- ]
- """
- Configuration for the [notification banner](https://docs.stripe.com/connect/supported-embedded-components/notification-banner/) embedded component.
- """
- payment_details: NotRequired[
- "AccountSessionService.CreateParamsComponentsPaymentDetails"
- ]
- """
- Configuration for the [payment details](https://docs.stripe.com/connect/supported-embedded-components/payment-details/) embedded component.
- """
- payment_disputes: NotRequired[
- "AccountSessionService.CreateParamsComponentsPaymentDisputes"
- ]
- """
- Configuration for the [payment disputes](https://docs.stripe.com/connect/supported-embedded-components/payment-disputes/) embedded component.
- """
- payments: NotRequired[
- "AccountSessionService.CreateParamsComponentsPayments"
- ]
- """
- Configuration for the [payments](https://docs.stripe.com/connect/supported-embedded-components/payments/) embedded component.
- """
- payout_details: NotRequired[
- "AccountSessionService.CreateParamsComponentsPayoutDetails"
- ]
- """
- Configuration for the [payout details](https://docs.stripe.com/connect/supported-embedded-components/payout-details/) embedded component.
- """
- payouts: NotRequired[
- "AccountSessionService.CreateParamsComponentsPayouts"
- ]
- """
- Configuration for the [payouts](https://docs.stripe.com/connect/supported-embedded-components/payouts/) embedded component.
- """
- payouts_list: NotRequired[
- "AccountSessionService.CreateParamsComponentsPayoutsList"
- ]
- """
- Configuration for the [payouts list](https://docs.stripe.com/connect/supported-embedded-components/payouts-list/) embedded component.
- """
- tax_registrations: NotRequired[
- "AccountSessionService.CreateParamsComponentsTaxRegistrations"
- ]
- """
- Configuration for the [tax registrations](https://docs.stripe.com/connect/supported-embedded-components/tax-registrations/) embedded component.
- """
- tax_settings: NotRequired[
- "AccountSessionService.CreateParamsComponentsTaxSettings"
- ]
- """
- Configuration for the [tax settings](https://docs.stripe.com/connect/supported-embedded-components/tax-settings/) embedded component.
- """
-
- class CreateParamsComponentsAccountManagement(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsAccountManagementFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsAccountManagementFeatures(TypedDict):
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- external_account_collection: NotRequired[bool]
- """
- Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
- """
-
- class CreateParamsComponentsAccountOnboarding(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsAccountOnboardingFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsAccountOnboardingFeatures(TypedDict):
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- external_account_collection: NotRequired[bool]
- """
- Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
- """
-
- class CreateParamsComponentsBalances(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsBalancesFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsBalancesFeatures(TypedDict):
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- edit_payout_schedule: NotRequired[bool]
- """
- Whether to allow payout schedule to be changed. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
- """
- external_account_collection: NotRequired[bool]
- """
- Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
- """
- instant_payouts: NotRequired[bool]
- """
- Whether to allow creation of instant payouts. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
- """
- standard_payouts: NotRequired[bool]
- """
- Whether to allow creation of standard payouts. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
- """
-
- class CreateParamsComponentsDisputesList(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsDisputesListFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsDisputesListFeatures(TypedDict):
- capture_payments: NotRequired[bool]
- """
- Whether to allow capturing and cancelling payment intents. This is `true` by default.
- """
- destination_on_behalf_of_charge_management: NotRequired[bool]
- """
- Whether connected accounts can manage destination charges that are created on behalf of them. This is `false` by default.
- """
- dispute_management: NotRequired[bool]
- """
- Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This is `true` by default.
- """
- refund_management: NotRequired[bool]
- """
- Whether sending refunds is enabled. This is `true` by default.
- """
-
- class CreateParamsComponentsDocuments(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsDocumentsFeatures"
- ]
- """
- An empty list, because this embedded component has no features.
- """
-
- class CreateParamsComponentsDocumentsFeatures(TypedDict):
- pass
-
- class CreateParamsComponentsFinancialAccount(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsFinancialAccountFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsFinancialAccountFeatures(TypedDict):
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- external_account_collection: NotRequired[bool]
- """
- Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
- """
- send_money: NotRequired[bool]
- """
- Whether to allow sending money.
- """
- transfer_balance: NotRequired[bool]
- """
- Whether to allow transferring balance.
- """
-
- class CreateParamsComponentsFinancialAccountTransactions(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsFinancialAccountTransactionsFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsFinancialAccountTransactionsFeatures(
- TypedDict
- ):
- card_spend_dispute_management: NotRequired[bool]
- """
- Whether to allow card spend dispute management features.
- """
-
- class CreateParamsComponentsInstantPayoutsPromotion(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsInstantPayoutsPromotionFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsInstantPayoutsPromotionFeatures(TypedDict):
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- external_account_collection: NotRequired[bool]
- """
- Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
- """
- instant_payouts: NotRequired[bool]
- """
- Whether to allow creation of instant payouts. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
- """
-
- class CreateParamsComponentsIssuingCard(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsIssuingCardFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsIssuingCardFeatures(TypedDict):
- card_management: NotRequired[bool]
- """
- Whether to allow card management features.
- """
- card_spend_dispute_management: NotRequired[bool]
- """
- Whether to allow card spend dispute management features.
- """
- cardholder_management: NotRequired[bool]
- """
- Whether to allow cardholder management features.
- """
- spend_control_management: NotRequired[bool]
- """
- Whether to allow spend control management features.
- """
-
- class CreateParamsComponentsIssuingCardsList(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsIssuingCardsListFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsIssuingCardsListFeatures(TypedDict):
- card_management: NotRequired[bool]
- """
- Whether to allow card management features.
- """
- card_spend_dispute_management: NotRequired[bool]
- """
- Whether to allow card spend dispute management features.
- """
- cardholder_management: NotRequired[bool]
- """
- Whether to allow cardholder management features.
- """
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- spend_control_management: NotRequired[bool]
- """
- Whether to allow spend control management features.
- """
-
- class CreateParamsComponentsNotificationBanner(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsNotificationBannerFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsNotificationBannerFeatures(TypedDict):
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- external_account_collection: NotRequired[bool]
- """
- Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
- """
-
- class CreateParamsComponentsPaymentDetails(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsPaymentDetailsFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsPaymentDetailsFeatures(TypedDict):
- capture_payments: NotRequired[bool]
- """
- Whether to allow capturing and cancelling payment intents. This is `true` by default.
- """
- destination_on_behalf_of_charge_management: NotRequired[bool]
- """
- Whether connected accounts can manage destination charges that are created on behalf of them. This is `false` by default.
- """
- dispute_management: NotRequired[bool]
- """
- Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This is `true` by default.
- """
- refund_management: NotRequired[bool]
- """
- Whether sending refunds is enabled. This is `true` by default.
- """
-
- class CreateParamsComponentsPaymentDisputes(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsPaymentDisputesFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsPaymentDisputesFeatures(TypedDict):
- destination_on_behalf_of_charge_management: NotRequired[bool]
- """
- Whether connected accounts can manage destination charges that are created on behalf of them. This is `false` by default.
- """
- dispute_management: NotRequired[bool]
- """
- Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This is `true` by default.
- """
- refund_management: NotRequired[bool]
- """
- Whether sending refunds is enabled. This is `true` by default.
- """
-
- class CreateParamsComponentsPayments(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsPaymentsFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsPaymentsFeatures(TypedDict):
- capture_payments: NotRequired[bool]
- """
- Whether to allow capturing and cancelling payment intents. This is `true` by default.
- """
- destination_on_behalf_of_charge_management: NotRequired[bool]
- """
- Whether connected accounts can manage destination charges that are created on behalf of them. This is `false` by default.
- """
- dispute_management: NotRequired[bool]
- """
- Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This is `true` by default.
- """
- refund_management: NotRequired[bool]
- """
- Whether sending refunds is enabled. This is `true` by default.
- """
-
- class CreateParamsComponentsPayoutDetails(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsPayoutDetailsFeatures"
- ]
- """
- An empty list, because this embedded component has no features.
- """
-
- class CreateParamsComponentsPayoutDetailsFeatures(TypedDict):
- pass
-
- class CreateParamsComponentsPayouts(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsPayoutsFeatures"
- ]
- """
- The list of features enabled in the embedded component.
- """
-
- class CreateParamsComponentsPayoutsFeatures(TypedDict):
- disable_stripe_user_authentication: NotRequired[bool]
- """
- Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
- """
- edit_payout_schedule: NotRequired[bool]
- """
- Whether to allow payout schedule to be changed. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
- """
- external_account_collection: NotRequired[bool]
- """
- Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
- """
- instant_payouts: NotRequired[bool]
- """
- Whether to allow creation of instant payouts. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
- """
- standard_payouts: NotRequired[bool]
- """
- Whether to allow creation of standard payouts. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
- """
-
- class CreateParamsComponentsPayoutsList(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsPayoutsListFeatures"
- ]
- """
- An empty list, because this embedded component has no features.
- """
-
- class CreateParamsComponentsPayoutsListFeatures(TypedDict):
- pass
-
- class CreateParamsComponentsTaxRegistrations(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsTaxRegistrationsFeatures"
- ]
- """
- An empty list, because this embedded component has no features.
- """
-
- class CreateParamsComponentsTaxRegistrationsFeatures(TypedDict):
- pass
-
- class CreateParamsComponentsTaxSettings(TypedDict):
- enabled: bool
- """
- Whether the embedded component is enabled.
- """
- features: NotRequired[
- "AccountSessionService.CreateParamsComponentsTaxSettingsFeatures"
- ]
- """
- An empty list, because this embedded component has no features.
- """
-
- class CreateParamsComponentsTaxSettingsFeatures(TypedDict):
- pass
+class AccountSessionService(StripeService):
def create(
self,
- params: "AccountSessionService.CreateParams",
+ params: "AccountSessionCreateParams",
options: Optional[RequestOptions] = None,
) -> AccountSession:
"""
@@ -624,7 +34,7 @@ def create(
async def create_async(
self,
- params: "AccountSessionService.CreateParams",
+ params: "AccountSessionCreateParams",
options: Optional[RequestOptions] = None,
) -> AccountSession:
"""
diff --git a/stripe/_apple_pay_domain.py b/stripe/_apple_pay_domain.py
index 1961b46ea..3ed5195a9 100644
--- a/stripe/_apple_pay_domain.py
+++ b/stripe/_apple_pay_domain.py
@@ -4,10 +4,23 @@
from stripe._deletable_api_resource import DeletableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, List, Optional, cast, overload
-from typing_extensions import Literal, NotRequired, Unpack
+from typing import ClassVar, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._apple_pay_domain_create_params import (
+ ApplePayDomainCreateParams,
+ )
+ from stripe.params._apple_pay_domain_delete_params import (
+ ApplePayDomainDeleteParams,
+ )
+ from stripe.params._apple_pay_domain_list_params import (
+ ApplePayDomainListParams,
+ )
+ from stripe.params._apple_pay_domain_retrieve_params import (
+ ApplePayDomainRetrieveParams,
+ )
class ApplePayDomain(
@@ -16,42 +29,6 @@ class ApplePayDomain(
ListableAPIResource["ApplePayDomain"],
):
OBJECT_NAME: ClassVar[Literal["apple_pay_domain"]] = "apple_pay_domain"
-
- class CreateParams(RequestOptions):
- domain_name: str
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class DeleteParams(RequestOptions):
- pass
-
- class ListParams(RequestOptions):
- domain_name: NotRequired[str]
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -76,7 +53,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["ApplePayDomain.CreateParams"]
+ cls, **params: Unpack["ApplePayDomainCreateParams"]
) -> "ApplePayDomain":
"""
Create an apple pay domain.
@@ -92,7 +69,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["ApplePayDomain.CreateParams"]
+ cls, **params: Unpack["ApplePayDomainCreateParams"]
) -> "ApplePayDomain":
"""
Create an apple pay domain.
@@ -108,7 +85,7 @@ async def create_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["ApplePayDomain.DeleteParams"]
+ cls, sid: str, **params: Unpack["ApplePayDomainDeleteParams"]
) -> "ApplePayDomain":
"""
Delete an apple pay domain.
@@ -126,7 +103,7 @@ def _cls_delete(
@overload
@staticmethod
def delete(
- sid: str, **params: Unpack["ApplePayDomain.DeleteParams"]
+ sid: str, **params: Unpack["ApplePayDomainDeleteParams"]
) -> "ApplePayDomain":
"""
Delete an apple pay domain.
@@ -135,7 +112,7 @@ def delete(
@overload
def delete(
- self, **params: Unpack["ApplePayDomain.DeleteParams"]
+ self, **params: Unpack["ApplePayDomainDeleteParams"]
) -> "ApplePayDomain":
"""
Delete an apple pay domain.
@@ -144,7 +121,7 @@ def delete(
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["ApplePayDomain.DeleteParams"]
+ self, **params: Unpack["ApplePayDomainDeleteParams"]
) -> "ApplePayDomain":
"""
Delete an apple pay domain.
@@ -157,7 +134,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["ApplePayDomain.DeleteParams"]
+ cls, sid: str, **params: Unpack["ApplePayDomainDeleteParams"]
) -> "ApplePayDomain":
"""
Delete an apple pay domain.
@@ -175,7 +152,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["ApplePayDomain.DeleteParams"]
+ sid: str, **params: Unpack["ApplePayDomainDeleteParams"]
) -> "ApplePayDomain":
"""
Delete an apple pay domain.
@@ -184,7 +161,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["ApplePayDomain.DeleteParams"]
+ self, **params: Unpack["ApplePayDomainDeleteParams"]
) -> "ApplePayDomain":
"""
Delete an apple pay domain.
@@ -193,7 +170,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["ApplePayDomain.DeleteParams"]
+ self, **params: Unpack["ApplePayDomainDeleteParams"]
) -> "ApplePayDomain":
"""
Delete an apple pay domain.
@@ -206,7 +183,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["ApplePayDomain.ListParams"]
+ cls, **params: Unpack["ApplePayDomainListParams"]
) -> ListObject["ApplePayDomain"]:
"""
List apple pay domains.
@@ -226,7 +203,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["ApplePayDomain.ListParams"]
+ cls, **params: Unpack["ApplePayDomainListParams"]
) -> ListObject["ApplePayDomain"]:
"""
List apple pay domains.
@@ -246,7 +223,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["ApplePayDomain.RetrieveParams"]
+ cls, id: str, **params: Unpack["ApplePayDomainRetrieveParams"]
) -> "ApplePayDomain":
"""
Retrieve an apple pay domain.
@@ -257,7 +234,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["ApplePayDomain.RetrieveParams"]
+ cls, id: str, **params: Unpack["ApplePayDomainRetrieveParams"]
) -> "ApplePayDomain":
"""
Retrieve an apple pay domain.
diff --git a/stripe/_apple_pay_domain_service.py b/stripe/_apple_pay_domain_service.py
index 750c7b781..a18d0ff0b 100644
--- a/stripe/_apple_pay_domain_service.py
+++ b/stripe/_apple_pay_domain_service.py
@@ -5,50 +5,29 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._apple_pay_domain_create_params import (
+ ApplePayDomainCreateParams,
+ )
+ from stripe.params._apple_pay_domain_delete_params import (
+ ApplePayDomainDeleteParams,
+ )
+ from stripe.params._apple_pay_domain_list_params import (
+ ApplePayDomainListParams,
+ )
+ from stripe.params._apple_pay_domain_retrieve_params import (
+ ApplePayDomainRetrieveParams,
+ )
-class ApplePayDomainService(StripeService):
- class CreateParams(TypedDict):
- domain_name: str
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- domain_name: NotRequired[str]
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class ApplePayDomainService(StripeService):
def delete(
self,
domain: str,
- params: Optional["ApplePayDomainService.DeleteParams"] = None,
+ params: Optional["ApplePayDomainDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> ApplePayDomain:
"""
@@ -70,7 +49,7 @@ def delete(
async def delete_async(
self,
domain: str,
- params: Optional["ApplePayDomainService.DeleteParams"] = None,
+ params: Optional["ApplePayDomainDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> ApplePayDomain:
"""
@@ -92,7 +71,7 @@ async def delete_async(
def retrieve(
self,
domain: str,
- params: Optional["ApplePayDomainService.RetrieveParams"] = None,
+ params: Optional["ApplePayDomainRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ApplePayDomain:
"""
@@ -114,7 +93,7 @@ def retrieve(
async def retrieve_async(
self,
domain: str,
- params: Optional["ApplePayDomainService.RetrieveParams"] = None,
+ params: Optional["ApplePayDomainRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ApplePayDomain:
"""
@@ -135,7 +114,7 @@ async def retrieve_async(
def list(
self,
- params: Optional["ApplePayDomainService.ListParams"] = None,
+ params: Optional["ApplePayDomainListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ApplePayDomain]:
"""
@@ -154,7 +133,7 @@ def list(
async def list_async(
self,
- params: Optional["ApplePayDomainService.ListParams"] = None,
+ params: Optional["ApplePayDomainListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ApplePayDomain]:
"""
@@ -173,7 +152,7 @@ async def list_async(
def create(
self,
- params: "ApplePayDomainService.CreateParams",
+ params: "ApplePayDomainCreateParams",
options: Optional[RequestOptions] = None,
) -> ApplePayDomain:
"""
@@ -192,7 +171,7 @@ def create(
async def create_async(
self,
- params: "ApplePayDomainService.CreateParams",
+ params: "ApplePayDomainCreateParams",
options: Optional[RequestOptions] = None,
) -> ApplePayDomain:
"""
diff --git a/stripe/_application_fee.py b/stripe/_application_fee.py
index aef0ada43..f83ab1ead 100644
--- a/stripe/_application_fee.py
+++ b/stripe/_application_fee.py
@@ -4,17 +4,10 @@
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
from stripe._nested_resource_class_methods import nested_resource_class_methods
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account
@@ -22,6 +15,27 @@
from stripe._application_fee_refund import ApplicationFeeRefund
from stripe._balance_transaction import BalanceTransaction
from stripe._charge import Charge
+ from stripe.params._application_fee_create_refund_params import (
+ ApplicationFeeCreateRefundParams,
+ )
+ from stripe.params._application_fee_list_params import (
+ ApplicationFeeListParams,
+ )
+ from stripe.params._application_fee_list_refunds_params import (
+ ApplicationFeeListRefundsParams,
+ )
+ from stripe.params._application_fee_modify_refund_params import (
+ ApplicationFeeModifyRefundParams,
+ )
+ from stripe.params._application_fee_refund_params import (
+ ApplicationFeeRefundParams,
+ )
+ from stripe.params._application_fee_retrieve_params import (
+ ApplicationFeeRetrieveParams,
+ )
+ from stripe.params._application_fee_retrieve_refund_params import (
+ ApplicationFeeRetrieveRefundParams,
+ )
@nested_resource_class_methods("refund")
@@ -42,118 +56,6 @@ class FeeSource(StripeObject):
Type of object that created the application fee.
"""
- class CreateRefundParams(RequestOptions):
- amount: NotRequired[int]
- """
- A positive integer, in _cents (or local equivalent)_, representing how much of this fee to refund. Can refund only up to the remaining unrefunded amount of the fee.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class ListParams(RequestOptions):
- charge: NotRequired[str]
- """
- Only return application fees for the charge specified by this charge ID.
- """
- created: NotRequired["ApplicationFee.ListParamsCreated|int"]
- """
- Only return applications fees that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListRefundsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ModifyRefundParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class RefundParams(RequestOptions):
- amount: NotRequired[int]
- """
- A positive integer, in _cents (or local equivalent)_, representing how much of this fee to refund. Can refund only up to the remaining unrefunded amount of the fee.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveRefundParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
account: ExpandableField["Account"]
"""
ID of the Stripe account this fee was taken from.
@@ -217,7 +119,7 @@ class RetrieveRefundParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["ApplicationFee.ListParams"]
+ cls, **params: Unpack["ApplicationFeeListParams"]
) -> ListObject["ApplicationFee"]:
"""
Returns a list of application fees you've previously collected. The application fees are returned in sorted order, with the most recent fees appearing first.
@@ -237,7 +139,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["ApplicationFee.ListParams"]
+ cls, **params: Unpack["ApplicationFeeListParams"]
) -> ListObject["ApplicationFee"]:
"""
Returns a list of application fees you've previously collected. The application fees are returned in sorted order, with the most recent fees appearing first.
@@ -257,7 +159,7 @@ async def list_async(
@classmethod
def _cls_refund(
- cls, id: str, **params: Unpack["ApplicationFee.RefundParams"]
+ cls, id: str, **params: Unpack["ApplicationFeeRefundParams"]
) -> "ApplicationFeeRefund":
"""
Refunds an application fee that has previously been collected but not yet refunded.
@@ -282,7 +184,7 @@ def _cls_refund(
@overload
@staticmethod
def refund(
- id: str, **params: Unpack["ApplicationFee.RefundParams"]
+ id: str, **params: Unpack["ApplicationFeeRefundParams"]
) -> "ApplicationFeeRefund":
"""
Refunds an application fee that has previously been collected but not yet refunded.
@@ -299,7 +201,7 @@ def refund(
@overload
def refund(
- self, **params: Unpack["ApplicationFee.RefundParams"]
+ self, **params: Unpack["ApplicationFeeRefundParams"]
) -> "ApplicationFeeRefund":
"""
Refunds an application fee that has previously been collected but not yet refunded.
@@ -316,7 +218,7 @@ def refund(
@class_method_variant("_cls_refund")
def refund( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["ApplicationFee.RefundParams"]
+ self, **params: Unpack["ApplicationFeeRefundParams"]
) -> "ApplicationFeeRefund":
"""
Refunds an application fee that has previously been collected but not yet refunded.
@@ -342,7 +244,7 @@ def refund( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_refund_async(
- cls, id: str, **params: Unpack["ApplicationFee.RefundParams"]
+ cls, id: str, **params: Unpack["ApplicationFeeRefundParams"]
) -> "ApplicationFeeRefund":
"""
Refunds an application fee that has previously been collected but not yet refunded.
@@ -367,7 +269,7 @@ async def _cls_refund_async(
@overload
@staticmethod
async def refund_async(
- id: str, **params: Unpack["ApplicationFee.RefundParams"]
+ id: str, **params: Unpack["ApplicationFeeRefundParams"]
) -> "ApplicationFeeRefund":
"""
Refunds an application fee that has previously been collected but not yet refunded.
@@ -384,7 +286,7 @@ async def refund_async(
@overload
async def refund_async(
- self, **params: Unpack["ApplicationFee.RefundParams"]
+ self, **params: Unpack["ApplicationFeeRefundParams"]
) -> "ApplicationFeeRefund":
"""
Refunds an application fee that has previously been collected but not yet refunded.
@@ -401,7 +303,7 @@ async def refund_async(
@class_method_variant("_cls_refund_async")
async def refund_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["ApplicationFee.RefundParams"]
+ self, **params: Unpack["ApplicationFeeRefundParams"]
) -> "ApplicationFeeRefund":
"""
Refunds an application fee that has previously been collected but not yet refunded.
@@ -427,7 +329,7 @@ async def refund_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["ApplicationFee.RetrieveParams"]
+ cls, id: str, **params: Unpack["ApplicationFeeRetrieveParams"]
) -> "ApplicationFee":
"""
Retrieves the details of an application fee that your account has collected. The same information is returned when refunding the application fee.
@@ -438,7 +340,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["ApplicationFee.RetrieveParams"]
+ cls, id: str, **params: Unpack["ApplicationFeeRetrieveParams"]
) -> "ApplicationFee":
"""
Retrieves the details of an application fee that your account has collected. The same information is returned when refunding the application fee.
@@ -452,7 +354,7 @@ def retrieve_refund(
cls,
fee: str,
id: str,
- **params: Unpack["ApplicationFee.RetrieveRefundParams"],
+ **params: Unpack["ApplicationFeeRetrieveRefundParams"],
) -> "ApplicationFeeRefund":
"""
By default, you can see the 10 most recent refunds stored directly on the application fee object, but you can also retrieve details about a specific refund stored on the application fee.
@@ -473,7 +375,7 @@ async def retrieve_refund_async(
cls,
fee: str,
id: str,
- **params: Unpack["ApplicationFee.RetrieveRefundParams"],
+ **params: Unpack["ApplicationFeeRetrieveRefundParams"],
) -> "ApplicationFeeRefund":
"""
By default, you can see the 10 most recent refunds stored directly on the application fee object, but you can also retrieve details about a specific refund stored on the application fee.
@@ -494,7 +396,7 @@ def modify_refund(
cls,
fee: str,
id: str,
- **params: Unpack["ApplicationFee.ModifyRefundParams"],
+ **params: Unpack["ApplicationFeeModifyRefundParams"],
) -> "ApplicationFeeRefund":
"""
Updates the specified application fee refund by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -517,7 +419,7 @@ async def modify_refund_async(
cls,
fee: str,
id: str,
- **params: Unpack["ApplicationFee.ModifyRefundParams"],
+ **params: Unpack["ApplicationFeeModifyRefundParams"],
) -> "ApplicationFeeRefund":
"""
Updates the specified application fee refund by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -537,7 +439,7 @@ async def modify_refund_async(
@classmethod
def list_refunds(
- cls, id: str, **params: Unpack["ApplicationFee.ListRefundsParams"]
+ 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.
@@ -553,7 +455,7 @@ def list_refunds(
@classmethod
async def list_refunds_async(
- cls, id: str, **params: Unpack["ApplicationFee.ListRefundsParams"]
+ 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.
@@ -569,7 +471,7 @@ async def list_refunds_async(
@classmethod
def create_refund(
- cls, id: str, **params: Unpack["ApplicationFee.CreateRefundParams"]
+ cls, id: str, **params: Unpack["ApplicationFeeCreateRefundParams"]
) -> "ApplicationFeeRefund":
"""
Refunds an application fee that has previously been collected but not yet refunded.
@@ -593,7 +495,7 @@ def create_refund(
@classmethod
async def create_refund_async(
- cls, id: str, **params: Unpack["ApplicationFee.CreateRefundParams"]
+ 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 74cb58839..e165ab3ef 100644
--- a/stripe/_application_fee_refund_service.py
+++ b/stripe/_application_fee_refund_service.py
@@ -5,64 +5,30 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._application_fee_refund_create_params import (
+ ApplicationFeeRefundCreateParams,
+ )
+ from stripe.params._application_fee_refund_list_params import (
+ ApplicationFeeRefundListParams,
+ )
+ from stripe.params._application_fee_refund_retrieve_params import (
+ ApplicationFeeRefundRetrieveParams,
+ )
+ from stripe.params._application_fee_refund_update_params import (
+ ApplicationFeeRefundUpdateParams,
+ )
class ApplicationFeeRefundService(StripeService):
- class CreateParams(TypedDict):
- amount: NotRequired[int]
- """
- A positive integer, in _cents (or local equivalent)_, representing how much of this fee to refund. Can refund only up to the remaining unrefunded amount of the fee.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
def retrieve(
self,
fee: str,
id: str,
- params: Optional["ApplicationFeeRefundService.RetrieveParams"] = None,
+ params: Optional["ApplicationFeeRefundRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ApplicationFeeRefund:
"""
@@ -86,7 +52,7 @@ async def retrieve_async(
self,
fee: str,
id: str,
- params: Optional["ApplicationFeeRefundService.RetrieveParams"] = None,
+ params: Optional["ApplicationFeeRefundRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ApplicationFeeRefund:
"""
@@ -110,7 +76,7 @@ def update(
self,
fee: str,
id: str,
- params: Optional["ApplicationFeeRefundService.UpdateParams"] = None,
+ params: Optional["ApplicationFeeRefundUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> ApplicationFeeRefund:
"""
@@ -136,7 +102,7 @@ async def update_async(
self,
fee: str,
id: str,
- params: Optional["ApplicationFeeRefundService.UpdateParams"] = None,
+ params: Optional["ApplicationFeeRefundUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> ApplicationFeeRefund:
"""
@@ -161,7 +127,7 @@ async def update_async(
def list(
self,
id: str,
- params: Optional["ApplicationFeeRefundService.ListParams"] = None,
+ params: Optional["ApplicationFeeRefundListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ApplicationFeeRefund]:
"""
@@ -181,7 +147,7 @@ def list(
async def list_async(
self,
id: str,
- params: Optional["ApplicationFeeRefundService.ListParams"] = None,
+ params: Optional["ApplicationFeeRefundListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ApplicationFeeRefund]:
"""
@@ -201,7 +167,7 @@ async def list_async(
def create(
self,
id: str,
- params: Optional["ApplicationFeeRefundService.CreateParams"] = None,
+ params: Optional["ApplicationFeeRefundCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> ApplicationFeeRefund:
"""
@@ -229,7 +195,7 @@ def create(
async def create_async(
self,
id: str,
- params: Optional["ApplicationFeeRefundService.CreateParams"] = None,
+ params: Optional["ApplicationFeeRefundCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> ApplicationFeeRefund:
"""
diff --git a/stripe/_application_fee_service.py b/stripe/_application_fee_service.py
index acd2122ba..975361c7f 100644
--- a/stripe/_application_fee_service.py
+++ b/stripe/_application_fee_service.py
@@ -6,8 +6,16 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._application_fee_list_params import (
+ ApplicationFeeListParams,
+ )
+ from stripe.params._application_fee_retrieve_params import (
+ ApplicationFeeRetrieveParams,
+ )
class ApplicationFeeService(StripeService):
@@ -15,59 +23,9 @@ def __init__(self, requestor):
super().__init__(requestor)
self.refunds = ApplicationFeeRefundService(self._requestor)
- class ListParams(TypedDict):
- charge: NotRequired[str]
- """
- Only return application fees for the charge specified by this charge ID.
- """
- created: NotRequired["ApplicationFeeService.ListParamsCreated|int"]
- """
- Only return applications fees that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
def list(
self,
- params: Optional["ApplicationFeeService.ListParams"] = None,
+ params: Optional["ApplicationFeeListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ApplicationFee]:
"""
@@ -86,7 +44,7 @@ def list(
async def list_async(
self,
- params: Optional["ApplicationFeeService.ListParams"] = None,
+ params: Optional["ApplicationFeeListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ApplicationFee]:
"""
@@ -106,7 +64,7 @@ async def list_async(
def retrieve(
self,
id: str,
- params: Optional["ApplicationFeeService.RetrieveParams"] = None,
+ params: Optional["ApplicationFeeRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ApplicationFee:
"""
@@ -126,7 +84,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["ApplicationFeeService.RetrieveParams"] = None,
+ params: Optional["ApplicationFeeRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ApplicationFee:
"""
diff --git a/stripe/_balance.py b/stripe/_balance.py
index da5c027db..e3a5e8475 100644
--- a/stripe/_balance.py
+++ b/stripe/_balance.py
@@ -1,10 +1,12 @@
# -*- coding: utf-8 -*-
# File generated from our OpenAPI spec
-from stripe._request_options import RequestOptions
from stripe._singleton_api_resource import SingletonAPIResource
from stripe._stripe_object import StripeObject
from typing import ClassVar, List, Optional
-from typing_extensions import Literal, NotRequired, Unpack
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._balance_retrieve_params import BalanceRetrieveParams
class Balance(SingletonAPIResource["Balance"]):
@@ -252,12 +254,6 @@ class SourceTypes(StripeObject):
"""
_inner_class_types = {"available": Available, "pending": Pending}
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
available: List[Available]
"""
Available funds that you can transfer or pay out automatically by Stripe or explicitly through the [Transfers API](https://stripe.com/docs/api#transfers) or [Payouts API](https://stripe.com/docs/api#payouts). You can find the available balance for each currency and payment type in the `source_types` property.
@@ -286,7 +282,7 @@ class RetrieveParams(RequestOptions):
refund_and_dispute_prefunding: Optional[RefundAndDisputePrefunding]
@classmethod
- def retrieve(cls, **params: Unpack["Balance.RetrieveParams"]) -> "Balance":
+ def retrieve(cls, **params: Unpack["BalanceRetrieveParams"]) -> "Balance":
"""
Retrieves the current account balance, based on the authentication that was used to make the request.
For a sample request, see [Accounting for negative balances](https://docs.stripe.com/docs/connect/account-balances#accounting-for-negative-balances).
@@ -297,7 +293,7 @@ def retrieve(cls, **params: Unpack["Balance.RetrieveParams"]) -> "Balance":
@classmethod
async def retrieve_async(
- cls, **params: Unpack["Balance.RetrieveParams"]
+ cls, **params: Unpack["BalanceRetrieveParams"]
) -> "Balance":
"""
Retrieves the current account balance, based on the authentication that was used to make the request.
diff --git a/stripe/_balance_service.py b/stripe/_balance_service.py
index 853093966..71356a8bf 100644
--- a/stripe/_balance_service.py
+++ b/stripe/_balance_service.py
@@ -3,20 +3,17 @@
from stripe._balance import Balance
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._balance_retrieve_params import BalanceRetrieveParams
-class BalanceService(StripeService):
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class BalanceService(StripeService):
def retrieve(
self,
- params: Optional["BalanceService.RetrieveParams"] = None,
+ params: Optional["BalanceRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Balance:
"""
@@ -36,7 +33,7 @@ def retrieve(
async def retrieve_async(
self,
- params: Optional["BalanceService.RetrieveParams"] = None,
+ params: Optional["BalanceRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Balance:
"""
diff --git a/stripe/_balance_settings.py b/stripe/_balance_settings.py
index 3e9414af9..bda6ce9b4 100644
--- a/stripe/_balance_settings.py
+++ b/stripe/_balance_settings.py
@@ -1,11 +1,18 @@
# -*- coding: utf-8 -*-
# File generated from our OpenAPI spec
-from stripe._request_options import RequestOptions
from stripe._singleton_api_resource import SingletonAPIResource
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
-from typing import ClassVar, Dict, List, Optional, Union, cast
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing import ClassVar, Dict, List, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._balance_settings_modify_params import (
+ BalanceSettingsModifyParams,
+ )
+ from stripe.params._balance_settings_retrieve_params import (
+ BalanceSettingsRetrieveParams,
+ )
class BalanceSettings(
@@ -88,80 +95,6 @@ class SettlementTiming(StripeObject):
"settlement_timing": SettlementTiming,
}
- class ModifyParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- payments: NotRequired["BalanceSettings.ModifyParamsPayments"]
- """
- Settings that apply to the [Payments Balance](https://docs.stripe.com/api/balance).
- """
-
- class ModifyParamsPayments(TypedDict):
- debit_negative_balances: NotRequired[bool]
- """
- A Boolean indicating whether Stripe should try to reclaim negative balances from an attached bank account. For details, see [Understanding Connect Account Balances](https://docs.stripe.com/connect/account-balances).
- """
- payouts: NotRequired["BalanceSettings.ModifyParamsPaymentsPayouts"]
- """
- Settings specific to the account's payouts.
- """
- settlement_timing: NotRequired[
- "BalanceSettings.ModifyParamsPaymentsSettlementTiming"
- ]
- """
- Settings related to the account's balance settlement timing.
- """
-
- class ModifyParamsPaymentsPayouts(TypedDict):
- minimum_balance_by_currency: NotRequired[
- "Literal['']|Dict[str, Union[Literal[''], int]]"
- ]
- """
- The minimum balance amount to retain per currency after automatic payouts. Only funds that exceed these amounts are paid out. Learn more about the [minimum balances for automatic payouts](https://docs.stripe.com/payouts/minimum-balances-for-automatic-payouts).
- """
- schedule: NotRequired[
- "BalanceSettings.ModifyParamsPaymentsPayoutsSchedule"
- ]
- """
- Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](https://docs.stripe.com/connect/bank-transfers#payout-information) documentation.
- """
- statement_descriptor: NotRequired[str]
- """
- The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
- """
-
- class ModifyParamsPaymentsPayoutsSchedule(TypedDict):
- interval: NotRequired[Literal["daily", "manual", "monthly", "weekly"]]
- """
- How frequently available funds are paid out. One of: `daily`, `manual`, `weekly`, or `monthly`. Default is `daily`.
- """
- monthly_payout_days: NotRequired[List[int]]
- """
- The days of the month when available funds are paid out, specified as an array of numbers between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly`.
- """
- weekly_payout_days: NotRequired[
- List[
- Literal["friday", "monday", "thursday", "tuesday", "wednesday"]
- ]
- ]
- """
- The days of the week when available funds are paid out, specified as an array, e.g., [`monday`, `tuesday`]. Required and applicable only if `interval` is `weekly`.
- """
-
- class ModifyParamsPaymentsSettlementTiming(TypedDict):
- delay_days_override: NotRequired["Literal['']|int"]
- """
- Change `delay_days` for this account, which determines the number of days charge funds are held before becoming available. The maximum value is 31. Passing an empty string to `delay_days_override` will return `delay_days` to the default, which is the lowest available value for the account. [Learn more about controlling delay days](https://docs.stripe.com/connect/manage-payout-schedule).
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
object: Literal["balance_settings"]
"""
String representing the object's type. Objects of the same type share the same value.
@@ -170,7 +103,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def modify(
- cls, **params: Unpack["BalanceSettings.ModifyParams"]
+ cls, **params: Unpack["BalanceSettingsModifyParams"]
) -> "BalanceSettings":
"""
Updates balance settings for a given connected account.
@@ -187,7 +120,7 @@ def modify(
@classmethod
async def modify_async(
- cls, **params: Unpack["BalanceSettings.ModifyParams"]
+ cls, **params: Unpack["BalanceSettingsModifyParams"]
) -> "BalanceSettings":
"""
Updates balance settings for a given connected account.
@@ -204,7 +137,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, **params: Unpack["BalanceSettings.RetrieveParams"]
+ cls, **params: Unpack["BalanceSettingsRetrieveParams"]
) -> "BalanceSettings":
"""
Retrieves balance settings for a given connected account.
@@ -216,7 +149,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, **params: Unpack["BalanceSettings.RetrieveParams"]
+ cls, **params: Unpack["BalanceSettingsRetrieveParams"]
) -> "BalanceSettings":
"""
Retrieves balance settings for a given connected account.
diff --git a/stripe/_balance_settings_service.py b/stripe/_balance_settings_service.py
index 180e0abd0..a4a238183 100644
--- a/stripe/_balance_settings_service.py
+++ b/stripe/_balance_settings_service.py
@@ -3,90 +3,22 @@
from stripe._balance_settings import BalanceSettings
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
-from typing import Dict, List, Optional, Union, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._balance_settings_retrieve_params import (
+ BalanceSettingsRetrieveParams,
+ )
+ from stripe.params._balance_settings_update_params import (
+ BalanceSettingsUpdateParams,
+ )
-class BalanceSettingsService(StripeService):
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- payments: NotRequired["BalanceSettingsService.UpdateParamsPayments"]
- """
- Settings that apply to the [Payments Balance](https://docs.stripe.com/api/balance).
- """
-
- class UpdateParamsPayments(TypedDict):
- debit_negative_balances: NotRequired[bool]
- """
- A Boolean indicating whether Stripe should try to reclaim negative balances from an attached bank account. For details, see [Understanding Connect Account Balances](https://docs.stripe.com/connect/account-balances).
- """
- payouts: NotRequired[
- "BalanceSettingsService.UpdateParamsPaymentsPayouts"
- ]
- """
- Settings specific to the account's payouts.
- """
- settlement_timing: NotRequired[
- "BalanceSettingsService.UpdateParamsPaymentsSettlementTiming"
- ]
- """
- Settings related to the account's balance settlement timing.
- """
-
- class UpdateParamsPaymentsPayouts(TypedDict):
- minimum_balance_by_currency: NotRequired[
- "Literal['']|Dict[str, Union[Literal[''], int]]"
- ]
- """
- The minimum balance amount to retain per currency after automatic payouts. Only funds that exceed these amounts are paid out. Learn more about the [minimum balances for automatic payouts](https://docs.stripe.com/payouts/minimum-balances-for-automatic-payouts).
- """
- schedule: NotRequired[
- "BalanceSettingsService.UpdateParamsPaymentsPayoutsSchedule"
- ]
- """
- Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](https://docs.stripe.com/connect/bank-transfers#payout-information) documentation.
- """
- statement_descriptor: NotRequired[str]
- """
- The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
- """
-
- class UpdateParamsPaymentsPayoutsSchedule(TypedDict):
- interval: NotRequired[Literal["daily", "manual", "monthly", "weekly"]]
- """
- How frequently available funds are paid out. One of: `daily`, `manual`, `weekly`, or `monthly`. Default is `daily`.
- """
- monthly_payout_days: NotRequired[List[int]]
- """
- The days of the month when available funds are paid out, specified as an array of numbers between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly`.
- """
- weekly_payout_days: NotRequired[
- List[
- Literal["friday", "monday", "thursday", "tuesday", "wednesday"]
- ]
- ]
- """
- The days of the week when available funds are paid out, specified as an array, e.g., [`monday`, `tuesday`]. Required and applicable only if `interval` is `weekly`.
- """
-
- class UpdateParamsPaymentsSettlementTiming(TypedDict):
- delay_days_override: NotRequired["Literal['']|int"]
- """
- Change `delay_days` for this account, which determines the number of days charge funds are held before becoming available. The maximum value is 31. Passing an empty string to `delay_days_override` will return `delay_days` to the default, which is the lowest available value for the account. [Learn more about controlling delay days](https://docs.stripe.com/connect/manage-payout-schedule).
- """
+class BalanceSettingsService(StripeService):
def retrieve(
self,
- params: Optional["BalanceSettingsService.RetrieveParams"] = None,
+ params: Optional["BalanceSettingsRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> BalanceSettings:
"""
@@ -106,7 +38,7 @@ def retrieve(
async def retrieve_async(
self,
- params: Optional["BalanceSettingsService.RetrieveParams"] = None,
+ params: Optional["BalanceSettingsRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> BalanceSettings:
"""
@@ -126,7 +58,7 @@ async def retrieve_async(
def update(
self,
- params: Optional["BalanceSettingsService.UpdateParams"] = None,
+ params: Optional["BalanceSettingsUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> BalanceSettings:
"""
@@ -146,7 +78,7 @@ def update(
async def update_async(
self,
- params: Optional["BalanceSettingsService.UpdateParams"] = None,
+ params: Optional["BalanceSettingsUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> BalanceSettings:
"""
diff --git a/stripe/_balance_transaction.py b/stripe/_balance_transaction.py
index af4cf03a4..e8393984c 100644
--- a/stripe/_balance_transaction.py
+++ b/stripe/_balance_transaction.py
@@ -3,16 +3,9 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from typing import ClassVar, List, Optional, Union
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._application_fee import ApplicationFee
@@ -33,6 +26,12 @@
from stripe.issuing._authorization import Authorization
from stripe.issuing._dispute import Dispute as IssuingDisputeResource
from stripe.issuing._transaction import Transaction
+ from stripe.params._balance_transaction_list_params import (
+ BalanceTransactionListParams,
+ )
+ from stripe.params._balance_transaction_retrieve_params import (
+ BalanceTransactionRetrieveParams,
+ )
class BalanceTransaction(ListableAPIResource["BalanceTransaction"]):
@@ -69,68 +68,6 @@ class FeeDetail(StripeObject):
Type of the fee, one of: `application_fee`, `payment_method_passthrough_fee`, `stripe_fee` or `tax`.
"""
- class ListParams(RequestOptions):
- created: NotRequired["BalanceTransaction.ListParamsCreated|int"]
- """
- Only return transactions that were created during the given date interval.
- """
- currency: NotRequired[str]
- """
- Only return transactions in a certain currency. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payout: NotRequired[str]
- """
- For automatic Stripe payouts only, only returns transactions that were paid out on the specified payout ID.
- """
- source: NotRequired[str]
- """
- Only returns the original transaction.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[str]
- """
- Only returns transactions of the given type. One of: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `climate_order_purchase`, `climate_order_refund`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `obligation_outbound`, `obligation_reversal_inbound`, `payment`, `payment_failure_refund`, `payment_network_reserve_hold`, `payment_network_reserve_release`, `payment_refund`, `payment_reversal`, `payment_unreconciled`, `payout`, `payout_cancel`, `payout_failure`, `payout_minimum_balance_hold`, `payout_minimum_balance_release`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `stripe_balance_payment_debit`, `stripe_balance_payment_debit_reversal`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount: int
"""
Gross amount of this transaction (in cents (or local equivalent)). A positive value represents funds charged to another party, and a negative value represents funds sent to another party.
@@ -266,7 +203,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["BalanceTransaction.ListParams"]
+ cls, **params: Unpack["BalanceTransactionListParams"]
) -> ListObject["BalanceTransaction"]:
"""
Returns a list of transactions that have contributed to the Stripe account balance (e.g., charges, transfers, and so forth). The transactions are returned in sorted order, with the most recent transactions appearing first.
@@ -288,7 +225,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["BalanceTransaction.ListParams"]
+ cls, **params: Unpack["BalanceTransactionListParams"]
) -> ListObject["BalanceTransaction"]:
"""
Returns a list of transactions that have contributed to the Stripe account balance (e.g., charges, transfers, and so forth). The transactions are returned in sorted order, with the most recent transactions appearing first.
@@ -310,7 +247,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["BalanceTransaction.RetrieveParams"]
+ cls, id: str, **params: Unpack["BalanceTransactionRetrieveParams"]
) -> "BalanceTransaction":
"""
Retrieves the balance transaction with the given ID.
@@ -323,7 +260,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["BalanceTransaction.RetrieveParams"]
+ cls, id: str, **params: Unpack["BalanceTransactionRetrieveParams"]
) -> "BalanceTransaction":
"""
Retrieves the balance transaction with the given ID.
diff --git a/stripe/_balance_transaction_service.py b/stripe/_balance_transaction_service.py
index 0ff6ee052..3a8deb243 100644
--- a/stripe/_balance_transaction_service.py
+++ b/stripe/_balance_transaction_service.py
@@ -5,76 +5,22 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._balance_transaction_list_params import (
+ BalanceTransactionListParams,
+ )
+ from stripe.params._balance_transaction_retrieve_params import (
+ BalanceTransactionRetrieveParams,
+ )
-class BalanceTransactionService(StripeService):
- class ListParams(TypedDict):
- created: NotRequired["BalanceTransactionService.ListParamsCreated|int"]
- """
- Only return transactions that were created during the given date interval.
- """
- currency: NotRequired[str]
- """
- Only return transactions in a certain currency. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payout: NotRequired[str]
- """
- For automatic Stripe payouts only, only returns transactions that were paid out on the specified payout ID.
- """
- source: NotRequired[str]
- """
- Only returns the original transaction.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[str]
- """
- Only returns transactions of the given type. One of: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `climate_order_purchase`, `climate_order_refund`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `obligation_outbound`, `obligation_reversal_inbound`, `payment`, `payment_failure_refund`, `payment_network_reserve_hold`, `payment_network_reserve_release`, `payment_refund`, `payment_reversal`, `payment_unreconciled`, `payout`, `payout_cancel`, `payout_failure`, `payout_minimum_balance_hold`, `payout_minimum_balance_release`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `stripe_balance_payment_debit`, `stripe_balance_payment_debit_reversal`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class BalanceTransactionService(StripeService):
def list(
self,
- params: Optional["BalanceTransactionService.ListParams"] = None,
+ params: Optional["BalanceTransactionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[BalanceTransaction]:
"""
@@ -95,7 +41,7 @@ def list(
async def list_async(
self,
- params: Optional["BalanceTransactionService.ListParams"] = None,
+ params: Optional["BalanceTransactionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[BalanceTransaction]:
"""
@@ -117,7 +63,7 @@ async def list_async(
def retrieve(
self,
id: str,
- params: Optional["BalanceTransactionService.RetrieveParams"] = None,
+ params: Optional["BalanceTransactionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> BalanceTransaction:
"""
@@ -139,7 +85,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["BalanceTransactionService.RetrieveParams"] = None,
+ params: Optional["BalanceTransactionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> BalanceTransaction:
"""
diff --git a/stripe/_bank_account.py b/stripe/_bank_account.py
index e03b816ca..068e8cccd 100644
--- a/stripe/_bank_account.py
+++ b/stripe/_bank_account.py
@@ -5,7 +5,6 @@
from stripe._deletable_api_resource import DeletableAPIResource
from stripe._error import InvalidRequestError
from stripe._expandable_field import ExpandableField
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
@@ -15,6 +14,9 @@
if TYPE_CHECKING:
from stripe._card import Card
+ from stripe.params._bank_account_delete_params import (
+ BankAccountDeleteParams,
+ )
class BankAccount(
@@ -296,9 +298,6 @@ class Error(StripeObject):
"""
_inner_class_types = {"errors": Error}
- class DeleteParams(RequestOptions):
- pass
-
account: Optional[ExpandableField["Account"]]
"""
The account this bank account belongs to. Only applicable on Accounts (not customers or recipients) This property is only available when returned as an [External Account](https://docs.stripe.com/api/external_account_bank_accounts/object) where [controller.is_controller](https://docs.stripe.com/api/accounts/object#account_object-controller-is_controller) is `true`.
@@ -384,7 +383,7 @@ class DeleteParams(RequestOptions):
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["BankAccount.DeleteParams"]
+ cls, sid: str, **params: Unpack["BankAccountDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -402,7 +401,7 @@ def _cls_delete(
@overload
@staticmethod
def delete(
- sid: str, **params: Unpack["BankAccount.DeleteParams"]
+ sid: str, **params: Unpack["BankAccountDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -411,7 +410,7 @@ def delete(
@overload
def delete(
- self, **params: Unpack["BankAccount.DeleteParams"]
+ self, **params: Unpack["BankAccountDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -420,7 +419,7 @@ def delete(
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["BankAccount.DeleteParams"]
+ self, **params: Unpack["BankAccountDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -433,7 +432,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["BankAccount.DeleteParams"]
+ cls, sid: str, **params: Unpack["BankAccountDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -451,7 +450,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["BankAccount.DeleteParams"]
+ sid: str, **params: Unpack["BankAccountDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -460,7 +459,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["BankAccount.DeleteParams"]
+ self, **params: Unpack["BankAccountDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -469,7 +468,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["BankAccount.DeleteParams"]
+ self, **params: Unpack["BankAccountDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
diff --git a/stripe/_card.py b/stripe/_card.py
index d16a120df..5936cc24f 100644
--- a/stripe/_card.py
+++ b/stripe/_card.py
@@ -5,7 +5,6 @@
from stripe._deletable_api_resource import DeletableAPIResource
from stripe._error import InvalidRequestError
from stripe._expandable_field import ExpandableField
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
@@ -14,6 +13,7 @@
if TYPE_CHECKING:
from stripe._bank_account import BankAccount
+ from stripe.params._card_delete_params import CardDeleteParams
class Card(DeletableAPIResource["Card"], UpdateableAPIResource["Card"]):
@@ -33,9 +33,6 @@ class Networks(StripeObject):
The preferred network for co-branded cards. Can be `cartes_bancaires`, `mastercard`, `visa` or `invalid_preference` if requested network is not valid for the card.
"""
- class DeleteParams(RequestOptions):
- pass
-
account: Optional[ExpandableField["Account"]]
address_city: Optional[str]
"""
@@ -175,7 +172,7 @@ class DeleteParams(RequestOptions):
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["Card.DeleteParams"]
+ cls, sid: str, **params: Unpack["CardDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -193,7 +190,7 @@ def _cls_delete(
@overload
@staticmethod
def delete(
- sid: str, **params: Unpack["Card.DeleteParams"]
+ sid: str, **params: Unpack["CardDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -202,7 +199,7 @@ def delete(
@overload
def delete(
- self, **params: Unpack["Card.DeleteParams"]
+ self, **params: Unpack["CardDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -211,7 +208,7 @@ def delete(
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Card.DeleteParams"]
+ self, **params: Unpack["CardDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -224,7 +221,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["Card.DeleteParams"]
+ cls, sid: str, **params: Unpack["CardDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -242,7 +239,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["Card.DeleteParams"]
+ sid: str, **params: Unpack["CardDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -251,7 +248,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["Card.DeleteParams"]
+ self, **params: Unpack["CardDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
@@ -260,7 +257,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Card.DeleteParams"]
+ self, **params: Unpack["CardDeleteParams"]
) -> Union["BankAccount", "Card"]:
"""
Delete a specified external account for a given account.
diff --git a/stripe/_charge.py b/stripe/_charge.py
index e9a3cb14c..4bf231cfe 100644
--- a/stripe/_charge.py
+++ b/stripe/_charge.py
@@ -5,7 +5,6 @@
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
from stripe._nested_resource_class_methods import nested_resource_class_methods
-from stripe._request_options import RequestOptions
from stripe._search_result_object import SearchResultObject
from stripe._searchable_api_resource import SearchableAPIResource
from stripe._stripe_object import StripeObject
@@ -22,13 +21,7 @@
cast,
overload,
)
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account
@@ -45,6 +38,18 @@
from stripe._review import Review
from stripe._source import Source
from stripe._transfer import Transfer
+ from stripe.params._charge_capture_params import ChargeCaptureParams
+ from stripe.params._charge_create_params import ChargeCreateParams
+ from stripe.params._charge_list_params import ChargeListParams
+ from stripe.params._charge_list_refunds_params import (
+ ChargeListRefundsParams,
+ )
+ from stripe.params._charge_modify_params import ChargeModifyParams
+ from stripe.params._charge_retrieve_params import ChargeRetrieveParams
+ from stripe.params._charge_retrieve_refund_params import (
+ ChargeRetrieveRefundParams,
+ )
+ from stripe.params._charge_search_params import ChargeSearchParams
@nested_resource_class_methods("refund")
@@ -2127,388 +2132,6 @@ class TransferData(StripeObject):
ID of an existing, connected Stripe account to transfer funds to if `transfer_data` was specified in the charge request.
"""
- class CaptureParams(RequestOptions):
- amount: NotRequired[int]
- """
- The amount to capture, which must be less than or equal to the original amount.
- """
- application_fee: NotRequired[int]
- """
- An application fee to add on to this charge.
- """
- application_fee_amount: NotRequired[int]
- """
- An application fee amount to add on to this charge, which must be less than or equal to the original amount.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- receipt_email: NotRequired[str]
- """
- The email address to send this charge's receipt to. This will override the previously-specified email address for this charge, if one was set. Receipts will not be sent in test mode.
- """
- statement_descriptor: NotRequired[str]
- """
- For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
-
- For a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.
- """
- statement_descriptor_suffix: NotRequired[str]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.
- """
- transfer_data: NotRequired["Charge.CaptureParamsTransferData"]
- """
- An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
- """
-
- class CaptureParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount transferred to the destination account, if specified. By default, the entire charge amount is transferred to the destination account.
- """
-
- class CreateParams(RequestOptions):
- amount: NotRequired[int]
- """
- Amount intended to be collected by this payment. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
- """
- application_fee: NotRequired[int]
- application_fee_amount: NotRequired[int]
- """
- A fee in cents (or local equivalent) that will be applied to the charge and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the `Stripe-Account` header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/connect/direct-charges#collect-fees).
- """
- capture: NotRequired[bool]
- """
- Whether to immediately capture the charge. Defaults to `true`. When `false`, the charge issues an authorization (or pre-authorization), and will need to be [captured](https://stripe.com/docs/api#capture_charge) later. Uncaptured charges expire after a set number of days (7 by default). For more information, see the [authorizing charges and settling later](https://stripe.com/docs/charges/placing-a-hold) documentation.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: NotRequired[str]
- """
- The ID of an existing customer that will be charged in this request.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to a `Charge` object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.
- """
- destination: NotRequired["Charge.CreateParamsDestination"]
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The Stripe account ID for which these funds are intended. Automatically set if you use the `destination` parameter. For details, see [Creating Separate Charges and Transfers](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant).
- """
- radar_options: NotRequired["Charge.CreateParamsRadarOptions"]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- receipt_email: NotRequired[str]
- """
- The email address to which this charge's [receipt](https://stripe.com/docs/dashboard/receipts) will be sent. The receipt will not be sent until the charge is paid, and no receipts will be sent for test mode charges. If this charge is for a [Customer](https://stripe.com/docs/api/customers/object), the email address specified here will override the customer's email address. If `receipt_email` is specified for a charge in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
- """
- shipping: NotRequired["Charge.CreateParamsShipping"]
- """
- Shipping information for the charge. Helps prevent fraud on charges for physical goods.
- """
- source: NotRequired[str]
- """
- A payment source to be charged. This can be the ID of a [card](https://stripe.com/docs/api#cards) (i.e., credit or debit card), a [bank account](https://stripe.com/docs/api#bank_accounts), a [source](https://stripe.com/docs/api#sources), a [token](https://stripe.com/docs/api#tokens), or a [connected account](https://stripe.com/docs/connect/account-debits#charging-a-connected-account). For certain sources---namely, [cards](https://stripe.com/docs/api#cards), [bank accounts](https://stripe.com/docs/api#bank_accounts), and attached [sources](https://stripe.com/docs/api#sources)---you must also pass the ID of the associated customer.
- """
- statement_descriptor: NotRequired[str]
- """
- For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
-
- For a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.
- """
- statement_descriptor_suffix: NotRequired[str]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.
- """
- transfer_data: NotRequired["Charge.CreateParamsTransferData"]
- """
- An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies this transaction as part of a group. For details, see [Grouping transactions](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options).
- """
-
- class CreateParamsDestination(TypedDict):
- account: str
- """
- ID of an existing, connected Stripe account.
- """
- amount: NotRequired[int]
- """
- The amount to transfer to the destination account without creating an `Application Fee` object. Cannot be combined with the `application_fee` parameter. Must be less than or equal to the charge amount.
- """
-
- class CreateParamsRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class CreateParamsShipping(TypedDict):
- address: "Charge.CreateParamsShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class CreateParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount transferred to the destination account, if specified. By default, the entire charge amount is transferred to the destination account.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["Charge.ListParamsCreated|int"]
- """
- Only return charges that were created during the given date interval.
- """
- customer: NotRequired[str]
- """
- Only return charges for the customer specified by this customer ID.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payment_intent: NotRequired[str]
- """
- Only return charges that were created by the PaymentIntent specified by this PaymentIntent ID.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- transfer_group: NotRequired[str]
- """
- Only return charges for this transfer group, limited to 100.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListRefundsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ModifyParams(RequestOptions):
- customer: NotRequired[str]
- """
- The ID of an existing customer that will be associated with this request. This field may only be updated if there is no existing associated customer with this charge.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to a charge object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- fraud_details: NotRequired["Charge.ModifyParamsFraudDetails"]
- """
- A set of key-value pairs you can attach to a charge giving information about its riskiness. If you believe a charge is fraudulent, include a `user_report` key with a value of `fraudulent`. If you believe a charge is safe, include a `user_report` key with a value of `safe`. Stripe will use the information you send to improve our fraud detection algorithms.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- receipt_email: NotRequired[str]
- """
- This is the email address that the receipt for this charge will be sent to. If this field is updated, then a new email receipt will be sent to the updated address.
- """
- shipping: NotRequired["Charge.ModifyParamsShipping"]
- """
- Shipping information for the charge. Helps prevent fraud on charges for physical goods.
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
- """
-
- class ModifyParamsFraudDetails(TypedDict):
- user_report: Union[Literal[""], Literal["fraudulent", "safe"]]
- """
- Either `safe` or `fraudulent`.
- """
-
- class ModifyParamsShipping(TypedDict):
- address: "Charge.ModifyParamsShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class ModifyParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveRefundParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SearchParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- page: NotRequired[str]
- """
- A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
- """
- query: str
- """
- The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for charges](https://stripe.com/docs/search#query-fields-for-charges).
- """
-
amount: int
"""
Amount intended to be collected by this payment. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
@@ -2699,7 +2322,7 @@ class SearchParams(RequestOptions):
@classmethod
def _cls_capture(
- cls, charge: str, **params: Unpack["Charge.CaptureParams"]
+ 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.
@@ -2722,7 +2345,7 @@ def _cls_capture(
@overload
@staticmethod
def capture(
- charge: str, **params: Unpack["Charge.CaptureParams"]
+ charge: str, **params: Unpack["ChargeCaptureParams"]
) -> "Charge":
"""
Capture the payment of an existing, uncaptured charge that was created with the capture option set to false.
@@ -2734,7 +2357,7 @@ def capture(
...
@overload
- def capture(self, **params: Unpack["Charge.CaptureParams"]) -> "Charge":
+ def capture(self, **params: Unpack["ChargeCaptureParams"]) -> "Charge":
"""
Capture the payment of an existing, uncaptured charge that was created with the capture option set to false.
@@ -2746,7 +2369,7 @@ def capture(self, **params: Unpack["Charge.CaptureParams"]) -> "Charge":
@class_method_variant("_cls_capture")
def capture( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Charge.CaptureParams"]
+ self, **params: Unpack["ChargeCaptureParams"]
) -> "Charge":
"""
Capture the payment of an existing, uncaptured charge that was created with the capture option set to false.
@@ -2768,7 +2391,7 @@ def capture( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_capture_async(
- cls, charge: str, **params: Unpack["Charge.CaptureParams"]
+ 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.
@@ -2791,7 +2414,7 @@ async def _cls_capture_async(
@overload
@staticmethod
async def capture_async(
- charge: str, **params: Unpack["Charge.CaptureParams"]
+ charge: str, **params: Unpack["ChargeCaptureParams"]
) -> "Charge":
"""
Capture the payment of an existing, uncaptured charge that was created with the capture option set to false.
@@ -2804,7 +2427,7 @@ async def capture_async(
@overload
async def capture_async(
- self, **params: Unpack["Charge.CaptureParams"]
+ self, **params: Unpack["ChargeCaptureParams"]
) -> "Charge":
"""
Capture the payment of an existing, uncaptured charge that was created with the capture option set to false.
@@ -2817,7 +2440,7 @@ async def capture_async(
@class_method_variant("_cls_capture_async")
async def capture_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Charge.CaptureParams"]
+ self, **params: Unpack["ChargeCaptureParams"]
) -> "Charge":
"""
Capture the payment of an existing, uncaptured charge that was created with the capture option set to false.
@@ -2838,7 +2461,7 @@ async def capture_async( # pyright: ignore[reportGeneralTypeIssues]
)
@classmethod
- def create(cls, **params: Unpack["Charge.CreateParams"]) -> "Charge":
+ def create(cls, **params: Unpack["ChargeCreateParams"]) -> "Charge":
"""
This method is no longer recommended—use the [Payment Intents API](https://docs.stripe.com/docs/api/payment_intents)
to initiate a new payment instead. Confirmation of the PaymentIntent creates the Charge
@@ -2855,7 +2478,7 @@ def create(cls, **params: Unpack["Charge.CreateParams"]) -> "Charge":
@classmethod
async def create_async(
- cls, **params: Unpack["Charge.CreateParams"]
+ cls, **params: Unpack["ChargeCreateParams"]
) -> "Charge":
"""
This method is no longer recommended—use the [Payment Intents API](https://docs.stripe.com/docs/api/payment_intents)
@@ -2873,7 +2496,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["Charge.ListParams"]
+ cls, **params: Unpack["ChargeListParams"]
) -> ListObject["Charge"]:
"""
Returns a list of charges you've previously created. The charges are returned in sorted order, with the most recent charges appearing first.
@@ -2893,7 +2516,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Charge.ListParams"]
+ cls, **params: Unpack["ChargeListParams"]
) -> ListObject["Charge"]:
"""
Returns a list of charges you've previously created. The charges are returned in sorted order, with the most recent charges appearing first.
@@ -2913,7 +2536,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Charge.ModifyParams"]
+ cls, id: str, **params: Unpack["ChargeModifyParams"]
) -> "Charge":
"""
Updates the specified charge by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -2930,7 +2553,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Charge.ModifyParams"]
+ cls, id: str, **params: Unpack["ChargeModifyParams"]
) -> "Charge":
"""
Updates the specified charge by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -2947,7 +2570,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Charge.RetrieveParams"]
+ cls, id: str, **params: Unpack["ChargeRetrieveParams"]
) -> "Charge":
"""
Retrieves the details of a charge that has previously been created. Supply the unique charge ID that was returned from your previous request, and Stripe will return the corresponding charge information. The same information is returned when creating or refunding the charge.
@@ -2958,7 +2581,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Charge.RetrieveParams"]
+ cls, id: str, **params: Unpack["ChargeRetrieveParams"]
) -> "Charge":
"""
Retrieves the details of a charge that has previously been created. Supply the unique charge ID that was returned from your previous request, and Stripe will return the corresponding charge information. The same information is returned when creating or refunding the charge.
@@ -2969,7 +2592,7 @@ async def retrieve_async(
@classmethod
def search(
- cls, *args, **kwargs: Unpack["Charge.SearchParams"]
+ cls, *args, **kwargs: Unpack["ChargeSearchParams"]
) -> SearchResultObject["Charge"]:
"""
Search for charges you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
@@ -2981,7 +2604,7 @@ def search(
@classmethod
async def search_async(
- cls, *args, **kwargs: Unpack["Charge.SearchParams"]
+ cls, *args, **kwargs: Unpack["ChargeSearchParams"]
) -> SearchResultObject["Charge"]:
"""
Search for charges you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
@@ -2995,13 +2618,13 @@ async def search_async(
@classmethod
def search_auto_paging_iter(
- cls, *args, **kwargs: Unpack["Charge.SearchParams"]
+ cls, *args, **kwargs: Unpack["ChargeSearchParams"]
) -> Iterator["Charge"]:
return cls.search(*args, **kwargs).auto_paging_iter()
@classmethod
async def search_auto_paging_iter_async(
- cls, *args, **kwargs: Unpack["Charge.SearchParams"]
+ cls, *args, **kwargs: Unpack["ChargeSearchParams"]
) -> AsyncIterator["Charge"]:
return (await cls.search_async(*args, **kwargs)).auto_paging_iter()
@@ -3028,7 +2651,7 @@ def retrieve_refund(
cls,
charge: str,
refund: str,
- **params: Unpack["Charge.RetrieveRefundParams"],
+ **params: Unpack["ChargeRetrieveRefundParams"],
) -> "Refund":
"""
Retrieves the details of an existing refund.
@@ -3049,7 +2672,7 @@ async def retrieve_refund_async(
cls,
charge: str,
refund: str,
- **params: Unpack["Charge.RetrieveRefundParams"],
+ **params: Unpack["ChargeRetrieveRefundParams"],
) -> "Refund":
"""
Retrieves the details of an existing refund.
@@ -3067,7 +2690,7 @@ async def retrieve_refund_async(
@classmethod
def list_refunds(
- cls, charge: str, **params: Unpack["Charge.ListRefundsParams"]
+ 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.
@@ -3085,7 +2708,7 @@ def list_refunds(
@classmethod
async def list_refunds_async(
- cls, charge: str, **params: Unpack["Charge.ListRefundsParams"]
+ 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 6c35dc66b..03a6da2ba 100644
--- a/stripe/_charge_service.py
+++ b/stripe/_charge_service.py
@@ -6,372 +6,22 @@
from stripe._search_result_object import SearchResultObject
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, Union, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._charge_capture_params import ChargeCaptureParams
+ from stripe.params._charge_create_params import ChargeCreateParams
+ from stripe.params._charge_list_params import ChargeListParams
+ from stripe.params._charge_retrieve_params import ChargeRetrieveParams
+ from stripe.params._charge_search_params import ChargeSearchParams
+ from stripe.params._charge_update_params import ChargeUpdateParams
-class ChargeService(StripeService):
- class CaptureParams(TypedDict):
- amount: NotRequired[int]
- """
- The amount to capture, which must be less than or equal to the original amount.
- """
- application_fee: NotRequired[int]
- """
- An application fee to add on to this charge.
- """
- application_fee_amount: NotRequired[int]
- """
- An application fee amount to add on to this charge, which must be less than or equal to the original amount.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- receipt_email: NotRequired[str]
- """
- The email address to send this charge's receipt to. This will override the previously-specified email address for this charge, if one was set. Receipts will not be sent in test mode.
- """
- statement_descriptor: NotRequired[str]
- """
- For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
-
- For a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.
- """
- statement_descriptor_suffix: NotRequired[str]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.
- """
- transfer_data: NotRequired["ChargeService.CaptureParamsTransferData"]
- """
- An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
- """
-
- class CaptureParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount transferred to the destination account, if specified. By default, the entire charge amount is transferred to the destination account.
- """
-
- class CreateParams(TypedDict):
- amount: NotRequired[int]
- """
- Amount intended to be collected by this payment. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
- """
- application_fee: NotRequired[int]
- application_fee_amount: NotRequired[int]
- """
- A fee in cents (or local equivalent) that will be applied to the charge and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the `Stripe-Account` header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/connect/direct-charges#collect-fees).
- """
- capture: NotRequired[bool]
- """
- Whether to immediately capture the charge. Defaults to `true`. When `false`, the charge issues an authorization (or pre-authorization), and will need to be [captured](https://stripe.com/docs/api#capture_charge) later. Uncaptured charges expire after a set number of days (7 by default). For more information, see the [authorizing charges and settling later](https://stripe.com/docs/charges/placing-a-hold) documentation.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: NotRequired[str]
- """
- The ID of an existing customer that will be charged in this request.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to a `Charge` object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.
- """
- destination: NotRequired["ChargeService.CreateParamsDestination"]
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The Stripe account ID for which these funds are intended. Automatically set if you use the `destination` parameter. For details, see [Creating Separate Charges and Transfers](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant).
- """
- radar_options: NotRequired["ChargeService.CreateParamsRadarOptions"]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- receipt_email: NotRequired[str]
- """
- The email address to which this charge's [receipt](https://stripe.com/docs/dashboard/receipts) will be sent. The receipt will not be sent until the charge is paid, and no receipts will be sent for test mode charges. If this charge is for a [Customer](https://stripe.com/docs/api/customers/object), the email address specified here will override the customer's email address. If `receipt_email` is specified for a charge in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
- """
- shipping: NotRequired["ChargeService.CreateParamsShipping"]
- """
- Shipping information for the charge. Helps prevent fraud on charges for physical goods.
- """
- source: NotRequired[str]
- """
- A payment source to be charged. This can be the ID of a [card](https://stripe.com/docs/api#cards) (i.e., credit or debit card), a [bank account](https://stripe.com/docs/api#bank_accounts), a [source](https://stripe.com/docs/api#sources), a [token](https://stripe.com/docs/api#tokens), or a [connected account](https://stripe.com/docs/connect/account-debits#charging-a-connected-account). For certain sources---namely, [cards](https://stripe.com/docs/api#cards), [bank accounts](https://stripe.com/docs/api#bank_accounts), and attached [sources](https://stripe.com/docs/api#sources)---you must also pass the ID of the associated customer.
- """
- statement_descriptor: NotRequired[str]
- """
- For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
-
- For a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.
- """
- statement_descriptor_suffix: NotRequired[str]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.
- """
- transfer_data: NotRequired["ChargeService.CreateParamsTransferData"]
- """
- An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies this transaction as part of a group. For details, see [Grouping transactions](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options).
- """
-
- class CreateParamsDestination(TypedDict):
- account: str
- """
- ID of an existing, connected Stripe account.
- """
- amount: NotRequired[int]
- """
- The amount to transfer to the destination account without creating an `Application Fee` object. Cannot be combined with the `application_fee` parameter. Must be less than or equal to the charge amount.
- """
-
- class CreateParamsRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class CreateParamsShipping(TypedDict):
- address: "ChargeService.CreateParamsShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class CreateParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount transferred to the destination account, if specified. By default, the entire charge amount is transferred to the destination account.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class ListParams(TypedDict):
- created: NotRequired["ChargeService.ListParamsCreated|int"]
- """
- Only return charges that were created during the given date interval.
- """
- customer: NotRequired[str]
- """
- Only return charges for the customer specified by this customer ID.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payment_intent: NotRequired[str]
- """
- Only return charges that were created by the PaymentIntent specified by this PaymentIntent ID.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- transfer_group: NotRequired[str]
- """
- Only return charges for this transfer group, limited to 100.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SearchParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- page: NotRequired[str]
- """
- A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
- """
- query: str
- """
- The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for charges](https://stripe.com/docs/search#query-fields-for-charges).
- """
-
- class UpdateParams(TypedDict):
- customer: NotRequired[str]
- """
- The ID of an existing customer that will be associated with this request. This field may only be updated if there is no existing associated customer with this charge.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to a charge object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- fraud_details: NotRequired["ChargeService.UpdateParamsFraudDetails"]
- """
- A set of key-value pairs you can attach to a charge giving information about its riskiness. If you believe a charge is fraudulent, include a `user_report` key with a value of `fraudulent`. If you believe a charge is safe, include a `user_report` key with a value of `safe`. Stripe will use the information you send to improve our fraud detection algorithms.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- receipt_email: NotRequired[str]
- """
- This is the email address that the receipt for this charge will be sent to. If this field is updated, then a new email receipt will be sent to the updated address.
- """
- shipping: NotRequired["ChargeService.UpdateParamsShipping"]
- """
- Shipping information for the charge. Helps prevent fraud on charges for physical goods.
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
- """
-
- class UpdateParamsFraudDetails(TypedDict):
- user_report: Union[Literal[""], Literal["fraudulent", "safe"]]
- """
- Either `safe` or `fraudulent`.
- """
-
- class UpdateParamsShipping(TypedDict):
- address: "ChargeService.UpdateParamsShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class UpdateParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
+class ChargeService(StripeService):
def list(
self,
- params: Optional["ChargeService.ListParams"] = None,
+ params: Optional["ChargeListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Charge]:
"""
@@ -390,7 +40,7 @@ def list(
async def list_async(
self,
- params: Optional["ChargeService.ListParams"] = None,
+ params: Optional["ChargeListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Charge]:
"""
@@ -409,7 +59,7 @@ async def list_async(
def create(
self,
- params: Optional["ChargeService.CreateParams"] = None,
+ params: Optional["ChargeCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Charge:
"""
@@ -430,7 +80,7 @@ def create(
async def create_async(
self,
- params: Optional["ChargeService.CreateParams"] = None,
+ params: Optional["ChargeCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Charge:
"""
@@ -452,7 +102,7 @@ async def create_async(
def retrieve(
self,
charge: str,
- params: Optional["ChargeService.RetrieveParams"] = None,
+ params: Optional["ChargeRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Charge:
"""
@@ -472,7 +122,7 @@ def retrieve(
async def retrieve_async(
self,
charge: str,
- params: Optional["ChargeService.RetrieveParams"] = None,
+ params: Optional["ChargeRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Charge:
"""
@@ -492,7 +142,7 @@ async def retrieve_async(
def update(
self,
charge: str,
- params: Optional["ChargeService.UpdateParams"] = None,
+ params: Optional["ChargeUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Charge:
"""
@@ -512,7 +162,7 @@ def update(
async def update_async(
self,
charge: str,
- params: Optional["ChargeService.UpdateParams"] = None,
+ params: Optional["ChargeUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Charge:
"""
@@ -531,7 +181,7 @@ async def update_async(
def search(
self,
- params: "ChargeService.SearchParams",
+ params: "ChargeSearchParams",
options: Optional[RequestOptions] = None,
) -> SearchResultObject[Charge]:
"""
@@ -553,7 +203,7 @@ def search(
async def search_async(
self,
- params: "ChargeService.SearchParams",
+ params: "ChargeSearchParams",
options: Optional[RequestOptions] = None,
) -> SearchResultObject[Charge]:
"""
@@ -576,7 +226,7 @@ async def search_async(
def capture(
self,
charge: str,
- params: Optional["ChargeService.CaptureParams"] = None,
+ params: Optional["ChargeCaptureParams"] = None,
options: Optional[RequestOptions] = None,
) -> Charge:
"""
@@ -602,7 +252,7 @@ def capture(
async def capture_async(
self,
charge: str,
- params: Optional["ChargeService.CaptureParams"] = None,
+ params: Optional["ChargeCaptureParams"] = None,
options: Optional[RequestOptions] = None,
) -> Charge:
"""
diff --git a/stripe/_confirmation_token.py b/stripe/_confirmation_token.py
index d418a98e8..93ff04b1f 100644
--- a/stripe/_confirmation_token.py
+++ b/stripe/_confirmation_token.py
@@ -2,23 +2,21 @@
# File generated from our OpenAPI spec
from stripe._api_resource import APIResource
from stripe._expandable_field import ExpandableField
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._test_helpers import APIResourceTestHelpers
-from typing import ClassVar, Dict, List, Optional, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- Type,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, List, Optional, cast
+from typing_extensions import Literal, Type, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._charge import Charge
from stripe._customer import Customer
from stripe._setup_attempt import SetupAttempt
+ from stripe.params._confirmation_token_create_params import (
+ ConfirmationTokenCreateParams,
+ )
+ from stripe.params._confirmation_token_retrieve_params import (
+ ConfirmationTokenRetrieveParams,
+ )
class ConfirmationToken(APIResource["ConfirmationToken"]):
@@ -1617,904 +1615,6 @@ class Address(StripeObject):
"""
_inner_class_types = {"address": Address}
- class CreateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- payment_method: NotRequired[str]
- """
- ID of an existing PaymentMethod.
- """
- payment_method_data: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodData"
- ]
- """
- If provided, this hash will be used to create a PaymentMethod.
- """
- payment_method_options: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodOptions"
- ]
- """
- Payment-method-specific configuration for this ConfirmationToken.
- """
- return_url: NotRequired[str]
- """
- Return URL used to confirm the Intent.
- """
- setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
- """
- Indicates that you intend to make future payments with this ConfirmationToken's payment method.
-
- The presence of this property will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete.
- """
- shipping: NotRequired["ConfirmationToken.CreateParamsShipping"]
- """
- Shipping information for this ConfirmationToken.
- """
-
- class CreateParamsPaymentMethodData(TypedDict):
- acss_debit: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataAcssDebit"
- ]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataAlipay"
- ]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataAlma"
- ]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataAmazonPay"
- ]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataAuBecsDebit"
- ]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataBlik"
- ]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- cashapp: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataCrypto"
- ]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer_balance: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired["ConfirmationToken.CreateParamsPaymentMethodDataEps"]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- fpx: NotRequired["ConfirmationToken.CreateParamsPaymentMethodDataFpx"]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataIdeal"
- ]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataLink"
- ]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataMbWay"
- ]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataMobilepay"
- ]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataNzBankAccount"
- ]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataOxxo"
- ]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired["ConfirmationToken.CreateParamsPaymentMethodDataP24"]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataPayco"
- ]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- paynow: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired["ConfirmationToken.CreateParamsPaymentMethodDataPix"]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataRadarOptions"
- ]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataSwish"
- ]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataTwint"
- ]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataWechatPay"
- ]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired["ConfirmationToken.CreateParamsPaymentMethodDataZip"]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class CreateParamsPaymentMethodDataAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class CreateParamsPaymentMethodDataAffirm(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAfterpayClearpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAlipay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAlma(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAmazonPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class CreateParamsPaymentMethodDataBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class CreateParamsPaymentMethodDataBancontact(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBillie(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|ConfirmationToken.CreateParamsPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class CreateParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsPaymentMethodDataBlik(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class CreateParamsPaymentMethodDataCashapp(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataCrypto(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataCustomerBalance(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataGiropay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataGrabpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class CreateParamsPaymentMethodDataInteracPresent(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKakaoPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKlarna(TypedDict):
- dob: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodDataKlarnaDob"
- ]
- """
- Customer's date of birth
- """
-
- class CreateParamsPaymentMethodDataKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsPaymentMethodDataKonbini(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKrCard(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataLink(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMbWay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMobilepay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMultibanco(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class CreateParamsPaymentMethodDataNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class CreateParamsPaymentMethodDataOxxo(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataPayByBank(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPayco(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPaynow(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPaypal(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPix(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPromptpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class CreateParamsPaymentMethodDataRevolutPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSamsungPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSatispay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class CreateParamsPaymentMethodDataSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class CreateParamsPaymentMethodDataSwish(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataTwint(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class CreateParamsPaymentMethodDataWechatPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataZip(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptions(TypedDict):
- card: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodOptionsCard"
- ]
- """
- Configuration for any card payments confirmed using this ConfirmationToken.
- """
-
- class CreateParamsPaymentMethodOptionsCard(TypedDict):
- installments: NotRequired[
- "ConfirmationToken.CreateParamsPaymentMethodOptionsCardInstallments"
- ]
- """
- Installment configuration for payments confirmed using this ConfirmationToken.
- """
-
- class CreateParamsPaymentMethodOptionsCardInstallments(TypedDict):
- plan: "ConfirmationToken.CreateParamsPaymentMethodOptionsCardInstallmentsPlan"
- """
- The selected installment plan to use for this payment attempt.
- This parameter can only be provided during confirmation.
- """
-
- class CreateParamsPaymentMethodOptionsCardInstallmentsPlan(TypedDict):
- count: NotRequired[int]
- """
- For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
- """
- interval: NotRequired[Literal["month"]]
- """
- For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
- One of `month`.
- """
- type: Literal["bonus", "fixed_count", "revolving"]
- """
- Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
- """
-
- class CreateParamsShipping(TypedDict):
- address: "ConfirmationToken.CreateParamsShippingAddress"
- """
- Shipping address
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Recipient phone (including extension)
- """
-
- class CreateParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -2576,7 +1676,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["ConfirmationToken.RetrieveParams"]
+ cls, id: str, **params: Unpack["ConfirmationTokenRetrieveParams"]
) -> "ConfirmationToken":
"""
Retrieves an existing ConfirmationToken object
@@ -2587,7 +1687,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["ConfirmationToken.RetrieveParams"]
+ cls, id: str, **params: Unpack["ConfirmationTokenRetrieveParams"]
) -> "ConfirmationToken":
"""
Retrieves an existing ConfirmationToken object
@@ -2601,7 +1701,7 @@ class TestHelpers(APIResourceTestHelpers["ConfirmationToken"]):
@classmethod
def create(
- cls, **params: Unpack["ConfirmationToken.CreateParams"]
+ cls, **params: Unpack["ConfirmationTokenCreateParams"]
) -> "ConfirmationToken":
"""
Creates a test mode Confirmation Token server side for your integration tests.
@@ -2617,7 +1717,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["ConfirmationToken.CreateParams"]
+ cls, **params: Unpack["ConfirmationTokenCreateParams"]
) -> "ConfirmationToken":
"""
Creates a test mode Confirmation Token server side for your integration tests.
diff --git a/stripe/_confirmation_token_service.py b/stripe/_confirmation_token_service.py
index 4084329d2..b1cdeb633 100644
--- a/stripe/_confirmation_token_service.py
+++ b/stripe/_confirmation_token_service.py
@@ -4,21 +4,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._confirmation_token_retrieve_params import (
+ ConfirmationTokenRetrieveParams,
+ )
-class ConfirmationTokenService(StripeService):
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class ConfirmationTokenService(StripeService):
def retrieve(
self,
confirmation_token: str,
- params: Optional["ConfirmationTokenService.RetrieveParams"] = None,
+ params: Optional["ConfirmationTokenRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ConfirmationToken:
"""
@@ -40,7 +39,7 @@ def retrieve(
async def retrieve_async(
self,
confirmation_token: str,
- params: Optional["ConfirmationTokenService.RetrieveParams"] = None,
+ params: Optional["ConfirmationTokenRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ConfirmationToken:
"""
diff --git a/stripe/_country_spec.py b/stripe/_country_spec.py
index 04dc662ce..2b7f67ff5 100644
--- a/stripe/_country_spec.py
+++ b/stripe/_country_spec.py
@@ -2,10 +2,15 @@
# File generated from our OpenAPI spec
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from typing import ClassVar, Dict, List
-from typing_extensions import Literal, NotRequired, Unpack
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._country_spec_list_params import CountrySpecListParams
+ from stripe.params._country_spec_retrieve_params import (
+ CountrySpecRetrieveParams,
+ )
class CountrySpec(ListableAPIResource["CountrySpec"]):
@@ -45,30 +50,6 @@ class Individual(StripeObject):
individual: Individual
_inner_class_types = {"company": Company, "individual": Individual}
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
default_currency: str
"""
The default currency for this country. This applies to both payment methods and bank accounts.
@@ -101,7 +82,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["CountrySpec.ListParams"]
+ cls, **params: Unpack["CountrySpecListParams"]
) -> ListObject["CountrySpec"]:
"""
Lists all Country Spec objects available in the API.
@@ -121,7 +102,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["CountrySpec.ListParams"]
+ cls, **params: Unpack["CountrySpecListParams"]
) -> ListObject["CountrySpec"]:
"""
Lists all Country Spec objects available in the API.
@@ -141,7 +122,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["CountrySpec.RetrieveParams"]
+ cls, id: str, **params: Unpack["CountrySpecRetrieveParams"]
) -> "CountrySpec":
"""
Returns a Country Spec for a given Country code.
@@ -152,7 +133,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["CountrySpec.RetrieveParams"]
+ cls, id: str, **params: Unpack["CountrySpecRetrieveParams"]
) -> "CountrySpec":
"""
Returns a Country Spec for a given Country code.
diff --git a/stripe/_country_spec_service.py b/stripe/_country_spec_service.py
index 581dbb41a..0e629d8fb 100644
--- a/stripe/_country_spec_service.py
+++ b/stripe/_country_spec_service.py
@@ -5,38 +5,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._country_spec_list_params import CountrySpecListParams
+ from stripe.params._country_spec_retrieve_params import (
+ CountrySpecRetrieveParams,
+ )
-class CountrySpecService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class CountrySpecService(StripeService):
def list(
self,
- params: Optional["CountrySpecService.ListParams"] = None,
+ params: Optional["CountrySpecListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[CountrySpec]:
"""
@@ -55,7 +37,7 @@ def list(
async def list_async(
self,
- params: Optional["CountrySpecService.ListParams"] = None,
+ params: Optional["CountrySpecListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[CountrySpec]:
"""
@@ -75,7 +57,7 @@ async def list_async(
def retrieve(
self,
country: str,
- params: Optional["CountrySpecService.RetrieveParams"] = None,
+ params: Optional["CountrySpecRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> CountrySpec:
"""
@@ -97,7 +79,7 @@ def retrieve(
async def retrieve_async(
self,
country: str,
- params: Optional["CountrySpecService.RetrieveParams"] = None,
+ params: Optional["CountrySpecRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> CountrySpec:
"""
diff --git a/stripe/_coupon.py b/stripe/_coupon.py
index 1aa9c2580..92bf85b7c 100644
--- a/stripe/_coupon.py
+++ b/stripe/_coupon.py
@@ -4,12 +4,18 @@
from stripe._deletable_api_resource import DeletableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._coupon_create_params import CouponCreateParams
+ from stripe.params._coupon_delete_params import CouponDeleteParams
+ from stripe.params._coupon_list_params import CouponListParams
+ from stripe.params._coupon_modify_params import CouponModifyParams
+ from stripe.params._coupon_retrieve_params import CouponRetrieveParams
class Coupon(
@@ -38,149 +44,6 @@ class CurrencyOptions(StripeObject):
Amount (in the `currency` specified) that will be taken off the subtotal of any invoices for this customer.
"""
- class CreateParams(RequestOptions):
- amount_off: NotRequired[int]
- """
- A positive integer representing the amount to subtract from an invoice total (required if `percent_off` is not passed).
- """
- applies_to: NotRequired["Coupon.CreateParamsAppliesTo"]
- """
- A hash containing directions for what this Coupon will apply discounts to.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `amount_off` parameter (required if `amount_off` is passed).
- """
- currency_options: NotRequired[
- Dict[str, "Coupon.CreateParamsCurrencyOptions"]
- ]
- """
- Coupons defined in each available currency option (only supported if `amount_off` is passed). Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
- duration: NotRequired[Literal["forever", "once", "repeating"]]
- """
- Specifies how long the discount will be in effect if used on a subscription. Defaults to `once`.
- """
- duration_in_months: NotRequired[int]
- """
- Required only if `duration` is `repeating`, in which case it must be a positive integer that specifies the number of months the discount will be in effect.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- id: NotRequired[str]
- """
- Unique string of your choice that will be used to identify this coupon when applying it to a customer. If you don't want to specify a particular code, you can leave the ID blank and we'll generate a random code for you.
- """
- max_redemptions: NotRequired[int]
- """
- A positive integer specifying the number of times the coupon can be redeemed before it's no longer valid. For example, you might have a 50% off coupon that the first 20 readers of your blog can use.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- Name of the coupon displayed to customers on, for instance invoices, or receipts. By default the `id` is shown if `name` is not set.
- """
- percent_off: NotRequired[float]
- """
- A positive float larger than 0, and smaller or equal to 100, that represents the discount the coupon will apply (required if `amount_off` is not passed).
- """
- redeem_by: NotRequired[int]
- """
- Unix timestamp specifying the last time at which the coupon can be redeemed. After the redeem_by date, the coupon can no longer be applied to new customers.
- """
-
- class CreateParamsAppliesTo(TypedDict):
- products: NotRequired[List[str]]
- """
- An array of Product IDs that this Coupon will apply to.
- """
-
- class CreateParamsCurrencyOptions(TypedDict):
- amount_off: int
- """
- A positive integer representing the amount to subtract from an invoice total.
- """
-
- class DeleteParams(RequestOptions):
- pass
-
- class ListParams(RequestOptions):
- created: NotRequired["Coupon.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- currency_options: NotRequired[
- Dict[str, "Coupon.ModifyParamsCurrencyOptions"]
- ]
- """
- Coupons defined in each available currency option (only supported if the coupon is amount-based). Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- Name of the coupon displayed to customers on, for instance invoices, or receipts. By default the `id` is shown if `name` is not set.
- """
-
- class ModifyParamsCurrencyOptions(TypedDict):
- amount_off: int
- """
- A positive integer representing the amount to subtract from an invoice total.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount_off: Optional[int]
"""
Amount (in the `currency` specified) that will be taken off the subtotal of any invoices for this customer.
@@ -252,7 +115,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["Coupon.CreateParams"]) -> "Coupon":
+ def create(cls, **params: Unpack["CouponCreateParams"]) -> "Coupon":
"""
You can create coupons easily via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. Coupon creation is also accessible via the API if you need to create coupons on the fly.
@@ -269,7 +132,7 @@ def create(cls, **params: Unpack["Coupon.CreateParams"]) -> "Coupon":
@classmethod
async def create_async(
- cls, **params: Unpack["Coupon.CreateParams"]
+ cls, **params: Unpack["CouponCreateParams"]
) -> "Coupon":
"""
You can create coupons easily via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. Coupon creation is also accessible via the API if you need to create coupons on the fly.
@@ -287,7 +150,7 @@ async def create_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["Coupon.DeleteParams"]
+ cls, sid: str, **params: Unpack["CouponDeleteParams"]
) -> "Coupon":
"""
You can delete coupons via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. However, deleting a coupon does not affect any customers who have already applied the coupon; it means that new customers can't redeem the coupon. You can also delete coupons via the API.
@@ -304,14 +167,14 @@ def _cls_delete(
@overload
@staticmethod
- def delete(sid: str, **params: Unpack["Coupon.DeleteParams"]) -> "Coupon":
+ def delete(sid: str, **params: Unpack["CouponDeleteParams"]) -> "Coupon":
"""
You can delete coupons via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. However, deleting a coupon does not affect any customers who have already applied the coupon; it means that new customers can't redeem the coupon. You can also delete coupons via the API.
"""
...
@overload
- def delete(self, **params: Unpack["Coupon.DeleteParams"]) -> "Coupon":
+ def delete(self, **params: Unpack["CouponDeleteParams"]) -> "Coupon":
"""
You can delete coupons via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. However, deleting a coupon does not affect any customers who have already applied the coupon; it means that new customers can't redeem the coupon. You can also delete coupons via the API.
"""
@@ -319,7 +182,7 @@ def delete(self, **params: Unpack["Coupon.DeleteParams"]) -> "Coupon":
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Coupon.DeleteParams"]
+ self, **params: Unpack["CouponDeleteParams"]
) -> "Coupon":
"""
You can delete coupons via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. However, deleting a coupon does not affect any customers who have already applied the coupon; it means that new customers can't redeem the coupon. You can also delete coupons via the API.
@@ -332,7 +195,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["Coupon.DeleteParams"]
+ cls, sid: str, **params: Unpack["CouponDeleteParams"]
) -> "Coupon":
"""
You can delete coupons via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. However, deleting a coupon does not affect any customers who have already applied the coupon; it means that new customers can't redeem the coupon. You can also delete coupons via the API.
@@ -350,7 +213,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["Coupon.DeleteParams"]
+ sid: str, **params: Unpack["CouponDeleteParams"]
) -> "Coupon":
"""
You can delete coupons via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. However, deleting a coupon does not affect any customers who have already applied the coupon; it means that new customers can't redeem the coupon. You can also delete coupons via the API.
@@ -359,7 +222,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["Coupon.DeleteParams"]
+ self, **params: Unpack["CouponDeleteParams"]
) -> "Coupon":
"""
You can delete coupons via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. However, deleting a coupon does not affect any customers who have already applied the coupon; it means that new customers can't redeem the coupon. You can also delete coupons via the API.
@@ -368,7 +231,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Coupon.DeleteParams"]
+ self, **params: Unpack["CouponDeleteParams"]
) -> "Coupon":
"""
You can delete coupons via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. However, deleting a coupon does not affect any customers who have already applied the coupon; it means that new customers can't redeem the coupon. You can also delete coupons via the API.
@@ -381,7 +244,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["Coupon.ListParams"]
+ cls, **params: Unpack["CouponListParams"]
) -> ListObject["Coupon"]:
"""
Returns a list of your coupons.
@@ -401,7 +264,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Coupon.ListParams"]
+ cls, **params: Unpack["CouponListParams"]
) -> ListObject["Coupon"]:
"""
Returns a list of your coupons.
@@ -421,7 +284,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Coupon.ModifyParams"]
+ cls, id: str, **params: Unpack["CouponModifyParams"]
) -> "Coupon":
"""
Updates the metadata of a coupon. Other coupon details (currency, duration, amount_off) are, by design, not editable.
@@ -438,7 +301,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Coupon.ModifyParams"]
+ cls, id: str, **params: Unpack["CouponModifyParams"]
) -> "Coupon":
"""
Updates the metadata of a coupon. Other coupon details (currency, duration, amount_off) are, by design, not editable.
@@ -455,7 +318,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Coupon.RetrieveParams"]
+ cls, id: str, **params: Unpack["CouponRetrieveParams"]
) -> "Coupon":
"""
Retrieves the coupon with the given ID.
@@ -466,7 +329,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Coupon.RetrieveParams"]
+ cls, id: str, **params: Unpack["CouponRetrieveParams"]
) -> "Coupon":
"""
Retrieves the coupon with the given ID.
diff --git a/stripe/_coupon_service.py b/stripe/_coupon_service.py
index 0f50a832c..f6df47979 100644
--- a/stripe/_coupon_service.py
+++ b/stripe/_coupon_service.py
@@ -5,158 +5,22 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._coupon_create_params import CouponCreateParams
+ from stripe.params._coupon_delete_params import CouponDeleteParams
+ from stripe.params._coupon_list_params import CouponListParams
+ from stripe.params._coupon_retrieve_params import CouponRetrieveParams
+ from stripe.params._coupon_update_params import CouponUpdateParams
-class CouponService(StripeService):
- class CreateParams(TypedDict):
- amount_off: NotRequired[int]
- """
- A positive integer representing the amount to subtract from an invoice total (required if `percent_off` is not passed).
- """
- applies_to: NotRequired["CouponService.CreateParamsAppliesTo"]
- """
- A hash containing directions for what this Coupon will apply discounts to.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `amount_off` parameter (required if `amount_off` is passed).
- """
- currency_options: NotRequired[
- Dict[str, "CouponService.CreateParamsCurrencyOptions"]
- ]
- """
- Coupons defined in each available currency option (only supported if `amount_off` is passed). Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
- duration: NotRequired[Literal["forever", "once", "repeating"]]
- """
- Specifies how long the discount will be in effect if used on a subscription. Defaults to `once`.
- """
- duration_in_months: NotRequired[int]
- """
- Required only if `duration` is `repeating`, in which case it must be a positive integer that specifies the number of months the discount will be in effect.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- id: NotRequired[str]
- """
- Unique string of your choice that will be used to identify this coupon when applying it to a customer. If you don't want to specify a particular code, you can leave the ID blank and we'll generate a random code for you.
- """
- max_redemptions: NotRequired[int]
- """
- A positive integer specifying the number of times the coupon can be redeemed before it's no longer valid. For example, you might have a 50% off coupon that the first 20 readers of your blog can use.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- Name of the coupon displayed to customers on, for instance invoices, or receipts. By default the `id` is shown if `name` is not set.
- """
- percent_off: NotRequired[float]
- """
- A positive float larger than 0, and smaller or equal to 100, that represents the discount the coupon will apply (required if `amount_off` is not passed).
- """
- redeem_by: NotRequired[int]
- """
- Unix timestamp specifying the last time at which the coupon can be redeemed. After the redeem_by date, the coupon can no longer be applied to new customers.
- """
-
- class CreateParamsAppliesTo(TypedDict):
- products: NotRequired[List[str]]
- """
- An array of Product IDs that this Coupon will apply to.
- """
-
- class CreateParamsCurrencyOptions(TypedDict):
- amount_off: int
- """
- A positive integer representing the amount to subtract from an invoice total.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- created: NotRequired["CouponService.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- currency_options: NotRequired[
- Dict[str, "CouponService.UpdateParamsCurrencyOptions"]
- ]
- """
- Coupons defined in each available currency option (only supported if the coupon is amount-based). Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- Name of the coupon displayed to customers on, for instance invoices, or receipts. By default the `id` is shown if `name` is not set.
- """
-
- class UpdateParamsCurrencyOptions(TypedDict):
- amount_off: int
- """
- A positive integer representing the amount to subtract from an invoice total.
- """
+class CouponService(StripeService):
def delete(
self,
coupon: str,
- params: Optional["CouponService.DeleteParams"] = None,
+ params: Optional["CouponDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Coupon:
"""
@@ -176,7 +40,7 @@ def delete(
async def delete_async(
self,
coupon: str,
- params: Optional["CouponService.DeleteParams"] = None,
+ params: Optional["CouponDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Coupon:
"""
@@ -196,7 +60,7 @@ async def delete_async(
def retrieve(
self,
coupon: str,
- params: Optional["CouponService.RetrieveParams"] = None,
+ params: Optional["CouponRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Coupon:
"""
@@ -216,7 +80,7 @@ def retrieve(
async def retrieve_async(
self,
coupon: str,
- params: Optional["CouponService.RetrieveParams"] = None,
+ params: Optional["CouponRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Coupon:
"""
@@ -236,7 +100,7 @@ async def retrieve_async(
def update(
self,
coupon: str,
- params: Optional["CouponService.UpdateParams"] = None,
+ params: Optional["CouponUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Coupon:
"""
@@ -256,7 +120,7 @@ def update(
async def update_async(
self,
coupon: str,
- params: Optional["CouponService.UpdateParams"] = None,
+ params: Optional["CouponUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Coupon:
"""
@@ -275,7 +139,7 @@ async def update_async(
def list(
self,
- params: Optional["CouponService.ListParams"] = None,
+ params: Optional["CouponListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Coupon]:
"""
@@ -294,7 +158,7 @@ def list(
async def list_async(
self,
- params: Optional["CouponService.ListParams"] = None,
+ params: Optional["CouponListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Coupon]:
"""
@@ -313,7 +177,7 @@ async def list_async(
def create(
self,
- params: Optional["CouponService.CreateParams"] = None,
+ params: Optional["CouponCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Coupon:
"""
@@ -334,7 +198,7 @@ def create(
async def create_async(
self,
- params: Optional["CouponService.CreateParams"] = None,
+ params: Optional["CouponCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Coupon:
"""
diff --git a/stripe/_credit_note.py b/stripe/_credit_note.py
index fc111a056..e40a3d2c2 100644
--- a/stripe/_credit_note.py
+++ b/stripe/_credit_note.py
@@ -5,18 +5,11 @@
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
from stripe._nested_resource_class_methods import nested_resource_class_methods
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._credit_note_line_item import CreditNoteLineItem
@@ -30,6 +23,24 @@
from stripe.billing._credit_balance_transaction import (
CreditBalanceTransaction,
)
+ from stripe.params._credit_note_create_params import CreditNoteCreateParams
+ from stripe.params._credit_note_list_lines_params import (
+ CreditNoteListLinesParams,
+ )
+ from stripe.params._credit_note_list_params import CreditNoteListParams
+ from stripe.params._credit_note_modify_params import CreditNoteModifyParams
+ from stripe.params._credit_note_preview_lines_params import (
+ CreditNotePreviewLinesParams,
+ )
+ from stripe.params._credit_note_preview_params import (
+ CreditNotePreviewParams,
+ )
+ from stripe.params._credit_note_retrieve_params import (
+ CreditNoteRetrieveParams,
+ )
+ from stripe.params._credit_note_void_credit_note_params import (
+ CreditNoteVoidCreditNoteParams,
+ )
@nested_resource_class_methods("line")
@@ -194,515 +205,6 @@ class TaxRateDetails(StripeObject):
"""
_inner_class_types = {"tax_rate_details": TaxRateDetails}
- class CreateParams(RequestOptions):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the total amount of the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
- credit_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
- """
- effective_at: NotRequired[int]
- """
- The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
- """
- email_type: NotRequired[Literal["credit_note", "none"]]
- """
- Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice: str
- """
- ID of the invoice.
- """
- lines: NotRequired[List["CreditNote.CreateParamsLine"]]
- """
- Line items that make up the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
- memo: NotRequired[str]
- """
- The credit note's memo appears on the credit note PDF.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- out_of_band_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
- """
- reason: NotRequired[
- Literal[
- "duplicate",
- "fraudulent",
- "order_change",
- "product_unsatisfactory",
- ]
- ]
- """
- Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
- """
- refund_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
- """
- refunds: NotRequired[List["CreditNote.CreateParamsRefund"]]
- """
- Refunds to link to this credit note.
- """
- shipping_cost: NotRequired["CreditNote.CreateParamsShippingCost"]
- """
- When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
-
- class CreateParamsLine(TypedDict):
- amount: NotRequired[int]
- """
- The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
- """
- description: NotRequired[str]
- """
- The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
- """
- invoice_line_item: NotRequired[str]
- """
- The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
- """
- quantity: NotRequired[int]
- """
- The line item quantity to credit.
- """
- tax_amounts: NotRequired[
- "Literal['']|List[CreditNote.CreateParamsLineTaxAmount]"
- ]
- """
- A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
- """
- type: Literal["custom_line_item", "invoice_line_item"]
- """
- Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
- """
- unit_amount: NotRequired[int]
- """
- The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsLineTaxAmount(TypedDict):
- amount: int
- """
- The amount, in cents (or local equivalent), of the tax.
- """
- tax_rate: str
- """
- The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
- """
- taxable_amount: int
- """
- The amount on which tax is calculated, in cents (or local equivalent).
- """
-
- class CreateParamsRefund(TypedDict):
- amount_refunded: NotRequired[int]
- """
- Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
- """
- refund: NotRequired[str]
- """
- ID of an existing refund to link this credit note to. Required when `type` is `refund`.
- """
-
- class CreateParamsShippingCost(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the shipping rate to use for this order.
- """
-
- class ListLinesParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["CreditNote.ListParamsCreated|int"]
- """
- Only return credit notes that were created during the given date interval.
- """
- customer: NotRequired[str]
- """
- Only return credit notes for the customer specified by this customer ID.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice: NotRequired[str]
- """
- Only return credit notes for the invoice specified by this invoice ID.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- memo: NotRequired[str]
- """
- Credit note memo.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class PreviewLinesParams(RequestOptions):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the total amount of the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
- credit_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
- """
- effective_at: NotRequired[int]
- """
- The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
- """
- email_type: NotRequired[Literal["credit_note", "none"]]
- """
- Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice: str
- """
- ID of the invoice.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- lines: NotRequired[List["CreditNote.PreviewLinesParamsLine"]]
- """
- Line items that make up the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
- memo: NotRequired[str]
- """
- The credit note's memo appears on the credit note PDF.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- out_of_band_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
- """
- reason: NotRequired[
- Literal[
- "duplicate",
- "fraudulent",
- "order_change",
- "product_unsatisfactory",
- ]
- ]
- """
- Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
- """
- refund_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
- """
- refunds: NotRequired[List["CreditNote.PreviewLinesParamsRefund"]]
- """
- Refunds to link to this credit note.
- """
- shipping_cost: NotRequired["CreditNote.PreviewLinesParamsShippingCost"]
- """
- When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class PreviewLinesParamsLine(TypedDict):
- amount: NotRequired[int]
- """
- The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
- """
- description: NotRequired[str]
- """
- The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
- """
- invoice_line_item: NotRequired[str]
- """
- The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
- """
- quantity: NotRequired[int]
- """
- The line item quantity to credit.
- """
- tax_amounts: NotRequired[
- "Literal['']|List[CreditNote.PreviewLinesParamsLineTaxAmount]"
- ]
- """
- A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
- """
- type: Literal["custom_line_item", "invoice_line_item"]
- """
- Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
- """
- unit_amount: NotRequired[int]
- """
- The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class PreviewLinesParamsLineTaxAmount(TypedDict):
- amount: int
- """
- The amount, in cents (or local equivalent), of the tax.
- """
- tax_rate: str
- """
- The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
- """
- taxable_amount: int
- """
- The amount on which tax is calculated, in cents (or local equivalent).
- """
-
- class PreviewLinesParamsRefund(TypedDict):
- amount_refunded: NotRequired[int]
- """
- Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
- """
- refund: NotRequired[str]
- """
- ID of an existing refund to link this credit note to. Required when `type` is `refund`.
- """
-
- class PreviewLinesParamsShippingCost(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the shipping rate to use for this order.
- """
-
- class PreviewParams(RequestOptions):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the total amount of the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
- credit_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
- """
- effective_at: NotRequired[int]
- """
- The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
- """
- email_type: NotRequired[Literal["credit_note", "none"]]
- """
- Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice: str
- """
- ID of the invoice.
- """
- lines: NotRequired[List["CreditNote.PreviewParamsLine"]]
- """
- Line items that make up the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
- memo: NotRequired[str]
- """
- The credit note's memo appears on the credit note PDF.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- out_of_band_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
- """
- reason: NotRequired[
- Literal[
- "duplicate",
- "fraudulent",
- "order_change",
- "product_unsatisfactory",
- ]
- ]
- """
- Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
- """
- refund_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
- """
- refunds: NotRequired[List["CreditNote.PreviewParamsRefund"]]
- """
- Refunds to link to this credit note.
- """
- shipping_cost: NotRequired["CreditNote.PreviewParamsShippingCost"]
- """
- When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
-
- class PreviewParamsLine(TypedDict):
- amount: NotRequired[int]
- """
- The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
- """
- description: NotRequired[str]
- """
- The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
- """
- invoice_line_item: NotRequired[str]
- """
- The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
- """
- quantity: NotRequired[int]
- """
- The line item quantity to credit.
- """
- tax_amounts: NotRequired[
- "Literal['']|List[CreditNote.PreviewParamsLineTaxAmount]"
- ]
- """
- A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
- """
- type: Literal["custom_line_item", "invoice_line_item"]
- """
- Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
- """
- unit_amount: NotRequired[int]
- """
- The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class PreviewParamsLineTaxAmount(TypedDict):
- amount: int
- """
- The amount, in cents (or local equivalent), of the tax.
- """
- tax_rate: str
- """
- The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
- """
- taxable_amount: int
- """
- The amount on which tax is calculated, in cents (or local equivalent).
- """
-
- class PreviewParamsRefund(TypedDict):
- amount_refunded: NotRequired[int]
- """
- Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
- """
- refund: NotRequired[str]
- """
- ID of an existing refund to link this credit note to. Required when `type` is `refund`.
- """
-
- class PreviewParamsShippingCost(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the shipping rate to use for this order.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class VoidCreditNoteParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount: int
"""
The integer amount in cents (or local equivalent) representing the total amount of the credit note, including tax.
@@ -844,7 +346,7 @@ class VoidCreditNoteParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["CreditNote.CreateParams"]
+ cls, **params: Unpack["CreditNoteCreateParams"]
) -> "CreditNote":
"""
Issue a credit note to adjust the amount of a finalized invoice. A credit note will first reduce the invoice's amount_remaining (and amount_due), but not below zero.
@@ -872,7 +374,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["CreditNote.CreateParams"]
+ cls, **params: Unpack["CreditNoteCreateParams"]
) -> "CreditNote":
"""
Issue a credit note to adjust the amount of a finalized invoice. A credit note will first reduce the invoice's amount_remaining (and amount_due), but not below zero.
@@ -900,7 +402,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["CreditNote.ListParams"]
+ cls, **params: Unpack["CreditNoteListParams"]
) -> ListObject["CreditNote"]:
"""
Returns a list of credit notes.
@@ -920,7 +422,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["CreditNote.ListParams"]
+ cls, **params: Unpack["CreditNoteListParams"]
) -> ListObject["CreditNote"]:
"""
Returns a list of credit notes.
@@ -940,7 +442,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["CreditNote.ModifyParams"]
+ cls, id: str, **params: Unpack["CreditNoteModifyParams"]
) -> "CreditNote":
"""
Updates an existing credit note.
@@ -957,7 +459,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["CreditNote.ModifyParams"]
+ cls, id: str, **params: Unpack["CreditNoteModifyParams"]
) -> "CreditNote":
"""
Updates an existing credit note.
@@ -974,7 +476,7 @@ async def modify_async(
@classmethod
def preview(
- cls, **params: Unpack["CreditNote.PreviewParams"]
+ cls, **params: Unpack["CreditNotePreviewParams"]
) -> "CreditNote":
"""
Get a preview of a credit note without creating it.
@@ -990,7 +492,7 @@ def preview(
@classmethod
async def preview_async(
- cls, **params: Unpack["CreditNote.PreviewParams"]
+ cls, **params: Unpack["CreditNotePreviewParams"]
) -> "CreditNote":
"""
Get a preview of a credit note without creating it.
@@ -1006,7 +508,7 @@ async def preview_async(
@classmethod
def preview_lines(
- cls, **params: Unpack["CreditNote.PreviewLinesParams"]
+ cls, **params: Unpack["CreditNotePreviewLinesParams"]
) -> ListObject["CreditNoteLineItem"]:
"""
When retrieving a credit note preview, you'll get a lines property containing the first handful of those items. This URL you can retrieve the full (paginated) list of line items.
@@ -1022,7 +524,7 @@ def preview_lines(
@classmethod
async def preview_lines_async(
- cls, **params: Unpack["CreditNote.PreviewLinesParams"]
+ cls, **params: Unpack["CreditNotePreviewLinesParams"]
) -> ListObject["CreditNoteLineItem"]:
"""
When retrieving a credit note preview, you'll get a lines property containing the first handful of those items. This URL you can retrieve the full (paginated) list of line items.
@@ -1038,7 +540,7 @@ async def preview_lines_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["CreditNote.RetrieveParams"]
+ cls, id: str, **params: Unpack["CreditNoteRetrieveParams"]
) -> "CreditNote":
"""
Retrieves the credit note object with the given identifier.
@@ -1049,7 +551,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["CreditNote.RetrieveParams"]
+ cls, id: str, **params: Unpack["CreditNoteRetrieveParams"]
) -> "CreditNote":
"""
Retrieves the credit note object with the given identifier.
@@ -1060,7 +562,7 @@ async def retrieve_async(
@classmethod
def _cls_void_credit_note(
- cls, id: str, **params: Unpack["CreditNote.VoidCreditNoteParams"]
+ 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).
@@ -1077,7 +579,7 @@ def _cls_void_credit_note(
@overload
@staticmethod
def void_credit_note(
- id: str, **params: Unpack["CreditNote.VoidCreditNoteParams"]
+ 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).
@@ -1086,7 +588,7 @@ def void_credit_note(
@overload
def void_credit_note(
- self, **params: Unpack["CreditNote.VoidCreditNoteParams"]
+ self, **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).
@@ -1095,7 +597,7 @@ def void_credit_note(
@class_method_variant("_cls_void_credit_note")
def void_credit_note( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["CreditNote.VoidCreditNoteParams"]
+ self, **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).
@@ -1113,7 +615,7 @@ def void_credit_note( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_void_credit_note_async(
- cls, id: str, **params: Unpack["CreditNote.VoidCreditNoteParams"]
+ 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).
@@ -1130,7 +632,7 @@ async def _cls_void_credit_note_async(
@overload
@staticmethod
async def void_credit_note_async(
- id: str, **params: Unpack["CreditNote.VoidCreditNoteParams"]
+ 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).
@@ -1139,7 +641,7 @@ async def void_credit_note_async(
@overload
async def void_credit_note_async(
- self, **params: Unpack["CreditNote.VoidCreditNoteParams"]
+ self, **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).
@@ -1148,7 +650,7 @@ async def void_credit_note_async(
@class_method_variant("_cls_void_credit_note_async")
async def void_credit_note_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["CreditNote.VoidCreditNoteParams"]
+ self, **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).
@@ -1166,7 +668,7 @@ async def void_credit_note_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list_lines(
- cls, credit_note: str, **params: Unpack["CreditNote.ListLinesParams"]
+ 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.
@@ -1184,7 +686,7 @@ def list_lines(
@classmethod
async def list_lines_async(
- cls, credit_note: str, **params: Unpack["CreditNote.ListLinesParams"]
+ 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 49341fb25..3ebb79fa8 100644
--- a/stripe/_credit_note_line_item_service.py
+++ b/stripe/_credit_note_line_item_service.py
@@ -5,33 +5,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._credit_note_line_item_list_params import (
+ CreditNoteLineItemListParams,
+ )
-class CreditNoteLineItemService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
+class CreditNoteLineItemService(StripeService):
def list(
self,
credit_note: str,
- params: Optional["CreditNoteLineItemService.ListParams"] = None,
+ params: Optional["CreditNoteLineItemListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[CreditNoteLineItem]:
"""
@@ -53,7 +40,7 @@ def list(
async def list_async(
self,
credit_note: str,
- params: Optional["CreditNoteLineItemService.ListParams"] = None,
+ params: Optional["CreditNoteLineItemListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[CreditNoteLineItem]:
"""
diff --git a/stripe/_credit_note_preview_lines_service.py b/stripe/_credit_note_preview_lines_service.py
index 543725e10..262c3e047 100644
--- a/stripe/_credit_note_preview_lines_service.py
+++ b/stripe/_credit_note_preview_lines_service.py
@@ -4,167 +4,19 @@
from stripe._list_object import ListObject
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._credit_note_preview_lines_list_params import (
+ CreditNotePreviewLinesListParams,
+ )
-class CreditNotePreviewLinesService(StripeService):
- class ListParams(TypedDict):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the total amount of the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
- credit_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
- """
- effective_at: NotRequired[int]
- """
- The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
- """
- email_type: NotRequired[Literal["credit_note", "none"]]
- """
- Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice: str
- """
- ID of the invoice.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- lines: NotRequired[
- List["CreditNotePreviewLinesService.ListParamsLine"]
- ]
- """
- Line items that make up the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
- memo: NotRequired[str]
- """
- The credit note's memo appears on the credit note PDF.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- out_of_band_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
- """
- reason: NotRequired[
- Literal[
- "duplicate",
- "fraudulent",
- "order_change",
- "product_unsatisfactory",
- ]
- ]
- """
- Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
- """
- refund_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
- """
- refunds: NotRequired[
- List["CreditNotePreviewLinesService.ListParamsRefund"]
- ]
- """
- Refunds to link to this credit note.
- """
- shipping_cost: NotRequired[
- "CreditNotePreviewLinesService.ListParamsShippingCost"
- ]
- """
- When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsLine(TypedDict):
- amount: NotRequired[int]
- """
- The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
- """
- description: NotRequired[str]
- """
- The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
- """
- invoice_line_item: NotRequired[str]
- """
- The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
- """
- quantity: NotRequired[int]
- """
- The line item quantity to credit.
- """
- tax_amounts: NotRequired[
- "Literal['']|List[CreditNotePreviewLinesService.ListParamsLineTaxAmount]"
- ]
- """
- A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
- """
- type: Literal["custom_line_item", "invoice_line_item"]
- """
- Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
- """
- unit_amount: NotRequired[int]
- """
- The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class ListParamsLineTaxAmount(TypedDict):
- amount: int
- """
- The amount, in cents (or local equivalent), of the tax.
- """
- tax_rate: str
- """
- The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
- """
- taxable_amount: int
- """
- The amount on which tax is calculated, in cents (or local equivalent).
- """
-
- class ListParamsRefund(TypedDict):
- amount_refunded: NotRequired[int]
- """
- Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
- """
- refund: NotRequired[str]
- """
- ID of an existing refund to link this credit note to. Required when `type` is `refund`.
- """
-
- class ListParamsShippingCost(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the shipping rate to use for this order.
- """
+class CreditNotePreviewLinesService(StripeService):
def list(
self,
- params: "CreditNotePreviewLinesService.ListParams",
+ params: "CreditNotePreviewLinesListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[CreditNoteLineItem]:
"""
@@ -183,7 +35,7 @@ def list(
async def list_async(
self,
- params: "CreditNotePreviewLinesService.ListParams",
+ params: "CreditNotePreviewLinesListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[CreditNoteLineItem]:
"""
diff --git a/stripe/_credit_note_service.py b/stripe/_credit_note_service.py
index 997fa515c..474365638 100644
--- a/stripe/_credit_note_service.py
+++ b/stripe/_credit_note_service.py
@@ -9,8 +9,22 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._credit_note_create_params import CreditNoteCreateParams
+ from stripe.params._credit_note_list_params import CreditNoteListParams
+ from stripe.params._credit_note_preview_params import (
+ CreditNotePreviewParams,
+ )
+ from stripe.params._credit_note_retrieve_params import (
+ CreditNoteRetrieveParams,
+ )
+ from stripe.params._credit_note_update_params import CreditNoteUpdateParams
+ from stripe.params._credit_note_void_credit_note_params import (
+ CreditNoteVoidCreditNoteParams,
+ )
class CreditNoteService(StripeService):
@@ -19,357 +33,9 @@ def __init__(self, requestor):
self.line_items = CreditNoteLineItemService(self._requestor)
self.preview_lines = CreditNotePreviewLinesService(self._requestor)
- class CreateParams(TypedDict):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the total amount of the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
- credit_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
- """
- effective_at: NotRequired[int]
- """
- The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
- """
- email_type: NotRequired[Literal["credit_note", "none"]]
- """
- Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice: str
- """
- ID of the invoice.
- """
- lines: NotRequired[List["CreditNoteService.CreateParamsLine"]]
- """
- Line items that make up the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
- memo: NotRequired[str]
- """
- The credit note's memo appears on the credit note PDF.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- out_of_band_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
- """
- reason: NotRequired[
- Literal[
- "duplicate",
- "fraudulent",
- "order_change",
- "product_unsatisfactory",
- ]
- ]
- """
- Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
- """
- refund_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
- """
- refunds: NotRequired[List["CreditNoteService.CreateParamsRefund"]]
- """
- Refunds to link to this credit note.
- """
- shipping_cost: NotRequired[
- "CreditNoteService.CreateParamsShippingCost"
- ]
- """
- When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
-
- class CreateParamsLine(TypedDict):
- amount: NotRequired[int]
- """
- The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
- """
- description: NotRequired[str]
- """
- The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
- """
- invoice_line_item: NotRequired[str]
- """
- The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
- """
- quantity: NotRequired[int]
- """
- The line item quantity to credit.
- """
- tax_amounts: NotRequired[
- "Literal['']|List[CreditNoteService.CreateParamsLineTaxAmount]"
- ]
- """
- A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
- """
- type: Literal["custom_line_item", "invoice_line_item"]
- """
- Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
- """
- unit_amount: NotRequired[int]
- """
- The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsLineTaxAmount(TypedDict):
- amount: int
- """
- The amount, in cents (or local equivalent), of the tax.
- """
- tax_rate: str
- """
- The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
- """
- taxable_amount: int
- """
- The amount on which tax is calculated, in cents (or local equivalent).
- """
-
- class CreateParamsRefund(TypedDict):
- amount_refunded: NotRequired[int]
- """
- Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
- """
- refund: NotRequired[str]
- """
- ID of an existing refund to link this credit note to. Required when `type` is `refund`.
- """
-
- class CreateParamsShippingCost(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the shipping rate to use for this order.
- """
-
- class ListParams(TypedDict):
- created: NotRequired["CreditNoteService.ListParamsCreated|int"]
- """
- Only return credit notes that were created during the given date interval.
- """
- customer: NotRequired[str]
- """
- Only return credit notes for the customer specified by this customer ID.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice: NotRequired[str]
- """
- Only return credit notes for the invoice specified by this invoice ID.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class PreviewParams(TypedDict):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the total amount of the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
- credit_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
- """
- effective_at: NotRequired[int]
- """
- The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
- """
- email_type: NotRequired[Literal["credit_note", "none"]]
- """
- Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice: str
- """
- ID of the invoice.
- """
- lines: NotRequired[List["CreditNoteService.PreviewParamsLine"]]
- """
- Line items that make up the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
- memo: NotRequired[str]
- """
- The credit note's memo appears on the credit note PDF.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- out_of_band_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
- """
- reason: NotRequired[
- Literal[
- "duplicate",
- "fraudulent",
- "order_change",
- "product_unsatisfactory",
- ]
- ]
- """
- Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
- """
- refund_amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
- """
- refunds: NotRequired[List["CreditNoteService.PreviewParamsRefund"]]
- """
- Refunds to link to this credit note.
- """
- shipping_cost: NotRequired[
- "CreditNoteService.PreviewParamsShippingCost"
- ]
- """
- When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
- """
-
- class PreviewParamsLine(TypedDict):
- amount: NotRequired[int]
- """
- The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
- """
- description: NotRequired[str]
- """
- The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
- """
- invoice_line_item: NotRequired[str]
- """
- The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
- """
- quantity: NotRequired[int]
- """
- The line item quantity to credit.
- """
- tax_amounts: NotRequired[
- "Literal['']|List[CreditNoteService.PreviewParamsLineTaxAmount]"
- ]
- """
- A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
- """
- type: Literal["custom_line_item", "invoice_line_item"]
- """
- Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
- """
- unit_amount: NotRequired[int]
- """
- The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class PreviewParamsLineTaxAmount(TypedDict):
- amount: int
- """
- The amount, in cents (or local equivalent), of the tax.
- """
- tax_rate: str
- """
- The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
- """
- taxable_amount: int
- """
- The amount on which tax is calculated, in cents (or local equivalent).
- """
-
- class PreviewParamsRefund(TypedDict):
- amount_refunded: NotRequired[int]
- """
- Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
- """
- refund: NotRequired[str]
- """
- ID of an existing refund to link this credit note to. Required when `type` is `refund`.
- """
-
- class PreviewParamsShippingCost(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the shipping rate to use for this order.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- memo: NotRequired[str]
- """
- Credit note memo.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class VoidCreditNoteParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
def list(
self,
- params: Optional["CreditNoteService.ListParams"] = None,
+ params: Optional["CreditNoteListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[CreditNote]:
"""
@@ -388,7 +54,7 @@ def list(
async def list_async(
self,
- params: Optional["CreditNoteService.ListParams"] = None,
+ params: Optional["CreditNoteListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[CreditNote]:
"""
@@ -407,7 +73,7 @@ async def list_async(
def create(
self,
- params: "CreditNoteService.CreateParams",
+ params: "CreditNoteCreateParams",
options: Optional[RequestOptions] = None,
) -> CreditNote:
"""
@@ -438,7 +104,7 @@ def create(
async def create_async(
self,
- params: "CreditNoteService.CreateParams",
+ params: "CreditNoteCreateParams",
options: Optional[RequestOptions] = None,
) -> CreditNote:
"""
@@ -470,7 +136,7 @@ async def create_async(
def retrieve(
self,
id: str,
- params: Optional["CreditNoteService.RetrieveParams"] = None,
+ params: Optional["CreditNoteRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditNote:
"""
@@ -490,7 +156,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["CreditNoteService.RetrieveParams"] = None,
+ params: Optional["CreditNoteRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditNote:
"""
@@ -510,7 +176,7 @@ async def retrieve_async(
def update(
self,
id: str,
- params: Optional["CreditNoteService.UpdateParams"] = None,
+ params: Optional["CreditNoteUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditNote:
"""
@@ -530,7 +196,7 @@ def update(
async def update_async(
self,
id: str,
- params: Optional["CreditNoteService.UpdateParams"] = None,
+ params: Optional["CreditNoteUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditNote:
"""
@@ -549,7 +215,7 @@ async def update_async(
def preview(
self,
- params: "CreditNoteService.PreviewParams",
+ params: "CreditNotePreviewParams",
options: Optional[RequestOptions] = None,
) -> CreditNote:
"""
@@ -568,7 +234,7 @@ def preview(
async def preview_async(
self,
- params: "CreditNoteService.PreviewParams",
+ params: "CreditNotePreviewParams",
options: Optional[RequestOptions] = None,
) -> CreditNote:
"""
@@ -588,7 +254,7 @@ async def preview_async(
def void_credit_note(
self,
id: str,
- params: Optional["CreditNoteService.VoidCreditNoteParams"] = None,
+ params: Optional["CreditNoteVoidCreditNoteParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditNote:
"""
@@ -608,7 +274,7 @@ def void_credit_note(
async def void_credit_note_async(
self,
id: str,
- params: Optional["CreditNoteService.VoidCreditNoteParams"] = None,
+ params: Optional["CreditNoteVoidCreditNoteParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditNote:
"""
diff --git a/stripe/_customer.py b/stripe/_customer.py
index b415e40e4..4b1af931e 100644
--- a/stripe/_customer.py
+++ b/stripe/_customer.py
@@ -6,7 +6,6 @@
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
from stripe._nested_resource_class_methods import nested_resource_class_methods
-from stripe._request_options import RequestOptions
from stripe._search_result_object import SearchResultObject
from stripe._searchable_api_resource import SearchableAPIResource
from stripe._stripe_object import StripeObject
@@ -24,14 +23,7 @@
cast,
overload,
)
-from typing_extensions import (
- Literal,
- NotRequired,
- Type,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Type, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account
@@ -48,6 +40,78 @@
from stripe._source import Source
from stripe._subscription import Subscription
from stripe._tax_id import TaxId
+ from stripe.params._customer_create_balance_transaction_params import (
+ CustomerCreateBalanceTransactionParams,
+ )
+ from stripe.params._customer_create_funding_instructions_params import (
+ CustomerCreateFundingInstructionsParams,
+ )
+ from stripe.params._customer_create_params import CustomerCreateParams
+ from stripe.params._customer_create_source_params import (
+ CustomerCreateSourceParams,
+ )
+ from stripe.params._customer_create_tax_id_params import (
+ CustomerCreateTaxIdParams,
+ )
+ from stripe.params._customer_delete_discount_params import (
+ CustomerDeleteDiscountParams,
+ )
+ from stripe.params._customer_delete_params import CustomerDeleteParams
+ from stripe.params._customer_delete_source_params import (
+ CustomerDeleteSourceParams,
+ )
+ from stripe.params._customer_delete_tax_id_params import (
+ CustomerDeleteTaxIdParams,
+ )
+ from stripe.params._customer_fund_cash_balance_params import (
+ CustomerFundCashBalanceParams,
+ )
+ from stripe.params._customer_list_balance_transactions_params import (
+ CustomerListBalanceTransactionsParams,
+ )
+ from stripe.params._customer_list_cash_balance_transactions_params import (
+ CustomerListCashBalanceTransactionsParams,
+ )
+ from stripe.params._customer_list_params import CustomerListParams
+ from stripe.params._customer_list_payment_methods_params import (
+ CustomerListPaymentMethodsParams,
+ )
+ from stripe.params._customer_list_sources_params import (
+ CustomerListSourcesParams,
+ )
+ from stripe.params._customer_list_tax_ids_params import (
+ CustomerListTaxIdsParams,
+ )
+ from stripe.params._customer_modify_balance_transaction_params import (
+ CustomerModifyBalanceTransactionParams,
+ )
+ from stripe.params._customer_modify_cash_balance_params import (
+ CustomerModifyCashBalanceParams,
+ )
+ from stripe.params._customer_modify_params import CustomerModifyParams
+ from stripe.params._customer_modify_source_params import (
+ CustomerModifySourceParams,
+ )
+ from stripe.params._customer_retrieve_balance_transaction_params import (
+ CustomerRetrieveBalanceTransactionParams,
+ )
+ from stripe.params._customer_retrieve_cash_balance_params import (
+ CustomerRetrieveCashBalanceParams,
+ )
+ from stripe.params._customer_retrieve_cash_balance_transaction_params import (
+ CustomerRetrieveCashBalanceTransactionParams,
+ )
+ from stripe.params._customer_retrieve_params import CustomerRetrieveParams
+ from stripe.params._customer_retrieve_payment_method_params import (
+ CustomerRetrievePaymentMethodParams,
+ )
+ from stripe.params._customer_retrieve_source_params import (
+ CustomerRetrieveSourceParams,
+ )
+ from stripe.params._customer_retrieve_tax_id_params import (
+ CustomerRetrieveTaxIdParams,
+ )
+ from stripe.params._customer_search_params import CustomerSearchParams
from stripe.test_helpers._test_clock import TestClock
@@ -219,1212 +283,6 @@ class Location(StripeObject):
"""
_inner_class_types = {"location": Location}
- class CreateBalanceTransactionParams(RequestOptions):
- amount: int
- """
- The integer amount in **cents (or local equivalent)** to apply to the customer's credit balance.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Specifies the [`invoice_credit_balance`](https://stripe.com/docs/api/customers/object#customer_object-invoice_credit_balance) that this transaction will apply to. If the customer's `currency` is not set, it will be updated to this value.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class CreateFundingInstructionsParams(RequestOptions):
- bank_transfer: "Customer.CreateFundingInstructionsParamsBankTransfer"
- """
- Additional parameters for `bank_transfer` funding types
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- funding_type: Literal["bank_transfer"]
- """
- The `funding_type` to get the instructions for.
- """
-
- class CreateFundingInstructionsParamsBankTransfer(TypedDict):
- eu_bank_transfer: NotRequired[
- "Customer.CreateFundingInstructionsParamsBankTransferEuBankTransfer"
- ]
- """
- Configuration for eu_bank_transfer funding type.
- """
- requested_address_types: NotRequired[
- List[Literal["iban", "sort_code", "spei", "zengin"]]
- ]
- """
- List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
-
- Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
- """
- type: Literal[
- "eu_bank_transfer",
- "gb_bank_transfer",
- "jp_bank_transfer",
- "mx_bank_transfer",
- "us_bank_transfer",
- ]
- """
- The type of the `bank_transfer`
- """
-
- class CreateFundingInstructionsParamsBankTransferEuBankTransfer(TypedDict):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class CreateParams(RequestOptions):
- address: NotRequired["Literal['']|Customer.CreateParamsAddress"]
- """
- The customer's address.
- """
- balance: NotRequired[int]
- """
- An integer amount in cents (or local equivalent) that represents the customer's current balance, which affect the customer's future invoices. A negative amount represents a credit that decreases the amount due on an invoice; a positive amount increases the amount due on an invoice.
- """
- business_name: NotRequired["Literal['']|str"]
- """
- The customer's business name. This may be up to *150 characters*.
- """
- cash_balance: NotRequired["Customer.CreateParamsCashBalance"]
- """
- Balance information and default balance settings for this customer.
- """
- description: NotRequired[str]
- """
- An arbitrary string that you can attach to a customer object. It is displayed alongside the customer in the dashboard.
- """
- email: NotRequired[str]
- """
- Customer's email address. It's displayed alongside the customer in your dashboard and can be useful for searching and tracking. This may be up to *512 characters*.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- individual_name: NotRequired["Literal['']|str"]
- """
- The customer's full name. This may be up to *150 characters*.
- """
- invoice_prefix: NotRequired[str]
- """
- The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.
- """
- invoice_settings: NotRequired["Customer.CreateParamsInvoiceSettings"]
- """
- Default invoice settings for this customer.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- The customer's full name or business name.
- """
- next_invoice_sequence: NotRequired[int]
- """
- The sequence to be used on the customer's next invoice. Defaults to 1.
- """
- payment_method: NotRequired[str]
- phone: NotRequired[str]
- """
- The customer's phone number.
- """
- preferred_locales: NotRequired[List[str]]
- """
- Customer's preferred languages, ordered by preference.
- """
- shipping: NotRequired["Literal['']|Customer.CreateParamsShipping"]
- """
- The customer's shipping information. Appears on invoices emailed to this customer.
- """
- source: NotRequired[str]
- tax: NotRequired["Customer.CreateParamsTax"]
- """
- Tax details about the customer.
- """
- tax_exempt: NotRequired[
- "Literal['']|Literal['exempt', 'none', 'reverse']"
- ]
- """
- The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
- """
- tax_id_data: NotRequired[List["Customer.CreateParamsTaxIdDatum"]]
- """
- The customer's tax IDs.
- """
- test_clock: NotRequired[str]
- """
- ID of the test clock to attach to the customer.
- """
- validate: NotRequired[bool]
-
- class CreateParamsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsCashBalance(TypedDict):
- settings: NotRequired["Customer.CreateParamsCashBalanceSettings"]
- """
- Settings controlling the behavior of the customer's cash balance,
- such as reconciliation of funds received.
- """
-
- class CreateParamsCashBalanceSettings(TypedDict):
- reconciliation_mode: NotRequired[
- Literal["automatic", "manual", "merchant_default"]
- ]
- """
- Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
- """
-
- class CreateParamsInvoiceSettings(TypedDict):
- custom_fields: NotRequired[
- "Literal['']|List[Customer.CreateParamsInvoiceSettingsCustomField]"
- ]
- """
- The list of up to 4 default custom fields to be displayed on invoices for this customer. When updating, pass an empty string to remove previously-defined fields.
- """
- default_payment_method: NotRequired[str]
- """
- ID of a payment method that's attached to the customer, to be used as the customer's default payment method for subscriptions and invoices.
- """
- footer: NotRequired[str]
- """
- Default footer to be displayed on invoices for this customer.
- """
- rendering_options: NotRequired[
- "Literal['']|Customer.CreateParamsInvoiceSettingsRenderingOptions"
- ]
- """
- Default options for invoice PDF rendering for this customer.
- """
-
- class CreateParamsInvoiceSettingsCustomField(TypedDict):
- name: str
- """
- The name of the custom field. This may be up to 40 characters.
- """
- value: str
- """
- The value of the custom field. This may be up to 140 characters.
- """
-
- class CreateParamsInvoiceSettingsRenderingOptions(TypedDict):
- amount_tax_display: NotRequired[
- "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
- ]
- """
- How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
- """
- template: NotRequired[str]
- """
- ID of the invoice rendering template to use for future invoices.
- """
-
- class CreateParamsShipping(TypedDict):
- address: "Customer.CreateParamsShippingAddress"
- """
- Customer shipping address.
- """
- name: str
- """
- Customer name.
- """
- phone: NotRequired[str]
- """
- Customer phone (including extension).
- """
-
- class CreateParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsTax(TypedDict):
- ip_address: NotRequired["Literal['']|str"]
- """
- A recent IP address of the customer used for tax reporting and tax location inference. Stripe recommends updating the IP address when a new PaymentMethod is attached or the address field on the customer is updated. We recommend against updating this field more frequently since it could result in unexpected tax location/reporting outcomes.
- """
- validate_location: NotRequired[Literal["deferred", "immediately"]]
- """
- A flag that indicates when Stripe should validate the customer tax location. Defaults to `deferred`.
- """
-
- class CreateParamsTaxIdDatum(TypedDict):
- type: Literal[
- "ad_nrt",
- "ae_trn",
- "al_tin",
- "am_tin",
- "ao_tin",
- "ar_cuit",
- "au_abn",
- "au_arn",
- "aw_tin",
- "az_tin",
- "ba_tin",
- "bb_tin",
- "bd_bin",
- "bf_ifu",
- "bg_uic",
- "bh_vat",
- "bj_ifu",
- "bo_tin",
- "br_cnpj",
- "br_cpf",
- "bs_tin",
- "by_tin",
- "ca_bn",
- "ca_gst_hst",
- "ca_pst_bc",
- "ca_pst_mb",
- "ca_pst_sk",
- "ca_qst",
- "cd_nif",
- "ch_uid",
- "ch_vat",
- "cl_tin",
- "cm_niu",
- "cn_tin",
- "co_nit",
- "cr_tin",
- "cv_nif",
- "de_stn",
- "do_rcn",
- "ec_ruc",
- "eg_tin",
- "es_cif",
- "et_tin",
- "eu_oss_vat",
- "eu_vat",
- "gb_vat",
- "ge_vat",
- "gn_nif",
- "hk_br",
- "hr_oib",
- "hu_tin",
- "id_npwp",
- "il_vat",
- "in_gst",
- "is_vat",
- "jp_cn",
- "jp_rn",
- "jp_trn",
- "ke_pin",
- "kg_tin",
- "kh_tin",
- "kr_brn",
- "kz_bin",
- "la_tin",
- "li_uid",
- "li_vat",
- "ma_vat",
- "md_vat",
- "me_pib",
- "mk_vat",
- "mr_nif",
- "mx_rfc",
- "my_frp",
- "my_itn",
- "my_sst",
- "ng_tin",
- "no_vat",
- "no_voec",
- "np_pan",
- "nz_gst",
- "om_vat",
- "pe_ruc",
- "ph_tin",
- "ro_tin",
- "rs_pib",
- "ru_inn",
- "ru_kpp",
- "sa_vat",
- "sg_gst",
- "sg_uen",
- "si_tin",
- "sn_ninea",
- "sr_fin",
- "sv_nit",
- "th_vat",
- "tj_tin",
- "tr_tin",
- "tw_vat",
- "tz_vat",
- "ua_vat",
- "ug_tin",
- "us_ein",
- "uy_ruc",
- "uz_tin",
- "uz_vat",
- "ve_rif",
- "vn_tin",
- "za_vat",
- "zm_tin",
- "zw_tin",
- ]
- """
- Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
- """
- value: str
- """
- Value of the tax ID.
- """
-
- class CreateSourceParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- source: str
- """
- Please refer to full [documentation](https://stripe.com/docs/api) instead.
- """
- validate: NotRequired[bool]
-
- class CreateTaxIdParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- type: Literal[
- "ad_nrt",
- "ae_trn",
- "al_tin",
- "am_tin",
- "ao_tin",
- "ar_cuit",
- "au_abn",
- "au_arn",
- "aw_tin",
- "az_tin",
- "ba_tin",
- "bb_tin",
- "bd_bin",
- "bf_ifu",
- "bg_uic",
- "bh_vat",
- "bj_ifu",
- "bo_tin",
- "br_cnpj",
- "br_cpf",
- "bs_tin",
- "by_tin",
- "ca_bn",
- "ca_gst_hst",
- "ca_pst_bc",
- "ca_pst_mb",
- "ca_pst_sk",
- "ca_qst",
- "cd_nif",
- "ch_uid",
- "ch_vat",
- "cl_tin",
- "cm_niu",
- "cn_tin",
- "co_nit",
- "cr_tin",
- "cv_nif",
- "de_stn",
- "do_rcn",
- "ec_ruc",
- "eg_tin",
- "es_cif",
- "et_tin",
- "eu_oss_vat",
- "eu_vat",
- "gb_vat",
- "ge_vat",
- "gn_nif",
- "hk_br",
- "hr_oib",
- "hu_tin",
- "id_npwp",
- "il_vat",
- "in_gst",
- "is_vat",
- "jp_cn",
- "jp_rn",
- "jp_trn",
- "ke_pin",
- "kg_tin",
- "kh_tin",
- "kr_brn",
- "kz_bin",
- "la_tin",
- "li_uid",
- "li_vat",
- "ma_vat",
- "md_vat",
- "me_pib",
- "mk_vat",
- "mr_nif",
- "mx_rfc",
- "my_frp",
- "my_itn",
- "my_sst",
- "ng_tin",
- "no_vat",
- "no_voec",
- "np_pan",
- "nz_gst",
- "om_vat",
- "pe_ruc",
- "ph_tin",
- "ro_tin",
- "rs_pib",
- "ru_inn",
- "ru_kpp",
- "sa_vat",
- "sg_gst",
- "sg_uen",
- "si_tin",
- "sn_ninea",
- "sr_fin",
- "sv_nit",
- "th_vat",
- "tj_tin",
- "tr_tin",
- "tw_vat",
- "tz_vat",
- "ua_vat",
- "ug_tin",
- "us_ein",
- "uy_ruc",
- "uz_tin",
- "uz_vat",
- "ve_rif",
- "vn_tin",
- "za_vat",
- "zm_tin",
- "zw_tin",
- ]
- """
- Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
- """
- value: str
- """
- Value of the tax ID.
- """
-
- class DeleteDiscountParams(RequestOptions):
- pass
-
- class DeleteParams(RequestOptions):
- pass
-
- class DeleteSourceParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class DeleteTaxIdParams(RequestOptions):
- pass
-
- class FundCashBalanceParams(RequestOptions):
- amount: int
- """
- Amount to be used for this test cash balance transaction. A positive integer representing how much to fund in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to fund $1.00 or 100 to fund ¥100, a zero-decimal currency).
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- reference: NotRequired[str]
- """
- A description of the test funding. This simulates free-text references supplied by customers when making bank transfers to their cash balance. You can use this to test how Stripe's [reconciliation algorithm](https://stripe.com/docs/payments/customer-balance/reconciliation) applies to different user inputs.
- """
-
- class ListBalanceTransactionsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListCashBalanceTransactionsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["Customer.ListParamsCreated|int"]
- """
- Only return customers that were created during the given date interval.
- """
- email: NotRequired[str]
- """
- A case-sensitive filter on the list based on the customer's `email` field. The value must be a string.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- test_clock: NotRequired[str]
- """
- Provides a list of customers that are associated with the specified test clock. The response will not include customers with test clocks if this parameter is not set.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListPaymentMethodsParams(RequestOptions):
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[
- Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "card",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- ]
- """
- An optional filter on the list, based on the object `type` field. Without the filter, the list includes all current and future payment method types. If your integration expects only one type of payment method in the response, make sure to provide a type value in the request.
- """
-
- class ListSourcesParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- object: NotRequired[str]
- """
- Filter sources according to a particular object type.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListTaxIdsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ModifyBalanceTransactionParams(RequestOptions):
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class ModifyCashBalanceParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- settings: NotRequired["Customer.ModifyCashBalanceParamsSettings"]
- """
- A hash of settings for this cash balance.
- """
-
- class ModifyCashBalanceParamsSettings(TypedDict):
- reconciliation_mode: NotRequired[
- Literal["automatic", "manual", "merchant_default"]
- ]
- """
- Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
- """
-
- class ModifyParams(RequestOptions):
- address: NotRequired["Literal['']|Customer.ModifyParamsAddress"]
- """
- The customer's address.
- """
- balance: NotRequired[int]
- """
- An integer amount in cents (or local equivalent) that represents the customer's current balance, which affect the customer's future invoices. A negative amount represents a credit that decreases the amount due on an invoice; a positive amount increases the amount due on an invoice.
- """
- business_name: NotRequired["Literal['']|str"]
- """
- The customer's business name. This may be up to *150 characters*.
- """
- cash_balance: NotRequired["Customer.ModifyParamsCashBalance"]
- """
- Balance information and default balance settings for this customer.
- """
- default_source: NotRequired[str]
- """
- If you are using payment methods created via the PaymentMethods API, see the [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method) parameter.
-
- Provide the ID of a payment source already attached to this customer to make it this customer's default payment source.
-
- If you want to add a new payment source and make it the default, see the [source](https://stripe.com/docs/api/customers/update#update_customer-source) property.
- """
- description: NotRequired[str]
- """
- An arbitrary string that you can attach to a customer object. It is displayed alongside the customer in the dashboard.
- """
- email: NotRequired[str]
- """
- Customer's email address. It's displayed alongside the customer in your dashboard and can be useful for searching and tracking. This may be up to *512 characters*.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- individual_name: NotRequired["Literal['']|str"]
- """
- The customer's full name. This may be up to *150 characters*.
- """
- invoice_prefix: NotRequired[str]
- """
- The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.
- """
- invoice_settings: NotRequired["Customer.ModifyParamsInvoiceSettings"]
- """
- Default invoice settings for this customer.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- The customer's full name or business name.
- """
- next_invoice_sequence: NotRequired[int]
- """
- The sequence to be used on the customer's next invoice. Defaults to 1.
- """
- phone: NotRequired[str]
- """
- The customer's phone number.
- """
- preferred_locales: NotRequired[List[str]]
- """
- Customer's preferred languages, ordered by preference.
- """
- shipping: NotRequired["Literal['']|Customer.ModifyParamsShipping"]
- """
- The customer's shipping information. Appears on invoices emailed to this customer.
- """
- source: NotRequired[str]
- tax: NotRequired["Customer.ModifyParamsTax"]
- """
- Tax details about the customer.
- """
- tax_exempt: NotRequired[
- "Literal['']|Literal['exempt', 'none', 'reverse']"
- ]
- """
- The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
- """
- validate: NotRequired[bool]
-
- class ModifyParamsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ModifyParamsCashBalance(TypedDict):
- settings: NotRequired["Customer.ModifyParamsCashBalanceSettings"]
- """
- Settings controlling the behavior of the customer's cash balance,
- such as reconciliation of funds received.
- """
-
- class ModifyParamsCashBalanceSettings(TypedDict):
- reconciliation_mode: NotRequired[
- Literal["automatic", "manual", "merchant_default"]
- ]
- """
- Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
- """
-
- class ModifyParamsInvoiceSettings(TypedDict):
- custom_fields: NotRequired[
- "Literal['']|List[Customer.ModifyParamsInvoiceSettingsCustomField]"
- ]
- """
- The list of up to 4 default custom fields to be displayed on invoices for this customer. When updating, pass an empty string to remove previously-defined fields.
- """
- default_payment_method: NotRequired[str]
- """
- ID of a payment method that's attached to the customer, to be used as the customer's default payment method for subscriptions and invoices.
- """
- footer: NotRequired[str]
- """
- Default footer to be displayed on invoices for this customer.
- """
- rendering_options: NotRequired[
- "Literal['']|Customer.ModifyParamsInvoiceSettingsRenderingOptions"
- ]
- """
- Default options for invoice PDF rendering for this customer.
- """
-
- class ModifyParamsInvoiceSettingsCustomField(TypedDict):
- name: str
- """
- The name of the custom field. This may be up to 40 characters.
- """
- value: str
- """
- The value of the custom field. This may be up to 140 characters.
- """
-
- class ModifyParamsInvoiceSettingsRenderingOptions(TypedDict):
- amount_tax_display: NotRequired[
- "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
- ]
- """
- How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
- """
- template: NotRequired[str]
- """
- ID of the invoice rendering template to use for future invoices.
- """
-
- class ModifyParamsShipping(TypedDict):
- address: "Customer.ModifyParamsShippingAddress"
- """
- Customer shipping address.
- """
- name: str
- """
- Customer name.
- """
- phone: NotRequired[str]
- """
- Customer phone (including extension).
- """
-
- class ModifyParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ModifyParamsTax(TypedDict):
- ip_address: NotRequired["Literal['']|str"]
- """
- A recent IP address of the customer used for tax reporting and tax location inference. Stripe recommends updating the IP address when a new PaymentMethod is attached or the address field on the customer is updated. We recommend against updating this field more frequently since it could result in unexpected tax location/reporting outcomes.
- """
- validate_location: NotRequired[
- Literal["auto", "deferred", "immediately"]
- ]
- """
- A flag that indicates when Stripe should validate the customer tax location. Defaults to `auto`.
- """
-
- class ModifySourceParams(RequestOptions):
- account_holder_name: NotRequired[str]
- """
- The name of the person or business that owns the bank account.
- """
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- The type of entity that holds the account. This can be either `individual` or `company`.
- """
- address_city: NotRequired[str]
- """
- City/District/Suburb/Town/Village.
- """
- address_country: NotRequired[str]
- """
- Billing address country, if provided when creating card.
- """
- address_line1: NotRequired[str]
- """
- Address line 1 (Street address/PO Box/Company name).
- """
- address_line2: NotRequired[str]
- """
- Address line 2 (Apartment/Suite/Unit/Building).
- """
- address_state: NotRequired[str]
- """
- State/County/Province/Region.
- """
- address_zip: NotRequired[str]
- """
- ZIP or postal code.
- """
- exp_month: NotRequired[str]
- """
- Two digit number representing the card's expiration month.
- """
- exp_year: NotRequired[str]
- """
- Four digit number representing the card's expiration year.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- Cardholder name.
- """
- owner: NotRequired["Customer.ModifySourceParamsOwner"]
-
- class ModifySourceParamsOwner(TypedDict):
- address: NotRequired["Customer.ModifySourceParamsOwnerAddress"]
- """
- Owner's address.
- """
- email: NotRequired[str]
- """
- Owner's email address.
- """
- name: NotRequired[str]
- """
- Owner's full name.
- """
- phone: NotRequired[str]
- """
- Owner's phone number.
- """
-
- class ModifySourceParamsOwnerAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class RetrieveBalanceTransactionParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveCashBalanceParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveCashBalanceTransactionParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrievePaymentMethodParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveSourceParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveTaxIdParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SearchParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- page: NotRequired[str]
- """
- A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
- """
- query: str
- """
- The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for customers](https://stripe.com/docs/search#query-fields-for-customers).
- """
-
address: Optional[Address]
"""
The customer's address.
@@ -1555,7 +413,7 @@ class SearchParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["Customer.CreateParams"]) -> "Customer":
+ def create(cls, **params: Unpack["CustomerCreateParams"]) -> "Customer":
"""
Creates a new customer object.
"""
@@ -1570,7 +428,7 @@ def create(cls, **params: Unpack["Customer.CreateParams"]) -> "Customer":
@classmethod
async def create_async(
- cls, **params: Unpack["Customer.CreateParams"]
+ cls, **params: Unpack["CustomerCreateParams"]
) -> "Customer":
"""
Creates a new customer object.
@@ -1588,7 +446,7 @@ async def create_async(
def _cls_create_funding_instructions(
cls,
customer: str,
- **params: Unpack["Customer.CreateFundingInstructionsParams"],
+ **params: Unpack["CustomerCreateFundingInstructionsParams"],
) -> "FundingInstructions":
"""
Retrieve funding instructions for a customer cash balance. If funding instructions do not yet exist for the customer, new
@@ -1610,7 +468,7 @@ def _cls_create_funding_instructions(
@staticmethod
def create_funding_instructions(
customer: str,
- **params: Unpack["Customer.CreateFundingInstructionsParams"],
+ **params: Unpack["CustomerCreateFundingInstructionsParams"],
) -> "FundingInstructions":
"""
Retrieve funding instructions for a customer cash balance. If funding instructions do not yet exist for the customer, new
@@ -1621,7 +479,7 @@ def create_funding_instructions(
@overload
def create_funding_instructions(
- self, **params: Unpack["Customer.CreateFundingInstructionsParams"]
+ self, **params: Unpack["CustomerCreateFundingInstructionsParams"]
) -> "FundingInstructions":
"""
Retrieve funding instructions for a customer cash balance. If funding instructions do not yet exist for the customer, new
@@ -1632,7 +490,7 @@ def create_funding_instructions(
@class_method_variant("_cls_create_funding_instructions")
def create_funding_instructions( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Customer.CreateFundingInstructionsParams"]
+ self, **params: Unpack["CustomerCreateFundingInstructionsParams"]
) -> "FundingInstructions":
"""
Retrieve funding instructions for a customer cash balance. If funding instructions do not yet exist for the customer, new
@@ -1654,7 +512,7 @@ def create_funding_instructions( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_create_funding_instructions_async(
cls,
customer: str,
- **params: Unpack["Customer.CreateFundingInstructionsParams"],
+ **params: Unpack["CustomerCreateFundingInstructionsParams"],
) -> "FundingInstructions":
"""
Retrieve funding instructions for a customer cash balance. If funding instructions do not yet exist for the customer, new
@@ -1676,7 +534,7 @@ async def _cls_create_funding_instructions_async(
@staticmethod
async def create_funding_instructions_async(
customer: str,
- **params: Unpack["Customer.CreateFundingInstructionsParams"],
+ **params: Unpack["CustomerCreateFundingInstructionsParams"],
) -> "FundingInstructions":
"""
Retrieve funding instructions for a customer cash balance. If funding instructions do not yet exist for the customer, new
@@ -1687,7 +545,7 @@ async def create_funding_instructions_async(
@overload
async def create_funding_instructions_async(
- self, **params: Unpack["Customer.CreateFundingInstructionsParams"]
+ self, **params: Unpack["CustomerCreateFundingInstructionsParams"]
) -> "FundingInstructions":
"""
Retrieve funding instructions for a customer cash balance. If funding instructions do not yet exist for the customer, new
@@ -1698,7 +556,7 @@ async def create_funding_instructions_async(
@class_method_variant("_cls_create_funding_instructions_async")
async def create_funding_instructions_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Customer.CreateFundingInstructionsParams"]
+ self, **params: Unpack["CustomerCreateFundingInstructionsParams"]
) -> "FundingInstructions":
"""
Retrieve funding instructions for a customer cash balance. If funding instructions do not yet exist for the customer, new
@@ -1718,7 +576,7 @@ async def create_funding_instructions_async( # pyright: ignore[reportGeneralTyp
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["Customer.DeleteParams"]
+ cls, sid: str, **params: Unpack["CustomerDeleteParams"]
) -> "Customer":
"""
Permanently deletes a customer. It cannot be undone. Also immediately cancels any active subscriptions on the customer.
@@ -1736,7 +594,7 @@ def _cls_delete(
@overload
@staticmethod
def delete(
- sid: str, **params: Unpack["Customer.DeleteParams"]
+ sid: str, **params: Unpack["CustomerDeleteParams"]
) -> "Customer":
"""
Permanently deletes a customer. It cannot be undone. Also immediately cancels any active subscriptions on the customer.
@@ -1744,7 +602,7 @@ def delete(
...
@overload
- def delete(self, **params: Unpack["Customer.DeleteParams"]) -> "Customer":
+ def delete(self, **params: Unpack["CustomerDeleteParams"]) -> "Customer":
"""
Permanently deletes a customer. It cannot be undone. Also immediately cancels any active subscriptions on the customer.
"""
@@ -1752,7 +610,7 @@ def delete(self, **params: Unpack["Customer.DeleteParams"]) -> "Customer":
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Customer.DeleteParams"]
+ self, **params: Unpack["CustomerDeleteParams"]
) -> "Customer":
"""
Permanently deletes a customer. It cannot be undone. Also immediately cancels any active subscriptions on the customer.
@@ -1765,7 +623,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["Customer.DeleteParams"]
+ cls, sid: str, **params: Unpack["CustomerDeleteParams"]
) -> "Customer":
"""
Permanently deletes a customer. It cannot be undone. Also immediately cancels any active subscriptions on the customer.
@@ -1783,7 +641,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["Customer.DeleteParams"]
+ sid: str, **params: Unpack["CustomerDeleteParams"]
) -> "Customer":
"""
Permanently deletes a customer. It cannot be undone. Also immediately cancels any active subscriptions on the customer.
@@ -1792,7 +650,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["Customer.DeleteParams"]
+ self, **params: Unpack["CustomerDeleteParams"]
) -> "Customer":
"""
Permanently deletes a customer. It cannot be undone. Also immediately cancels any active subscriptions on the customer.
@@ -1801,7 +659,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Customer.DeleteParams"]
+ self, **params: Unpack["CustomerDeleteParams"]
) -> "Customer":
"""
Permanently deletes a customer. It cannot be undone. Also immediately cancels any active subscriptions on the customer.
@@ -1814,7 +672,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_delete_discount(
- cls, customer: str, **params: Unpack["Customer.DeleteDiscountParams"]
+ cls, customer: str, **params: Unpack["CustomerDeleteDiscountParams"]
) -> "Discount":
"""
Removes the currently applied discount on a customer.
@@ -1833,7 +691,7 @@ def _cls_delete_discount(
@overload
@staticmethod
def delete_discount(
- customer: str, **params: Unpack["Customer.DeleteDiscountParams"]
+ customer: str, **params: Unpack["CustomerDeleteDiscountParams"]
) -> "Discount":
"""
Removes the currently applied discount on a customer.
@@ -1842,7 +700,7 @@ def delete_discount(
@overload
def delete_discount(
- self, **params: Unpack["Customer.DeleteDiscountParams"]
+ self, **params: Unpack["CustomerDeleteDiscountParams"]
) -> "Discount":
"""
Removes the currently applied discount on a customer.
@@ -1851,7 +709,7 @@ def delete_discount(
@class_method_variant("_cls_delete_discount")
def delete_discount( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Customer.DeleteDiscountParams"]
+ self, **params: Unpack["CustomerDeleteDiscountParams"]
) -> "Discount":
"""
Removes the currently applied discount on a customer.
@@ -1869,7 +727,7 @@ def delete_discount( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_discount_async(
- cls, customer: str, **params: Unpack["Customer.DeleteDiscountParams"]
+ cls, customer: str, **params: Unpack["CustomerDeleteDiscountParams"]
) -> "Discount":
"""
Removes the currently applied discount on a customer.
@@ -1888,7 +746,7 @@ async def _cls_delete_discount_async(
@overload
@staticmethod
async def delete_discount_async(
- customer: str, **params: Unpack["Customer.DeleteDiscountParams"]
+ customer: str, **params: Unpack["CustomerDeleteDiscountParams"]
) -> "Discount":
"""
Removes the currently applied discount on a customer.
@@ -1897,7 +755,7 @@ async def delete_discount_async(
@overload
async def delete_discount_async(
- self, **params: Unpack["Customer.DeleteDiscountParams"]
+ self, **params: Unpack["CustomerDeleteDiscountParams"]
) -> "Discount":
"""
Removes the currently applied discount on a customer.
@@ -1906,7 +764,7 @@ async def delete_discount_async(
@class_method_variant("_cls_delete_discount_async")
async def delete_discount_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Customer.DeleteDiscountParams"]
+ self, **params: Unpack["CustomerDeleteDiscountParams"]
) -> "Discount":
"""
Removes the currently applied discount on a customer.
@@ -1924,7 +782,7 @@ async def delete_discount_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["Customer.ListParams"]
+ cls, **params: Unpack["CustomerListParams"]
) -> ListObject["Customer"]:
"""
Returns a list of your customers. The customers are returned sorted by creation date, with the most recent customers appearing first.
@@ -1944,7 +802,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Customer.ListParams"]
+ cls, **params: Unpack["CustomerListParams"]
) -> ListObject["Customer"]:
"""
Returns a list of your customers. The customers are returned sorted by creation date, with the most recent customers appearing first.
@@ -1966,7 +824,7 @@ async def list_async(
def _cls_list_payment_methods(
cls,
customer: str,
- **params: Unpack["Customer.ListPaymentMethodsParams"],
+ **params: Unpack["CustomerListPaymentMethodsParams"],
) -> ListObject["PaymentMethod"]:
"""
Returns a list of PaymentMethods for a given Customer
@@ -1985,7 +843,7 @@ def _cls_list_payment_methods(
@overload
@staticmethod
def list_payment_methods(
- customer: str, **params: Unpack["Customer.ListPaymentMethodsParams"]
+ customer: str, **params: Unpack["CustomerListPaymentMethodsParams"]
) -> ListObject["PaymentMethod"]:
"""
Returns a list of PaymentMethods for a given Customer
@@ -1994,7 +852,7 @@ def list_payment_methods(
@overload
def list_payment_methods(
- self, **params: Unpack["Customer.ListPaymentMethodsParams"]
+ self, **params: Unpack["CustomerListPaymentMethodsParams"]
) -> ListObject["PaymentMethod"]:
"""
Returns a list of PaymentMethods for a given Customer
@@ -2003,7 +861,7 @@ def list_payment_methods(
@class_method_variant("_cls_list_payment_methods")
def list_payment_methods( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Customer.ListPaymentMethodsParams"]
+ self, **params: Unpack["CustomerListPaymentMethodsParams"]
) -> ListObject["PaymentMethod"]:
"""
Returns a list of PaymentMethods for a given Customer
@@ -2023,7 +881,7 @@ def list_payment_methods( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_list_payment_methods_async(
cls,
customer: str,
- **params: Unpack["Customer.ListPaymentMethodsParams"],
+ **params: Unpack["CustomerListPaymentMethodsParams"],
) -> ListObject["PaymentMethod"]:
"""
Returns a list of PaymentMethods for a given Customer
@@ -2042,7 +900,7 @@ async def _cls_list_payment_methods_async(
@overload
@staticmethod
async def list_payment_methods_async(
- customer: str, **params: Unpack["Customer.ListPaymentMethodsParams"]
+ customer: str, **params: Unpack["CustomerListPaymentMethodsParams"]
) -> ListObject["PaymentMethod"]:
"""
Returns a list of PaymentMethods for a given Customer
@@ -2051,7 +909,7 @@ async def list_payment_methods_async(
@overload
async def list_payment_methods_async(
- self, **params: Unpack["Customer.ListPaymentMethodsParams"]
+ self, **params: Unpack["CustomerListPaymentMethodsParams"]
) -> ListObject["PaymentMethod"]:
"""
Returns a list of PaymentMethods for a given Customer
@@ -2060,7 +918,7 @@ async def list_payment_methods_async(
@class_method_variant("_cls_list_payment_methods_async")
async def list_payment_methods_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Customer.ListPaymentMethodsParams"]
+ self, **params: Unpack["CustomerListPaymentMethodsParams"]
) -> ListObject["PaymentMethod"]:
"""
Returns a list of PaymentMethods for a given Customer
@@ -2078,7 +936,7 @@ async def list_payment_methods_async( # pyright: ignore[reportGeneralTypeIssues
@classmethod
def modify(
- cls, id: str, **params: Unpack["Customer.ModifyParams"]
+ cls, id: str, **params: Unpack["CustomerModifyParams"]
) -> "Customer":
"""
Updates the specified customer by setting the values of the parameters passed. Any parameters not provided will be left unchanged. For example, if you pass the source parameter, that becomes the customer's active source (e.g., a card) to be used for all charges in the future. When you update a customer to a new valid card source by passing the source parameter: for each of the customer's current subscriptions, if the subscription bills automatically and is in the past_due state, then the latest open invoice for the subscription with automatic collection enabled will be retried. This retry will not count as an automatic retry, and will not affect the next regularly scheduled payment for the invoice. Changing the default_source for a customer will not trigger this behavior.
@@ -2097,7 +955,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Customer.ModifyParams"]
+ cls, id: str, **params: Unpack["CustomerModifyParams"]
) -> "Customer":
"""
Updates the specified customer by setting the values of the parameters passed. Any parameters not provided will be left unchanged. For example, if you pass the source parameter, that becomes the customer's active source (e.g., a card) to be used for all charges in the future. When you update a customer to a new valid card source by passing the source parameter: for each of the customer's current subscriptions, if the subscription bills automatically and is in the past_due state, then the latest open invoice for the subscription with automatic collection enabled will be retried. This retry will not count as an automatic retry, and will not affect the next regularly scheduled payment for the invoice. Changing the default_source for a customer will not trigger this behavior.
@@ -2116,7 +974,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Customer.RetrieveParams"]
+ cls, id: str, **params: Unpack["CustomerRetrieveParams"]
) -> "Customer":
"""
Retrieves a Customer object.
@@ -2127,7 +985,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Customer.RetrieveParams"]
+ cls, id: str, **params: Unpack["CustomerRetrieveParams"]
) -> "Customer":
"""
Retrieves a Customer object.
@@ -2141,7 +999,7 @@ def _cls_retrieve_payment_method(
cls,
customer: str,
payment_method: str,
- **params: Unpack["Customer.RetrievePaymentMethodParams"],
+ **params: Unpack["CustomerRetrievePaymentMethodParams"],
) -> "PaymentMethod":
"""
Retrieves a PaymentMethod object for a given Customer.
@@ -2163,7 +1021,7 @@ def _cls_retrieve_payment_method(
def retrieve_payment_method(
customer: str,
payment_method: str,
- **params: Unpack["Customer.RetrievePaymentMethodParams"],
+ **params: Unpack["CustomerRetrievePaymentMethodParams"],
) -> "PaymentMethod":
"""
Retrieves a PaymentMethod object for a given Customer.
@@ -2174,7 +1032,7 @@ def retrieve_payment_method(
def retrieve_payment_method(
self,
payment_method: str,
- **params: Unpack["Customer.RetrievePaymentMethodParams"],
+ **params: Unpack["CustomerRetrievePaymentMethodParams"],
) -> "PaymentMethod":
"""
Retrieves a PaymentMethod object for a given Customer.
@@ -2185,7 +1043,7 @@ def retrieve_payment_method(
def retrieve_payment_method( # pyright: ignore[reportGeneralTypeIssues]
self,
payment_method: str,
- **params: Unpack["Customer.RetrievePaymentMethodParams"],
+ **params: Unpack["CustomerRetrievePaymentMethodParams"],
) -> "PaymentMethod":
"""
Retrieves a PaymentMethod object for a given Customer.
@@ -2207,7 +1065,7 @@ async def _cls_retrieve_payment_method_async(
cls,
customer: str,
payment_method: str,
- **params: Unpack["Customer.RetrievePaymentMethodParams"],
+ **params: Unpack["CustomerRetrievePaymentMethodParams"],
) -> "PaymentMethod":
"""
Retrieves a PaymentMethod object for a given Customer.
@@ -2229,7 +1087,7 @@ async def _cls_retrieve_payment_method_async(
async def retrieve_payment_method_async(
customer: str,
payment_method: str,
- **params: Unpack["Customer.RetrievePaymentMethodParams"],
+ **params: Unpack["CustomerRetrievePaymentMethodParams"],
) -> "PaymentMethod":
"""
Retrieves a PaymentMethod object for a given Customer.
@@ -2240,7 +1098,7 @@ async def retrieve_payment_method_async(
async def retrieve_payment_method_async(
self,
payment_method: str,
- **params: Unpack["Customer.RetrievePaymentMethodParams"],
+ **params: Unpack["CustomerRetrievePaymentMethodParams"],
) -> "PaymentMethod":
"""
Retrieves a PaymentMethod object for a given Customer.
@@ -2251,7 +1109,7 @@ async def retrieve_payment_method_async(
async def retrieve_payment_method_async( # pyright: ignore[reportGeneralTypeIssues]
self,
payment_method: str,
- **params: Unpack["Customer.RetrievePaymentMethodParams"],
+ **params: Unpack["CustomerRetrievePaymentMethodParams"],
) -> "PaymentMethod":
"""
Retrieves a PaymentMethod object for a given Customer.
@@ -2270,7 +1128,7 @@ async def retrieve_payment_method_async( # pyright: ignore[reportGeneralTypeIss
@classmethod
def search(
- cls, *args, **kwargs: Unpack["Customer.SearchParams"]
+ cls, *args, **kwargs: Unpack["CustomerSearchParams"]
) -> SearchResultObject["Customer"]:
"""
Search for customers you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
@@ -2282,7 +1140,7 @@ def search(
@classmethod
async def search_async(
- cls, *args, **kwargs: Unpack["Customer.SearchParams"]
+ cls, *args, **kwargs: Unpack["CustomerSearchParams"]
) -> SearchResultObject["Customer"]:
"""
Search for customers you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
@@ -2296,13 +1154,13 @@ async def search_async(
@classmethod
def search_auto_paging_iter(
- cls, *args, **kwargs: Unpack["Customer.SearchParams"]
+ cls, *args, **kwargs: Unpack["CustomerSearchParams"]
) -> Iterator["Customer"]:
return cls.search(*args, **kwargs).auto_paging_iter()
@classmethod
async def search_auto_paging_iter_async(
- cls, *args, **kwargs: Unpack["Customer.SearchParams"]
+ cls, *args, **kwargs: Unpack["CustomerSearchParams"]
) -> AsyncIterator["Customer"]:
return (await cls.search_async(*args, **kwargs)).auto_paging_iter()
@@ -2310,7 +1168,7 @@ async def search_auto_paging_iter_async(
def list_balance_transactions(
cls,
customer: str,
- **params: Unpack["Customer.ListBalanceTransactionsParams"],
+ **params: Unpack["CustomerListBalanceTransactionsParams"],
) -> ListObject["CustomerBalanceTransaction"]:
"""
Returns a list of transactions that updated the customer's [balances](https://docs.stripe.com/docs/billing/customer/balance).
@@ -2330,7 +1188,7 @@ def list_balance_transactions(
async def list_balance_transactions_async(
cls,
customer: str,
- **params: Unpack["Customer.ListBalanceTransactionsParams"],
+ **params: Unpack["CustomerListBalanceTransactionsParams"],
) -> ListObject["CustomerBalanceTransaction"]:
"""
Returns a list of transactions that updated the customer's [balances](https://docs.stripe.com/docs/billing/customer/balance).
@@ -2350,7 +1208,7 @@ async def list_balance_transactions_async(
def create_balance_transaction(
cls,
customer: str,
- **params: Unpack["Customer.CreateBalanceTransactionParams"],
+ **params: Unpack["CustomerCreateBalanceTransactionParams"],
) -> "CustomerBalanceTransaction":
"""
Creates an immutable transaction that updates the customer's credit [balance](https://docs.stripe.com/docs/billing/customer/balance).
@@ -2370,7 +1228,7 @@ def create_balance_transaction(
async def create_balance_transaction_async(
cls,
customer: str,
- **params: Unpack["Customer.CreateBalanceTransactionParams"],
+ **params: Unpack["CustomerCreateBalanceTransactionParams"],
) -> "CustomerBalanceTransaction":
"""
Creates an immutable transaction that updates the customer's credit [balance](https://docs.stripe.com/docs/billing/customer/balance).
@@ -2391,7 +1249,7 @@ def retrieve_balance_transaction(
cls,
customer: str,
transaction: str,
- **params: Unpack["Customer.RetrieveBalanceTransactionParams"],
+ **params: Unpack["CustomerRetrieveBalanceTransactionParams"],
) -> "CustomerBalanceTransaction":
"""
Retrieves a specific customer balance transaction that updated the customer's [balances](https://docs.stripe.com/docs/billing/customer/balance).
@@ -2413,7 +1271,7 @@ async def retrieve_balance_transaction_async(
cls,
customer: str,
transaction: str,
- **params: Unpack["Customer.RetrieveBalanceTransactionParams"],
+ **params: Unpack["CustomerRetrieveBalanceTransactionParams"],
) -> "CustomerBalanceTransaction":
"""
Retrieves a specific customer balance transaction that updated the customer's [balances](https://docs.stripe.com/docs/billing/customer/balance).
@@ -2435,7 +1293,7 @@ def modify_balance_transaction(
cls,
customer: str,
transaction: str,
- **params: Unpack["Customer.ModifyBalanceTransactionParams"],
+ **params: Unpack["CustomerModifyBalanceTransactionParams"],
) -> "CustomerBalanceTransaction":
"""
Most credit balance transaction fields are immutable, but you may update its description and metadata.
@@ -2457,7 +1315,7 @@ async def modify_balance_transaction_async(
cls,
customer: str,
transaction: str,
- **params: Unpack["Customer.ModifyBalanceTransactionParams"],
+ **params: Unpack["CustomerModifyBalanceTransactionParams"],
) -> "CustomerBalanceTransaction":
"""
Most credit balance transaction fields are immutable, but you may update its description and metadata.
@@ -2478,7 +1336,7 @@ async def modify_balance_transaction_async(
def list_cash_balance_transactions(
cls,
customer: str,
- **params: Unpack["Customer.ListCashBalanceTransactionsParams"],
+ **params: Unpack["CustomerListCashBalanceTransactionsParams"],
) -> ListObject["CustomerCashBalanceTransaction"]:
"""
Returns a list of transactions that modified the customer's [cash balance](https://docs.stripe.com/docs/payments/customer-balance).
@@ -2498,7 +1356,7 @@ def list_cash_balance_transactions(
async def list_cash_balance_transactions_async(
cls,
customer: str,
- **params: Unpack["Customer.ListCashBalanceTransactionsParams"],
+ **params: Unpack["CustomerListCashBalanceTransactionsParams"],
) -> ListObject["CustomerCashBalanceTransaction"]:
"""
Returns a list of transactions that modified the customer's [cash balance](https://docs.stripe.com/docs/payments/customer-balance).
@@ -2519,7 +1377,7 @@ def retrieve_cash_balance_transaction(
cls,
customer: str,
transaction: str,
- **params: Unpack["Customer.RetrieveCashBalanceTransactionParams"],
+ **params: Unpack["CustomerRetrieveCashBalanceTransactionParams"],
) -> "CustomerCashBalanceTransaction":
"""
Retrieves a specific cash balance transaction, which updated the customer's [cash balance](https://docs.stripe.com/docs/payments/customer-balance).
@@ -2541,7 +1399,7 @@ async def retrieve_cash_balance_transaction_async(
cls,
customer: str,
transaction: str,
- **params: Unpack["Customer.RetrieveCashBalanceTransactionParams"],
+ **params: Unpack["CustomerRetrieveCashBalanceTransactionParams"],
) -> "CustomerCashBalanceTransaction":
"""
Retrieves a specific cash balance transaction, which updated the customer's [cash balance](https://docs.stripe.com/docs/payments/customer-balance).
@@ -2560,7 +1418,7 @@ async def retrieve_cash_balance_transaction_async(
@classmethod
def list_sources(
- cls, customer: str, **params: Unpack["Customer.ListSourcesParams"]
+ cls, customer: str, **params: Unpack["CustomerListSourcesParams"]
) -> ListObject[Union["Account", "BankAccount", "Card", "Source"]]:
"""
List sources for a specified customer.
@@ -2578,7 +1436,7 @@ def list_sources(
@classmethod
async def list_sources_async(
- cls, customer: str, **params: Unpack["Customer.ListSourcesParams"]
+ cls, customer: str, **params: Unpack["CustomerListSourcesParams"]
) -> ListObject[Union["Account", "BankAccount", "Card", "Source"]]:
"""
List sources for a specified customer.
@@ -2596,7 +1454,7 @@ async def list_sources_async(
@classmethod
def create_source(
- cls, customer: str, **params: Unpack["Customer.CreateSourceParams"]
+ 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.
@@ -2618,7 +1476,7 @@ def create_source(
@classmethod
async def create_source_async(
- cls, customer: str, **params: Unpack["Customer.CreateSourceParams"]
+ 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.
@@ -2643,7 +1501,7 @@ def retrieve_source(
cls,
customer: str,
id: str,
- **params: Unpack["Customer.RetrieveSourceParams"],
+ **params: Unpack["CustomerRetrieveSourceParams"],
) -> Union["Account", "BankAccount", "Card", "Source"]:
"""
Retrieve a specified source for a given customer.
@@ -2664,7 +1522,7 @@ async def retrieve_source_async(
cls,
customer: str,
id: str,
- **params: Unpack["Customer.RetrieveSourceParams"],
+ **params: Unpack["CustomerRetrieveSourceParams"],
) -> Union["Account", "BankAccount", "Card", "Source"]:
"""
Retrieve a specified source for a given customer.
@@ -2685,7 +1543,7 @@ def modify_source(
cls,
customer: str,
id: str,
- **params: Unpack["Customer.ModifySourceParams"],
+ **params: Unpack["CustomerModifySourceParams"],
) -> Union["Account", "BankAccount", "Card", "Source"]:
"""
Update a specified source for a given customer.
@@ -2706,7 +1564,7 @@ async def modify_source_async(
cls,
customer: str,
id: str,
- **params: Unpack["Customer.ModifySourceParams"],
+ **params: Unpack["CustomerModifySourceParams"],
) -> Union["Account", "BankAccount", "Card", "Source"]:
"""
Update a specified source for a given customer.
@@ -2727,7 +1585,7 @@ def delete_source(
cls,
customer: str,
id: str,
- **params: Unpack["Customer.DeleteSourceParams"],
+ **params: Unpack["CustomerDeleteSourceParams"],
) -> Union["Account", "BankAccount", "Card", "Source"]:
"""
Delete a specified source for a given customer.
@@ -2748,7 +1606,7 @@ async def delete_source_async(
cls,
customer: str,
id: str,
- **params: Unpack["Customer.DeleteSourceParams"],
+ **params: Unpack["CustomerDeleteSourceParams"],
) -> Union["Account", "BankAccount", "Card", "Source"]:
"""
Delete a specified source for a given customer.
@@ -2766,7 +1624,7 @@ async def delete_source_async(
@classmethod
def create_tax_id(
- cls, customer: str, **params: Unpack["Customer.CreateTaxIdParams"]
+ cls, customer: str, **params: Unpack["CustomerCreateTaxIdParams"]
) -> "TaxId":
"""
Creates a new tax_id object for a customer.
@@ -2784,7 +1642,7 @@ def create_tax_id(
@classmethod
async def create_tax_id_async(
- cls, customer: str, **params: Unpack["Customer.CreateTaxIdParams"]
+ cls, customer: str, **params: Unpack["CustomerCreateTaxIdParams"]
) -> "TaxId":
"""
Creates a new tax_id object for a customer.
@@ -2805,7 +1663,7 @@ def retrieve_tax_id(
cls,
customer: str,
id: str,
- **params: Unpack["Customer.RetrieveTaxIdParams"],
+ **params: Unpack["CustomerRetrieveTaxIdParams"],
) -> "TaxId":
"""
Retrieves the tax_id object with the given identifier.
@@ -2826,7 +1684,7 @@ async def retrieve_tax_id_async(
cls,
customer: str,
id: str,
- **params: Unpack["Customer.RetrieveTaxIdParams"],
+ **params: Unpack["CustomerRetrieveTaxIdParams"],
) -> "TaxId":
"""
Retrieves the tax_id object with the given identifier.
@@ -2847,7 +1705,7 @@ def delete_tax_id(
cls,
customer: str,
id: str,
- **params: Unpack["Customer.DeleteTaxIdParams"],
+ **params: Unpack["CustomerDeleteTaxIdParams"],
) -> "TaxId":
"""
Deletes an existing tax_id object.
@@ -2868,7 +1726,7 @@ async def delete_tax_id_async(
cls,
customer: str,
id: str,
- **params: Unpack["Customer.DeleteTaxIdParams"],
+ **params: Unpack["CustomerDeleteTaxIdParams"],
) -> "TaxId":
"""
Deletes an existing tax_id object.
@@ -2886,7 +1744,7 @@ async def delete_tax_id_async(
@classmethod
def list_tax_ids(
- cls, customer: str, **params: Unpack["Customer.ListTaxIdsParams"]
+ cls, customer: str, **params: Unpack["CustomerListTaxIdsParams"]
) -> ListObject["TaxId"]:
"""
Returns a list of tax IDs for a customer.
@@ -2904,7 +1762,7 @@ def list_tax_ids(
@classmethod
async def list_tax_ids_async(
- cls, customer: str, **params: Unpack["Customer.ListTaxIdsParams"]
+ cls, customer: str, **params: Unpack["CustomerListTaxIdsParams"]
) -> ListObject["TaxId"]:
"""
Returns a list of tax IDs for a customer.
@@ -2924,7 +1782,7 @@ async def list_tax_ids_async(
def retrieve_cash_balance(
cls,
customer: str,
- **params: Unpack["Customer.RetrieveCashBalanceParams"],
+ **params: Unpack["CustomerRetrieveCashBalanceParams"],
) -> "CashBalance":
"""
Retrieves a customer's cash balance.
@@ -2944,7 +1802,7 @@ def retrieve_cash_balance(
async def retrieve_cash_balance_async(
cls,
customer: str,
- **params: Unpack["Customer.RetrieveCashBalanceParams"],
+ **params: Unpack["CustomerRetrieveCashBalanceParams"],
) -> "CashBalance":
"""
Retrieves a customer's cash balance.
@@ -2962,9 +1820,7 @@ async def retrieve_cash_balance_async(
@classmethod
def modify_cash_balance(
- cls,
- customer: str,
- **params: Unpack["Customer.ModifyCashBalanceParams"],
+ cls, customer: str, **params: Unpack["CustomerModifyCashBalanceParams"]
) -> "CashBalance":
"""
Changes the settings on a customer's cash balance.
@@ -2982,9 +1838,7 @@ def modify_cash_balance(
@classmethod
async def modify_cash_balance_async(
- cls,
- customer: str,
- **params: Unpack["Customer.ModifyCashBalanceParams"],
+ cls, customer: str, **params: Unpack["CustomerModifyCashBalanceParams"]
) -> "CashBalance":
"""
Changes the settings on a customer's cash balance.
@@ -3007,7 +1861,7 @@ class TestHelpers(APIResourceTestHelpers["Customer"]):
def _cls_fund_cash_balance(
cls,
customer: str,
- **params: Unpack["Customer.FundCashBalanceParams"],
+ **params: Unpack["CustomerFundCashBalanceParams"],
) -> "CustomerCashBalanceTransaction":
"""
Create an incoming testmode bank transfer
@@ -3026,7 +1880,7 @@ def _cls_fund_cash_balance(
@overload
@staticmethod
def fund_cash_balance(
- customer: str, **params: Unpack["Customer.FundCashBalanceParams"]
+ customer: str, **params: Unpack["CustomerFundCashBalanceParams"]
) -> "CustomerCashBalanceTransaction":
"""
Create an incoming testmode bank transfer
@@ -3035,7 +1889,7 @@ def fund_cash_balance(
@overload
def fund_cash_balance(
- self, **params: Unpack["Customer.FundCashBalanceParams"]
+ self, **params: Unpack["CustomerFundCashBalanceParams"]
) -> "CustomerCashBalanceTransaction":
"""
Create an incoming testmode bank transfer
@@ -3044,7 +1898,7 @@ def fund_cash_balance(
@class_method_variant("_cls_fund_cash_balance")
def fund_cash_balance( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Customer.FundCashBalanceParams"]
+ self, **params: Unpack["CustomerFundCashBalanceParams"]
) -> "CustomerCashBalanceTransaction":
"""
Create an incoming testmode bank transfer
@@ -3064,7 +1918,7 @@ def fund_cash_balance( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_fund_cash_balance_async(
cls,
customer: str,
- **params: Unpack["Customer.FundCashBalanceParams"],
+ **params: Unpack["CustomerFundCashBalanceParams"],
) -> "CustomerCashBalanceTransaction":
"""
Create an incoming testmode bank transfer
@@ -3083,7 +1937,7 @@ async def _cls_fund_cash_balance_async(
@overload
@staticmethod
async def fund_cash_balance_async(
- customer: str, **params: Unpack["Customer.FundCashBalanceParams"]
+ customer: str, **params: Unpack["CustomerFundCashBalanceParams"]
) -> "CustomerCashBalanceTransaction":
"""
Create an incoming testmode bank transfer
@@ -3092,7 +1946,7 @@ async def fund_cash_balance_async(
@overload
async def fund_cash_balance_async(
- self, **params: Unpack["Customer.FundCashBalanceParams"]
+ self, **params: Unpack["CustomerFundCashBalanceParams"]
) -> "CustomerCashBalanceTransaction":
"""
Create an incoming testmode bank transfer
@@ -3101,7 +1955,7 @@ async def fund_cash_balance_async(
@class_method_variant("_cls_fund_cash_balance_async")
async def fund_cash_balance_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Customer.FundCashBalanceParams"]
+ self, **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 e8b04b420..154fedb02 100644
--- a/stripe/_customer_balance_transaction_service.py
+++ b/stripe/_customer_balance_transaction_service.py
@@ -5,77 +5,29 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._customer_balance_transaction_create_params import (
+ CustomerBalanceTransactionCreateParams,
+ )
+ from stripe.params._customer_balance_transaction_list_params import (
+ CustomerBalanceTransactionListParams,
+ )
+ from stripe.params._customer_balance_transaction_retrieve_params import (
+ CustomerBalanceTransactionRetrieveParams,
+ )
+ from stripe.params._customer_balance_transaction_update_params import (
+ CustomerBalanceTransactionUpdateParams,
+ )
-class CustomerBalanceTransactionService(StripeService):
- class CreateParams(TypedDict):
- amount: int
- """
- The integer amount in **cents (or local equivalent)** to apply to the customer's credit balance.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Specifies the [`invoice_credit_balance`](https://stripe.com/docs/api/customers/object#customer_object-invoice_credit_balance) that this transaction will apply to. If the customer's `currency` is not set, it will be updated to this value.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
+class CustomerBalanceTransactionService(StripeService):
def list(
self,
customer: str,
- params: Optional[
- "CustomerBalanceTransactionService.ListParams"
- ] = None,
+ params: Optional["CustomerBalanceTransactionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[CustomerBalanceTransaction]:
"""
@@ -97,9 +49,7 @@ def list(
async def list_async(
self,
customer: str,
- params: Optional[
- "CustomerBalanceTransactionService.ListParams"
- ] = None,
+ params: Optional["CustomerBalanceTransactionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[CustomerBalanceTransaction]:
"""
@@ -121,7 +71,7 @@ async def list_async(
def create(
self,
customer: str,
- params: "CustomerBalanceTransactionService.CreateParams",
+ params: "CustomerBalanceTransactionCreateParams",
options: Optional[RequestOptions] = None,
) -> CustomerBalanceTransaction:
"""
@@ -143,7 +93,7 @@ def create(
async def create_async(
self,
customer: str,
- params: "CustomerBalanceTransactionService.CreateParams",
+ params: "CustomerBalanceTransactionCreateParams",
options: Optional[RequestOptions] = None,
) -> CustomerBalanceTransaction:
"""
@@ -166,9 +116,7 @@ def retrieve(
self,
customer: str,
transaction: str,
- params: Optional[
- "CustomerBalanceTransactionService.RetrieveParams"
- ] = None,
+ params: Optional["CustomerBalanceTransactionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> CustomerBalanceTransaction:
"""
@@ -192,9 +140,7 @@ async def retrieve_async(
self,
customer: str,
transaction: str,
- params: Optional[
- "CustomerBalanceTransactionService.RetrieveParams"
- ] = None,
+ params: Optional["CustomerBalanceTransactionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> CustomerBalanceTransaction:
"""
@@ -218,9 +164,7 @@ def update(
self,
customer: str,
transaction: str,
- params: Optional[
- "CustomerBalanceTransactionService.UpdateParams"
- ] = None,
+ params: Optional["CustomerBalanceTransactionUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> CustomerBalanceTransaction:
"""
@@ -244,9 +188,7 @@ async def update_async(
self,
customer: str,
transaction: str,
- params: Optional[
- "CustomerBalanceTransactionService.UpdateParams"
- ] = None,
+ 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 9d6f55fd4..14e21c57d 100644
--- a/stripe/_customer_cash_balance_service.py
+++ b/stripe/_customer_cash_balance_service.py
@@ -4,41 +4,23 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._customer_cash_balance_retrieve_params import (
+ CustomerCashBalanceRetrieveParams,
+ )
+ from stripe.params._customer_cash_balance_update_params import (
+ CustomerCashBalanceUpdateParams,
+ )
-class CustomerCashBalanceService(StripeService):
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- settings: NotRequired[
- "CustomerCashBalanceService.UpdateParamsSettings"
- ]
- """
- A hash of settings for this cash balance.
- """
-
- class UpdateParamsSettings(TypedDict):
- reconciliation_mode: NotRequired[
- Literal["automatic", "manual", "merchant_default"]
- ]
- """
- Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
- """
+class CustomerCashBalanceService(StripeService):
def retrieve(
self,
customer: str,
- params: Optional["CustomerCashBalanceService.RetrieveParams"] = None,
+ params: Optional["CustomerCashBalanceRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> CashBalance:
"""
@@ -60,7 +42,7 @@ def retrieve(
async def retrieve_async(
self,
customer: str,
- params: Optional["CustomerCashBalanceService.RetrieveParams"] = None,
+ params: Optional["CustomerCashBalanceRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> CashBalance:
"""
@@ -82,7 +64,7 @@ async def retrieve_async(
def update(
self,
customer: str,
- params: Optional["CustomerCashBalanceService.UpdateParams"] = None,
+ params: Optional["CustomerCashBalanceUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> CashBalance:
"""
@@ -104,7 +86,7 @@ def update(
async def update_async(
self,
customer: str,
- params: Optional["CustomerCashBalanceService.UpdateParams"] = None,
+ 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 13d83f227..861f9dd1d 100644
--- a/stripe/_customer_cash_balance_transaction_service.py
+++ b/stripe/_customer_cash_balance_transaction_service.py
@@ -7,41 +7,23 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._customer_cash_balance_transaction_list_params import (
+ CustomerCashBalanceTransactionListParams,
+ )
+ from stripe.params._customer_cash_balance_transaction_retrieve_params import (
+ CustomerCashBalanceTransactionRetrieveParams,
+ )
-class CustomerCashBalanceTransactionService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class CustomerCashBalanceTransactionService(StripeService):
def list(
self,
customer: str,
- params: Optional[
- "CustomerCashBalanceTransactionService.ListParams"
- ] = None,
+ params: Optional["CustomerCashBalanceTransactionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[CustomerCashBalanceTransaction]:
"""
@@ -63,9 +45,7 @@ def list(
async def list_async(
self,
customer: str,
- params: Optional[
- "CustomerCashBalanceTransactionService.ListParams"
- ] = None,
+ params: Optional["CustomerCashBalanceTransactionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[CustomerCashBalanceTransaction]:
"""
@@ -89,7 +69,7 @@ def retrieve(
customer: str,
transaction: str,
params: Optional[
- "CustomerCashBalanceTransactionService.RetrieveParams"
+ "CustomerCashBalanceTransactionRetrieveParams"
] = None,
options: Optional[RequestOptions] = None,
) -> CustomerCashBalanceTransaction:
@@ -115,7 +95,7 @@ async def retrieve_async(
customer: str,
transaction: str,
params: Optional[
- "CustomerCashBalanceTransactionService.RetrieveParams"
+ "CustomerCashBalanceTransactionRetrieveParams"
] = None,
options: Optional[RequestOptions] = None,
) -> CustomerCashBalanceTransaction:
diff --git a/stripe/_customer_funding_instructions_service.py b/stripe/_customer_funding_instructions_service.py
index cfdd185b6..7df3a4ba8 100644
--- a/stripe/_customer_funding_instructions_service.py
+++ b/stripe/_customer_funding_instructions_service.py
@@ -4,67 +4,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._customer_funding_instructions_create_params import (
+ CustomerFundingInstructionsCreateParams,
+ )
-class CustomerFundingInstructionsService(StripeService):
- class CreateParams(TypedDict):
- bank_transfer: (
- "CustomerFundingInstructionsService.CreateParamsBankTransfer"
- )
- """
- Additional parameters for `bank_transfer` funding types
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- funding_type: Literal["bank_transfer"]
- """
- The `funding_type` to get the instructions for.
- """
-
- class CreateParamsBankTransfer(TypedDict):
- eu_bank_transfer: NotRequired[
- "CustomerFundingInstructionsService.CreateParamsBankTransferEuBankTransfer"
- ]
- """
- Configuration for eu_bank_transfer funding type.
- """
- requested_address_types: NotRequired[
- List[Literal["iban", "sort_code", "spei", "zengin"]]
- ]
- """
- List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
-
- Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
- """
- type: Literal[
- "eu_bank_transfer",
- "gb_bank_transfer",
- "jp_bank_transfer",
- "mx_bank_transfer",
- "us_bank_transfer",
- ]
- """
- The type of the `bank_transfer`
- """
-
- class CreateParamsBankTransferEuBankTransfer(TypedDict):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
+class CustomerFundingInstructionsService(StripeService):
def create(
self,
customer: str,
- params: "CustomerFundingInstructionsService.CreateParams",
+ params: "CustomerFundingInstructionsCreateParams",
options: Optional[RequestOptions] = None,
) -> FundingInstructions:
"""
@@ -88,7 +41,7 @@ def create(
async def create_async(
self,
customer: str,
- params: "CustomerFundingInstructionsService.CreateParams",
+ params: "CustomerFundingInstructionsCreateParams",
options: Optional[RequestOptions] = None,
) -> FundingInstructions:
"""
diff --git a/stripe/_customer_payment_method_service.py b/stripe/_customer_payment_method_service.py
index eac26dd8c..02b9e188e 100644
--- a/stripe/_customer_payment_method_service.py
+++ b/stripe/_customer_payment_method_service.py
@@ -5,101 +5,23 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._customer_payment_method_list_params import (
+ CustomerPaymentMethodListParams,
+ )
+ from stripe.params._customer_payment_method_retrieve_params import (
+ CustomerPaymentMethodRetrieveParams,
+ )
-class CustomerPaymentMethodService(StripeService):
- class ListParams(TypedDict):
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[
- Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "card",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- ]
- """
- An optional filter on the list, based on the object `type` field. Without the filter, the list includes all current and future payment method types. If your integration expects only one type of payment method in the response, make sure to provide a type value in the request.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class CustomerPaymentMethodService(StripeService):
def list(
self,
customer: str,
- params: Optional["CustomerPaymentMethodService.ListParams"] = None,
+ params: Optional["CustomerPaymentMethodListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PaymentMethod]:
"""
@@ -121,7 +43,7 @@ def list(
async def list_async(
self,
customer: str,
- params: Optional["CustomerPaymentMethodService.ListParams"] = None,
+ params: Optional["CustomerPaymentMethodListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PaymentMethod]:
"""
@@ -144,7 +66,7 @@ def retrieve(
self,
customer: str,
payment_method: str,
- params: Optional["CustomerPaymentMethodService.RetrieveParams"] = None,
+ params: Optional["CustomerPaymentMethodRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethod:
"""
@@ -168,7 +90,7 @@ async def retrieve_async(
self,
customer: str,
payment_method: str,
- params: Optional["CustomerPaymentMethodService.RetrieveParams"] = None,
+ 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 7fad95914..7d865a4c2 100644
--- a/stripe/_customer_payment_source_service.py
+++ b/stripe/_customer_payment_source_service.py
@@ -8,175 +8,35 @@
from stripe._source import Source
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, Union, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, Union, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._customer_payment_source_create_params import (
+ CustomerPaymentSourceCreateParams,
+ )
+ from stripe.params._customer_payment_source_delete_params import (
+ CustomerPaymentSourceDeleteParams,
+ )
+ from stripe.params._customer_payment_source_list_params import (
+ CustomerPaymentSourceListParams,
+ )
+ from stripe.params._customer_payment_source_retrieve_params import (
+ CustomerPaymentSourceRetrieveParams,
+ )
+ from stripe.params._customer_payment_source_update_params import (
+ CustomerPaymentSourceUpdateParams,
+ )
+ from stripe.params._customer_payment_source_verify_params import (
+ CustomerPaymentSourceVerifyParams,
+ )
-class CustomerPaymentSourceService(StripeService):
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- source: str
- """
- Please refer to full [documentation](https://stripe.com/docs/api) instead.
- """
- validate: NotRequired[bool]
-
- class DeleteParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- object: NotRequired[str]
- """
- Filter sources according to a particular object type.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name of the person or business that owns the bank account.
- """
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- The type of entity that holds the account. This can be either `individual` or `company`.
- """
- address_city: NotRequired[str]
- """
- City/District/Suburb/Town/Village.
- """
- address_country: NotRequired[str]
- """
- Billing address country, if provided when creating card.
- """
- address_line1: NotRequired[str]
- """
- Address line 1 (Street address/PO Box/Company name).
- """
- address_line2: NotRequired[str]
- """
- Address line 2 (Apartment/Suite/Unit/Building).
- """
- address_state: NotRequired[str]
- """
- State/County/Province/Region.
- """
- address_zip: NotRequired[str]
- """
- ZIP or postal code.
- """
- exp_month: NotRequired[str]
- """
- Two digit number representing the card's expiration month.
- """
- exp_year: NotRequired[str]
- """
- Four digit number representing the card's expiration year.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- Cardholder name.
- """
- owner: NotRequired["CustomerPaymentSourceService.UpdateParamsOwner"]
-
- class UpdateParamsOwner(TypedDict):
- address: NotRequired[
- "CustomerPaymentSourceService.UpdateParamsOwnerAddress"
- ]
- """
- Owner's address.
- """
- email: NotRequired[str]
- """
- Owner's email address.
- """
- name: NotRequired[str]
- """
- Owner's full name.
- """
- phone: NotRequired[str]
- """
- Owner's phone number.
- """
-
- class UpdateParamsOwnerAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class VerifyParams(TypedDict):
- amounts: NotRequired[List[int]]
- """
- Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class CustomerPaymentSourceService(StripeService):
def list(
self,
customer: str,
- params: Optional["CustomerPaymentSourceService.ListParams"] = None,
+ params: Optional["CustomerPaymentSourceListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Union[Account, BankAccount, Card, Source]]:
"""
@@ -198,7 +58,7 @@ def list(
async def list_async(
self,
customer: str,
- params: Optional["CustomerPaymentSourceService.ListParams"] = None,
+ params: Optional["CustomerPaymentSourceListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Union[Account, BankAccount, Card, Source]]:
"""
@@ -220,7 +80,7 @@ async def list_async(
def create(
self,
customer: str,
- params: "CustomerPaymentSourceService.CreateParams",
+ params: "CustomerPaymentSourceCreateParams",
options: Optional[RequestOptions] = None,
) -> Union[Account, BankAccount, Card, Source]:
"""
@@ -246,7 +106,7 @@ def create(
async def create_async(
self,
customer: str,
- params: "CustomerPaymentSourceService.CreateParams",
+ params: "CustomerPaymentSourceCreateParams",
options: Optional[RequestOptions] = None,
) -> Union[Account, BankAccount, Card, Source]:
"""
@@ -273,7 +133,7 @@ def retrieve(
self,
customer: str,
id: str,
- params: Optional["CustomerPaymentSourceService.RetrieveParams"] = None,
+ params: Optional["CustomerPaymentSourceRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Union[Account, BankAccount, Card, Source]:
"""
@@ -297,7 +157,7 @@ async def retrieve_async(
self,
customer: str,
id: str,
- params: Optional["CustomerPaymentSourceService.RetrieveParams"] = None,
+ params: Optional["CustomerPaymentSourceRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Union[Account, BankAccount, Card, Source]:
"""
@@ -321,7 +181,7 @@ def update(
self,
customer: str,
id: str,
- params: Optional["CustomerPaymentSourceService.UpdateParams"] = None,
+ params: Optional["CustomerPaymentSourceUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Union[Account, BankAccount, Card, Source]:
"""
@@ -345,7 +205,7 @@ async def update_async(
self,
customer: str,
id: str,
- params: Optional["CustomerPaymentSourceService.UpdateParams"] = None,
+ params: Optional["CustomerPaymentSourceUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Union[Account, BankAccount, Card, Source]:
"""
@@ -369,7 +229,7 @@ def delete(
self,
customer: str,
id: str,
- params: Optional["CustomerPaymentSourceService.DeleteParams"] = None,
+ params: Optional["CustomerPaymentSourceDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Union[Account, BankAccount, Card, Source]:
"""
@@ -393,7 +253,7 @@ async def delete_async(
self,
customer: str,
id: str,
- params: Optional["CustomerPaymentSourceService.DeleteParams"] = None,
+ params: Optional["CustomerPaymentSourceDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Union[Account, BankAccount, Card, Source]:
"""
@@ -417,7 +277,7 @@ def verify(
self,
customer: str,
id: str,
- params: Optional["CustomerPaymentSourceService.VerifyParams"] = None,
+ params: Optional["CustomerPaymentSourceVerifyParams"] = None,
options: Optional[RequestOptions] = None,
) -> BankAccount:
"""
@@ -441,7 +301,7 @@ async def verify_async(
self,
customer: str,
id: str,
- params: Optional["CustomerPaymentSourceService.VerifyParams"] = None,
+ params: Optional["CustomerPaymentSourceVerifyParams"] = None,
options: Optional[RequestOptions] = None,
) -> BankAccount:
"""
diff --git a/stripe/_customer_service.py b/stripe/_customer_service.py
index cbd6f6655..987f31db4 100644
--- a/stripe/_customer_service.py
+++ b/stripe/_customer_service.py
@@ -24,8 +24,19 @@
from stripe._search_result_object import SearchResultObject
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._customer_create_params import CustomerCreateParams
+ from stripe.params._customer_delete_discount_params import (
+ CustomerDeleteDiscountParams,
+ )
+ from stripe.params._customer_delete_params import CustomerDeleteParams
+ from stripe.params._customer_list_params import CustomerListParams
+ from stripe.params._customer_retrieve_params import CustomerRetrieveParams
+ from stripe.params._customer_search_params import CustomerSearchParams
+ from stripe.params._customer_update_params import CustomerUpdateParams
class CustomerService(StripeService):
@@ -45,668 +56,10 @@ def __init__(self, requestor):
self.payment_sources = CustomerPaymentSourceService(self._requestor)
self.tax_ids = CustomerTaxIdService(self._requestor)
- class CreateParams(TypedDict):
- address: NotRequired["Literal['']|CustomerService.CreateParamsAddress"]
- """
- The customer's address.
- """
- balance: NotRequired[int]
- """
- An integer amount in cents (or local equivalent) that represents the customer's current balance, which affect the customer's future invoices. A negative amount represents a credit that decreases the amount due on an invoice; a positive amount increases the amount due on an invoice.
- """
- business_name: NotRequired["Literal['']|str"]
- """
- The customer's business name. This may be up to *150 characters*.
- """
- cash_balance: NotRequired["CustomerService.CreateParamsCashBalance"]
- """
- Balance information and default balance settings for this customer.
- """
- description: NotRequired[str]
- """
- An arbitrary string that you can attach to a customer object. It is displayed alongside the customer in the dashboard.
- """
- email: NotRequired[str]
- """
- Customer's email address. It's displayed alongside the customer in your dashboard and can be useful for searching and tracking. This may be up to *512 characters*.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- individual_name: NotRequired["Literal['']|str"]
- """
- The customer's full name. This may be up to *150 characters*.
- """
- invoice_prefix: NotRequired[str]
- """
- The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.
- """
- invoice_settings: NotRequired[
- "CustomerService.CreateParamsInvoiceSettings"
- ]
- """
- Default invoice settings for this customer.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- The customer's full name or business name.
- """
- next_invoice_sequence: NotRequired[int]
- """
- The sequence to be used on the customer's next invoice. Defaults to 1.
- """
- payment_method: NotRequired[str]
- phone: NotRequired[str]
- """
- The customer's phone number.
- """
- preferred_locales: NotRequired[List[str]]
- """
- Customer's preferred languages, ordered by preference.
- """
- shipping: NotRequired[
- "Literal['']|CustomerService.CreateParamsShipping"
- ]
- """
- The customer's shipping information. Appears on invoices emailed to this customer.
- """
- source: NotRequired[str]
- tax: NotRequired["CustomerService.CreateParamsTax"]
- """
- Tax details about the customer.
- """
- tax_exempt: NotRequired[
- "Literal['']|Literal['exempt', 'none', 'reverse']"
- ]
- """
- The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
- """
- tax_id_data: NotRequired[
- List["CustomerService.CreateParamsTaxIdDatum"]
- ]
- """
- The customer's tax IDs.
- """
- test_clock: NotRequired[str]
- """
- ID of the test clock to attach to the customer.
- """
- validate: NotRequired[bool]
-
- class CreateParamsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsCashBalance(TypedDict):
- settings: NotRequired[
- "CustomerService.CreateParamsCashBalanceSettings"
- ]
- """
- Settings controlling the behavior of the customer's cash balance,
- such as reconciliation of funds received.
- """
-
- class CreateParamsCashBalanceSettings(TypedDict):
- reconciliation_mode: NotRequired[
- Literal["automatic", "manual", "merchant_default"]
- ]
- """
- Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
- """
-
- class CreateParamsInvoiceSettings(TypedDict):
- custom_fields: NotRequired[
- "Literal['']|List[CustomerService.CreateParamsInvoiceSettingsCustomField]"
- ]
- """
- The list of up to 4 default custom fields to be displayed on invoices for this customer. When updating, pass an empty string to remove previously-defined fields.
- """
- default_payment_method: NotRequired[str]
- """
- ID of a payment method that's attached to the customer, to be used as the customer's default payment method for subscriptions and invoices.
- """
- footer: NotRequired[str]
- """
- Default footer to be displayed on invoices for this customer.
- """
- rendering_options: NotRequired[
- "Literal['']|CustomerService.CreateParamsInvoiceSettingsRenderingOptions"
- ]
- """
- Default options for invoice PDF rendering for this customer.
- """
-
- class CreateParamsInvoiceSettingsCustomField(TypedDict):
- name: str
- """
- The name of the custom field. This may be up to 40 characters.
- """
- value: str
- """
- The value of the custom field. This may be up to 140 characters.
- """
-
- class CreateParamsInvoiceSettingsRenderingOptions(TypedDict):
- amount_tax_display: NotRequired[
- "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
- ]
- """
- How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
- """
- template: NotRequired[str]
- """
- ID of the invoice rendering template to use for future invoices.
- """
-
- class CreateParamsShipping(TypedDict):
- address: "CustomerService.CreateParamsShippingAddress"
- """
- Customer shipping address.
- """
- name: str
- """
- Customer name.
- """
- phone: NotRequired[str]
- """
- Customer phone (including extension).
- """
-
- class CreateParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsTax(TypedDict):
- ip_address: NotRequired["Literal['']|str"]
- """
- A recent IP address of the customer used for tax reporting and tax location inference. Stripe recommends updating the IP address when a new PaymentMethod is attached or the address field on the customer is updated. We recommend against updating this field more frequently since it could result in unexpected tax location/reporting outcomes.
- """
- validate_location: NotRequired[Literal["deferred", "immediately"]]
- """
- A flag that indicates when Stripe should validate the customer tax location. Defaults to `deferred`.
- """
-
- class CreateParamsTaxIdDatum(TypedDict):
- type: Literal[
- "ad_nrt",
- "ae_trn",
- "al_tin",
- "am_tin",
- "ao_tin",
- "ar_cuit",
- "au_abn",
- "au_arn",
- "aw_tin",
- "az_tin",
- "ba_tin",
- "bb_tin",
- "bd_bin",
- "bf_ifu",
- "bg_uic",
- "bh_vat",
- "bj_ifu",
- "bo_tin",
- "br_cnpj",
- "br_cpf",
- "bs_tin",
- "by_tin",
- "ca_bn",
- "ca_gst_hst",
- "ca_pst_bc",
- "ca_pst_mb",
- "ca_pst_sk",
- "ca_qst",
- "cd_nif",
- "ch_uid",
- "ch_vat",
- "cl_tin",
- "cm_niu",
- "cn_tin",
- "co_nit",
- "cr_tin",
- "cv_nif",
- "de_stn",
- "do_rcn",
- "ec_ruc",
- "eg_tin",
- "es_cif",
- "et_tin",
- "eu_oss_vat",
- "eu_vat",
- "gb_vat",
- "ge_vat",
- "gn_nif",
- "hk_br",
- "hr_oib",
- "hu_tin",
- "id_npwp",
- "il_vat",
- "in_gst",
- "is_vat",
- "jp_cn",
- "jp_rn",
- "jp_trn",
- "ke_pin",
- "kg_tin",
- "kh_tin",
- "kr_brn",
- "kz_bin",
- "la_tin",
- "li_uid",
- "li_vat",
- "ma_vat",
- "md_vat",
- "me_pib",
- "mk_vat",
- "mr_nif",
- "mx_rfc",
- "my_frp",
- "my_itn",
- "my_sst",
- "ng_tin",
- "no_vat",
- "no_voec",
- "np_pan",
- "nz_gst",
- "om_vat",
- "pe_ruc",
- "ph_tin",
- "ro_tin",
- "rs_pib",
- "ru_inn",
- "ru_kpp",
- "sa_vat",
- "sg_gst",
- "sg_uen",
- "si_tin",
- "sn_ninea",
- "sr_fin",
- "sv_nit",
- "th_vat",
- "tj_tin",
- "tr_tin",
- "tw_vat",
- "tz_vat",
- "ua_vat",
- "ug_tin",
- "us_ein",
- "uy_ruc",
- "uz_tin",
- "uz_vat",
- "ve_rif",
- "vn_tin",
- "za_vat",
- "zm_tin",
- "zw_tin",
- ]
- """
- Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
- """
- value: str
- """
- Value of the tax ID.
- """
-
- class DeleteDiscountParams(TypedDict):
- pass
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- created: NotRequired["CustomerService.ListParamsCreated|int"]
- """
- Only return customers that were created during the given date interval.
- """
- email: NotRequired[str]
- """
- A case-sensitive filter on the list based on the customer's `email` field. The value must be a string.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- test_clock: NotRequired[str]
- """
- Provides a list of customers that are associated with the specified test clock. The response will not include customers with test clocks if this parameter is not set.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SearchParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- page: NotRequired[str]
- """
- A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
- """
- query: str
- """
- The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for customers](https://stripe.com/docs/search#query-fields-for-customers).
- """
-
- class UpdateParams(TypedDict):
- address: NotRequired["Literal['']|CustomerService.UpdateParamsAddress"]
- """
- The customer's address.
- """
- balance: NotRequired[int]
- """
- An integer amount in cents (or local equivalent) that represents the customer's current balance, which affect the customer's future invoices. A negative amount represents a credit that decreases the amount due on an invoice; a positive amount increases the amount due on an invoice.
- """
- business_name: NotRequired["Literal['']|str"]
- """
- The customer's business name. This may be up to *150 characters*.
- """
- cash_balance: NotRequired["CustomerService.UpdateParamsCashBalance"]
- """
- Balance information and default balance settings for this customer.
- """
- default_source: NotRequired[str]
- """
- If you are using payment methods created via the PaymentMethods API, see the [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method) parameter.
-
- Provide the ID of a payment source already attached to this customer to make it this customer's default payment source.
-
- If you want to add a new payment source and make it the default, see the [source](https://stripe.com/docs/api/customers/update#update_customer-source) property.
- """
- description: NotRequired[str]
- """
- An arbitrary string that you can attach to a customer object. It is displayed alongside the customer in the dashboard.
- """
- email: NotRequired[str]
- """
- Customer's email address. It's displayed alongside the customer in your dashboard and can be useful for searching and tracking. This may be up to *512 characters*.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- individual_name: NotRequired["Literal['']|str"]
- """
- The customer's full name. This may be up to *150 characters*.
- """
- invoice_prefix: NotRequired[str]
- """
- The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.
- """
- invoice_settings: NotRequired[
- "CustomerService.UpdateParamsInvoiceSettings"
- ]
- """
- Default invoice settings for this customer.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- The customer's full name or business name.
- """
- next_invoice_sequence: NotRequired[int]
- """
- The sequence to be used on the customer's next invoice. Defaults to 1.
- """
- phone: NotRequired[str]
- """
- The customer's phone number.
- """
- preferred_locales: NotRequired[List[str]]
- """
- Customer's preferred languages, ordered by preference.
- """
- shipping: NotRequired[
- "Literal['']|CustomerService.UpdateParamsShipping"
- ]
- """
- The customer's shipping information. Appears on invoices emailed to this customer.
- """
- source: NotRequired[str]
- tax: NotRequired["CustomerService.UpdateParamsTax"]
- """
- Tax details about the customer.
- """
- tax_exempt: NotRequired[
- "Literal['']|Literal['exempt', 'none', 'reverse']"
- ]
- """
- The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
- """
- validate: NotRequired[bool]
-
- class UpdateParamsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsCashBalance(TypedDict):
- settings: NotRequired[
- "CustomerService.UpdateParamsCashBalanceSettings"
- ]
- """
- Settings controlling the behavior of the customer's cash balance,
- such as reconciliation of funds received.
- """
-
- class UpdateParamsCashBalanceSettings(TypedDict):
- reconciliation_mode: NotRequired[
- Literal["automatic", "manual", "merchant_default"]
- ]
- """
- Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
- """
-
- class UpdateParamsInvoiceSettings(TypedDict):
- custom_fields: NotRequired[
- "Literal['']|List[CustomerService.UpdateParamsInvoiceSettingsCustomField]"
- ]
- """
- The list of up to 4 default custom fields to be displayed on invoices for this customer. When updating, pass an empty string to remove previously-defined fields.
- """
- default_payment_method: NotRequired[str]
- """
- ID of a payment method that's attached to the customer, to be used as the customer's default payment method for subscriptions and invoices.
- """
- footer: NotRequired[str]
- """
- Default footer to be displayed on invoices for this customer.
- """
- rendering_options: NotRequired[
- "Literal['']|CustomerService.UpdateParamsInvoiceSettingsRenderingOptions"
- ]
- """
- Default options for invoice PDF rendering for this customer.
- """
-
- class UpdateParamsInvoiceSettingsCustomField(TypedDict):
- name: str
- """
- The name of the custom field. This may be up to 40 characters.
- """
- value: str
- """
- The value of the custom field. This may be up to 140 characters.
- """
-
- class UpdateParamsInvoiceSettingsRenderingOptions(TypedDict):
- amount_tax_display: NotRequired[
- "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
- ]
- """
- How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
- """
- template: NotRequired[str]
- """
- ID of the invoice rendering template to use for future invoices.
- """
-
- class UpdateParamsShipping(TypedDict):
- address: "CustomerService.UpdateParamsShippingAddress"
- """
- Customer shipping address.
- """
- name: str
- """
- Customer name.
- """
- phone: NotRequired[str]
- """
- Customer phone (including extension).
- """
-
- class UpdateParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsTax(TypedDict):
- ip_address: NotRequired["Literal['']|str"]
- """
- A recent IP address of the customer used for tax reporting and tax location inference. Stripe recommends updating the IP address when a new PaymentMethod is attached or the address field on the customer is updated. We recommend against updating this field more frequently since it could result in unexpected tax location/reporting outcomes.
- """
- validate_location: NotRequired[
- Literal["auto", "deferred", "immediately"]
- ]
- """
- A flag that indicates when Stripe should validate the customer tax location. Defaults to `auto`.
- """
-
def delete(
self,
customer: str,
- params: Optional["CustomerService.DeleteParams"] = None,
+ params: Optional["CustomerDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Customer:
"""
@@ -728,7 +81,7 @@ def delete(
async def delete_async(
self,
customer: str,
- params: Optional["CustomerService.DeleteParams"] = None,
+ params: Optional["CustomerDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Customer:
"""
@@ -750,7 +103,7 @@ async def delete_async(
def retrieve(
self,
customer: str,
- params: Optional["CustomerService.RetrieveParams"] = None,
+ params: Optional["CustomerRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Customer:
"""
@@ -772,7 +125,7 @@ def retrieve(
async def retrieve_async(
self,
customer: str,
- params: Optional["CustomerService.RetrieveParams"] = None,
+ params: Optional["CustomerRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Customer:
"""
@@ -794,7 +147,7 @@ async def retrieve_async(
def update(
self,
customer: str,
- params: Optional["CustomerService.UpdateParams"] = None,
+ params: Optional["CustomerUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Customer:
"""
@@ -818,7 +171,7 @@ def update(
async def update_async(
self,
customer: str,
- params: Optional["CustomerService.UpdateParams"] = None,
+ params: Optional["CustomerUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Customer:
"""
@@ -842,7 +195,7 @@ async def update_async(
def delete_discount(
self,
customer: str,
- params: Optional["CustomerService.DeleteDiscountParams"] = None,
+ params: Optional["CustomerDeleteDiscountParams"] = None,
options: Optional[RequestOptions] = None,
) -> Discount:
"""
@@ -864,7 +217,7 @@ def delete_discount(
async def delete_discount_async(
self,
customer: str,
- params: Optional["CustomerService.DeleteDiscountParams"] = None,
+ params: Optional["CustomerDeleteDiscountParams"] = None,
options: Optional[RequestOptions] = None,
) -> Discount:
"""
@@ -885,7 +238,7 @@ async def delete_discount_async(
def list(
self,
- params: Optional["CustomerService.ListParams"] = None,
+ params: Optional["CustomerListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Customer]:
"""
@@ -904,7 +257,7 @@ def list(
async def list_async(
self,
- params: Optional["CustomerService.ListParams"] = None,
+ params: Optional["CustomerListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Customer]:
"""
@@ -923,7 +276,7 @@ async def list_async(
def create(
self,
- params: Optional["CustomerService.CreateParams"] = None,
+ params: Optional["CustomerCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Customer:
"""
@@ -942,7 +295,7 @@ def create(
async def create_async(
self,
- params: Optional["CustomerService.CreateParams"] = None,
+ params: Optional["CustomerCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Customer:
"""
@@ -961,7 +314,7 @@ async def create_async(
def search(
self,
- params: "CustomerService.SearchParams",
+ params: "CustomerSearchParams",
options: Optional[RequestOptions] = None,
) -> SearchResultObject[Customer]:
"""
@@ -983,7 +336,7 @@ def search(
async def search_async(
self,
- params: "CustomerService.SearchParams",
+ params: "CustomerSearchParams",
options: Optional[RequestOptions] = None,
) -> SearchResultObject[Customer]:
"""
diff --git a/stripe/_customer_session.py b/stripe/_customer_session.py
index 04c201cd6..cd7006264 100644
--- a/stripe/_customer_session.py
+++ b/stripe/_customer_session.py
@@ -2,19 +2,15 @@
# File generated from our OpenAPI spec
from stripe._createable_api_resource import CreateableAPIResource
from stripe._expandable_field import ExpandableField
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from typing import ClassVar, List, Optional, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._customer import Customer
+ from stripe.params._customer_session_create_params import (
+ CustomerSessionCreateParams,
+ )
class CustomerSession(CreateableAPIResource["CustomerSession"]):
@@ -109,102 +105,6 @@ class PricingTable(StripeObject):
"pricing_table": PricingTable,
}
- class CreateParams(RequestOptions):
- components: "CustomerSession.CreateParamsComponents"
- """
- Configuration for each component. Exactly 1 component must be enabled.
- """
- customer: str
- """
- The ID of an existing customer for which to create the Customer Session.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParamsComponents(TypedDict):
- buy_button: NotRequired[
- "CustomerSession.CreateParamsComponentsBuyButton"
- ]
- """
- Configuration for buy button.
- """
- payment_element: NotRequired[
- "CustomerSession.CreateParamsComponentsPaymentElement"
- ]
- """
- Configuration for the Payment Element.
- """
- pricing_table: NotRequired[
- "CustomerSession.CreateParamsComponentsPricingTable"
- ]
- """
- Configuration for the pricing table.
- """
-
- class CreateParamsComponentsBuyButton(TypedDict):
- enabled: bool
- """
- Whether the buy button is enabled.
- """
-
- class CreateParamsComponentsPaymentElement(TypedDict):
- enabled: bool
- """
- Whether the Payment Element is enabled.
- """
- features: NotRequired[
- "CustomerSession.CreateParamsComponentsPaymentElementFeatures"
- ]
- """
- This hash defines whether the Payment Element supports certain features.
- """
-
- class CreateParamsComponentsPaymentElementFeatures(TypedDict):
- payment_method_allow_redisplay_filters: NotRequired[
- List[Literal["always", "limited", "unspecified"]]
- ]
- """
- A list of [`allow_redisplay`](https://docs.stripe.com/api/payment_methods/object#payment_method_object-allow_redisplay) values that controls which saved payment methods the Payment Element displays by filtering to only show payment methods with an `allow_redisplay` value that is present in this list.
-
- If not specified, defaults to ["always"]. In order to display all saved payment methods, specify ["always", "limited", "unspecified"].
- """
- payment_method_redisplay: NotRequired[Literal["disabled", "enabled"]]
- """
- Controls whether or not the Payment Element shows saved payment methods. This parameter defaults to `disabled`.
- """
- payment_method_redisplay_limit: NotRequired[int]
- """
- Determines the max number of saved payment methods for the Payment Element to display. This parameter defaults to `3`. The maximum redisplay limit is `10`.
- """
- payment_method_remove: NotRequired[Literal["disabled", "enabled"]]
- """
- Controls whether the Payment Element displays the option to remove a saved payment method. This parameter defaults to `disabled`.
-
- Allowing buyers to remove their saved payment methods impacts subscriptions that depend on that payment method. Removing the payment method detaches the [`customer` object](https://docs.stripe.com/api/payment_methods/object#payment_method_object-customer) from that [PaymentMethod](https://docs.stripe.com/api/payment_methods).
- """
- payment_method_save: NotRequired[Literal["disabled", "enabled"]]
- """
- Controls whether the Payment Element displays a checkbox offering to save a new payment method. This parameter defaults to `disabled`.
-
- If a customer checks the box, the [`allow_redisplay`](https://docs.stripe.com/api/payment_methods/object#payment_method_object-allow_redisplay) value on the PaymentMethod is set to `'always'` at confirmation time. For PaymentIntents, the [`setup_future_usage`](https://docs.stripe.com/api/payment_intents/object#payment_intent_object-setup_future_usage) value is also set to the value defined in `payment_method_save_usage`.
- """
- payment_method_save_usage: NotRequired[
- Literal["off_session", "on_session"]
- ]
- """
- When using PaymentIntents and the customer checks the save checkbox, this field determines the [`setup_future_usage`](https://docs.stripe.com/api/payment_intents/object#payment_intent_object-setup_future_usage) value used to confirm the PaymentIntent.
-
- When using SetupIntents, directly configure the [`usage`](https://docs.stripe.com/api/setup_intents/object#setup_intent_object-usage) value on SetupIntent creation.
- """
-
- class CreateParamsComponentsPricingTable(TypedDict):
- enabled: bool
- """
- Whether the pricing table is enabled.
- """
-
client_secret: str
"""
The client secret of this Customer Session. Used on the client to set up secure access to the given `customer`.
@@ -238,7 +138,7 @@ class CreateParamsComponentsPricingTable(TypedDict):
@classmethod
def create(
- cls, **params: Unpack["CustomerSession.CreateParams"]
+ cls, **params: Unpack["CustomerSessionCreateParams"]
) -> "CustomerSession":
"""
Creates a Customer Session object that includes a single-use client secret that you can use on your front-end to grant client-side API access for certain customer resources.
@@ -254,7 +154,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["CustomerSession.CreateParams"]
+ cls, **params: Unpack["CustomerSessionCreateParams"]
) -> "CustomerSession":
"""
Creates a Customer Session object that includes a single-use client secret that you can use on your front-end to grant client-side API access for certain customer resources.
diff --git a/stripe/_customer_session_service.py b/stripe/_customer_session_service.py
index 28180697d..61d8e9cc1 100644
--- a/stripe/_customer_session_service.py
+++ b/stripe/_customer_session_service.py
@@ -3,110 +3,19 @@
from stripe._customer_session import CustomerSession
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._customer_session_create_params import (
+ CustomerSessionCreateParams,
+ )
-class CustomerSessionService(StripeService):
- class CreateParams(TypedDict):
- components: "CustomerSessionService.CreateParamsComponents"
- """
- Configuration for each component. Exactly 1 component must be enabled.
- """
- customer: str
- """
- The ID of an existing customer for which to create the Customer Session.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParamsComponents(TypedDict):
- buy_button: NotRequired[
- "CustomerSessionService.CreateParamsComponentsBuyButton"
- ]
- """
- Configuration for buy button.
- """
- payment_element: NotRequired[
- "CustomerSessionService.CreateParamsComponentsPaymentElement"
- ]
- """
- Configuration for the Payment Element.
- """
- pricing_table: NotRequired[
- "CustomerSessionService.CreateParamsComponentsPricingTable"
- ]
- """
- Configuration for the pricing table.
- """
-
- class CreateParamsComponentsBuyButton(TypedDict):
- enabled: bool
- """
- Whether the buy button is enabled.
- """
-
- class CreateParamsComponentsPaymentElement(TypedDict):
- enabled: bool
- """
- Whether the Payment Element is enabled.
- """
- features: NotRequired[
- "CustomerSessionService.CreateParamsComponentsPaymentElementFeatures"
- ]
- """
- This hash defines whether the Payment Element supports certain features.
- """
-
- class CreateParamsComponentsPaymentElementFeatures(TypedDict):
- payment_method_allow_redisplay_filters: NotRequired[
- List[Literal["always", "limited", "unspecified"]]
- ]
- """
- A list of [`allow_redisplay`](https://docs.stripe.com/api/payment_methods/object#payment_method_object-allow_redisplay) values that controls which saved payment methods the Payment Element displays by filtering to only show payment methods with an `allow_redisplay` value that is present in this list.
-
- If not specified, defaults to ["always"]. In order to display all saved payment methods, specify ["always", "limited", "unspecified"].
- """
- payment_method_redisplay: NotRequired[Literal["disabled", "enabled"]]
- """
- Controls whether or not the Payment Element shows saved payment methods. This parameter defaults to `disabled`.
- """
- payment_method_redisplay_limit: NotRequired[int]
- """
- Determines the max number of saved payment methods for the Payment Element to display. This parameter defaults to `3`. The maximum redisplay limit is `10`.
- """
- payment_method_remove: NotRequired[Literal["disabled", "enabled"]]
- """
- Controls whether the Payment Element displays the option to remove a saved payment method. This parameter defaults to `disabled`.
-
- Allowing buyers to remove their saved payment methods impacts subscriptions that depend on that payment method. Removing the payment method detaches the [`customer` object](https://docs.stripe.com/api/payment_methods/object#payment_method_object-customer) from that [PaymentMethod](https://docs.stripe.com/api/payment_methods).
- """
- payment_method_save: NotRequired[Literal["disabled", "enabled"]]
- """
- Controls whether the Payment Element displays a checkbox offering to save a new payment method. This parameter defaults to `disabled`.
-
- If a customer checks the box, the [`allow_redisplay`](https://docs.stripe.com/api/payment_methods/object#payment_method_object-allow_redisplay) value on the PaymentMethod is set to `'always'` at confirmation time. For PaymentIntents, the [`setup_future_usage`](https://docs.stripe.com/api/payment_intents/object#payment_intent_object-setup_future_usage) value is also set to the value defined in `payment_method_save_usage`.
- """
- payment_method_save_usage: NotRequired[
- Literal["off_session", "on_session"]
- ]
- """
- When using PaymentIntents and the customer checks the save checkbox, this field determines the [`setup_future_usage`](https://docs.stripe.com/api/payment_intents/object#payment_intent_object-setup_future_usage) value used to confirm the PaymentIntent.
-
- When using SetupIntents, directly configure the [`usage`](https://docs.stripe.com/api/setup_intents/object#setup_intent_object-usage) value on SetupIntent creation.
- """
-
- class CreateParamsComponentsPricingTable(TypedDict):
- enabled: bool
- """
- Whether the pricing table is enabled.
- """
+class CustomerSessionService(StripeService):
def create(
self,
- params: "CustomerSessionService.CreateParams",
+ params: "CustomerSessionCreateParams",
options: Optional[RequestOptions] = None,
) -> CustomerSession:
"""
@@ -125,7 +34,7 @@ def create(
async def create_async(
self,
- params: "CustomerSessionService.CreateParams",
+ params: "CustomerSessionCreateParams",
options: Optional[RequestOptions] = None,
) -> CustomerSession:
"""
diff --git a/stripe/_customer_tax_id_service.py b/stripe/_customer_tax_id_service.py
index 215f8c386..99c5088c7 100644
--- a/stripe/_customer_tax_id_service.py
+++ b/stripe/_customer_tax_id_service.py
@@ -5,168 +5,30 @@
from stripe._stripe_service import StripeService
from stripe._tax_id import TaxId
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._customer_tax_id_create_params import (
+ CustomerTaxIdCreateParams,
+ )
+ from stripe.params._customer_tax_id_delete_params import (
+ CustomerTaxIdDeleteParams,
+ )
+ from stripe.params._customer_tax_id_list_params import (
+ CustomerTaxIdListParams,
+ )
+ from stripe.params._customer_tax_id_retrieve_params import (
+ CustomerTaxIdRetrieveParams,
+ )
-class CustomerTaxIdService(StripeService):
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- type: Literal[
- "ad_nrt",
- "ae_trn",
- "al_tin",
- "am_tin",
- "ao_tin",
- "ar_cuit",
- "au_abn",
- "au_arn",
- "aw_tin",
- "az_tin",
- "ba_tin",
- "bb_tin",
- "bd_bin",
- "bf_ifu",
- "bg_uic",
- "bh_vat",
- "bj_ifu",
- "bo_tin",
- "br_cnpj",
- "br_cpf",
- "bs_tin",
- "by_tin",
- "ca_bn",
- "ca_gst_hst",
- "ca_pst_bc",
- "ca_pst_mb",
- "ca_pst_sk",
- "ca_qst",
- "cd_nif",
- "ch_uid",
- "ch_vat",
- "cl_tin",
- "cm_niu",
- "cn_tin",
- "co_nit",
- "cr_tin",
- "cv_nif",
- "de_stn",
- "do_rcn",
- "ec_ruc",
- "eg_tin",
- "es_cif",
- "et_tin",
- "eu_oss_vat",
- "eu_vat",
- "gb_vat",
- "ge_vat",
- "gn_nif",
- "hk_br",
- "hr_oib",
- "hu_tin",
- "id_npwp",
- "il_vat",
- "in_gst",
- "is_vat",
- "jp_cn",
- "jp_rn",
- "jp_trn",
- "ke_pin",
- "kg_tin",
- "kh_tin",
- "kr_brn",
- "kz_bin",
- "la_tin",
- "li_uid",
- "li_vat",
- "ma_vat",
- "md_vat",
- "me_pib",
- "mk_vat",
- "mr_nif",
- "mx_rfc",
- "my_frp",
- "my_itn",
- "my_sst",
- "ng_tin",
- "no_vat",
- "no_voec",
- "np_pan",
- "nz_gst",
- "om_vat",
- "pe_ruc",
- "ph_tin",
- "ro_tin",
- "rs_pib",
- "ru_inn",
- "ru_kpp",
- "sa_vat",
- "sg_gst",
- "sg_uen",
- "si_tin",
- "sn_ninea",
- "sr_fin",
- "sv_nit",
- "th_vat",
- "tj_tin",
- "tr_tin",
- "tw_vat",
- "tz_vat",
- "ua_vat",
- "ug_tin",
- "us_ein",
- "uy_ruc",
- "uz_tin",
- "uz_vat",
- "ve_rif",
- "vn_tin",
- "za_vat",
- "zm_tin",
- "zw_tin",
- ]
- """
- Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
- """
- value: str
- """
- Value of the tax ID.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class CustomerTaxIdService(StripeService):
def delete(
self,
customer: str,
id: str,
- params: Optional["CustomerTaxIdService.DeleteParams"] = None,
+ params: Optional["CustomerTaxIdDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> TaxId:
"""
@@ -190,7 +52,7 @@ async def delete_async(
self,
customer: str,
id: str,
- params: Optional["CustomerTaxIdService.DeleteParams"] = None,
+ params: Optional["CustomerTaxIdDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> TaxId:
"""
@@ -214,7 +76,7 @@ def retrieve(
self,
customer: str,
id: str,
- params: Optional["CustomerTaxIdService.RetrieveParams"] = None,
+ params: Optional["CustomerTaxIdRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> TaxId:
"""
@@ -238,7 +100,7 @@ async def retrieve_async(
self,
customer: str,
id: str,
- params: Optional["CustomerTaxIdService.RetrieveParams"] = None,
+ params: Optional["CustomerTaxIdRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> TaxId:
"""
@@ -261,7 +123,7 @@ async def retrieve_async(
def list(
self,
customer: str,
- params: Optional["CustomerTaxIdService.ListParams"] = None,
+ params: Optional["CustomerTaxIdListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[TaxId]:
"""
@@ -283,7 +145,7 @@ def list(
async def list_async(
self,
customer: str,
- params: Optional["CustomerTaxIdService.ListParams"] = None,
+ params: Optional["CustomerTaxIdListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[TaxId]:
"""
@@ -305,7 +167,7 @@ async def list_async(
def create(
self,
customer: str,
- params: "CustomerTaxIdService.CreateParams",
+ params: "CustomerTaxIdCreateParams",
options: Optional[RequestOptions] = None,
) -> TaxId:
"""
@@ -327,7 +189,7 @@ def create(
async def create_async(
self,
customer: str,
- params: "CustomerTaxIdService.CreateParams",
+ params: "CustomerTaxIdCreateParams",
options: Optional[RequestOptions] = None,
) -> TaxId:
"""
diff --git a/stripe/_dispute.py b/stripe/_dispute.py
index 589c08f8c..9c519b4a7 100644
--- a/stripe/_dispute.py
+++ b/stripe/_dispute.py
@@ -3,24 +3,21 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._balance_transaction import BalanceTransaction
from stripe._charge import Charge
from stripe._file import File
from stripe._payment_intent import PaymentIntent
+ from stripe.params._dispute_close_params import DisputeCloseParams
+ from stripe.params._dispute_list_params import DisputeListParams
+ from stripe.params._dispute_modify_params import DisputeModifyParams
+ from stripe.params._dispute_retrieve_params import DisputeRetrieveParams
class Dispute(
@@ -414,372 +411,6 @@ class Paypal(StripeObject):
"paypal": Paypal,
}
- class CloseParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(RequestOptions):
- charge: NotRequired[str]
- """
- Only return disputes associated to the charge specified by this charge ID.
- """
- created: NotRequired["Dispute.ListParamsCreated|int"]
- """
- Only return disputes that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payment_intent: NotRequired[str]
- """
- Only return disputes associated to the PaymentIntent specified by this PaymentIntent ID.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- evidence: NotRequired["Dispute.ModifyParamsEvidence"]
- """
- Evidence to upload, to respond to a dispute. Updating any field in the hash will submit all fields in the hash for review. The combined character count of all fields is limited to 150,000.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- submit: NotRequired[bool]
- """
- Whether to immediately submit evidence to the bank. If `false`, evidence is staged on the dispute. Staged evidence is visible in the API and Dashboard, and can be submitted to the bank by making another request with this attribute set to `true` (the default).
- """
-
- class ModifyParamsEvidence(TypedDict):
- access_activity_log: NotRequired[str]
- """
- Any server or activity logs showing proof that the customer accessed or downloaded the purchased digital product. This information should include IP addresses, corresponding timestamps, and any detailed recorded activity. Has a maximum character count of 20,000.
- """
- billing_address: NotRequired[str]
- """
- The billing address provided by the customer.
- """
- cancellation_policy: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your subscription cancellation policy, as shown to the customer.
- """
- cancellation_policy_disclosure: NotRequired[str]
- """
- An explanation of how and when the customer was shown your refund policy prior to purchase. Has a maximum character count of 20,000.
- """
- cancellation_rebuttal: NotRequired[str]
- """
- A justification for why the customer's subscription was not canceled. Has a maximum character count of 20,000.
- """
- customer_communication: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any communication with the customer that you feel is relevant to your case. Examples include emails proving that the customer received the product or service, or demonstrating their use of or satisfaction with the product or service.
- """
- customer_email_address: NotRequired[str]
- """
- The email address of the customer.
- """
- customer_name: NotRequired[str]
- """
- The name of the customer.
- """
- customer_purchase_ip: NotRequired[str]
- """
- The IP address that the customer used when making the purchase.
- """
- customer_signature: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A relevant document or contract showing the customer's signature.
- """
- duplicate_charge_documentation: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation for the prior charge that can uniquely identify the charge, such as a receipt, shipping label, work order, etc. This document should be paired with a similar document from the disputed payment that proves the two payments are separate.
- """
- duplicate_charge_explanation: NotRequired[str]
- """
- An explanation of the difference between the disputed charge versus the prior charge that appears to be a duplicate. Has a maximum character count of 20,000.
- """
- duplicate_charge_id: NotRequired[str]
- """
- The Stripe ID for the prior charge which appears to be a duplicate of the disputed charge.
- """
- enhanced_evidence: NotRequired[
- "Literal['']|Dispute.ModifyParamsEvidenceEnhancedEvidence"
- ]
- """
- Additional evidence for qualifying evidence programs.
- """
- product_description: NotRequired[str]
- """
- A description of the product or service that was sold. Has a maximum character count of 20,000.
- """
- receipt: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any receipt or message sent to the customer notifying them of the charge.
- """
- refund_policy: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your refund policy, as shown to the customer.
- """
- refund_policy_disclosure: NotRequired[str]
- """
- Documentation demonstrating that the customer was shown your refund policy prior to purchase. Has a maximum character count of 20,000.
- """
- refund_refusal_explanation: NotRequired[str]
- """
- A justification for why the customer is not entitled to a refund. Has a maximum character count of 20,000.
- """
- service_date: NotRequired[str]
- """
- The date on which the customer received or began receiving the purchased service, in a clear human-readable format.
- """
- service_documentation: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a service was provided to the customer. This could include a copy of a signed contract, work order, or other form of written agreement.
- """
- shipping_address: NotRequired[str]
- """
- The address to which a physical product was shipped. You should try to include as complete address information as possible.
- """
- shipping_carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc. If multiple carriers were used for this purchase, please separate them with commas.
- """
- shipping_date: NotRequired[str]
- """
- The date on which a physical product began its route to the shipping address, in a clear human-readable format.
- """
- shipping_documentation: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a product was shipped to the customer at the same address the customer provided to you. This could include a copy of the shipment receipt, shipping label, etc. It should show the customer's full shipping address, if possible.
- """
- shipping_tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
- uncategorized_file: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any additional evidence or statements.
- """
- uncategorized_text: NotRequired[str]
- """
- Any additional evidence or statements. Has a maximum character count of 20,000.
- """
-
- class ModifyParamsEvidenceEnhancedEvidence(TypedDict):
- visa_compelling_evidence_3: NotRequired[
- "Dispute.ModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3"
- ]
- """
- Evidence provided for Visa Compelling Evidence 3.0 evidence submission.
- """
- visa_compliance: NotRequired[
- "Dispute.ModifyParamsEvidenceEnhancedEvidenceVisaCompliance"
- ]
- """
- Evidence provided for Visa compliance evidence submission.
- """
-
- class ModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3(
- TypedDict,
- ):
- disputed_transaction: NotRequired[
- "Dispute.ModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransaction"
- ]
- """
- Disputed transaction details for Visa Compelling Evidence 3.0 evidence submission.
- """
- prior_undisputed_transactions: NotRequired[
- List[
- "Dispute.ModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransaction"
- ]
- ]
- """
- List of exactly two prior undisputed transaction objects for Visa Compelling Evidence 3.0 evidence submission.
- """
-
- class ModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransaction(
- TypedDict,
- ):
- customer_account_id: NotRequired["Literal['']|str"]
- """
- User Account ID used to log into business platform. Must be recognizable by the user.
- """
- customer_device_fingerprint: NotRequired["Literal['']|str"]
- """
- Unique identifier of the cardholder's device derived from a combination of at least two hardware and software attributes. Must be at least 20 characters.
- """
- customer_device_id: NotRequired["Literal['']|str"]
- """
- Unique identifier of the cardholder's device such as a device serial number (e.g., International Mobile Equipment Identity [IMEI]). Must be at least 15 characters.
- """
- customer_email_address: NotRequired["Literal['']|str"]
- """
- The email address of the customer.
- """
- customer_purchase_ip: NotRequired["Literal['']|str"]
- """
- The IP address that the customer used when making the purchase.
- """
- merchandise_or_services: NotRequired[
- Literal["merchandise", "services"]
- ]
- """
- Categorization of disputed payment.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- A description of the product or service that was sold.
- """
- shipping_address: NotRequired[
- "Dispute.ModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransactionShippingAddress"
- ]
- """
- The address to which a physical product was shipped. All fields are required for Visa Compelling Evidence 3.0 evidence submission.
- """
-
- class ModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransactionShippingAddress(
- TypedDict,
- ):
- city: NotRequired["Literal['']|str"]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired["Literal['']|str"]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired["Literal['']|str"]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired["Literal['']|str"]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired["Literal['']|str"]
- """
- ZIP or postal code.
- """
- state: NotRequired["Literal['']|str"]
- """
- State, county, province, or region.
- """
-
- class ModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransaction(
- TypedDict,
- ):
- charge: str
- """
- Stripe charge ID for the Visa Compelling Evidence 3.0 eligible prior charge.
- """
- customer_account_id: NotRequired["Literal['']|str"]
- """
- User Account ID used to log into business platform. Must be recognizable by the user.
- """
- customer_device_fingerprint: NotRequired["Literal['']|str"]
- """
- Unique identifier of the cardholder's device derived from a combination of at least two hardware and software attributes. Must be at least 20 characters.
- """
- customer_device_id: NotRequired["Literal['']|str"]
- """
- Unique identifier of the cardholder's device such as a device serial number (e.g., International Mobile Equipment Identity [IMEI]). Must be at least 15 characters.
- """
- customer_email_address: NotRequired["Literal['']|str"]
- """
- The email address of the customer.
- """
- customer_purchase_ip: NotRequired["Literal['']|str"]
- """
- The IP address that the customer used when making the purchase.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- A description of the product or service that was sold.
- """
- shipping_address: NotRequired[
- "Dispute.ModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransactionShippingAddress"
- ]
- """
- The address to which a physical product was shipped. All fields are required for Visa Compelling Evidence 3.0 evidence submission.
- """
-
- class ModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransactionShippingAddress(
- TypedDict,
- ):
- city: NotRequired["Literal['']|str"]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired["Literal['']|str"]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired["Literal['']|str"]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired["Literal['']|str"]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired["Literal['']|str"]
- """
- ZIP or postal code.
- """
- state: NotRequired["Literal['']|str"]
- """
- State, county, province, or region.
- """
-
- class ModifyParamsEvidenceEnhancedEvidenceVisaCompliance(TypedDict):
- fee_acknowledged: NotRequired[bool]
- """
- A field acknowledging the fee incurred when countering a Visa compliance dispute. If this field is set to true, evidence can be submitted for the compliance dispute. Stripe collects a 500 USD (or local equivalent) amount to cover the network costs associated with resolving compliance disputes. Stripe refunds the 500 USD network fee if you win the dispute.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount: int
"""
Disputed amount. Usually the amount of the charge, but it can differ (usually because of currency fluctuation or because only part of the order is disputed).
@@ -857,7 +488,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def _cls_close(
- cls, dispute: str, **params: Unpack["Dispute.CloseParams"]
+ 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, acknowledging it as lost.
@@ -878,7 +509,7 @@ def _cls_close(
@overload
@staticmethod
def close(
- dispute: str, **params: Unpack["Dispute.CloseParams"]
+ 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, acknowledging it as lost.
@@ -888,7 +519,7 @@ def close(
...
@overload
- def close(self, **params: Unpack["Dispute.CloseParams"]) -> "Dispute":
+ def close(self, **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, acknowledging it as lost.
@@ -898,7 +529,7 @@ def close(self, **params: Unpack["Dispute.CloseParams"]) -> "Dispute":
@class_method_variant("_cls_close")
def close( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Dispute.CloseParams"]
+ self, **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, acknowledging it as lost.
@@ -918,7 +549,7 @@ def close( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_close_async(
- cls, dispute: str, **params: Unpack["Dispute.CloseParams"]
+ 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, acknowledging it as lost.
@@ -939,7 +570,7 @@ async def _cls_close_async(
@overload
@staticmethod
async def close_async(
- dispute: str, **params: Unpack["Dispute.CloseParams"]
+ 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, acknowledging it as lost.
@@ -950,7 +581,7 @@ async def close_async(
@overload
async def close_async(
- self, **params: Unpack["Dispute.CloseParams"]
+ self, **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, acknowledging it as lost.
@@ -961,7 +592,7 @@ async def close_async(
@class_method_variant("_cls_close_async")
async def close_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Dispute.CloseParams"]
+ self, **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, acknowledging it as lost.
@@ -981,7 +612,7 @@ async def close_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["Dispute.ListParams"]
+ cls, **params: Unpack["DisputeListParams"]
) -> ListObject["Dispute"]:
"""
Returns a list of your disputes.
@@ -1001,7 +632,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Dispute.ListParams"]
+ cls, **params: Unpack["DisputeListParams"]
) -> ListObject["Dispute"]:
"""
Returns a list of your disputes.
@@ -1021,7 +652,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Dispute.ModifyParams"]
+ cls, id: str, **params: Unpack["DisputeModifyParams"]
) -> "Dispute":
"""
When you get a dispute, contacting your customer is always the best first step. If that doesn't work, you can submit evidence to help us resolve the dispute in your favor. You can do this in your [dashboard](https://dashboard.stripe.com/disputes), but if you prefer, you can use the API to submit evidence programmatically.
@@ -1040,7 +671,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Dispute.ModifyParams"]
+ cls, id: str, **params: Unpack["DisputeModifyParams"]
) -> "Dispute":
"""
When you get a dispute, contacting your customer is always the best first step. If that doesn't work, you can submit evidence to help us resolve the dispute in your favor. You can do this in your [dashboard](https://dashboard.stripe.com/disputes), but if you prefer, you can use the API to submit evidence programmatically.
@@ -1059,7 +690,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Dispute.RetrieveParams"]
+ cls, id: str, **params: Unpack["DisputeRetrieveParams"]
) -> "Dispute":
"""
Retrieves the dispute with the given ID.
@@ -1070,7 +701,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Dispute.RetrieveParams"]
+ cls, id: str, **params: Unpack["DisputeRetrieveParams"]
) -> "Dispute":
"""
Retrieves the dispute with the given ID.
diff --git a/stripe/_dispute_service.py b/stripe/_dispute_service.py
index 57a0fec4c..706140dc3 100644
--- a/stripe/_dispute_service.py
+++ b/stripe/_dispute_service.py
@@ -5,380 +5,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._dispute_close_params import DisputeCloseParams
+ from stripe.params._dispute_list_params import DisputeListParams
+ from stripe.params._dispute_retrieve_params import DisputeRetrieveParams
+ from stripe.params._dispute_update_params import DisputeUpdateParams
-class DisputeService(StripeService):
- class CloseParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(TypedDict):
- charge: NotRequired[str]
- """
- Only return disputes associated to the charge specified by this charge ID.
- """
- created: NotRequired["DisputeService.ListParamsCreated|int"]
- """
- Only return disputes that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payment_intent: NotRequired[str]
- """
- Only return disputes associated to the PaymentIntent specified by this PaymentIntent ID.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- evidence: NotRequired["DisputeService.UpdateParamsEvidence"]
- """
- Evidence to upload, to respond to a dispute. Updating any field in the hash will submit all fields in the hash for review. The combined character count of all fields is limited to 150,000.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- submit: NotRequired[bool]
- """
- Whether to immediately submit evidence to the bank. If `false`, evidence is staged on the dispute. Staged evidence is visible in the API and Dashboard, and can be submitted to the bank by making another request with this attribute set to `true` (the default).
- """
-
- class UpdateParamsEvidence(TypedDict):
- access_activity_log: NotRequired[str]
- """
- Any server or activity logs showing proof that the customer accessed or downloaded the purchased digital product. This information should include IP addresses, corresponding timestamps, and any detailed recorded activity. Has a maximum character count of 20,000.
- """
- billing_address: NotRequired[str]
- """
- The billing address provided by the customer.
- """
- cancellation_policy: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your subscription cancellation policy, as shown to the customer.
- """
- cancellation_policy_disclosure: NotRequired[str]
- """
- An explanation of how and when the customer was shown your refund policy prior to purchase. Has a maximum character count of 20,000.
- """
- cancellation_rebuttal: NotRequired[str]
- """
- A justification for why the customer's subscription was not canceled. Has a maximum character count of 20,000.
- """
- customer_communication: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any communication with the customer that you feel is relevant to your case. Examples include emails proving that the customer received the product or service, or demonstrating their use of or satisfaction with the product or service.
- """
- customer_email_address: NotRequired[str]
- """
- The email address of the customer.
- """
- customer_name: NotRequired[str]
- """
- The name of the customer.
- """
- customer_purchase_ip: NotRequired[str]
- """
- The IP address that the customer used when making the purchase.
- """
- customer_signature: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A relevant document or contract showing the customer's signature.
- """
- duplicate_charge_documentation: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation for the prior charge that can uniquely identify the charge, such as a receipt, shipping label, work order, etc. This document should be paired with a similar document from the disputed payment that proves the two payments are separate.
- """
- duplicate_charge_explanation: NotRequired[str]
- """
- An explanation of the difference between the disputed charge versus the prior charge that appears to be a duplicate. Has a maximum character count of 20,000.
- """
- duplicate_charge_id: NotRequired[str]
- """
- The Stripe ID for the prior charge which appears to be a duplicate of the disputed charge.
- """
- enhanced_evidence: NotRequired[
- "Literal['']|DisputeService.UpdateParamsEvidenceEnhancedEvidence"
- ]
- """
- Additional evidence for qualifying evidence programs.
- """
- product_description: NotRequired[str]
- """
- A description of the product or service that was sold. Has a maximum character count of 20,000.
- """
- receipt: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any receipt or message sent to the customer notifying them of the charge.
- """
- refund_policy: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your refund policy, as shown to the customer.
- """
- refund_policy_disclosure: NotRequired[str]
- """
- Documentation demonstrating that the customer was shown your refund policy prior to purchase. Has a maximum character count of 20,000.
- """
- refund_refusal_explanation: NotRequired[str]
- """
- A justification for why the customer is not entitled to a refund. Has a maximum character count of 20,000.
- """
- service_date: NotRequired[str]
- """
- The date on which the customer received or began receiving the purchased service, in a clear human-readable format.
- """
- service_documentation: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a service was provided to the customer. This could include a copy of a signed contract, work order, or other form of written agreement.
- """
- shipping_address: NotRequired[str]
- """
- The address to which a physical product was shipped. You should try to include as complete address information as possible.
- """
- shipping_carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc. If multiple carriers were used for this purchase, please separate them with commas.
- """
- shipping_date: NotRequired[str]
- """
- The date on which a physical product began its route to the shipping address, in a clear human-readable format.
- """
- shipping_documentation: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a product was shipped to the customer at the same address the customer provided to you. This could include a copy of the shipment receipt, shipping label, etc. It should show the customer's full shipping address, if possible.
- """
- shipping_tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
- uncategorized_file: NotRequired[str]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any additional evidence or statements.
- """
- uncategorized_text: NotRequired[str]
- """
- Any additional evidence or statements. Has a maximum character count of 20,000.
- """
-
- class UpdateParamsEvidenceEnhancedEvidence(TypedDict):
- visa_compelling_evidence_3: NotRequired[
- "DisputeService.UpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3"
- ]
- """
- Evidence provided for Visa Compelling Evidence 3.0 evidence submission.
- """
- visa_compliance: NotRequired[
- "DisputeService.UpdateParamsEvidenceEnhancedEvidenceVisaCompliance"
- ]
- """
- Evidence provided for Visa compliance evidence submission.
- """
-
- class UpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3(
- TypedDict,
- ):
- disputed_transaction: NotRequired[
- "DisputeService.UpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransaction"
- ]
- """
- Disputed transaction details for Visa Compelling Evidence 3.0 evidence submission.
- """
- prior_undisputed_transactions: NotRequired[
- List[
- "DisputeService.UpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransaction"
- ]
- ]
- """
- List of exactly two prior undisputed transaction objects for Visa Compelling Evidence 3.0 evidence submission.
- """
-
- class UpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransaction(
- TypedDict,
- ):
- customer_account_id: NotRequired["Literal['']|str"]
- """
- User Account ID used to log into business platform. Must be recognizable by the user.
- """
- customer_device_fingerprint: NotRequired["Literal['']|str"]
- """
- Unique identifier of the cardholder's device derived from a combination of at least two hardware and software attributes. Must be at least 20 characters.
- """
- customer_device_id: NotRequired["Literal['']|str"]
- """
- Unique identifier of the cardholder's device such as a device serial number (e.g., International Mobile Equipment Identity [IMEI]). Must be at least 15 characters.
- """
- customer_email_address: NotRequired["Literal['']|str"]
- """
- The email address of the customer.
- """
- customer_purchase_ip: NotRequired["Literal['']|str"]
- """
- The IP address that the customer used when making the purchase.
- """
- merchandise_or_services: NotRequired[
- Literal["merchandise", "services"]
- ]
- """
- Categorization of disputed payment.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- A description of the product or service that was sold.
- """
- shipping_address: NotRequired[
- "DisputeService.UpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransactionShippingAddress"
- ]
- """
- The address to which a physical product was shipped. All fields are required for Visa Compelling Evidence 3.0 evidence submission.
- """
-
- class UpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransactionShippingAddress(
- TypedDict,
- ):
- city: NotRequired["Literal['']|str"]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired["Literal['']|str"]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired["Literal['']|str"]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired["Literal['']|str"]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired["Literal['']|str"]
- """
- ZIP or postal code.
- """
- state: NotRequired["Literal['']|str"]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransaction(
- TypedDict,
- ):
- charge: str
- """
- Stripe charge ID for the Visa Compelling Evidence 3.0 eligible prior charge.
- """
- customer_account_id: NotRequired["Literal['']|str"]
- """
- User Account ID used to log into business platform. Must be recognizable by the user.
- """
- customer_device_fingerprint: NotRequired["Literal['']|str"]
- """
- Unique identifier of the cardholder's device derived from a combination of at least two hardware and software attributes. Must be at least 20 characters.
- """
- customer_device_id: NotRequired["Literal['']|str"]
- """
- Unique identifier of the cardholder's device such as a device serial number (e.g., International Mobile Equipment Identity [IMEI]). Must be at least 15 characters.
- """
- customer_email_address: NotRequired["Literal['']|str"]
- """
- The email address of the customer.
- """
- customer_purchase_ip: NotRequired["Literal['']|str"]
- """
- The IP address that the customer used when making the purchase.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- A description of the product or service that was sold.
- """
- shipping_address: NotRequired[
- "DisputeService.UpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransactionShippingAddress"
- ]
- """
- The address to which a physical product was shipped. All fields are required for Visa Compelling Evidence 3.0 evidence submission.
- """
-
- class UpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransactionShippingAddress(
- TypedDict,
- ):
- city: NotRequired["Literal['']|str"]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired["Literal['']|str"]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired["Literal['']|str"]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired["Literal['']|str"]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired["Literal['']|str"]
- """
- ZIP or postal code.
- """
- state: NotRequired["Literal['']|str"]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsEvidenceEnhancedEvidenceVisaCompliance(TypedDict):
- fee_acknowledged: NotRequired[bool]
- """
- A field acknowledging the fee incurred when countering a Visa compliance dispute. If this field is set to true, evidence can be submitted for the compliance dispute. Stripe collects a 500 USD (or local equivalent) amount to cover the network costs associated with resolving compliance disputes. Stripe refunds the 500 USD network fee if you win the dispute.
- """
+class DisputeService(StripeService):
def list(
self,
- params: Optional["DisputeService.ListParams"] = None,
+ params: Optional["DisputeListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Dispute]:
"""
@@ -397,7 +37,7 @@ def list(
async def list_async(
self,
- params: Optional["DisputeService.ListParams"] = None,
+ params: Optional["DisputeListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Dispute]:
"""
@@ -417,7 +57,7 @@ async def list_async(
def retrieve(
self,
dispute: str,
- params: Optional["DisputeService.RetrieveParams"] = None,
+ params: Optional["DisputeRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Dispute:
"""
@@ -437,7 +77,7 @@ def retrieve(
async def retrieve_async(
self,
dispute: str,
- params: Optional["DisputeService.RetrieveParams"] = None,
+ params: Optional["DisputeRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Dispute:
"""
@@ -457,7 +97,7 @@ async def retrieve_async(
def update(
self,
dispute: str,
- params: Optional["DisputeService.UpdateParams"] = None,
+ params: Optional["DisputeUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Dispute:
"""
@@ -479,7 +119,7 @@ def update(
async def update_async(
self,
dispute: str,
- params: Optional["DisputeService.UpdateParams"] = None,
+ params: Optional["DisputeUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Dispute:
"""
@@ -501,7 +141,7 @@ async def update_async(
def close(
self,
dispute: str,
- params: Optional["DisputeService.CloseParams"] = None,
+ params: Optional["DisputeCloseParams"] = None,
options: Optional[RequestOptions] = None,
) -> Dispute:
"""
@@ -525,7 +165,7 @@ def close(
async def close_async(
self,
dispute: str,
- params: Optional["DisputeService.CloseParams"] = None,
+ params: Optional["DisputeCloseParams"] = None,
options: Optional[RequestOptions] = None,
) -> Dispute:
"""
diff --git a/stripe/_ephemeral_key.py b/stripe/_ephemeral_key.py
index 8347402a4..830e86b51 100644
--- a/stripe/_ephemeral_key.py
+++ b/stripe/_ephemeral_key.py
@@ -2,10 +2,14 @@
# File generated from our OpenAPI spec
from stripe._createable_api_resource import CreateableAPIResource
from stripe._deletable_api_resource import DeletableAPIResource
-from stripe._request_options import RequestOptions
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, List, Optional, cast, overload
-from typing_extensions import Literal, NotRequired, Unpack
+from typing import ClassVar, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._ephemeral_key_delete_params import (
+ EphemeralKeyDeleteParams,
+ )
class EphemeralKey(
@@ -13,13 +17,6 @@ class EphemeralKey(
DeletableAPIResource["EphemeralKey"],
):
OBJECT_NAME: ClassVar[Literal["ephemeral_key"]] = "ephemeral_key"
-
- class DeleteParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -47,7 +44,7 @@ class DeleteParams(RequestOptions):
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["EphemeralKey.DeleteParams"]
+ cls, sid: str, **params: Unpack["EphemeralKeyDeleteParams"]
) -> "EphemeralKey":
"""
Invalidates a short-lived API key for a given resource.
@@ -65,7 +62,7 @@ def _cls_delete(
@overload
@staticmethod
def delete(
- sid: str, **params: Unpack["EphemeralKey.DeleteParams"]
+ sid: str, **params: Unpack["EphemeralKeyDeleteParams"]
) -> "EphemeralKey":
"""
Invalidates a short-lived API key for a given resource.
@@ -74,7 +71,7 @@ def delete(
@overload
def delete(
- self, **params: Unpack["EphemeralKey.DeleteParams"]
+ self, **params: Unpack["EphemeralKeyDeleteParams"]
) -> "EphemeralKey":
"""
Invalidates a short-lived API key for a given resource.
@@ -83,7 +80,7 @@ def delete(
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["EphemeralKey.DeleteParams"]
+ self, **params: Unpack["EphemeralKeyDeleteParams"]
) -> "EphemeralKey":
"""
Invalidates a short-lived API key for a given resource.
@@ -96,7 +93,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["EphemeralKey.DeleteParams"]
+ cls, sid: str, **params: Unpack["EphemeralKeyDeleteParams"]
) -> "EphemeralKey":
"""
Invalidates a short-lived API key for a given resource.
@@ -114,7 +111,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["EphemeralKey.DeleteParams"]
+ sid: str, **params: Unpack["EphemeralKeyDeleteParams"]
) -> "EphemeralKey":
"""
Invalidates a short-lived API key for a given resource.
@@ -123,7 +120,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["EphemeralKey.DeleteParams"]
+ self, **params: Unpack["EphemeralKeyDeleteParams"]
) -> "EphemeralKey":
"""
Invalidates a short-lived API key for a given resource.
@@ -132,7 +129,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["EphemeralKey.DeleteParams"]
+ self, **params: Unpack["EphemeralKeyDeleteParams"]
) -> "EphemeralKey":
"""
Invalidates a short-lived API key for a given resource.
diff --git a/stripe/_ephemeral_key_service.py b/stripe/_ephemeral_key_service.py
index 9b37ff8e7..96ac943a1 100644
--- a/stripe/_ephemeral_key_service.py
+++ b/stripe/_ephemeral_key_service.py
@@ -4,43 +4,23 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._ephemeral_key_create_params import (
+ EphemeralKeyCreateParams,
+ )
+ from stripe.params._ephemeral_key_delete_params import (
+ EphemeralKeyDeleteParams,
+ )
-class EphemeralKeyService(StripeService):
- class CreateParams(TypedDict):
- customer: NotRequired[str]
- """
- The ID of the Customer you'd like to modify using the resulting ephemeral key.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- issuing_card: NotRequired[str]
- """
- The ID of the Issuing Card you'd like to access using the resulting ephemeral key.
- """
- nonce: NotRequired[str]
- """
- A single-use token, created by Stripe.js, used for creating ephemeral keys for Issuing Cards without exchanging sensitive information.
- """
- verification_session: NotRequired[str]
- """
- The ID of the Identity VerificationSession you'd like to access using the resulting ephemeral key
- """
-
- class DeleteParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class EphemeralKeyService(StripeService):
def delete(
self,
key: str,
- params: Optional["EphemeralKeyService.DeleteParams"] = None,
+ params: Optional["EphemeralKeyDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> EphemeralKey:
"""
@@ -60,7 +40,7 @@ def delete(
async def delete_async(
self,
key: str,
- params: Optional["EphemeralKeyService.DeleteParams"] = None,
+ params: Optional["EphemeralKeyDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> EphemeralKey:
"""
@@ -79,7 +59,7 @@ async def delete_async(
def create(
self,
- params: Optional["EphemeralKeyService.CreateParams"] = None,
+ params: Optional["EphemeralKeyCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> EphemeralKey:
"""
@@ -98,7 +78,7 @@ def create(
async def create_async(
self,
- params: Optional["EphemeralKeyService.CreateParams"] = None,
+ params: Optional["EphemeralKeyCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> EphemeralKey:
"""
diff --git a/stripe/_event.py b/stripe/_event.py
index c2b3273ae..f9db3a4c5 100644
--- a/stripe/_event.py
+++ b/stripe/_event.py
@@ -2,10 +2,13 @@
# File generated from our OpenAPI spec
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
-from typing import Any, ClassVar, Dict, List, Optional
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing import Any, ClassVar, Dict, Optional
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._event_list_params import EventListParams
+ from stripe.params._event_retrieve_params import EventRetrieveParams
class Event(ListableAPIResource["Event"]):
@@ -52,64 +55,6 @@ class Request(StripeObject):
The idempotency key transmitted during the request, if any. *Note: This property is populated only for events on or after May 23, 2017*.
"""
- class ListParams(RequestOptions):
- created: NotRequired["Event.ListParamsCreated|int"]
- """
- Only return events that were created during the given date interval.
- """
- delivery_success: NotRequired[bool]
- """
- Filter events by whether all webhooks were successfully delivered. If false, events which are still pending or have failed all delivery attempts to a webhook endpoint will be returned.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[str]
- """
- A string containing a specific event name, or group of events using * as a wildcard. The list will be filtered to include only events with a matching event property.
- """
- types: NotRequired[List[str]]
- """
- An array of up to 20 strings containing specific event names. The list will be filtered to include only events with a matching event property. You may pass either `type` or `types`, but not both.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
account: Optional[str]
"""
The connected account that originates the event.
@@ -403,7 +348,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def list(cls, **params: Unpack["Event.ListParams"]) -> ListObject["Event"]:
+ def list(cls, **params: Unpack["EventListParams"]) -> ListObject["Event"]:
"""
List events, going back up to 30 days. Each event data is rendered according to Stripe API version at its creation time, specified in [event object](https://docs.stripe.com/api/events/object) api_version attribute (not according to your current Stripe API version or Stripe-Version header).
"""
@@ -422,7 +367,7 @@ def list(cls, **params: Unpack["Event.ListParams"]) -> ListObject["Event"]:
@classmethod
async def list_async(
- cls, **params: Unpack["Event.ListParams"]
+ cls, **params: Unpack["EventListParams"]
) -> ListObject["Event"]:
"""
List events, going back up to 30 days. Each event data is rendered according to Stripe API version at its creation time, specified in [event object](https://docs.stripe.com/api/events/object) api_version attribute (not according to your current Stripe API version or Stripe-Version header).
@@ -442,7 +387,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Event.RetrieveParams"]
+ cls, id: str, **params: Unpack["EventRetrieveParams"]
) -> "Event":
"""
Retrieves the details of an event if it was created in the last 30 days. Supply the unique identifier of the event, which you might have received in a webhook.
@@ -453,7 +398,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Event.RetrieveParams"]
+ cls, id: str, **params: Unpack["EventRetrieveParams"]
) -> "Event":
"""
Retrieves the details of an event if it was created in the last 30 days. Supply the unique identifier of the event, which you might have received in a webhook.
diff --git a/stripe/_event_service.py b/stripe/_event_service.py
index 6034a062e..ede795857 100644
--- a/stripe/_event_service.py
+++ b/stripe/_event_service.py
@@ -5,72 +5,18 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._event_list_params import EventListParams
+ from stripe.params._event_retrieve_params import EventRetrieveParams
-class EventService(StripeService):
- class ListParams(TypedDict):
- created: NotRequired["EventService.ListParamsCreated|int"]
- """
- Only return events that were created during the given date interval.
- """
- delivery_success: NotRequired[bool]
- """
- Filter events by whether all webhooks were successfully delivered. If false, events which are still pending or have failed all delivery attempts to a webhook endpoint will be returned.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[str]
- """
- A string containing a specific event name, or group of events using * as a wildcard. The list will be filtered to include only events with a matching event property.
- """
- types: NotRequired[List[str]]
- """
- An array of up to 20 strings containing specific event names. The list will be filtered to include only events with a matching event property. You may pass either `type` or `types`, but not both.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class EventService(StripeService):
def list(
self,
- params: Optional["EventService.ListParams"] = None,
+ params: Optional["EventListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Event]:
"""
@@ -89,7 +35,7 @@ def list(
async def list_async(
self,
- params: Optional["EventService.ListParams"] = None,
+ params: Optional["EventListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Event]:
"""
@@ -109,7 +55,7 @@ async def list_async(
def retrieve(
self,
id: str,
- params: Optional["EventService.RetrieveParams"] = None,
+ params: Optional["EventRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Event:
"""
@@ -129,7 +75,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["EventService.RetrieveParams"] = None,
+ params: Optional["EventRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Event:
"""
diff --git a/stripe/_exchange_rate.py b/stripe/_exchange_rate.py
index 83ec43d65..4e7bdfff4 100644
--- a/stripe/_exchange_rate.py
+++ b/stripe/_exchange_rate.py
@@ -2,10 +2,15 @@
# File generated from our OpenAPI spec
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._util import deprecated
-from typing import ClassVar, Dict, List
-from typing_extensions import Literal, NotRequired, Unpack
+from typing import ClassVar, Dict
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._exchange_rate_list_params import ExchangeRateListParams
+ from stripe.params._exchange_rate_retrieve_params import (
+ ExchangeRateRetrieveParams,
+ )
class ExchangeRate(ListableAPIResource["ExchangeRate"]):
@@ -41,31 +46,6 @@ class ExchangeRate(ListableAPIResource["ExchangeRate"]):
"""
OBJECT_NAME: ClassVar[Literal["exchange_rate"]] = "exchange_rate"
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is the currency that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with the exchange rate for currency X your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and total number of supported payout currencies, and the default is the max.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is the currency that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with the exchange rate for currency X, your subsequent call can include `starting_after=X` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
id: str
"""
Unique identifier for the object. Represented as the three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) in lowercase.
@@ -84,7 +64,7 @@ class RetrieveParams(RequestOptions):
"This method is deprecated, please refer to the description for details.",
)
def list(
- cls, **params: Unpack["ExchangeRate.ListParams"]
+ cls, **params: Unpack["ExchangeRateListParams"]
) -> ListObject["ExchangeRate"]:
"""
[Deprecated] The ExchangeRate APIs are deprecated. Please use the [FX Quotes API](https://docs.stripe.com/payments/currencies/localize-prices/fx-quotes-api) instead.
@@ -109,7 +89,7 @@ def list(
"This method is deprecated, please refer to the description for details.",
)
async def list_async(
- cls, **params: Unpack["ExchangeRate.ListParams"]
+ cls, **params: Unpack["ExchangeRateListParams"]
) -> ListObject["ExchangeRate"]:
"""
[Deprecated] The ExchangeRate APIs are deprecated. Please use the [FX Quotes API](https://docs.stripe.com/payments/currencies/localize-prices/fx-quotes-api) instead.
@@ -134,7 +114,7 @@ async def list_async(
"This method is deprecated, please refer to the description for details.",
)
def retrieve(
- cls, id: str, **params: Unpack["ExchangeRate.RetrieveParams"]
+ cls, id: str, **params: Unpack["ExchangeRateRetrieveParams"]
) -> "ExchangeRate":
"""
[Deprecated] The ExchangeRate APIs are deprecated. Please use the [FX Quotes API](https://docs.stripe.com/payments/currencies/localize-prices/fx-quotes-api) instead.
@@ -150,7 +130,7 @@ def retrieve(
"This method is deprecated, please refer to the description for details.",
)
async def retrieve_async(
- cls, id: str, **params: Unpack["ExchangeRate.RetrieveParams"]
+ cls, id: str, **params: Unpack["ExchangeRateRetrieveParams"]
) -> "ExchangeRate":
"""
[Deprecated] The ExchangeRate APIs are deprecated. Please use the [FX Quotes API](https://docs.stripe.com/payments/currencies/localize-prices/fx-quotes-api) instead.
diff --git a/stripe/_exchange_rate_service.py b/stripe/_exchange_rate_service.py
index 027971300..70c8f3870 100644
--- a/stripe/_exchange_rate_service.py
+++ b/stripe/_exchange_rate_service.py
@@ -5,38 +5,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._exchange_rate_list_params import ExchangeRateListParams
+ from stripe.params._exchange_rate_retrieve_params import (
+ ExchangeRateRetrieveParams,
+ )
-class ExchangeRateService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is the currency that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with the exchange rate for currency X your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and total number of supported payout currencies, and the default is the max.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is the currency that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with the exchange rate for currency X, your subsequent call can include `starting_after=X` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class ExchangeRateService(StripeService):
def list(
self,
- params: Optional["ExchangeRateService.ListParams"] = None,
+ params: Optional["ExchangeRateListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ExchangeRate]:
"""
@@ -57,7 +39,7 @@ def list(
async def list_async(
self,
- params: Optional["ExchangeRateService.ListParams"] = None,
+ params: Optional["ExchangeRateListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ExchangeRate]:
"""
@@ -79,7 +61,7 @@ async def list_async(
def retrieve(
self,
rate_id: str,
- params: Optional["ExchangeRateService.RetrieveParams"] = None,
+ params: Optional["ExchangeRateRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ExchangeRate:
"""
@@ -103,7 +85,7 @@ def retrieve(
async def retrieve_async(
self,
rate_id: str,
- params: Optional["ExchangeRateService.RetrieveParams"] = None,
+ params: Optional["ExchangeRateRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ExchangeRate:
"""
diff --git a/stripe/_file.py b/stripe/_file.py
index 87bf9cdc4..c20c2b016 100644
--- a/stripe/_file.py
+++ b/stripe/_file.py
@@ -3,18 +3,14 @@
from stripe._createable_api_resource import CreateableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
-from typing import Any, ClassVar, Dict, List, Optional, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._file_link import FileLink
+ from stripe.params._file_create_params import FileCreateParams
+ from stripe.params._file_list_params import FileListParams
+ from stripe.params._file_retrieve_params import FileRetrieveParams
class File(CreateableAPIResource["File"], ListableAPIResource["File"]):
@@ -29,123 +25,6 @@ class File(CreateableAPIResource["File"], ListableAPIResource["File"]):
"""
OBJECT_NAME: ClassVar[Literal["file"]] = "file"
-
- class CreateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- file: Any
- """
- A file to upload. Make sure that the specifications follow RFC 2388, which defines file transfers for the `multipart/form-data` protocol.
- """
- file_link_data: NotRequired["File.CreateParamsFileLinkData"]
- """
- Optional parameters that automatically create a [file link](https://stripe.com/docs/api#file_links) for the newly created file.
- """
- purpose: Literal[
- "account_requirement",
- "additional_verification",
- "business_icon",
- "business_logo",
- "customer_signature",
- "dispute_evidence",
- "identity_document",
- "issuing_regulatory_reporting",
- "pci_document",
- "tax_document_user_upload",
- "terminal_android_apk",
- "terminal_reader_splashscreen",
- ]
- """
- The [purpose](https://stripe.com/docs/file-upload#uploading-a-file) of the uploaded file.
- """
-
- class CreateParamsFileLinkData(TypedDict):
- create: bool
- """
- Set this to `true` to create a file link for the newly created file. Creating a link is only possible when the file's `purpose` is one of the following: `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `issuing_regulatory_reporting`, `pci_document`, `tax_document_user_upload`, `terminal_android_apk`, or `terminal_reader_splashscreen`.
- """
- expires_at: NotRequired[int]
- """
- The link isn't available after this future timestamp.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["File.ListParamsCreated|int"]
- """
- Only return files that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- purpose: NotRequired[
- Literal[
- "account_requirement",
- "additional_verification",
- "business_icon",
- "business_logo",
- "customer_signature",
- "dispute_evidence",
- "document_provider_identity_document",
- "finance_report_run",
- "financial_account_statement",
- "identity_document",
- "identity_document_downloadable",
- "issuing_regulatory_reporting",
- "pci_document",
- "selfie",
- "sigma_scheduled_query",
- "tax_document_user_upload",
- "terminal_android_apk",
- "terminal_reader_splashscreen",
- ]
- ]
- """
- Filter queries by the file purpose. If you don't provide a purpose, the queries return unfiltered files.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -211,7 +90,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["File.CreateParams"]) -> "File":
+ def create(cls, **params: Unpack["FileCreateParams"]) -> "File":
"""
To upload a file to Stripe, you need to send a request of type multipart/form-data. Include the file you want to upload in the request, and the parameters for creating a file.
@@ -231,7 +110,7 @@ def create(cls, **params: Unpack["File.CreateParams"]) -> "File":
@classmethod
async def create_async(
- cls, **params: Unpack["File.CreateParams"]
+ cls, **params: Unpack["FileCreateParams"]
) -> "File":
"""
To upload a file to Stripe, you need to send a request of type multipart/form-data. Include the file you want to upload in the request, and the parameters for creating a file.
@@ -251,7 +130,7 @@ async def create_async(
)
@classmethod
- def list(cls, **params: Unpack["File.ListParams"]) -> ListObject["File"]:
+ def list(cls, **params: Unpack["FileListParams"]) -> ListObject["File"]:
"""
Returns a list of the files that your account has access to. Stripe sorts and returns the files by their creation dates, placing the most recently created files at the top.
"""
@@ -270,7 +149,7 @@ def list(cls, **params: Unpack["File.ListParams"]) -> ListObject["File"]:
@classmethod
async def list_async(
- cls, **params: Unpack["File.ListParams"]
+ cls, **params: Unpack["FileListParams"]
) -> ListObject["File"]:
"""
Returns a list of the files that your account has access to. Stripe sorts and returns the files by their creation dates, placing the most recently created files at the top.
@@ -290,7 +169,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["File.RetrieveParams"]
+ cls, id: str, **params: Unpack["FileRetrieveParams"]
) -> "File":
"""
Retrieves the details of an existing file object. After you supply a unique file ID, Stripe returns the corresponding file object. Learn how to [access file contents](https://docs.stripe.com/docs/file-upload#download-file-contents).
@@ -301,7 +180,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["File.RetrieveParams"]
+ cls, id: str, **params: Unpack["FileRetrieveParams"]
) -> "File":
"""
Retrieves the details of an existing file object. After you supply a unique file ID, Stripe returns the corresponding file object. Learn how to [access file contents](https://docs.stripe.com/docs/file-upload#download-file-contents).
diff --git a/stripe/_file_link.py b/stripe/_file_link.py
index b1e5a103d..d72e14894 100644
--- a/stripe/_file_link.py
+++ b/stripe/_file_link.py
@@ -4,20 +4,17 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import sanitize_id
-from typing import ClassVar, Dict, List, Optional, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Dict, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._file import File
+ from stripe.params._file_link_create_params import FileLinkCreateParams
+ from stripe.params._file_link_list_params import FileLinkListParams
+ from stripe.params._file_link_modify_params import FileLinkModifyParams
+ from stripe.params._file_link_retrieve_params import FileLinkRetrieveParams
class FileLink(
@@ -32,93 +29,6 @@ class FileLink(
"""
OBJECT_NAME: ClassVar[Literal["file_link"]] = "file_link"
-
- class CreateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- The link isn't usable after this future timestamp.
- """
- file: str
- """
- The ID of the file. The file's `purpose` must be one of the following: `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `finance_report_run`, `financial_account_statement`, `identity_document_downloadable`, `issuing_regulatory_reporting`, `pci_document`, `selfie`, `sigma_scheduled_query`, `tax_document_user_upload`, `terminal_android_apk`, or `terminal_reader_splashscreen`.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["FileLink.ListParamsCreated|int"]
- """
- Only return links that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expired: NotRequired[bool]
- """
- Filter links by their expiration status. By default, Stripe returns all links.
- """
- file: NotRequired[str]
- """
- Only return links for the given file.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired["Literal['']|Literal['now']|int"]
- """
- A future timestamp after which the link will no longer be usable, or `now` to expire the link immediately.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -157,7 +67,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["FileLink.CreateParams"]) -> "FileLink":
+ def create(cls, **params: Unpack["FileLinkCreateParams"]) -> "FileLink":
"""
Creates a new file link object.
"""
@@ -172,7 +82,7 @@ def create(cls, **params: Unpack["FileLink.CreateParams"]) -> "FileLink":
@classmethod
async def create_async(
- cls, **params: Unpack["FileLink.CreateParams"]
+ cls, **params: Unpack["FileLinkCreateParams"]
) -> "FileLink":
"""
Creates a new file link object.
@@ -188,7 +98,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["FileLink.ListParams"]
+ cls, **params: Unpack["FileLinkListParams"]
) -> ListObject["FileLink"]:
"""
Returns a list of file links.
@@ -208,7 +118,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["FileLink.ListParams"]
+ cls, **params: Unpack["FileLinkListParams"]
) -> ListObject["FileLink"]:
"""
Returns a list of file links.
@@ -228,7 +138,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["FileLink.ModifyParams"]
+ cls, id: str, **params: Unpack["FileLinkModifyParams"]
) -> "FileLink":
"""
Updates an existing file link object. Expired links can no longer be updated.
@@ -245,7 +155,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["FileLink.ModifyParams"]
+ cls, id: str, **params: Unpack["FileLinkModifyParams"]
) -> "FileLink":
"""
Updates an existing file link object. Expired links can no longer be updated.
@@ -262,7 +172,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["FileLink.RetrieveParams"]
+ cls, id: str, **params: Unpack["FileLinkRetrieveParams"]
) -> "FileLink":
"""
Retrieves the file link with the given ID.
@@ -273,7 +183,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["FileLink.RetrieveParams"]
+ cls, id: str, **params: Unpack["FileLinkRetrieveParams"]
) -> "FileLink":
"""
Retrieves the file link with the given ID.
diff --git a/stripe/_file_link_service.py b/stripe/_file_link_service.py
index 5aa6dbf05..96398a3b7 100644
--- a/stripe/_file_link_service.py
+++ b/stripe/_file_link_service.py
@@ -5,100 +5,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._file_link_create_params import FileLinkCreateParams
+ from stripe.params._file_link_list_params import FileLinkListParams
+ from stripe.params._file_link_retrieve_params import FileLinkRetrieveParams
+ from stripe.params._file_link_update_params import FileLinkUpdateParams
-class FileLinkService(StripeService):
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- The link isn't usable after this future timestamp.
- """
- file: str
- """
- The ID of the file. The file's `purpose` must be one of the following: `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `finance_report_run`, `financial_account_statement`, `identity_document_downloadable`, `issuing_regulatory_reporting`, `pci_document`, `selfie`, `sigma_scheduled_query`, `tax_document_user_upload`, `terminal_android_apk`, or `terminal_reader_splashscreen`.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class ListParams(TypedDict):
- created: NotRequired["FileLinkService.ListParamsCreated|int"]
- """
- Only return links that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expired: NotRequired[bool]
- """
- Filter links by their expiration status. By default, Stripe returns all links.
- """
- file: NotRequired[str]
- """
- Only return links for the given file.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired["Literal['']|Literal['now']|int"]
- """
- A future timestamp after which the link will no longer be usable, or `now` to expire the link immediately.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
+class FileLinkService(StripeService):
def list(
self,
- params: Optional["FileLinkService.ListParams"] = None,
+ params: Optional["FileLinkListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[FileLink]:
"""
@@ -117,7 +37,7 @@ def list(
async def list_async(
self,
- params: Optional["FileLinkService.ListParams"] = None,
+ params: Optional["FileLinkListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[FileLink]:
"""
@@ -136,7 +56,7 @@ async def list_async(
def create(
self,
- params: "FileLinkService.CreateParams",
+ params: "FileLinkCreateParams",
options: Optional[RequestOptions] = None,
) -> FileLink:
"""
@@ -155,7 +75,7 @@ def create(
async def create_async(
self,
- params: "FileLinkService.CreateParams",
+ params: "FileLinkCreateParams",
options: Optional[RequestOptions] = None,
) -> FileLink:
"""
@@ -175,7 +95,7 @@ async def create_async(
def retrieve(
self,
link: str,
- params: Optional["FileLinkService.RetrieveParams"] = None,
+ params: Optional["FileLinkRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> FileLink:
"""
@@ -195,7 +115,7 @@ def retrieve(
async def retrieve_async(
self,
link: str,
- params: Optional["FileLinkService.RetrieveParams"] = None,
+ params: Optional["FileLinkRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> FileLink:
"""
@@ -215,7 +135,7 @@ async def retrieve_async(
def update(
self,
link: str,
- params: Optional["FileLinkService.UpdateParams"] = None,
+ params: Optional["FileLinkUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> FileLink:
"""
@@ -235,7 +155,7 @@ def update(
async def update_async(
self,
link: str,
- params: Optional["FileLinkService.UpdateParams"] = None,
+ params: Optional["FileLinkUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> FileLink:
"""
diff --git a/stripe/_file_service.py b/stripe/_file_service.py
index 12ca02ef4..48416e5fc 100644
--- a/stripe/_file_service.py
+++ b/stripe/_file_service.py
@@ -5,130 +5,19 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Any, Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._file_create_params import FileCreateParams
+ from stripe.params._file_list_params import FileListParams
+ from stripe.params._file_retrieve_params import FileRetrieveParams
-class FileService(StripeService):
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- file: Any
- """
- A file to upload. Make sure that the specifications follow RFC 2388, which defines file transfers for the `multipart/form-data` protocol.
- """
- file_link_data: NotRequired["FileService.CreateParamsFileLinkData"]
- """
- Optional parameters that automatically create a [file link](https://stripe.com/docs/api#file_links) for the newly created file.
- """
- purpose: Literal[
- "account_requirement",
- "additional_verification",
- "business_icon",
- "business_logo",
- "customer_signature",
- "dispute_evidence",
- "identity_document",
- "issuing_regulatory_reporting",
- "pci_document",
- "tax_document_user_upload",
- "terminal_android_apk",
- "terminal_reader_splashscreen",
- ]
- """
- The [purpose](https://stripe.com/docs/file-upload#uploading-a-file) of the uploaded file.
- """
-
- class CreateParamsFileLinkData(TypedDict):
- create: bool
- """
- Set this to `true` to create a file link for the newly created file. Creating a link is only possible when the file's `purpose` is one of the following: `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `issuing_regulatory_reporting`, `pci_document`, `tax_document_user_upload`, `terminal_android_apk`, or `terminal_reader_splashscreen`.
- """
- expires_at: NotRequired[int]
- """
- The link isn't available after this future timestamp.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class ListParams(TypedDict):
- created: NotRequired["FileService.ListParamsCreated|int"]
- """
- Only return files that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- purpose: NotRequired[
- Literal[
- "account_requirement",
- "additional_verification",
- "business_icon",
- "business_logo",
- "customer_signature",
- "dispute_evidence",
- "document_provider_identity_document",
- "finance_report_run",
- "financial_account_statement",
- "identity_document",
- "identity_document_downloadable",
- "issuing_regulatory_reporting",
- "pci_document",
- "selfie",
- "sigma_scheduled_query",
- "tax_document_user_upload",
- "terminal_android_apk",
- "terminal_reader_splashscreen",
- ]
- ]
- """
- Filter queries by the file purpose. If you don't provide a purpose, the queries return unfiltered files.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class FileService(StripeService):
def list(
self,
- params: Optional["FileService.ListParams"] = None,
+ params: Optional["FileListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[File]:
"""
@@ -147,7 +36,7 @@ def list(
async def list_async(
self,
- params: Optional["FileService.ListParams"] = None,
+ params: Optional["FileListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[File]:
"""
@@ -166,7 +55,7 @@ async def list_async(
def create(
self,
- params: "FileService.CreateParams",
+ params: "FileCreateParams",
options: Optional[RequestOptions] = None,
) -> File:
"""
@@ -190,7 +79,7 @@ def create(
async def create_async(
self,
- params: "FileService.CreateParams",
+ params: "FileCreateParams",
options: Optional[RequestOptions] = None,
) -> File:
"""
@@ -215,7 +104,7 @@ async def create_async(
def retrieve(
self,
file: str,
- params: Optional["FileService.RetrieveParams"] = None,
+ params: Optional["FileRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> File:
"""
@@ -235,7 +124,7 @@ def retrieve(
async def retrieve_async(
self,
file: str,
- params: Optional["FileService.RetrieveParams"] = None,
+ params: Optional["FileRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> File:
"""
diff --git a/stripe/_invoice.py b/stripe/_invoice.py
index 5d21b8cb5..6cb440aaa 100644
--- a/stripe/_invoice.py
+++ b/stripe/_invoice.py
@@ -6,7 +6,6 @@
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
from stripe._nested_resource_class_methods import nested_resource_class_methods
-from stripe._request_options import RequestOptions
from stripe._search_result_object import SearchResultObject
from stripe._searchable_api_resource import SearchableAPIResource
from stripe._stripe_object import StripeObject
@@ -23,13 +22,7 @@
cast,
overload,
)
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account
@@ -51,6 +44,39 @@
from stripe.billing._credit_balance_transaction import (
CreditBalanceTransaction,
)
+ from stripe.params._invoice_add_lines_params import InvoiceAddLinesParams
+ from stripe.params._invoice_attach_payment_params import (
+ InvoiceAttachPaymentParams,
+ )
+ from stripe.params._invoice_create_params import InvoiceCreateParams
+ from stripe.params._invoice_create_preview_params import (
+ InvoiceCreatePreviewParams,
+ )
+ from stripe.params._invoice_delete_params import InvoiceDeleteParams
+ from stripe.params._invoice_finalize_invoice_params import (
+ InvoiceFinalizeInvoiceParams,
+ )
+ from stripe.params._invoice_list_lines_params import InvoiceListLinesParams
+ from stripe.params._invoice_list_params import InvoiceListParams
+ from stripe.params._invoice_mark_uncollectible_params import (
+ InvoiceMarkUncollectibleParams,
+ )
+ from stripe.params._invoice_modify_params import InvoiceModifyParams
+ from stripe.params._invoice_pay_params import InvoicePayParams
+ from stripe.params._invoice_remove_lines_params import (
+ InvoiceRemoveLinesParams,
+ )
+ from stripe.params._invoice_retrieve_params import InvoiceRetrieveParams
+ from stripe.params._invoice_search_params import InvoiceSearchParams
+ from stripe.params._invoice_send_invoice_params import (
+ InvoiceSendInvoiceParams,
+ )
+ from stripe.params._invoice_update_lines_params import (
+ InvoiceUpdateLinesParams,
+ )
+ from stripe.params._invoice_void_invoice_params import (
+ InvoiceVoidInvoiceParams,
+ )
from stripe.test_helpers._test_clock import TestClock
@@ -1154,3211 +1180,142 @@ class TaxRateDetails(StripeObject):
"""
_inner_class_types = {"tax_rate_details": TaxRateDetails}
- class AddLinesParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- lines: List["Invoice.AddLinesParamsLine"]
- """
- The line items to add.
- """
-
- class AddLinesParamsLine(TypedDict):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
- """
- discountable: NotRequired[bool]
- """
- Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.
- """
- discounts: NotRequired[
- "Literal['']|List[Invoice.AddLinesParamsLineDiscount]"
- ]
- """
- The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
- """
- invoice_item: NotRequired[str]
- """
- ID of an unassigned invoice item to assign to this invoice. If not provided, a new item will be created.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired["Invoice.AddLinesParamsLinePeriod"]
- """
- The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
- """
- price_data: NotRequired["Invoice.AddLinesParamsLinePriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- pricing: NotRequired["Invoice.AddLinesParamsLinePricing"]
- """
- The pricing information for the invoice item.
- """
- quantity: NotRequired[int]
- """
- Non-negative integer. The quantity of units for the line item.
- """
- tax_amounts: NotRequired[
- "Literal['']|List[Invoice.AddLinesParamsLineTaxAmount]"
- ]
- """
- A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has [tax_rates](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-tax_rates) or if the invoice has [default_tax_rates](https://stripe.com/docs/api/invoices/object#invoice_object-default_tax_rates) or uses [automatic tax](https://stripe.com/docs/tax/invoicing). Pass an empty string to remove previously defined tax amounts.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the line item. When set, the `default_tax_rates` on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.
- """
-
- class AddLinesParamsLineDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class AddLinesParamsLinePeriod(TypedDict):
- end: int
- """
- The end of the period, which must be greater than or equal to the start. This value is inclusive.
- """
- start: int
- """
- The start of the period. This value is inclusive.
- """
-
- class AddLinesParamsLinePriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: NotRequired[str]
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
- """
- product_data: NotRequired[
- "Invoice.AddLinesParamsLinePriceDataProductData"
- ]
- """
- Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class AddLinesParamsLinePriceDataProductData(TypedDict):
- description: NotRequired[str]
- """
- The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
- """
- images: NotRequired[List[str]]
- """
- A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The product's name, meant to be displayable to the customer.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- unit_label: NotRequired[str]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
- """
-
- class AddLinesParamsLinePricing(TypedDict):
- price: NotRequired[str]
- """
- The ID of the price object.
- """
-
- class AddLinesParamsLineTaxAmount(TypedDict):
- amount: int
- """
- The amount, in cents (or local equivalent), of the tax.
- """
- tax_rate_data: "Invoice.AddLinesParamsLineTaxAmountTaxRateData"
- """
- Data to find or create a TaxRate object.
-
- Stripe automatically creates or reuses a TaxRate object for each tax amount. If the `tax_rate_data` exactly matches a previous value, Stripe will reuse the TaxRate object. TaxRate objects created automatically by Stripe are immediately archived, do not appear in the line item's `tax_rates`, and cannot be directly added to invoices, payments, or line items.
- """
- taxability_reason: NotRequired[
- Literal[
- "customer_exempt",
- "not_collecting",
- "not_subject_to_tax",
- "not_supported",
- "portion_product_exempt",
- "portion_reduced_rated",
- "portion_standard_rated",
- "product_exempt",
- "product_exempt_holiday",
- "proportionally_rated",
- "reduced_rated",
- "reverse_charge",
- "standard_rated",
- "taxable_basis_reduced",
- "zero_rated",
- ]
+ account_country: Optional[str]
+ """
+ The country of the business associated with this invoice, most often the business creating the invoice.
+ """
+ account_name: Optional[str]
+ """
+ The public name of the business associated with this invoice, most often the business creating the invoice.
+ """
+ account_tax_ids: Optional[List[ExpandableField["TaxId"]]]
+ """
+ The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
+ """
+ amount_due: int
+ """
+ Final amount due at this time for this invoice. If the invoice's total is smaller than the minimum charge amount, for example, or if there is account credit that can be applied to the invoice, the `amount_due` may be 0. If there is a positive `starting_balance` for the invoice (the customer owes money), the `amount_due` will also take that into account. The charge that gets generated for the invoice will be for the amount specified in `amount_due`.
+ """
+ amount_overpaid: int
+ """
+ Amount that was overpaid on the invoice. The amount overpaid is credited to the customer's credit balance.
+ """
+ amount_paid: int
+ """
+ The amount, in cents (or local equivalent), that was paid.
+ """
+ amount_remaining: int
+ """
+ The difference between amount_due and amount_paid, in cents (or local equivalent).
+ """
+ amount_shipping: int
+ """
+ This is the sum of all the shipping amounts.
+ """
+ application: Optional[ExpandableField["Application"]]
+ """
+ ID of the Connect Application that created the invoice.
+ """
+ attempt_count: int
+ """
+ Number of payment attempts made for this invoice, from the perspective of the payment retry schedule. Any payment attempt counts as the first attempt, and subsequently only automatic retries increment the attempt count. In other words, manual payment attempts after the first attempt do not affect the retry schedule. If a failure is returned with a non-retryable return code, the invoice can no longer be retried unless a new payment method is obtained. Retries will continue to be scheduled, and attempt_count will continue to increment, but retries will only be executed if a new payment method is obtained.
+ """
+ attempted: bool
+ """
+ Whether an attempt has been made to pay the invoice. An invoice is not attempted until 1 hour after the `invoice.created` webhook, for example, so you might not want to display that invoice as unpaid to your users.
+ """
+ auto_advance: Optional[bool]
+ """
+ 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",
+ "manual",
+ "quote_accept",
+ "subscription",
+ "subscription_create",
+ "subscription_cycle",
+ "subscription_threshold",
+ "subscription_update",
+ "upcoming",
]
- """
- The reasoning behind this tax, for example, if the product is tax exempt.
- """
- taxable_amount: int
- """
- The amount on which tax is calculated, in cents (or local equivalent).
- """
+ ]
+ """
+ Indicates the reason why the invoice was created.
- class AddLinesParamsLineTaxAmountTaxRateData(TypedDict):
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
- """
- display_name: str
- """
- The display name of the tax rate, which will be shown to users.
- """
- inclusive: bool
- """
- This specifies if the tax rate is inclusive or exclusive.
- """
- jurisdiction: NotRequired[str]
- """
- The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer's invoice.
- """
- jurisdiction_level: NotRequired[
- Literal[
- "city", "country", "county", "district", "multiple", "state"
- ]
- ]
- """
- The level of the jurisdiction that imposes this tax rate.
- """
- percentage: float
- """
- The statutory tax rate percent. This field accepts decimal values between 0 and 100 inclusive with at most 4 decimal places. To accommodate fixed-amount taxes, set the percentage to zero. Stripe will not display zero percentages on the invoice unless the `amount` of the tax is also zero.
- """
- state: NotRequired[str]
- """
- [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, "NY" for New York, United States.
- """
- tax_type: NotRequired[
- Literal[
- "amusement_tax",
- "communications_tax",
- "gst",
- "hst",
- "igst",
- "jct",
- "lease_tax",
- "pst",
- "qst",
- "retail_delivery_fee",
- "rst",
- "sales_tax",
- "service_tax",
- "vat",
- ]
- ]
- """
- The high-level tax type, such as `vat` or `sales_tax`.
- """
-
- class AttachPaymentParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- payment_intent: NotRequired[str]
- """
- The ID of the PaymentIntent to attach to the invoice.
- """
-
- class CreateParams(RequestOptions):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
- """
- application_fee_amount: NotRequired[int]
- """
- A fee in cents (or local equivalent) that will be applied to the invoice and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the Stripe-Account header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/billing/invoices/connect#collecting-fees).
- """
- auto_advance: NotRequired[bool]
- """
- 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. Defaults to false.
- """
- automatic_tax: NotRequired["Invoice.CreateParamsAutomaticTax"]
- """
- Settings for automatic tax lookup for this invoice.
- """
- automatically_finalizes_at: NotRequired[int]
- """
- The time when this invoice should be scheduled to finalize (up to 5 years in the future). The invoice is finalized at this time if it's still in draft state.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`.
- """
- currency: NotRequired[str]
- """
- The currency to create this invoice in. Defaults to that of `customer` if not specified.
- """
- custom_fields: NotRequired[
- "Literal['']|List[Invoice.CreateParamsCustomField]"
- ]
- """
- A list of up to 4 custom fields to be displayed on the invoice.
- """
- customer: NotRequired[str]
- """
- The ID of the customer who will be billed.
- """
- days_until_due: NotRequired[int]
- """
- The number of days from when the invoice is created until it is due. Valid only for invoices where `collection_method=send_invoice`.
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.
- """
- default_source: NotRequired[str]
- """
- ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.
- """
- default_tax_rates: NotRequired[List[str]]
- """
- The tax rates that will apply to any line item that does not have `tax_rates` set.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.
- """
- discounts: NotRequired[
- "Literal['']|List[Invoice.CreateParamsDiscount]"
- ]
- """
- The coupons and promotion codes to redeem into discounts for the invoice. If not specified, inherits the discount from the invoice's customer. Pass an empty string to avoid inheriting any discounts.
- """
- due_date: NotRequired[int]
- """
- The date on which payment for this invoice is due. Valid only for invoices where `collection_method=send_invoice`.
- """
- effective_at: NotRequired[int]
- """
- The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- footer: NotRequired[str]
- """
- Footer to be displayed on the invoice.
- """
- from_invoice: NotRequired["Invoice.CreateParamsFromInvoice"]
- """
- Revise an existing invoice. The new invoice will be created in `status=draft`. See the [revision documentation](https://stripe.com/docs/invoicing/invoice-revisions) for more details.
- """
- issuer: NotRequired["Invoice.CreateParamsIssuer"]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- number: NotRequired[str]
- """
- Set the number for this invoice. If no number is present then a number will be assigned automatically when the invoice is finalized. In many markets, regulations require invoices to be unique, sequential and / or gapless. You are responsible for ensuring this is true across all your different invoicing systems in the event that you edit the invoice number using our API. If you use only Stripe for your invoices and do not change invoice numbers, Stripe handles this aspect of compliance for you automatically.
- """
- on_behalf_of: NotRequired[str]
- """
- The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
- """
- payment_settings: NotRequired["Invoice.CreateParamsPaymentSettings"]
- """
- Configuration settings for the PaymentIntent that is generated when the invoice is finalized.
- """
- pending_invoice_items_behavior: NotRequired[
- Literal["exclude", "include"]
- ]
- """
- How to handle pending invoice items on invoice creation. Defaults to `exclude` if the parameter is omitted.
- """
- rendering: NotRequired["Invoice.CreateParamsRendering"]
- """
- The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.
- """
- shipping_cost: NotRequired["Invoice.CreateParamsShippingCost"]
- """
- Settings for the cost of shipping for this invoice.
- """
- shipping_details: NotRequired["Invoice.CreateParamsShippingDetails"]
- """
- Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer.
- """
- statement_descriptor: NotRequired[str]
- """
- Extra information about a charge for the customer's credit card statement. It must contain at least one letter. If not specified and this invoice is part of a subscription, the default `statement_descriptor` will be set to the first subscription item's product's `statement_descriptor`.
- """
- subscription: NotRequired[str]
- """
- The ID of the subscription to invoice, if any. If set, the created invoice will only include pending invoice items for that subscription. The subscription's billing cycle and regular subscription events won't be affected.
- """
- transfer_data: NotRequired["Invoice.CreateParamsTransferData"]
- """
- If specified, the funds from the invoice will be transferred to the destination and the ID of the resulting transfer will be found on the invoice's charge.
- """
-
- class CreateParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Whether Stripe automatically computes tax on this invoice. Note that incompatible invoice items (invoice items with manually specified [tax rates](https://stripe.com/docs/api/tax_rates), negative amounts, or `tax_behavior=unspecified`) cannot be added to automatic tax invoices.
- """
- liability: NotRequired["Invoice.CreateParamsAutomaticTaxLiability"]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreateParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsCustomField(TypedDict):
- name: str
- """
- The name of the custom field. This may be up to 40 characters.
- """
- value: str
- """
- The value of the custom field. This may be up to 140 characters.
- """
-
- class CreateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsFromInvoice(TypedDict):
- action: Literal["revision"]
- """
- The relation between the new invoice and the original invoice. Currently, only 'revision' is permitted
- """
- invoice: str
- """
- The `id` of the invoice that will be cloned.
- """
-
- class CreateParamsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsPaymentSettings(TypedDict):
- default_mandate: NotRequired["Literal['']|str"]
- """
- ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the invoice's default_payment_method or default_source, if set.
- """
- payment_method_options: NotRequired[
- "Invoice.CreateParamsPaymentSettingsPaymentMethodOptions"
- ]
- """
- Payment-method-specific configuration to provide to the invoice's PaymentIntent.
- """
- payment_method_types: NotRequired[
- "Literal['']|List[Literal['ach_credit_transfer', 'ach_debit', 'acss_debit', 'affirm', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'jp_credit_transfer', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'link', 'multibanco', 'naver_pay', 'nz_bank_account', 'p24', 'payco', 'paynow', 'paypal', 'promptpay', 'revolut_pay', 'sepa_credit_transfer', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
- ]
- """
- The list of payment method types (e.g. card) to provide to the invoice's PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice's default payment method, the subscription's default payment method, the customer's default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice).
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "Literal['']|Invoice.CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebit"
- ]
- """
- If paying by `acss_debit`, this sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice's PaymentIntent.
- """
- bancontact: NotRequired[
- "Literal['']|Invoice.CreateParamsPaymentSettingsPaymentMethodOptionsBancontact"
- ]
- """
- If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the invoice's PaymentIntent.
- """
- card: NotRequired[
- "Literal['']|Invoice.CreateParamsPaymentSettingsPaymentMethodOptionsCard"
- ]
- """
- If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the invoice's PaymentIntent.
- """
- customer_balance: NotRequired[
- "Literal['']|Invoice.CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance"
- ]
- """
- If paying by `customer_balance`, this sub-hash contains details about the Bank transfer payment method options to pass to the invoice's PaymentIntent.
- """
- konbini: NotRequired[
- "Literal['']|Invoice.CreateParamsPaymentSettingsPaymentMethodOptionsKonbini"
- ]
- """
- If paying by `konbini`, this sub-hash contains details about the Konbini payment method options to pass to the invoice's PaymentIntent.
- """
- sepa_debit: NotRequired[
- "Literal['']|Invoice.CreateParamsPaymentSettingsPaymentMethodOptionsSepaDebit"
- ]
- """
- If paying by `sepa_debit`, this sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice's PaymentIntent.
- """
- us_bank_account: NotRequired[
- "Literal['']|Invoice.CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If paying by `us_bank_account`, this sub-hash contains details about the ACH direct debit payment method options to pass to the invoice's PaymentIntent.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebit(TypedDict):
- mandate_options: NotRequired[
- "Invoice.CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions(
- TypedDict,
- ):
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsBancontact(TypedDict):
- preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
- """
- Preferred language of the Bancontact authorization page that the customer is redirected to.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCard(TypedDict):
- installments: NotRequired[
- "Invoice.CreateParamsPaymentSettingsPaymentMethodOptionsCardInstallments"
- ]
- """
- Installment configuration for payments attempted on this invoice.
-
- For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCardInstallments(
- TypedDict,
- ):
- enabled: NotRequired[bool]
- """
- Setting to true enables installments for this invoice.
- Setting to false will prevent any selected plan from applying to a payment.
- """
- plan: NotRequired[
- "Literal['']|Invoice.CreateParamsPaymentSettingsPaymentMethodOptionsCardInstallmentsPlan"
- ]
- """
- The selected installment plan to use for this invoice.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCardInstallmentsPlan(
- TypedDict,
- ):
- count: NotRequired[int]
- """
- For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
- """
- interval: NotRequired[Literal["month"]]
- """
- For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
- One of `month`.
- """
- type: Literal["bonus", "fixed_count", "revolving"]
- """
- Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance(
- TypedDict,
- ):
- bank_transfer: NotRequired[
- "Invoice.CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[str]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "Invoice.CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for eu_bank_transfer funding type.
- """
- type: NotRequired[str]
- """
- The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsKonbini(TypedDict):
- pass
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsSepaDebit(TypedDict):
- pass
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount(
- TypedDict,
- ):
- financial_connections: NotRequired[
- "Invoice.CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "Invoice.CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class CreateParamsRendering(TypedDict):
- amount_tax_display: NotRequired[
- "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
- ]
- """
- How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
- """
- pdf: NotRequired["Invoice.CreateParamsRenderingPdf"]
- """
- Invoice pdf rendering options
- """
- template: NotRequired[str]
- """
- ID of the invoice rendering template to use for this invoice.
- """
- template_version: NotRequired["Literal['']|int"]
- """
- The specific version of invoice rendering template to use for this invoice.
- """
-
- class CreateParamsRenderingPdf(TypedDict):
- page_size: NotRequired[Literal["a4", "auto", "letter"]]
- """
- Page size for invoice PDF. Can be set to `a4`, `letter`, or `auto`.
- If set to `auto`, invoice PDF page size defaults to `a4` for customers with
- Japanese locale and `letter` for customers with other locales.
- """
-
- class CreateParamsShippingCost(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the shipping rate to use for this order.
- """
- shipping_rate_data: NotRequired[
- "Invoice.CreateParamsShippingCostShippingRateData"
- ]
- """
- Parameters to create a new ad-hoc shipping rate for this order.
- """
-
- class CreateParamsShippingCostShippingRateData(TypedDict):
- delivery_estimate: NotRequired[
- "Invoice.CreateParamsShippingCostShippingRateDataDeliveryEstimate"
- ]
- """
- The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- display_name: str
- """
- The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- fixed_amount: NotRequired[
- "Invoice.CreateParamsShippingCostShippingRateDataFixedAmount"
- ]
- """
- Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
- """
- type: NotRequired[Literal["fixed_amount"]]
- """
- The type of calculation to use on the shipping rate.
- """
-
- class CreateParamsShippingCostShippingRateDataDeliveryEstimate(TypedDict):
- maximum: NotRequired[
- "Invoice.CreateParamsShippingCostShippingRateDataDeliveryEstimateMaximum"
- ]
- """
- The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
- """
- minimum: NotRequired[
- "Invoice.CreateParamsShippingCostShippingRateDataDeliveryEstimateMinimum"
- ]
- """
- The lower bound of the estimated range. If empty, represents no lower bound.
- """
-
- class CreateParamsShippingCostShippingRateDataDeliveryEstimateMaximum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class CreateParamsShippingCostShippingRateDataDeliveryEstimateMinimum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class CreateParamsShippingCostShippingRateDataFixedAmount(TypedDict):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- currency_options: NotRequired[
- Dict[
- str,
- "Invoice.CreateParamsShippingCostShippingRateDataFixedAmountCurrencyOptions",
- ]
- ]
- """
- Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class CreateParamsShippingCostShippingRateDataFixedAmountCurrencyOptions(
- TypedDict,
- ):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
-
- class CreateParamsShippingDetails(TypedDict):
- address: "Invoice.CreateParamsShippingDetailsAddress"
- """
- Shipping address
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Recipient phone (including extension)
- """
-
- class CreateParamsShippingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class CreatePreviewParams(RequestOptions):
- automatic_tax: NotRequired["Invoice.CreatePreviewParamsAutomaticTax"]
- """
- Settings for automatic tax lookup for this invoice preview.
- """
- currency: NotRequired[str]
- """
- The currency to preview this invoice in. Defaults to that of `customer` if not specified.
- """
- customer: NotRequired[str]
- """
- The identifier of the customer whose upcoming invoice you'd like to retrieve. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.
- """
- customer_details: NotRequired[
- "Invoice.CreatePreviewParamsCustomerDetails"
- ]
- """
- Details about the customer you want to invoice or overrides for an existing customer. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.
- """
- discounts: NotRequired[
- "Literal['']|List[Invoice.CreatePreviewParamsDiscount]"
- ]
- """
- The coupons to redeem into discounts for the invoice preview. If not specified, inherits the discount from the subscription or customer. This works for both coupons directly applied to an invoice and coupons applied to a subscription. Pass an empty string to avoid inheriting any discounts.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_items: NotRequired[
- List["Invoice.CreatePreviewParamsInvoiceItem"]
- ]
- """
- List of invoice items to add or update in the upcoming invoice preview (up to 250).
- """
- issuer: NotRequired["Invoice.CreatePreviewParamsIssuer"]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
- """
- preview_mode: NotRequired[Literal["next", "recurring"]]
- """
- Customizes the types of values to include when calculating the invoice. Defaults to `next` if unspecified.
- """
- schedule: NotRequired[str]
- """
- The identifier of the schedule whose upcoming invoice you'd like to retrieve. Cannot be used with subscription or subscription fields.
- """
- schedule_details: NotRequired[
- "Invoice.CreatePreviewParamsScheduleDetails"
- ]
- """
- The schedule creation or modification params to apply as a preview. Cannot be used with `subscription` or `subscription_` prefixed fields.
- """
- subscription: NotRequired[str]
- """
- The identifier of the subscription for which you'd like to retrieve the upcoming invoice. If not provided, but a `subscription_details.items` is provided, you will preview creating a subscription with those items. If neither `subscription` nor `subscription_details.items` is provided, you will retrieve the next upcoming invoice from among the customer's subscriptions.
- """
- subscription_details: NotRequired[
- "Invoice.CreatePreviewParamsSubscriptionDetails"
- ]
- """
- The subscription creation or modification params to apply as a preview. Cannot be used with `schedule` or `schedule_details` fields.
- """
-
- class CreatePreviewParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Whether Stripe automatically computes tax on this invoice. Note that incompatible invoice items (invoice items with manually specified [tax rates](https://stripe.com/docs/api/tax_rates), negative amounts, or `tax_behavior=unspecified`) cannot be added to automatic tax invoices.
- """
- liability: NotRequired[
- "Invoice.CreatePreviewParamsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreatePreviewParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreatePreviewParamsCustomerDetails(TypedDict):
- address: NotRequired[
- "Literal['']|Invoice.CreatePreviewParamsCustomerDetailsAddress"
- ]
- """
- The customer's address.
- """
- shipping: NotRequired[
- "Literal['']|Invoice.CreatePreviewParamsCustomerDetailsShipping"
- ]
- """
- The customer's shipping information. Appears on invoices emailed to this customer.
- """
- tax: NotRequired["Invoice.CreatePreviewParamsCustomerDetailsTax"]
- """
- Tax details about the customer.
- """
- tax_exempt: NotRequired[
- "Literal['']|Literal['exempt', 'none', 'reverse']"
- ]
- """
- The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
- """
- tax_ids: NotRequired[
- List["Invoice.CreatePreviewParamsCustomerDetailsTaxId"]
- ]
- """
- The customer's tax IDs.
- """
-
- class CreatePreviewParamsCustomerDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreatePreviewParamsCustomerDetailsShipping(TypedDict):
- address: "Invoice.CreatePreviewParamsCustomerDetailsShippingAddress"
- """
- Customer shipping address.
- """
- name: str
- """
- Customer name.
- """
- phone: NotRequired[str]
- """
- Customer phone (including extension).
- """
-
- class CreatePreviewParamsCustomerDetailsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreatePreviewParamsCustomerDetailsTax(TypedDict):
- ip_address: NotRequired["Literal['']|str"]
- """
- A recent IP address of the customer used for tax reporting and tax location inference. Stripe recommends updating the IP address when a new PaymentMethod is attached or the address field on the customer is updated. We recommend against updating this field more frequently since it could result in unexpected tax location/reporting outcomes.
- """
-
- class CreatePreviewParamsCustomerDetailsTaxId(TypedDict):
- type: Literal[
- "ad_nrt",
- "ae_trn",
- "al_tin",
- "am_tin",
- "ao_tin",
- "ar_cuit",
- "au_abn",
- "au_arn",
- "aw_tin",
- "az_tin",
- "ba_tin",
- "bb_tin",
- "bd_bin",
- "bf_ifu",
- "bg_uic",
- "bh_vat",
- "bj_ifu",
- "bo_tin",
- "br_cnpj",
- "br_cpf",
- "bs_tin",
- "by_tin",
- "ca_bn",
- "ca_gst_hst",
- "ca_pst_bc",
- "ca_pst_mb",
- "ca_pst_sk",
- "ca_qst",
- "cd_nif",
- "ch_uid",
- "ch_vat",
- "cl_tin",
- "cm_niu",
- "cn_tin",
- "co_nit",
- "cr_tin",
- "cv_nif",
- "de_stn",
- "do_rcn",
- "ec_ruc",
- "eg_tin",
- "es_cif",
- "et_tin",
- "eu_oss_vat",
- "eu_vat",
- "gb_vat",
- "ge_vat",
- "gn_nif",
- "hk_br",
- "hr_oib",
- "hu_tin",
- "id_npwp",
- "il_vat",
- "in_gst",
- "is_vat",
- "jp_cn",
- "jp_rn",
- "jp_trn",
- "ke_pin",
- "kg_tin",
- "kh_tin",
- "kr_brn",
- "kz_bin",
- "la_tin",
- "li_uid",
- "li_vat",
- "ma_vat",
- "md_vat",
- "me_pib",
- "mk_vat",
- "mr_nif",
- "mx_rfc",
- "my_frp",
- "my_itn",
- "my_sst",
- "ng_tin",
- "no_vat",
- "no_voec",
- "np_pan",
- "nz_gst",
- "om_vat",
- "pe_ruc",
- "ph_tin",
- "ro_tin",
- "rs_pib",
- "ru_inn",
- "ru_kpp",
- "sa_vat",
- "sg_gst",
- "sg_uen",
- "si_tin",
- "sn_ninea",
- "sr_fin",
- "sv_nit",
- "th_vat",
- "tj_tin",
- "tr_tin",
- "tw_vat",
- "tz_vat",
- "ua_vat",
- "ug_tin",
- "us_ein",
- "uy_ruc",
- "uz_tin",
- "uz_vat",
- "ve_rif",
- "vn_tin",
- "za_vat",
- "zm_tin",
- "zw_tin",
- ]
- """
- Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
- """
- value: str
- """
- Value of the tax ID.
- """
-
- class CreatePreviewParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreatePreviewParamsInvoiceItem(TypedDict):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) of previewed invoice item.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Only applicable to new invoice items.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
- """
- discountable: NotRequired[bool]
- """
- Explicitly controls whether discounts apply to this invoice item. Defaults to true, except for negative invoice items.
- """
- discounts: NotRequired[
- "Literal['']|List[Invoice.CreatePreviewParamsInvoiceItemDiscount]"
- ]
- """
- The coupons to redeem into discounts for the invoice item in the preview.
- """
- invoiceitem: NotRequired[str]
- """
- The ID of the invoice item to update in preview. If not specified, a new invoice item will be added to the preview of the upcoming invoice.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired["Invoice.CreatePreviewParamsInvoiceItemPeriod"]
- """
- The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired[
- "Invoice.CreatePreviewParamsInvoiceItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Non-negative integer. The quantity of units for the invoice item.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- tax_code: NotRequired["Literal['']|str"]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates that apply to the item. When set, any `default_tax_rates` do not apply to this item.
- """
- unit_amount: NotRequired[int]
- """
- The integer unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This unit_amount will be multiplied by the quantity to get the full amount. If you want to apply a credit to the customer's account, pass a negative unit_amount.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreatePreviewParamsInvoiceItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreatePreviewParamsInvoiceItemPeriod(TypedDict):
- end: int
- """
- The end of the period, which must be greater than or equal to the start. This value is inclusive.
- """
- start: int
- """
- The start of the period. This value is inclusive.
- """
-
- class CreatePreviewParamsInvoiceItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreatePreviewParamsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreatePreviewParamsScheduleDetails(TypedDict):
- billing_mode: NotRequired[
- "Invoice.CreatePreviewParamsScheduleDetailsBillingMode"
- ]
- """
- Controls how prorations and invoices for subscriptions are calculated and orchestrated.
- """
- end_behavior: NotRequired[Literal["cancel", "release"]]
- """
- Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
- """
- phases: NotRequired[
- List["Invoice.CreatePreviewParamsScheduleDetailsPhase"]
- ]
- """
- List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- In cases where the `schedule_details` params update the currently active phase, specifies if and how to prorate at the time of the request.
- """
-
- class CreatePreviewParamsScheduleDetailsBillingMode(TypedDict):
- flexible: NotRequired[
- "Invoice.CreatePreviewParamsScheduleDetailsBillingModeFlexible"
- ]
- """
- Configure behavior for flexible billing mode.
- """
- type: Literal["classic", "flexible"]
- """
- Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
- """
-
- class CreatePreviewParamsScheduleDetailsBillingModeFlexible(TypedDict):
- proration_discounts: NotRequired[Literal["included", "itemized"]]
- """
- Controls how invoices and invoice items display proration amounts and discount amounts.
- """
-
- class CreatePreviewParamsScheduleDetailsPhase(TypedDict):
- add_invoice_items: NotRequired[
- List[
- "Invoice.CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItem"
- ]
- ]
- """
- A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
- """
- application_fee_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- automatic_tax: NotRequired[
- "Invoice.CreatePreviewParamsScheduleDetailsPhaseAutomaticTax"
- ]
- """
- Automatic tax settings for this phase.
- """
- billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
- """
- Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
- """
- billing_thresholds: NotRequired[
- "Literal['']|Invoice.CreatePreviewParamsScheduleDetailsPhaseBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
- """
- description: NotRequired["Literal['']|str"]
- """
- Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- discounts: NotRequired[
- "Literal['']|List[Invoice.CreatePreviewParamsScheduleDetailsPhaseDiscount]"
- ]
- """
- The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
- """
- duration: NotRequired[
- "Invoice.CreatePreviewParamsScheduleDetailsPhaseDuration"
- ]
- """
- The number of intervals the phase should last. If set, `end_date` must not be set.
- """
- end_date: NotRequired["int|Literal['now']"]
- """
- The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
- """
- invoice_settings: NotRequired[
- "Invoice.CreatePreviewParamsScheduleDetailsPhaseInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- items: List["Invoice.CreatePreviewParamsScheduleDetailsPhaseItem"]
- """
- List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The account on behalf of which to charge, for each of the associated subscription's invoices.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. It's different from the request-level [proration_behavior](https://stripe.com/docs/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration (item price, quantity, etc.) of the current phase.
- """
- start_date: NotRequired["int|Literal['now']"]
- """
- The date at which this phase of the subscription schedule starts or `now`. Must be set on the first phase.
- """
- transfer_data: NotRequired[
- "Invoice.CreatePreviewParamsScheduleDetailsPhaseTransferData"
- ]
- """
- The data with which to automatically create a Transfer for each of the associated subscription's invoices.
- """
- trial: NotRequired[bool]
- """
- If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
- """
- trial_end: NotRequired["int|Literal['now']"]
- """
- Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItem(TypedDict):
- discounts: NotRequired[
- List[
- "Invoice.CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemDiscount"
- ]
- ]
- """
- The coupons to redeem into discounts for the item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired[
- "Invoice.CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriod"
- ]
- """
- The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired[
- "Invoice.CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item. Defaults to 1.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemDiscount(
- TypedDict,
- ):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriod(
- TypedDict,
- ):
- end: "Invoice.CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriodEnd"
- """
- End of the invoice item period.
- """
- start: "Invoice.CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriodStart"
- """
- Start of the invoice item period.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriodEnd(
- TypedDict,
- ):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
- """
- type: Literal["min_item_period_end", "phase_end", "timestamp"]
- """
- Select how to calculate the end of the invoice item period.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriodStart(
- TypedDict,
- ):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
- """
- type: Literal["max_item_period_start", "phase_start", "timestamp"]
- """
- Select how to calculate the start of the invoice item period.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPriceData(
- TypedDict,
- ):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
- liability: NotRequired[
- "Invoice.CreatePreviewParamsScheduleDetailsPhaseAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAutomaticTaxLiability(
- TypedDict,
- ):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseBillingThresholds(TypedDict):
- amount_gte: NotRequired[int]
- """
- Monetary threshold that triggers the subscription to advance to a new billing period
- """
- reset_billing_cycle_anchor: NotRequired[bool]
- """
- Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseDuration(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies phase duration. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The multiplier applied to the interval.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseInvoiceSettings(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
- """
- days_until_due: NotRequired[int]
- """
- Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
- """
- issuer: NotRequired[
- "Invoice.CreatePreviewParamsScheduleDetailsPhaseInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseInvoiceSettingsIssuer(
- TypedDict,
- ):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseItem(TypedDict):
- billing_thresholds: NotRequired[
- "Literal['']|Invoice.CreatePreviewParamsScheduleDetailsPhaseItemBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- discounts: NotRequired[
- "Literal['']|List[Invoice.CreatePreviewParamsScheduleDetailsPhaseItemDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
- """
- plan: NotRequired[str]
- """
- The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
- """
- price: NotRequired[str]
- """
- The ID of the price object.
- """
- price_data: NotRequired[
- "Invoice.CreatePreviewParamsScheduleDetailsPhaseItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- quantity: NotRequired[int]
- """
- Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseItemBillingThresholds(
- TypedDict,
- ):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: "Invoice.CreatePreviewParamsScheduleDetailsPhaseItemPriceDataRecurring"
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseItemPriceDataRecurring(
- TypedDict,
- ):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class CreatePreviewParamsSubscriptionDetails(TypedDict):
- billing_cycle_anchor: NotRequired["Literal['now', 'unchanged']|int"]
- """
- For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`.
- """
- billing_mode: NotRequired[
- "Invoice.CreatePreviewParamsSubscriptionDetailsBillingMode"
- ]
- """
- Controls how prorations and invoices for subscriptions are calculated and orchestrated.
- """
- cancel_at: NotRequired[
- "Literal['']|int|Literal['max_period_end', 'min_period_end']"
- ]
- """
- A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
- """
- cancel_at_period_end: NotRequired[bool]
- """
- Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`.
- """
- cancel_now: NotRequired[bool]
- """
- This simulates the subscription being canceled or expired immediately.
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set.
- """
- items: NotRequired[
- List["Invoice.CreatePreviewParamsSubscriptionDetailsItem"]
- ]
- """
- A list of up to 20 subscription items, each with an attached price.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
- """
- proration_date: NotRequired[int]
- """
- If previewing an update to a subscription, and doing proration, `subscription_details.proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period and within the current phase of the schedule backing this subscription, if the schedule exists. If set, `subscription`, and one of `subscription_details.items`, or `subscription_details.trial_end` are required. Also, `subscription_details.proration_behavior` cannot be set to 'none'.
- """
- resume_at: NotRequired[Literal["now"]]
- """
- For paused subscriptions, setting `subscription_details.resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed.
- """
- start_date: NotRequired[int]
- """
- Date a subscription is intended to start (can be future or past).
- """
- trial_end: NotRequired["Literal['now']|int"]
- """
- If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_details.items` or `subscription` is required.
- """
-
- class CreatePreviewParamsSubscriptionDetailsBillingMode(TypedDict):
- flexible: NotRequired[
- "Invoice.CreatePreviewParamsSubscriptionDetailsBillingModeFlexible"
- ]
- """
- Configure behavior for flexible billing mode.
- """
- type: Literal["classic", "flexible"]
- """
- Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
- """
-
- class CreatePreviewParamsSubscriptionDetailsBillingModeFlexible(TypedDict):
- proration_discounts: NotRequired[Literal["included", "itemized"]]
- """
- Controls how invoices and invoice items display proration amounts and discount amounts.
- """
-
- class CreatePreviewParamsSubscriptionDetailsItem(TypedDict):
- billing_thresholds: NotRequired[
- "Literal['']|Invoice.CreatePreviewParamsSubscriptionDetailsItemBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- clear_usage: NotRequired[bool]
- """
- Delete all usage for a given subscription item. You must pass this when deleting a usage records subscription item. `clear_usage` has no effect if the plan has a billing meter attached.
- """
- deleted: NotRequired[bool]
- """
- A flag that, if set to `true`, will delete the specified item.
- """
- discounts: NotRequired[
- "Literal['']|List[Invoice.CreatePreviewParamsSubscriptionDetailsItemDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- id: NotRequired[str]
- """
- Subscription item to update.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- plan: NotRequired[str]
- """
- Plan ID for this item, as a string.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
- """
- price_data: NotRequired[
- "Invoice.CreatePreviewParamsSubscriptionDetailsItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class CreatePreviewParamsSubscriptionDetailsItemBillingThresholds(
- TypedDict,
- ):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class CreatePreviewParamsSubscriptionDetailsItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreatePreviewParamsSubscriptionDetailsItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: "Invoice.CreatePreviewParamsSubscriptionDetailsItemPriceDataRecurring"
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreatePreviewParamsSubscriptionDetailsItemPriceDataRecurring(
- TypedDict,
- ):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class DeleteParams(RequestOptions):
- pass
-
- class FinalizeInvoiceParams(RequestOptions):
- auto_advance: NotRequired[bool]
- """
- 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.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListLinesParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParams(RequestOptions):
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- The collection method of the invoice to retrieve. Either `charge_automatically` or `send_invoice`.
- """
- created: NotRequired["Invoice.ListParamsCreated|int"]
- """
- Only return invoices that were created during the given date interval.
- """
- customer: NotRequired[str]
- """
- Only return invoices for the customer specified by this customer ID.
- """
- due_date: NotRequired["Invoice.ListParamsDueDate|int"]
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["draft", "open", "paid", "uncollectible", "void"]
- ]
- """
- The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview)
- """
- subscription: NotRequired[str]
- """
- Only return invoices for the subscription specified by this subscription ID.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsDueDate(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class MarkUncollectibleParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ModifyParams(RequestOptions):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
- """
- application_fee_amount: NotRequired[int]
- """
- A fee in cents (or local equivalent) that will be applied to the invoice and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the Stripe-Account header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/billing/invoices/connect#collecting-fees).
- """
- auto_advance: NotRequired[bool]
- """
- Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice.
- """
- automatic_tax: NotRequired["Invoice.ModifyParamsAutomaticTax"]
- """
- Settings for automatic tax lookup for this invoice.
- """
- automatically_finalizes_at: NotRequired[int]
- """
- The time when this invoice should be scheduled to finalize (up to 5 years in the future). The invoice is finalized at this time if it's still in draft state. To turn off automatic finalization, set `auto_advance` to false.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices.
- """
- custom_fields: NotRequired[
- "Literal['']|List[Invoice.ModifyParamsCustomField]"
- ]
- """
- A list of up to 4 custom fields to be displayed on the invoice. If a value for `custom_fields` is specified, the list specified will replace the existing custom field list on this invoice. Pass an empty string to remove previously-defined fields.
- """
- days_until_due: NotRequired[int]
- """
- The number of days from which the invoice is created until it is due. Only valid for invoices where `collection_method=send_invoice`. This field can only be updated on `draft` invoices.
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.
- """
- default_source: NotRequired["Literal['']|str"]
- """
- ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates that will apply to any line item that does not have `tax_rates` set. Pass an empty string to remove previously-defined tax rates.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.
- """
- discounts: NotRequired[
- "Literal['']|List[Invoice.ModifyParamsDiscount]"
- ]
- """
- The discounts that will apply to the invoice. Pass an empty string to remove previously-defined discounts.
- """
- due_date: NotRequired[int]
- """
- The date on which payment for this invoice is due. Only valid for invoices where `collection_method=send_invoice`. This field can only be updated on `draft` invoices.
- """
- effective_at: NotRequired["Literal['']|int"]
- """
- The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- footer: NotRequired[str]
- """
- Footer to be displayed on the invoice.
- """
- issuer: NotRequired["Invoice.ModifyParamsIssuer"]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- number: NotRequired["Literal['']|str"]
- """
- Set the number for this invoice. If no number is present then a number will be assigned automatically when the invoice is finalized. In many markets, regulations require invoices to be unique, sequential and / or gapless. You are responsible for ensuring this is true across all your different invoicing systems in the event that you edit the invoice number using our API. If you use only Stripe for your invoices and do not change invoice numbers, Stripe handles this aspect of compliance for you automatically.
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
- """
- payment_settings: NotRequired["Invoice.ModifyParamsPaymentSettings"]
- """
- Configuration settings for the PaymentIntent that is generated when the invoice is finalized.
- """
- rendering: NotRequired["Invoice.ModifyParamsRendering"]
- """
- The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.
- """
- shipping_cost: NotRequired[
- "Literal['']|Invoice.ModifyParamsShippingCost"
- ]
- """
- Settings for the cost of shipping for this invoice.
- """
- shipping_details: NotRequired[
- "Literal['']|Invoice.ModifyParamsShippingDetails"
- ]
- """
- Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer.
- """
- statement_descriptor: NotRequired[str]
- """
- Extra information about a charge for the customer's credit card statement. It must contain at least one letter. If not specified and this invoice is part of a subscription, the default `statement_descriptor` will be set to the first subscription item's product's `statement_descriptor`.
- """
- transfer_data: NotRequired[
- "Literal['']|Invoice.ModifyParamsTransferData"
- ]
- """
- If specified, the funds from the invoice will be transferred to the destination and the ID of the resulting transfer will be found on the invoice's charge. This will be unset if you POST an empty value.
- """
-
- class ModifyParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Whether Stripe automatically computes tax on this invoice. Note that incompatible invoice items (invoice items with manually specified [tax rates](https://stripe.com/docs/api/tax_rates), negative amounts, or `tax_behavior=unspecified`) cannot be added to automatic tax invoices.
- """
- liability: NotRequired["Invoice.ModifyParamsAutomaticTaxLiability"]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class ModifyParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class ModifyParamsCustomField(TypedDict):
- name: str
- """
- The name of the custom field. This may be up to 40 characters.
- """
- value: str
- """
- The value of the custom field. This may be up to 140 characters.
- """
-
- class ModifyParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class ModifyParamsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class ModifyParamsPaymentSettings(TypedDict):
- default_mandate: NotRequired["Literal['']|str"]
- """
- ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the invoice's default_payment_method or default_source, if set.
- """
- payment_method_options: NotRequired[
- "Invoice.ModifyParamsPaymentSettingsPaymentMethodOptions"
- ]
- """
- Payment-method-specific configuration to provide to the invoice's PaymentIntent.
- """
- payment_method_types: NotRequired[
- "Literal['']|List[Literal['ach_credit_transfer', 'ach_debit', 'acss_debit', 'affirm', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'jp_credit_transfer', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'link', 'multibanco', 'naver_pay', 'nz_bank_account', 'p24', 'payco', 'paynow', 'paypal', 'promptpay', 'revolut_pay', 'sepa_credit_transfer', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
- ]
- """
- The list of payment method types (e.g. card) to provide to the invoice's PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice's default payment method, the subscription's default payment method, the customer's default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice).
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "Literal['']|Invoice.ModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebit"
- ]
- """
- If paying by `acss_debit`, this sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice's PaymentIntent.
- """
- bancontact: NotRequired[
- "Literal['']|Invoice.ModifyParamsPaymentSettingsPaymentMethodOptionsBancontact"
- ]
- """
- If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the invoice's PaymentIntent.
- """
- card: NotRequired[
- "Literal['']|Invoice.ModifyParamsPaymentSettingsPaymentMethodOptionsCard"
- ]
- """
- If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the invoice's PaymentIntent.
- """
- customer_balance: NotRequired[
- "Literal['']|Invoice.ModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalance"
- ]
- """
- If paying by `customer_balance`, this sub-hash contains details about the Bank transfer payment method options to pass to the invoice's PaymentIntent.
- """
- konbini: NotRequired[
- "Literal['']|Invoice.ModifyParamsPaymentSettingsPaymentMethodOptionsKonbini"
- ]
- """
- If paying by `konbini`, this sub-hash contains details about the Konbini payment method options to pass to the invoice's PaymentIntent.
- """
- sepa_debit: NotRequired[
- "Literal['']|Invoice.ModifyParamsPaymentSettingsPaymentMethodOptionsSepaDebit"
- ]
- """
- If paying by `sepa_debit`, this sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice's PaymentIntent.
- """
- us_bank_account: NotRequired[
- "Literal['']|Invoice.ModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If paying by `us_bank_account`, this sub-hash contains details about the ACH direct debit payment method options to pass to the invoice's PaymentIntent.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebit(TypedDict):
- mandate_options: NotRequired[
- "Invoice.ModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions(
- TypedDict,
- ):
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsBancontact(TypedDict):
- preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
- """
- Preferred language of the Bancontact authorization page that the customer is redirected to.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsCard(TypedDict):
- installments: NotRequired[
- "Invoice.ModifyParamsPaymentSettingsPaymentMethodOptionsCardInstallments"
- ]
- """
- Installment configuration for payments attempted on this invoice.
-
- For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsCardInstallments(
- TypedDict,
- ):
- enabled: NotRequired[bool]
- """
- Setting to true enables installments for this invoice.
- Setting to false will prevent any selected plan from applying to a payment.
- """
- plan: NotRequired[
- "Literal['']|Invoice.ModifyParamsPaymentSettingsPaymentMethodOptionsCardInstallmentsPlan"
- ]
- """
- The selected installment plan to use for this invoice.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsCardInstallmentsPlan(
- TypedDict,
- ):
- count: NotRequired[int]
- """
- For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
- """
- interval: NotRequired[Literal["month"]]
- """
- For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
- One of `month`.
- """
- type: Literal["bonus", "fixed_count", "revolving"]
- """
- Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalance(
- TypedDict,
- ):
- bank_transfer: NotRequired[
- "Invoice.ModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[str]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "Invoice.ModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for eu_bank_transfer funding type.
- """
- type: NotRequired[str]
- """
- The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsKonbini(TypedDict):
- pass
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsSepaDebit(TypedDict):
- pass
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccount(
- TypedDict,
- ):
- financial_connections: NotRequired[
- "Invoice.ModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "Invoice.ModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class ModifyParamsRendering(TypedDict):
- amount_tax_display: NotRequired[
- "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
- ]
- """
- How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
- """
- pdf: NotRequired["Invoice.ModifyParamsRenderingPdf"]
- """
- Invoice pdf rendering options
- """
- template: NotRequired[str]
- """
- ID of the invoice rendering template to use for this invoice.
- """
- template_version: NotRequired["Literal['']|int"]
- """
- The specific version of invoice rendering template to use for this invoice.
- """
-
- class ModifyParamsRenderingPdf(TypedDict):
- page_size: NotRequired[Literal["a4", "auto", "letter"]]
- """
- Page size for invoice PDF. Can be set to `a4`, `letter`, or `auto`.
- If set to `auto`, invoice PDF page size defaults to `a4` for customers with
- Japanese locale and `letter` for customers with other locales.
- """
-
- class ModifyParamsShippingCost(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the shipping rate to use for this order.
- """
- shipping_rate_data: NotRequired[
- "Invoice.ModifyParamsShippingCostShippingRateData"
- ]
- """
- Parameters to create a new ad-hoc shipping rate for this order.
- """
-
- class ModifyParamsShippingCostShippingRateData(TypedDict):
- delivery_estimate: NotRequired[
- "Invoice.ModifyParamsShippingCostShippingRateDataDeliveryEstimate"
- ]
- """
- The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- display_name: str
- """
- The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- fixed_amount: NotRequired[
- "Invoice.ModifyParamsShippingCostShippingRateDataFixedAmount"
- ]
- """
- Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
- """
- type: NotRequired[Literal["fixed_amount"]]
- """
- The type of calculation to use on the shipping rate.
- """
-
- class ModifyParamsShippingCostShippingRateDataDeliveryEstimate(TypedDict):
- maximum: NotRequired[
- "Invoice.ModifyParamsShippingCostShippingRateDataDeliveryEstimateMaximum"
- ]
- """
- The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
- """
- minimum: NotRequired[
- "Invoice.ModifyParamsShippingCostShippingRateDataDeliveryEstimateMinimum"
- ]
- """
- The lower bound of the estimated range. If empty, represents no lower bound.
- """
-
- class ModifyParamsShippingCostShippingRateDataDeliveryEstimateMaximum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class ModifyParamsShippingCostShippingRateDataDeliveryEstimateMinimum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class ModifyParamsShippingCostShippingRateDataFixedAmount(TypedDict):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- currency_options: NotRequired[
- Dict[
- str,
- "Invoice.ModifyParamsShippingCostShippingRateDataFixedAmountCurrencyOptions",
- ]
- ]
- """
- Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class ModifyParamsShippingCostShippingRateDataFixedAmountCurrencyOptions(
- TypedDict,
- ):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
-
- class ModifyParamsShippingDetails(TypedDict):
- address: "Invoice.ModifyParamsShippingDetailsAddress"
- """
- Shipping address
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Recipient phone (including extension)
- """
-
- class ModifyParamsShippingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ModifyParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class PayParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- forgive: NotRequired[bool]
- """
- In cases where the source used to pay the invoice has insufficient funds, passing `forgive=true` controls whether a charge should be attempted for the full amount available on the source, up to the amount to fully pay the invoice. This effectively forgives the difference between the amount available on the source and the amount due.
-
- Passing `forgive=false` will fail the charge if the source hasn't been pre-funded with the right amount. An example for this case is with ACH Credit Transfers and wires: if the amount wired is less than the amount due by a small amount, you might want to forgive the difference. Defaults to `false`.
- """
- mandate: NotRequired["Literal['']|str"]
- """
- ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the payment_method param or the invoice's default_payment_method or default_source, if set.
- """
- off_session: NotRequired[bool]
- """
- Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `true` (off-session).
- """
- paid_out_of_band: NotRequired[bool]
- """
- Boolean representing whether an invoice is paid outside of Stripe. This will result in no charge being made. Defaults to `false`.
- """
- payment_method: NotRequired[str]
- """
- A PaymentMethod to be charged. The PaymentMethod must be the ID of a PaymentMethod belonging to the customer associated with the invoice being paid.
- """
- source: NotRequired[str]
- """
- A payment source to be charged. The source must be the ID of a source belonging to the customer associated with the invoice being paid.
- """
-
- class RemoveLinesParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- lines: List["Invoice.RemoveLinesParamsLine"]
- """
- The line items to remove.
- """
-
- class RemoveLinesParamsLine(TypedDict):
- behavior: Literal["delete", "unassign"]
- """
- Either `delete` or `unassign`. Deleted line items are permanently deleted. Unassigned line items can be reassigned to an invoice.
- """
- id: str
- """
- ID of an existing line item to remove from this invoice.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SearchParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- page: NotRequired[str]
- """
- A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
- """
- query: str
- """
- The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for invoices](https://stripe.com/docs/search#query-fields-for-invoices).
- """
-
- class SendInvoiceParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateLinesParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data.
- """
- lines: List["Invoice.UpdateLinesParamsLine"]
- """
- The line items to update.
- """
-
- class UpdateLinesParamsLine(TypedDict):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
- """
- discountable: NotRequired[bool]
- """
- Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.
- """
- discounts: NotRequired[
- "Literal['']|List[Invoice.UpdateLinesParamsLineDiscount]"
- ]
- """
- The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
- """
- id: str
- """
- ID of an existing line item on the invoice.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data.
- """
- period: NotRequired["Invoice.UpdateLinesParamsLinePeriod"]
- """
- The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
- """
- price_data: NotRequired["Invoice.UpdateLinesParamsLinePriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- pricing: NotRequired["Invoice.UpdateLinesParamsLinePricing"]
- """
- The pricing information for the invoice item.
- """
- quantity: NotRequired[int]
- """
- Non-negative integer. The quantity of units for the line item.
- """
- tax_amounts: NotRequired[
- "Literal['']|List[Invoice.UpdateLinesParamsLineTaxAmount]"
- ]
- """
- A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has [tax_rates](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-tax_rates) or if the invoice has [default_tax_rates](https://stripe.com/docs/api/invoices/object#invoice_object-default_tax_rates) or uses [automatic tax](https://stripe.com/docs/tax/invoicing). Pass an empty string to remove previously defined tax amounts.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the line item. When set, the `default_tax_rates` on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.
- """
-
- class UpdateLinesParamsLineDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class UpdateLinesParamsLinePeriod(TypedDict):
- end: int
- """
- The end of the period, which must be greater than or equal to the start. This value is inclusive.
- """
- start: int
- """
- The start of the period. This value is inclusive.
- """
-
- class UpdateLinesParamsLinePriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: NotRequired[str]
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
- """
- product_data: NotRequired[
- "Invoice.UpdateLinesParamsLinePriceDataProductData"
- ]
- """
- Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class UpdateLinesParamsLinePriceDataProductData(TypedDict):
- description: NotRequired[str]
- """
- The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
- """
- images: NotRequired[List[str]]
- """
- A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The product's name, meant to be displayable to the customer.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- unit_label: NotRequired[str]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
- """
-
- class UpdateLinesParamsLinePricing(TypedDict):
- price: NotRequired[str]
- """
- The ID of the price object.
- """
-
- class UpdateLinesParamsLineTaxAmount(TypedDict):
- amount: int
- """
- The amount, in cents (or local equivalent), of the tax.
- """
- tax_rate_data: "Invoice.UpdateLinesParamsLineTaxAmountTaxRateData"
- """
- Data to find or create a TaxRate object.
-
- Stripe automatically creates or reuses a TaxRate object for each tax amount. If the `tax_rate_data` exactly matches a previous value, Stripe will reuse the TaxRate object. TaxRate objects created automatically by Stripe are immediately archived, do not appear in the line item's `tax_rates`, and cannot be directly added to invoices, payments, or line items.
- """
- taxability_reason: NotRequired[
- Literal[
- "customer_exempt",
- "not_collecting",
- "not_subject_to_tax",
- "not_supported",
- "portion_product_exempt",
- "portion_reduced_rated",
- "portion_standard_rated",
- "product_exempt",
- "product_exempt_holiday",
- "proportionally_rated",
- "reduced_rated",
- "reverse_charge",
- "standard_rated",
- "taxable_basis_reduced",
- "zero_rated",
- ]
- ]
- """
- The reasoning behind this tax, for example, if the product is tax exempt.
- """
- taxable_amount: int
- """
- The amount on which tax is calculated, in cents (or local equivalent).
- """
-
- class UpdateLinesParamsLineTaxAmountTaxRateData(TypedDict):
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
- """
- display_name: str
- """
- The display name of the tax rate, which will be shown to users.
- """
- inclusive: bool
- """
- This specifies if the tax rate is inclusive or exclusive.
- """
- jurisdiction: NotRequired[str]
- """
- The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer's invoice.
- """
- jurisdiction_level: NotRequired[
- Literal[
- "city", "country", "county", "district", "multiple", "state"
- ]
- ]
- """
- The level of the jurisdiction that imposes this tax rate.
- """
- percentage: float
- """
- The statutory tax rate percent. This field accepts decimal values between 0 and 100 inclusive with at most 4 decimal places. To accommodate fixed-amount taxes, set the percentage to zero. Stripe will not display zero percentages on the invoice unless the `amount` of the tax is also zero.
- """
- state: NotRequired[str]
- """
- [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, "NY" for New York, United States.
- """
- tax_type: NotRequired[
- Literal[
- "amusement_tax",
- "communications_tax",
- "gst",
- "hst",
- "igst",
- "jct",
- "lease_tax",
- "pst",
- "qst",
- "retail_delivery_fee",
- "rst",
- "sales_tax",
- "service_tax",
- "vat",
- ]
- ]
- """
- The high-level tax type, such as `vat` or `sales_tax`.
- """
-
- class VoidInvoiceParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- account_country: Optional[str]
- """
- The country of the business associated with this invoice, most often the business creating the invoice.
- """
- account_name: Optional[str]
- """
- The public name of the business associated with this invoice, most often the business creating the invoice.
- """
- account_tax_ids: Optional[List[ExpandableField["TaxId"]]]
- """
- The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
- """
- amount_due: int
- """
- Final amount due at this time for this invoice. If the invoice's total is smaller than the minimum charge amount, for example, or if there is account credit that can be applied to the invoice, the `amount_due` may be 0. If there is a positive `starting_balance` for the invoice (the customer owes money), the `amount_due` will also take that into account. The charge that gets generated for the invoice will be for the amount specified in `amount_due`.
- """
- amount_overpaid: int
- """
- Amount that was overpaid on the invoice. The amount overpaid is credited to the customer's credit balance.
- """
- amount_paid: int
- """
- The amount, in cents (or local equivalent), that was paid.
- """
- amount_remaining: int
- """
- The difference between amount_due and amount_paid, in cents (or local equivalent).
- """
- amount_shipping: int
- """
- This is the sum of all the shipping amounts.
- """
- application: Optional[ExpandableField["Application"]]
- """
- ID of the Connect Application that created the invoice.
- """
- attempt_count: int
- """
- Number of payment attempts made for this invoice, from the perspective of the payment retry schedule. Any payment attempt counts as the first attempt, and subsequently only automatic retries increment the attempt count. In other words, manual payment attempts after the first attempt do not affect the retry schedule. If a failure is returned with a non-retryable return code, the invoice can no longer be retried unless a new payment method is obtained. Retries will continue to be scheduled, and attempt_count will continue to increment, but retries will only be executed if a new payment method is obtained.
- """
- attempted: bool
- """
- Whether an attempt has been made to pay the invoice. An invoice is not attempted until 1 hour after the `invoice.created` webhook, for example, so you might not want to display that invoice as unpaid to your users.
- """
- auto_advance: Optional[bool]
- """
- 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",
- "manual",
- "quote_accept",
- "subscription",
- "subscription_create",
- "subscription_cycle",
- "subscription_threshold",
- "subscription_update",
- "upcoming",
- ]
- ]
- """
- Indicates the reason why the invoice was created.
-
- * `manual`: Unrelated to a subscription, for example, created via the invoice editor.
- * `subscription`: No longer in use. Applies to subscriptions from before May 2018 where no distinction was made between updates, cycles, and thresholds.
- * `subscription_create`: A new subscription was created.
- * `subscription_cycle`: A subscription advanced into a new period.
- * `subscription_threshold`: A subscription reached a billing threshold.
- * `subscription_update`: A subscription was updated.
- * `upcoming`: Reserved for simulated invoices, per the upcoming invoice endpoint.
- """
- collection_method: Literal["charge_automatically", "send_invoice"]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions.
- """
- confirmation_secret: Optional[ConfirmationSecret]
- """
- The confirmation secret associated with this invoice. Currently, this contains the client_secret of the PaymentIntent that Stripe creates during invoice finalization.
- """
- created: int
- """
- Time at which the object was created. Measured in seconds since the Unix epoch.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- custom_fields: Optional[List[CustomField]]
- """
- Custom fields displayed on the invoice.
- """
- customer: Optional[ExpandableField["Customer"]]
- """
- The ID of the customer who will be billed.
- """
- customer_address: Optional[CustomerAddress]
- """
- The customer's address. Until the invoice is finalized, this field will equal `customer.address`. Once the invoice is finalized, this field will no longer be updated.
- """
- customer_email: Optional[str]
- """
- The customer's email. Until the invoice is finalized, this field will equal `customer.email`. Once the invoice is finalized, this field will no longer be updated.
- """
- customer_name: Optional[str]
- """
- The customer's name. Until the invoice is finalized, this field will equal `customer.name`. Once the invoice is finalized, this field will no longer be updated.
- """
- customer_phone: Optional[str]
- """
- The customer's phone number. Until the invoice is finalized, this field will equal `customer.phone`. Once the invoice is finalized, this field will no longer be updated.
- """
- customer_shipping: Optional[CustomerShipping]
- """
- The customer's shipping information. Until the invoice is finalized, this field will equal `customer.shipping`. Once the invoice is finalized, this field will no longer be updated.
- """
- customer_tax_exempt: Optional[Literal["exempt", "none", "reverse"]]
- """
- The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated.
- """
- customer_tax_ids: Optional[List[CustomerTaxId]]
- """
- The customer's tax IDs. Until the invoice is finalized, this field will contain the same tax IDs as `customer.tax_ids`. Once the invoice is finalized, this field will no longer be updated.
- """
- default_payment_method: Optional[ExpandableField["PaymentMethod"]]
- """
- ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.
- """
- default_source: Optional[
- ExpandableField[
- Union["Account", "BankAccount", "CardResource", "Source"]
+ * `manual`: Unrelated to a subscription, for example, created via the invoice editor.
+ * `subscription`: No longer in use. Applies to subscriptions from before May 2018 where no distinction was made between updates, cycles, and thresholds.
+ * `subscription_create`: A new subscription was created.
+ * `subscription_cycle`: A subscription advanced into a new period.
+ * `subscription_threshold`: A subscription reached a billing threshold.
+ * `subscription_update`: A subscription was updated.
+ * `upcoming`: Reserved for simulated invoices, per the upcoming invoice endpoint.
+ """
+ collection_method: Literal["charge_automatically", "send_invoice"]
+ """
+ Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions.
+ """
+ confirmation_secret: Optional[ConfirmationSecret]
+ """
+ The confirmation secret associated with this invoice. Currently, this contains the client_secret of the PaymentIntent that Stripe creates during invoice finalization.
+ """
+ created: int
+ """
+ Time at which the object was created. Measured in seconds since the Unix epoch.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ custom_fields: Optional[List[CustomField]]
+ """
+ Custom fields displayed on the invoice.
+ """
+ customer: Optional[ExpandableField["Customer"]]
+ """
+ The ID of the customer who will be billed.
+ """
+ customer_address: Optional[CustomerAddress]
+ """
+ The customer's address. Until the invoice is finalized, this field will equal `customer.address`. Once the invoice is finalized, this field will no longer be updated.
+ """
+ customer_email: Optional[str]
+ """
+ The customer's email. Until the invoice is finalized, this field will equal `customer.email`. Once the invoice is finalized, this field will no longer be updated.
+ """
+ customer_name: Optional[str]
+ """
+ The customer's name. Until the invoice is finalized, this field will equal `customer.name`. Once the invoice is finalized, this field will no longer be updated.
+ """
+ customer_phone: Optional[str]
+ """
+ The customer's phone number. Until the invoice is finalized, this field will equal `customer.phone`. Once the invoice is finalized, this field will no longer be updated.
+ """
+ customer_shipping: Optional[CustomerShipping]
+ """
+ The customer's shipping information. Until the invoice is finalized, this field will equal `customer.shipping`. Once the invoice is finalized, this field will no longer be updated.
+ """
+ customer_tax_exempt: Optional[Literal["exempt", "none", "reverse"]]
+ """
+ The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated.
+ """
+ customer_tax_ids: Optional[List[CustomerTaxId]]
+ """
+ The customer's tax IDs. Until the invoice is finalized, this field will contain the same tax IDs as `customer.tax_ids`. Once the invoice is finalized, this field will no longer be updated.
+ """
+ default_payment_method: Optional[ExpandableField["PaymentMethod"]]
+ """
+ ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.
+ """
+ default_source: Optional[
+ ExpandableField[
+ Union["Account", "BankAccount", "CardResource", "Source"]
]
]
"""
@@ -4543,7 +1500,7 @@ class VoidInvoiceParams(RequestOptions):
@classmethod
def _cls_add_lines(
- cls, invoice: str, **params: Unpack["Invoice.AddLinesParams"]
+ 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.
@@ -4562,7 +1519,7 @@ def _cls_add_lines(
@overload
@staticmethod
def add_lines(
- invoice: str, **params: Unpack["Invoice.AddLinesParams"]
+ invoice: str, **params: Unpack["InvoiceAddLinesParams"]
) -> "Invoice":
"""
Adds multiple line items to an invoice. This is only possible when an invoice is still a draft.
@@ -4571,7 +1528,7 @@ def add_lines(
@overload
def add_lines(
- self, **params: Unpack["Invoice.AddLinesParams"]
+ self, **params: Unpack["InvoiceAddLinesParams"]
) -> "Invoice":
"""
Adds multiple line items to an invoice. This is only possible when an invoice is still a draft.
@@ -4580,7 +1537,7 @@ def add_lines(
@class_method_variant("_cls_add_lines")
def add_lines( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.AddLinesParams"]
+ self, **params: Unpack["InvoiceAddLinesParams"]
) -> "Invoice":
"""
Adds multiple line items to an invoice. This is only possible when an invoice is still a draft.
@@ -4598,7 +1555,7 @@ def add_lines( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_add_lines_async(
- cls, invoice: str, **params: Unpack["Invoice.AddLinesParams"]
+ 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.
@@ -4617,7 +1574,7 @@ async def _cls_add_lines_async(
@overload
@staticmethod
async def add_lines_async(
- invoice: str, **params: Unpack["Invoice.AddLinesParams"]
+ invoice: str, **params: Unpack["InvoiceAddLinesParams"]
) -> "Invoice":
"""
Adds multiple line items to an invoice. This is only possible when an invoice is still a draft.
@@ -4626,7 +1583,7 @@ async def add_lines_async(
@overload
async def add_lines_async(
- self, **params: Unpack["Invoice.AddLinesParams"]
+ self, **params: Unpack["InvoiceAddLinesParams"]
) -> "Invoice":
"""
Adds multiple line items to an invoice. This is only possible when an invoice is still a draft.
@@ -4635,7 +1592,7 @@ async def add_lines_async(
@class_method_variant("_cls_add_lines_async")
async def add_lines_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.AddLinesParams"]
+ self, **params: Unpack["InvoiceAddLinesParams"]
) -> "Invoice":
"""
Adds multiple line items to an invoice. This is only possible when an invoice is still a draft.
@@ -4653,7 +1610,7 @@ async def add_lines_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_attach_payment(
- cls, invoice: str, **params: Unpack["Invoice.AttachPaymentParams"]
+ 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.
@@ -4681,7 +1638,7 @@ def _cls_attach_payment(
@overload
@staticmethod
def attach_payment(
- invoice: str, **params: Unpack["Invoice.AttachPaymentParams"]
+ 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.
@@ -4699,7 +1656,7 @@ def attach_payment(
@overload
def attach_payment(
- self, **params: Unpack["Invoice.AttachPaymentParams"]
+ self, **params: Unpack["InvoiceAttachPaymentParams"]
) -> "Invoice":
"""
Attaches a PaymentIntent or an Out of Band Payment to the invoice, adding it to the list of payments.
@@ -4717,7 +1674,7 @@ def attach_payment(
@class_method_variant("_cls_attach_payment")
def attach_payment( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.AttachPaymentParams"]
+ self, **params: Unpack["InvoiceAttachPaymentParams"]
) -> "Invoice":
"""
Attaches a PaymentIntent or an Out of Band Payment to the invoice, adding it to the list of payments.
@@ -4744,7 +1701,7 @@ def attach_payment( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_attach_payment_async(
- cls, invoice: str, **params: Unpack["Invoice.AttachPaymentParams"]
+ 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.
@@ -4772,7 +1729,7 @@ async def _cls_attach_payment_async(
@overload
@staticmethod
async def attach_payment_async(
- invoice: str, **params: Unpack["Invoice.AttachPaymentParams"]
+ 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.
@@ -4790,7 +1747,7 @@ async def attach_payment_async(
@overload
async def attach_payment_async(
- self, **params: Unpack["Invoice.AttachPaymentParams"]
+ self, **params: Unpack["InvoiceAttachPaymentParams"]
) -> "Invoice":
"""
Attaches a PaymentIntent or an Out of Band Payment to the invoice, adding it to the list of payments.
@@ -4808,7 +1765,7 @@ async def attach_payment_async(
@class_method_variant("_cls_attach_payment_async")
async def attach_payment_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.AttachPaymentParams"]
+ self, **params: Unpack["InvoiceAttachPaymentParams"]
) -> "Invoice":
"""
Attaches a PaymentIntent or an Out of Band Payment to the invoice, adding it to the list of payments.
@@ -4834,7 +1791,7 @@ async def attach_payment_async( # pyright: ignore[reportGeneralTypeIssues]
)
@classmethod
- def create(cls, **params: Unpack["Invoice.CreateParams"]) -> "Invoice":
+ def create(cls, **params: Unpack["InvoiceCreateParams"]) -> "Invoice":
"""
This endpoint creates a draft invoice for a given customer. The invoice remains a draft until you [finalize the invoice, which allows you to [pay](#pay_invoice) or send](https://docs.stripe.com/api#finalize_invoice) the invoice to your customers.
"""
@@ -4849,7 +1806,7 @@ def create(cls, **params: Unpack["Invoice.CreateParams"]) -> "Invoice":
@classmethod
async def create_async(
- cls, **params: Unpack["Invoice.CreateParams"]
+ cls, **params: Unpack["InvoiceCreateParams"]
) -> "Invoice":
"""
This endpoint creates a draft invoice for a given customer. The invoice remains a draft until you [finalize the invoice, which allows you to [pay](#pay_invoice) or send](https://docs.stripe.com/api#finalize_invoice) the invoice to your customers.
@@ -4865,7 +1822,7 @@ async def create_async(
@classmethod
def create_preview(
- cls, **params: Unpack["Invoice.CreatePreviewParams"]
+ cls, **params: Unpack["InvoiceCreatePreviewParams"]
) -> "Invoice":
"""
At any time, you can preview the upcoming invoice for a subscription or subscription schedule. This will show you all the charges that are pending, including subscription renewal charges, invoice item charges, etc. It will also show you any discounts that are applicable to the invoice.
@@ -4889,7 +1846,7 @@ def create_preview(
@classmethod
async def create_preview_async(
- cls, **params: Unpack["Invoice.CreatePreviewParams"]
+ cls, **params: Unpack["InvoiceCreatePreviewParams"]
) -> "Invoice":
"""
At any time, you can preview the upcoming invoice for a subscription or subscription schedule. This will show you all the charges that are pending, including subscription renewal charges, invoice item charges, etc. It will also show you any discounts that are applicable to the invoice.
@@ -4913,7 +1870,7 @@ async def create_preview_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["Invoice.DeleteParams"]
+ cls, sid: str, **params: Unpack["InvoiceDeleteParams"]
) -> "Invoice":
"""
Permanently deletes a one-off invoice draft. This cannot be undone. Attempts to delete invoices that are no longer in a draft state will fail; once an invoice has been finalized or if an invoice is for a subscription, it must be [voided](https://docs.stripe.com/api#void_invoice).
@@ -4930,16 +1887,14 @@ def _cls_delete(
@overload
@staticmethod
- def delete(
- sid: str, **params: Unpack["Invoice.DeleteParams"]
- ) -> "Invoice":
+ def delete(sid: str, **params: Unpack["InvoiceDeleteParams"]) -> "Invoice":
"""
Permanently deletes a one-off invoice draft. This cannot be undone. Attempts to delete invoices that are no longer in a draft state will fail; once an invoice has been finalized or if an invoice is for a subscription, it must be [voided](https://docs.stripe.com/api#void_invoice).
"""
...
@overload
- def delete(self, **params: Unpack["Invoice.DeleteParams"]) -> "Invoice":
+ def delete(self, **params: Unpack["InvoiceDeleteParams"]) -> "Invoice":
"""
Permanently deletes a one-off invoice draft. This cannot be undone. Attempts to delete invoices that are no longer in a draft state will fail; once an invoice has been finalized or if an invoice is for a subscription, it must be [voided](https://docs.stripe.com/api#void_invoice).
"""
@@ -4947,7 +1902,7 @@ def delete(self, **params: Unpack["Invoice.DeleteParams"]) -> "Invoice":
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.DeleteParams"]
+ self, **params: Unpack["InvoiceDeleteParams"]
) -> "Invoice":
"""
Permanently deletes a one-off invoice draft. This cannot be undone. Attempts to delete invoices that are no longer in a draft state will fail; once an invoice has been finalized or if an invoice is for a subscription, it must be [voided](https://docs.stripe.com/api#void_invoice).
@@ -4960,7 +1915,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["Invoice.DeleteParams"]
+ cls, sid: str, **params: Unpack["InvoiceDeleteParams"]
) -> "Invoice":
"""
Permanently deletes a one-off invoice draft. This cannot be undone. Attempts to delete invoices that are no longer in a draft state will fail; once an invoice has been finalized or if an invoice is for a subscription, it must be [voided](https://docs.stripe.com/api#void_invoice).
@@ -4978,7 +1933,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["Invoice.DeleteParams"]
+ sid: str, **params: Unpack["InvoiceDeleteParams"]
) -> "Invoice":
"""
Permanently deletes a one-off invoice draft. This cannot be undone. Attempts to delete invoices that are no longer in a draft state will fail; once an invoice has been finalized or if an invoice is for a subscription, it must be [voided](https://docs.stripe.com/api#void_invoice).
@@ -4987,7 +1942,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["Invoice.DeleteParams"]
+ self, **params: Unpack["InvoiceDeleteParams"]
) -> "Invoice":
"""
Permanently deletes a one-off invoice draft. This cannot be undone. Attempts to delete invoices that are no longer in a draft state will fail; once an invoice has been finalized or if an invoice is for a subscription, it must be [voided](https://docs.stripe.com/api#void_invoice).
@@ -4996,7 +1951,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.DeleteParams"]
+ self, **params: Unpack["InvoiceDeleteParams"]
) -> "Invoice":
"""
Permanently deletes a one-off invoice draft. This cannot be undone. Attempts to delete invoices that are no longer in a draft state will fail; once an invoice has been finalized or if an invoice is for a subscription, it must be [voided](https://docs.stripe.com/api#void_invoice).
@@ -5009,7 +1964,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_finalize_invoice(
- cls, invoice: str, **params: Unpack["Invoice.FinalizeInvoiceParams"]
+ 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.
@@ -5028,7 +1983,7 @@ def _cls_finalize_invoice(
@overload
@staticmethod
def finalize_invoice(
- invoice: str, **params: Unpack["Invoice.FinalizeInvoiceParams"]
+ 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.
@@ -5037,7 +1992,7 @@ def finalize_invoice(
@overload
def finalize_invoice(
- self, **params: Unpack["Invoice.FinalizeInvoiceParams"]
+ self, **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.
@@ -5046,7 +2001,7 @@ def finalize_invoice(
@class_method_variant("_cls_finalize_invoice")
def finalize_invoice( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.FinalizeInvoiceParams"]
+ self, **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.
@@ -5064,7 +2019,7 @@ def finalize_invoice( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_finalize_invoice_async(
- cls, invoice: str, **params: Unpack["Invoice.FinalizeInvoiceParams"]
+ 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.
@@ -5083,7 +2038,7 @@ async def _cls_finalize_invoice_async(
@overload
@staticmethod
async def finalize_invoice_async(
- invoice: str, **params: Unpack["Invoice.FinalizeInvoiceParams"]
+ 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.
@@ -5092,7 +2047,7 @@ async def finalize_invoice_async(
@overload
async def finalize_invoice_async(
- self, **params: Unpack["Invoice.FinalizeInvoiceParams"]
+ self, **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.
@@ -5101,7 +2056,7 @@ async def finalize_invoice_async(
@class_method_variant("_cls_finalize_invoice_async")
async def finalize_invoice_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.FinalizeInvoiceParams"]
+ self, **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.
@@ -5119,7 +2074,7 @@ async def finalize_invoice_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["Invoice.ListParams"]
+ cls, **params: Unpack["InvoiceListParams"]
) -> ListObject["Invoice"]:
"""
You can list all invoices, or list the invoices for a specific customer. The invoices are returned sorted by creation date, with the most recently created invoices appearing first.
@@ -5139,7 +2094,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Invoice.ListParams"]
+ cls, **params: Unpack["InvoiceListParams"]
) -> ListObject["Invoice"]:
"""
You can list all invoices, or list the invoices for a specific customer. The invoices are returned sorted by creation date, with the most recently created invoices appearing first.
@@ -5159,7 +2114,7 @@ async def list_async(
@classmethod
def _cls_mark_uncollectible(
- cls, invoice: str, **params: Unpack["Invoice.MarkUncollectibleParams"]
+ 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.
@@ -5178,7 +2133,7 @@ def _cls_mark_uncollectible(
@overload
@staticmethod
def mark_uncollectible(
- invoice: str, **params: Unpack["Invoice.MarkUncollectibleParams"]
+ 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.
@@ -5187,7 +2142,7 @@ def mark_uncollectible(
@overload
def mark_uncollectible(
- self, **params: Unpack["Invoice.MarkUncollectibleParams"]
+ self, **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.
@@ -5196,7 +2151,7 @@ def mark_uncollectible(
@class_method_variant("_cls_mark_uncollectible")
def mark_uncollectible( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.MarkUncollectibleParams"]
+ self, **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.
@@ -5214,7 +2169,7 @@ def mark_uncollectible( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_mark_uncollectible_async(
- cls, invoice: str, **params: Unpack["Invoice.MarkUncollectibleParams"]
+ 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.
@@ -5233,7 +2188,7 @@ async def _cls_mark_uncollectible_async(
@overload
@staticmethod
async def mark_uncollectible_async(
- invoice: str, **params: Unpack["Invoice.MarkUncollectibleParams"]
+ 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.
@@ -5242,7 +2197,7 @@ async def mark_uncollectible_async(
@overload
async def mark_uncollectible_async(
- self, **params: Unpack["Invoice.MarkUncollectibleParams"]
+ self, **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.
@@ -5251,7 +2206,7 @@ async def mark_uncollectible_async(
@class_method_variant("_cls_mark_uncollectible_async")
async def mark_uncollectible_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.MarkUncollectibleParams"]
+ self, **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.
@@ -5269,7 +2224,7 @@ async def mark_uncollectible_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def modify(
- cls, id: str, **params: Unpack["Invoice.ModifyParams"]
+ cls, id: str, **params: Unpack["InvoiceModifyParams"]
) -> "Invoice":
"""
Draft invoices are fully editable. Once an invoice is [finalized](https://docs.stripe.com/docs/billing/invoices/workflow#finalized),
@@ -5291,7 +2246,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Invoice.ModifyParams"]
+ cls, id: str, **params: Unpack["InvoiceModifyParams"]
) -> "Invoice":
"""
Draft invoices are fully editable. Once an invoice is [finalized](https://docs.stripe.com/docs/billing/invoices/workflow#finalized),
@@ -5313,7 +2268,7 @@ async def modify_async(
@classmethod
def _cls_pay(
- cls, invoice: str, **params: Unpack["Invoice.PayParams"]
+ 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.
@@ -5331,14 +2286,14 @@ def _cls_pay(
@overload
@staticmethod
- def pay(invoice: str, **params: Unpack["Invoice.PayParams"]) -> "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.
"""
...
@overload
- def pay(self, **params: Unpack["Invoice.PayParams"]) -> "Invoice":
+ def pay(self, **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.
"""
@@ -5346,7 +2301,7 @@ def pay(self, **params: Unpack["Invoice.PayParams"]) -> "Invoice":
@class_method_variant("_cls_pay")
def pay( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.PayParams"]
+ self, **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.
@@ -5364,7 +2319,7 @@ def pay( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_pay_async(
- cls, invoice: str, **params: Unpack["Invoice.PayParams"]
+ 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.
@@ -5383,7 +2338,7 @@ async def _cls_pay_async(
@overload
@staticmethod
async def pay_async(
- invoice: str, **params: Unpack["Invoice.PayParams"]
+ 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.
@@ -5392,7 +2347,7 @@ async def pay_async(
@overload
async def pay_async(
- self, **params: Unpack["Invoice.PayParams"]
+ self, **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.
@@ -5401,7 +2356,7 @@ async def pay_async(
@class_method_variant("_cls_pay_async")
async def pay_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.PayParams"]
+ self, **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.
@@ -5419,7 +2374,7 @@ async def pay_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_remove_lines(
- cls, invoice: str, **params: Unpack["Invoice.RemoveLinesParams"]
+ 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.
@@ -5438,7 +2393,7 @@ def _cls_remove_lines(
@overload
@staticmethod
def remove_lines(
- invoice: str, **params: Unpack["Invoice.RemoveLinesParams"]
+ invoice: str, **params: Unpack["InvoiceRemoveLinesParams"]
) -> "Invoice":
"""
Removes multiple line items from an invoice. This is only possible when an invoice is still a draft.
@@ -5447,7 +2402,7 @@ def remove_lines(
@overload
def remove_lines(
- self, **params: Unpack["Invoice.RemoveLinesParams"]
+ self, **params: Unpack["InvoiceRemoveLinesParams"]
) -> "Invoice":
"""
Removes multiple line items from an invoice. This is only possible when an invoice is still a draft.
@@ -5456,7 +2411,7 @@ def remove_lines(
@class_method_variant("_cls_remove_lines")
def remove_lines( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.RemoveLinesParams"]
+ self, **params: Unpack["InvoiceRemoveLinesParams"]
) -> "Invoice":
"""
Removes multiple line items from an invoice. This is only possible when an invoice is still a draft.
@@ -5474,7 +2429,7 @@ def remove_lines( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_remove_lines_async(
- cls, invoice: str, **params: Unpack["Invoice.RemoveLinesParams"]
+ 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.
@@ -5493,7 +2448,7 @@ async def _cls_remove_lines_async(
@overload
@staticmethod
async def remove_lines_async(
- invoice: str, **params: Unpack["Invoice.RemoveLinesParams"]
+ invoice: str, **params: Unpack["InvoiceRemoveLinesParams"]
) -> "Invoice":
"""
Removes multiple line items from an invoice. This is only possible when an invoice is still a draft.
@@ -5502,7 +2457,7 @@ async def remove_lines_async(
@overload
async def remove_lines_async(
- self, **params: Unpack["Invoice.RemoveLinesParams"]
+ self, **params: Unpack["InvoiceRemoveLinesParams"]
) -> "Invoice":
"""
Removes multiple line items from an invoice. This is only possible when an invoice is still a draft.
@@ -5511,7 +2466,7 @@ async def remove_lines_async(
@class_method_variant("_cls_remove_lines_async")
async def remove_lines_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.RemoveLinesParams"]
+ self, **params: Unpack["InvoiceRemoveLinesParams"]
) -> "Invoice":
"""
Removes multiple line items from an invoice. This is only possible when an invoice is still a draft.
@@ -5529,7 +2484,7 @@ async def remove_lines_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Invoice.RetrieveParams"]
+ cls, id: str, **params: Unpack["InvoiceRetrieveParams"]
) -> "Invoice":
"""
Retrieves the invoice with the given ID.
@@ -5540,7 +2495,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Invoice.RetrieveParams"]
+ cls, id: str, **params: Unpack["InvoiceRetrieveParams"]
) -> "Invoice":
"""
Retrieves the invoice with the given ID.
@@ -5551,7 +2506,7 @@ async def retrieve_async(
@classmethod
def _cls_send_invoice(
- cls, invoice: str, **params: Unpack["Invoice.SendInvoiceParams"]
+ 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.
@@ -5572,7 +2527,7 @@ def _cls_send_invoice(
@overload
@staticmethod
def send_invoice(
- invoice: str, **params: Unpack["Invoice.SendInvoiceParams"]
+ 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.
@@ -5583,7 +2538,7 @@ def send_invoice(
@overload
def send_invoice(
- self, **params: Unpack["Invoice.SendInvoiceParams"]
+ self, **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.
@@ -5594,7 +2549,7 @@ def send_invoice(
@class_method_variant("_cls_send_invoice")
def send_invoice( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.SendInvoiceParams"]
+ self, **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.
@@ -5614,7 +2569,7 @@ def send_invoice( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_send_invoice_async(
- cls, invoice: str, **params: Unpack["Invoice.SendInvoiceParams"]
+ 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.
@@ -5635,7 +2590,7 @@ async def _cls_send_invoice_async(
@overload
@staticmethod
async def send_invoice_async(
- invoice: str, **params: Unpack["Invoice.SendInvoiceParams"]
+ 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.
@@ -5646,7 +2601,7 @@ async def send_invoice_async(
@overload
async def send_invoice_async(
- self, **params: Unpack["Invoice.SendInvoiceParams"]
+ self, **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.
@@ -5657,7 +2612,7 @@ async def send_invoice_async(
@class_method_variant("_cls_send_invoice_async")
async def send_invoice_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.SendInvoiceParams"]
+ self, **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.
@@ -5677,7 +2632,7 @@ async def send_invoice_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_update_lines(
- cls, invoice: str, **params: Unpack["Invoice.UpdateLinesParams"]
+ 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.
@@ -5696,7 +2651,7 @@ def _cls_update_lines(
@overload
@staticmethod
def update_lines(
- invoice: str, **params: Unpack["Invoice.UpdateLinesParams"]
+ invoice: str, **params: Unpack["InvoiceUpdateLinesParams"]
) -> "Invoice":
"""
Updates multiple line items on an invoice. This is only possible when an invoice is still a draft.
@@ -5705,7 +2660,7 @@ def update_lines(
@overload
def update_lines(
- self, **params: Unpack["Invoice.UpdateLinesParams"]
+ self, **params: Unpack["InvoiceUpdateLinesParams"]
) -> "Invoice":
"""
Updates multiple line items on an invoice. This is only possible when an invoice is still a draft.
@@ -5714,7 +2669,7 @@ def update_lines(
@class_method_variant("_cls_update_lines")
def update_lines( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.UpdateLinesParams"]
+ self, **params: Unpack["InvoiceUpdateLinesParams"]
) -> "Invoice":
"""
Updates multiple line items on an invoice. This is only possible when an invoice is still a draft.
@@ -5732,7 +2687,7 @@ def update_lines( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_update_lines_async(
- cls, invoice: str, **params: Unpack["Invoice.UpdateLinesParams"]
+ 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.
@@ -5751,7 +2706,7 @@ async def _cls_update_lines_async(
@overload
@staticmethod
async def update_lines_async(
- invoice: str, **params: Unpack["Invoice.UpdateLinesParams"]
+ invoice: str, **params: Unpack["InvoiceUpdateLinesParams"]
) -> "Invoice":
"""
Updates multiple line items on an invoice. This is only possible when an invoice is still a draft.
@@ -5760,7 +2715,7 @@ async def update_lines_async(
@overload
async def update_lines_async(
- self, **params: Unpack["Invoice.UpdateLinesParams"]
+ self, **params: Unpack["InvoiceUpdateLinesParams"]
) -> "Invoice":
"""
Updates multiple line items on an invoice. This is only possible when an invoice is still a draft.
@@ -5769,7 +2724,7 @@ async def update_lines_async(
@class_method_variant("_cls_update_lines_async")
async def update_lines_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.UpdateLinesParams"]
+ self, **params: Unpack["InvoiceUpdateLinesParams"]
) -> "Invoice":
"""
Updates multiple line items on an invoice. This is only possible when an invoice is still a draft.
@@ -5787,7 +2742,7 @@ async def update_lines_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_void_invoice(
- cls, invoice: str, **params: Unpack["Invoice.VoidInvoiceParams"]
+ 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#delete_invoice), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found.
@@ -5808,7 +2763,7 @@ def _cls_void_invoice(
@overload
@staticmethod
def void_invoice(
- invoice: str, **params: Unpack["Invoice.VoidInvoiceParams"]
+ 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#delete_invoice), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found.
@@ -5819,7 +2774,7 @@ def void_invoice(
@overload
def void_invoice(
- self, **params: Unpack["Invoice.VoidInvoiceParams"]
+ self, **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#delete_invoice), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found.
@@ -5830,7 +2785,7 @@ def void_invoice(
@class_method_variant("_cls_void_invoice")
def void_invoice( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.VoidInvoiceParams"]
+ self, **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#delete_invoice), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found.
@@ -5850,7 +2805,7 @@ def void_invoice( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_void_invoice_async(
- cls, invoice: str, **params: Unpack["Invoice.VoidInvoiceParams"]
+ 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#delete_invoice), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found.
@@ -5871,7 +2826,7 @@ async def _cls_void_invoice_async(
@overload
@staticmethod
async def void_invoice_async(
- invoice: str, **params: Unpack["Invoice.VoidInvoiceParams"]
+ 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#delete_invoice), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found.
@@ -5882,7 +2837,7 @@ async def void_invoice_async(
@overload
async def void_invoice_async(
- self, **params: Unpack["Invoice.VoidInvoiceParams"]
+ self, **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#delete_invoice), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found.
@@ -5893,7 +2848,7 @@ async def void_invoice_async(
@class_method_variant("_cls_void_invoice_async")
async def void_invoice_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Invoice.VoidInvoiceParams"]
+ self, **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#delete_invoice), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found.
@@ -5913,7 +2868,7 @@ async def void_invoice_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def search(
- cls, *args, **kwargs: Unpack["Invoice.SearchParams"]
+ cls, *args, **kwargs: Unpack["InvoiceSearchParams"]
) -> SearchResultObject["Invoice"]:
"""
Search for invoices you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
@@ -5925,7 +2880,7 @@ def search(
@classmethod
async def search_async(
- cls, *args, **kwargs: Unpack["Invoice.SearchParams"]
+ cls, *args, **kwargs: Unpack["InvoiceSearchParams"]
) -> SearchResultObject["Invoice"]:
"""
Search for invoices you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
@@ -5939,19 +2894,19 @@ async def search_async(
@classmethod
def search_auto_paging_iter(
- cls, *args, **kwargs: Unpack["Invoice.SearchParams"]
+ cls, *args, **kwargs: Unpack["InvoiceSearchParams"]
) -> Iterator["Invoice"]:
return cls.search(*args, **kwargs).auto_paging_iter()
@classmethod
async def search_auto_paging_iter_async(
- cls, *args, **kwargs: Unpack["Invoice.SearchParams"]
+ cls, *args, **kwargs: Unpack["InvoiceSearchParams"]
) -> AsyncIterator["Invoice"]:
return (await cls.search_async(*args, **kwargs)).auto_paging_iter()
@classmethod
def list_lines(
- cls, invoice: str, **params: Unpack["Invoice.ListLinesParams"]
+ 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.
@@ -5969,7 +2924,7 @@ def list_lines(
@classmethod
async def list_lines_async(
- cls, invoice: str, **params: Unpack["Invoice.ListLinesParams"]
+ 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.py b/stripe/_invoice_item.py
index 80f1da6db..ab1b503e6 100644
--- a/stripe/_invoice_item.py
+++ b/stripe/_invoice_item.py
@@ -5,24 +5,30 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._customer import Customer
from stripe._discount import Discount
from stripe._invoice import Invoice
from stripe._tax_rate import TaxRate
+ from stripe.params._invoice_item_create_params import (
+ InvoiceItemCreateParams,
+ )
+ from stripe.params._invoice_item_delete_params import (
+ InvoiceItemDeleteParams,
+ )
+ from stripe.params._invoice_item_list_params import InvoiceItemListParams
+ from stripe.params._invoice_item_modify_params import (
+ InvoiceItemModifyParams,
+ )
+ from stripe.params._invoice_item_retrieve_params import (
+ InvoiceItemRetrieveParams,
+ )
from stripe.test_helpers._test_clock import TestClock
@@ -115,315 +121,6 @@ class DiscountAmount(StripeObject):
"""
_inner_class_types = {"discount_amounts": DiscountAmount}
- class CreateParams(RequestOptions):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. Passing in a negative `amount` will reduce the `amount_due` on the invoice.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: str
- """
- The ID of the customer who will be billed when this invoice item is billed.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
- """
- discountable: NotRequired[bool]
- """
- Controls whether discounts apply to this invoice item. Defaults to false for prorations or negative invoice items, and true for all other invoice items.
- """
- discounts: NotRequired[
- "Literal['']|List[InvoiceItem.CreateParamsDiscount]"
- ]
- """
- The coupons and promotion codes to redeem into discounts for the invoice item or invoice line item.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice: NotRequired[str]
- """
- The ID of an existing invoice to add this invoice item to. For subscription invoices, when left blank, the invoice item will be added to the next upcoming scheduled invoice. For standalone invoices, the invoice item won't be automatically added unless you pass `pending_invoice_item_behavior: 'include'` when creating the invoice. This is useful when adding invoice items in response to an invoice.created webhook. You can only add invoice items to draft invoices and there is a maximum of 250 items per invoice.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired["InvoiceItem.CreateParamsPeriod"]
- """
- The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
- """
- price_data: NotRequired["InvoiceItem.CreateParamsPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- pricing: NotRequired["InvoiceItem.CreateParamsPricing"]
- """
- The pricing information for the invoice item.
- """
- quantity: NotRequired[int]
- """
- Non-negative integer. The quantity of units for the invoice item.
- """
- subscription: NotRequired[str]
- """
- The ID of a subscription to add this invoice item to. When left blank, the invoice item is added to the next upcoming scheduled invoice. When set, scheduled invoices for subscriptions other than the specified subscription will ignore the invoice item. Use this when you want to express that an invoice item has been accrued within the context of a particular subscription.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- tax_code: NotRequired["Literal['']|str"]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- tax_rates: NotRequired[List[str]]
- """
- The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item.
- """
- unit_amount_decimal: NotRequired[str]
- """
- The decimal unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This `unit_amount_decimal` will be multiplied by the quantity to get the full amount. Passing in a negative `unit_amount_decimal` will reduce the `amount_due` on the invoice. Accepts at most 12 decimal places.
- """
-
- class CreateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsPeriod(TypedDict):
- end: int
- """
- The end of the period, which must be greater than or equal to the start. This value is inclusive.
- """
- start: int
- """
- The start of the period. This value is inclusive.
- """
-
- class CreateParamsPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsPricing(TypedDict):
- price: NotRequired[str]
- """
- The ID of the price object.
- """
-
- class DeleteParams(RequestOptions):
- pass
-
- class ListParams(RequestOptions):
- created: NotRequired["InvoiceItem.ListParamsCreated|int"]
- """
- Only return invoice items that were created during the given date interval.
- """
- customer: NotRequired[str]
- """
- The identifier of the customer whose invoice items to return. If none is provided, all invoice items will be returned.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice: NotRequired[str]
- """
- Only return invoice items belonging to this invoice. If none is provided, all invoice items will be returned. If specifying an invoice, no customer identifier is needed.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- pending: NotRequired[bool]
- """
- Set to `true` to only show pending invoice items, which are not yet attached to any invoices. Set to `false` to only show invoice items already attached to invoices. If unspecified, no filter is applied.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
- """
- discountable: NotRequired[bool]
- """
- Controls whether discounts apply to this invoice item. Defaults to false for prorations or negative invoice items, and true for all other invoice items. Cannot be set to true for prorations.
- """
- discounts: NotRequired[
- "Literal['']|List[InvoiceItem.ModifyParamsDiscount]"
- ]
- """
- The coupons, promotion codes & existing discounts which apply to the invoice item or invoice line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired["InvoiceItem.ModifyParamsPeriod"]
- """
- The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
- """
- price_data: NotRequired["InvoiceItem.ModifyParamsPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- pricing: NotRequired["InvoiceItem.ModifyParamsPricing"]
- """
- The pricing information for the invoice item.
- """
- quantity: NotRequired[int]
- """
- Non-negative integer. The quantity of units for the invoice item.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- tax_code: NotRequired["Literal['']|str"]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item. Pass an empty string to remove previously-defined tax rates.
- """
- unit_amount_decimal: NotRequired[str]
- """
- The decimal unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This `unit_amount_decimal` will be multiplied by the quantity to get the full amount. Passing in a negative `unit_amount_decimal` will reduce the `amount_due` on the invoice. Accepts at most 12 decimal places.
- """
-
- class ModifyParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class ModifyParamsPeriod(TypedDict):
- end: int
- """
- The end of the period, which must be greater than or equal to the start. This value is inclusive.
- """
- start: int
- """
- The start of the period. This value is inclusive.
- """
-
- class ModifyParamsPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class ModifyParamsPricing(TypedDict):
- price: NotRequired[str]
- """
- The ID of the price object.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount: int
"""
Amount (in the `currency` specified) of the invoice item. This should always be equal to `unit_amount * quantity`.
@@ -509,7 +206,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["InvoiceItem.CreateParams"]
+ cls, **params: Unpack["InvoiceItemCreateParams"]
) -> "InvoiceItem":
"""
Creates an item to be added to a draft invoice (up to 250 items per invoice). If no invoice is specified, the item will be on the next invoice created for the customer specified.
@@ -525,7 +222,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["InvoiceItem.CreateParams"]
+ cls, **params: Unpack["InvoiceItemCreateParams"]
) -> "InvoiceItem":
"""
Creates an item to be added to a draft invoice (up to 250 items per invoice). If no invoice is specified, the item will be on the next invoice created for the customer specified.
@@ -541,7 +238,7 @@ async def create_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["InvoiceItem.DeleteParams"]
+ cls, sid: str, **params: Unpack["InvoiceItemDeleteParams"]
) -> "InvoiceItem":
"""
Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they're not attached to invoices, or if it's attached to a draft invoice.
@@ -559,7 +256,7 @@ def _cls_delete(
@overload
@staticmethod
def delete(
- sid: str, **params: Unpack["InvoiceItem.DeleteParams"]
+ sid: str, **params: Unpack["InvoiceItemDeleteParams"]
) -> "InvoiceItem":
"""
Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they're not attached to invoices, or if it's attached to a draft invoice.
@@ -568,7 +265,7 @@ def delete(
@overload
def delete(
- self, **params: Unpack["InvoiceItem.DeleteParams"]
+ self, **params: Unpack["InvoiceItemDeleteParams"]
) -> "InvoiceItem":
"""
Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they're not attached to invoices, or if it's attached to a draft invoice.
@@ -577,7 +274,7 @@ def delete(
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["InvoiceItem.DeleteParams"]
+ self, **params: Unpack["InvoiceItemDeleteParams"]
) -> "InvoiceItem":
"""
Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they're not attached to invoices, or if it's attached to a draft invoice.
@@ -590,7 +287,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["InvoiceItem.DeleteParams"]
+ cls, sid: str, **params: Unpack["InvoiceItemDeleteParams"]
) -> "InvoiceItem":
"""
Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they're not attached to invoices, or if it's attached to a draft invoice.
@@ -608,7 +305,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["InvoiceItem.DeleteParams"]
+ sid: str, **params: Unpack["InvoiceItemDeleteParams"]
) -> "InvoiceItem":
"""
Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they're not attached to invoices, or if it's attached to a draft invoice.
@@ -617,7 +314,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["InvoiceItem.DeleteParams"]
+ self, **params: Unpack["InvoiceItemDeleteParams"]
) -> "InvoiceItem":
"""
Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they're not attached to invoices, or if it's attached to a draft invoice.
@@ -626,7 +323,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["InvoiceItem.DeleteParams"]
+ self, **params: Unpack["InvoiceItemDeleteParams"]
) -> "InvoiceItem":
"""
Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they're not attached to invoices, or if it's attached to a draft invoice.
@@ -639,7 +336,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["InvoiceItem.ListParams"]
+ cls, **params: Unpack["InvoiceItemListParams"]
) -> ListObject["InvoiceItem"]:
"""
Returns a list of your invoice items. Invoice items are returned sorted by creation date, with the most recently created invoice items appearing first.
@@ -659,7 +356,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["InvoiceItem.ListParams"]
+ cls, **params: Unpack["InvoiceItemListParams"]
) -> ListObject["InvoiceItem"]:
"""
Returns a list of your invoice items. Invoice items are returned sorted by creation date, with the most recently created invoice items appearing first.
@@ -679,7 +376,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["InvoiceItem.ModifyParams"]
+ cls, id: str, **params: Unpack["InvoiceItemModifyParams"]
) -> "InvoiceItem":
"""
Updates the amount or description of an invoice item on an upcoming invoice. Updating an invoice item is only possible before the invoice it's attached to is closed.
@@ -696,7 +393,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["InvoiceItem.ModifyParams"]
+ cls, id: str, **params: Unpack["InvoiceItemModifyParams"]
) -> "InvoiceItem":
"""
Updates the amount or description of an invoice item on an upcoming invoice. Updating an invoice item is only possible before the invoice it's attached to is closed.
@@ -713,7 +410,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["InvoiceItem.RetrieveParams"]
+ cls, id: str, **params: Unpack["InvoiceItemRetrieveParams"]
) -> "InvoiceItem":
"""
Retrieves the invoice item with the given ID.
@@ -724,7 +421,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["InvoiceItem.RetrieveParams"]
+ cls, id: str, **params: Unpack["InvoiceItemRetrieveParams"]
) -> "InvoiceItem":
"""
Retrieves the invoice item with the given ID.
diff --git a/stripe/_invoice_item_service.py b/stripe/_invoice_item_service.py
index c0bab581c..6692492b3 100644
--- a/stripe/_invoice_item_service.py
+++ b/stripe/_invoice_item_service.py
@@ -5,324 +5,30 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._invoice_item_create_params import (
+ InvoiceItemCreateParams,
+ )
+ from stripe.params._invoice_item_delete_params import (
+ InvoiceItemDeleteParams,
+ )
+ from stripe.params._invoice_item_list_params import InvoiceItemListParams
+ from stripe.params._invoice_item_retrieve_params import (
+ InvoiceItemRetrieveParams,
+ )
+ from stripe.params._invoice_item_update_params import (
+ InvoiceItemUpdateParams,
+ )
class InvoiceItemService(StripeService):
- class CreateParams(TypedDict):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. Passing in a negative `amount` will reduce the `amount_due` on the invoice.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: str
- """
- The ID of the customer who will be billed when this invoice item is billed.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
- """
- discountable: NotRequired[bool]
- """
- Controls whether discounts apply to this invoice item. Defaults to false for prorations or negative invoice items, and true for all other invoice items.
- """
- discounts: NotRequired[
- "Literal['']|List[InvoiceItemService.CreateParamsDiscount]"
- ]
- """
- The coupons and promotion codes to redeem into discounts for the invoice item or invoice line item.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice: NotRequired[str]
- """
- The ID of an existing invoice to add this invoice item to. For subscription invoices, when left blank, the invoice item will be added to the next upcoming scheduled invoice. For standalone invoices, the invoice item won't be automatically added unless you pass `pending_invoice_item_behavior: 'include'` when creating the invoice. This is useful when adding invoice items in response to an invoice.created webhook. You can only add invoice items to draft invoices and there is a maximum of 250 items per invoice.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired["InvoiceItemService.CreateParamsPeriod"]
- """
- The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
- """
- price_data: NotRequired["InvoiceItemService.CreateParamsPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- pricing: NotRequired["InvoiceItemService.CreateParamsPricing"]
- """
- The pricing information for the invoice item.
- """
- quantity: NotRequired[int]
- """
- Non-negative integer. The quantity of units for the invoice item.
- """
- subscription: NotRequired[str]
- """
- The ID of a subscription to add this invoice item to. When left blank, the invoice item is added to the next upcoming scheduled invoice. When set, scheduled invoices for subscriptions other than the specified subscription will ignore the invoice item. Use this when you want to express that an invoice item has been accrued within the context of a particular subscription.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- tax_code: NotRequired["Literal['']|str"]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- tax_rates: NotRequired[List[str]]
- """
- The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item.
- """
- unit_amount_decimal: NotRequired[str]
- """
- The decimal unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This `unit_amount_decimal` will be multiplied by the quantity to get the full amount. Passing in a negative `unit_amount_decimal` will reduce the `amount_due` on the invoice. Accepts at most 12 decimal places.
- """
-
- class CreateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsPeriod(TypedDict):
- end: int
- """
- The end of the period, which must be greater than or equal to the start. This value is inclusive.
- """
- start: int
- """
- The start of the period. This value is inclusive.
- """
-
- class CreateParamsPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsPricing(TypedDict):
- price: NotRequired[str]
- """
- The ID of the price object.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- created: NotRequired["InvoiceItemService.ListParamsCreated|int"]
- """
- Only return invoice items that were created during the given date interval.
- """
- customer: NotRequired[str]
- """
- The identifier of the customer whose invoice items to return. If none is provided, all invoice items will be returned.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice: NotRequired[str]
- """
- Only return invoice items belonging to this invoice. If none is provided, all invoice items will be returned. If specifying an invoice, no customer identifier is needed.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- pending: NotRequired[bool]
- """
- Set to `true` to only show pending invoice items, which are not yet attached to any invoices. Set to `false` to only show invoice items already attached to invoices. If unspecified, no filter is applied.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
- """
- discountable: NotRequired[bool]
- """
- Controls whether discounts apply to this invoice item. Defaults to false for prorations or negative invoice items, and true for all other invoice items. Cannot be set to true for prorations.
- """
- discounts: NotRequired[
- "Literal['']|List[InvoiceItemService.UpdateParamsDiscount]"
- ]
- """
- The coupons, promotion codes & existing discounts which apply to the invoice item or invoice line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired["InvoiceItemService.UpdateParamsPeriod"]
- """
- The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
- """
- price_data: NotRequired["InvoiceItemService.UpdateParamsPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- pricing: NotRequired["InvoiceItemService.UpdateParamsPricing"]
- """
- The pricing information for the invoice item.
- """
- quantity: NotRequired[int]
- """
- Non-negative integer. The quantity of units for the invoice item.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- tax_code: NotRequired["Literal['']|str"]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item. Pass an empty string to remove previously-defined tax rates.
- """
- unit_amount_decimal: NotRequired[str]
- """
- The decimal unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This `unit_amount_decimal` will be multiplied by the quantity to get the full amount. Passing in a negative `unit_amount_decimal` will reduce the `amount_due` on the invoice. Accepts at most 12 decimal places.
- """
-
- class UpdateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class UpdateParamsPeriod(TypedDict):
- end: int
- """
- The end of the period, which must be greater than or equal to the start. This value is inclusive.
- """
- start: int
- """
- The start of the period. This value is inclusive.
- """
-
- class UpdateParamsPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class UpdateParamsPricing(TypedDict):
- price: NotRequired[str]
- """
- The ID of the price object.
- """
-
def delete(
self,
invoiceitem: str,
- params: Optional["InvoiceItemService.DeleteParams"] = None,
+ params: Optional["InvoiceItemDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoiceItem:
"""
@@ -344,7 +50,7 @@ def delete(
async def delete_async(
self,
invoiceitem: str,
- params: Optional["InvoiceItemService.DeleteParams"] = None,
+ params: Optional["InvoiceItemDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoiceItem:
"""
@@ -366,7 +72,7 @@ async def delete_async(
def retrieve(
self,
invoiceitem: str,
- params: Optional["InvoiceItemService.RetrieveParams"] = None,
+ params: Optional["InvoiceItemRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoiceItem:
"""
@@ -388,7 +94,7 @@ def retrieve(
async def retrieve_async(
self,
invoiceitem: str,
- params: Optional["InvoiceItemService.RetrieveParams"] = None,
+ params: Optional["InvoiceItemRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoiceItem:
"""
@@ -410,7 +116,7 @@ async def retrieve_async(
def update(
self,
invoiceitem: str,
- params: Optional["InvoiceItemService.UpdateParams"] = None,
+ params: Optional["InvoiceItemUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoiceItem:
"""
@@ -432,7 +138,7 @@ def update(
async def update_async(
self,
invoiceitem: str,
- params: Optional["InvoiceItemService.UpdateParams"] = None,
+ params: Optional["InvoiceItemUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoiceItem:
"""
@@ -453,7 +159,7 @@ async def update_async(
def list(
self,
- params: Optional["InvoiceItemService.ListParams"] = None,
+ params: Optional["InvoiceItemListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[InvoiceItem]:
"""
@@ -472,7 +178,7 @@ def list(
async def list_async(
self,
- params: Optional["InvoiceItemService.ListParams"] = None,
+ params: Optional["InvoiceItemListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[InvoiceItem]:
"""
@@ -491,7 +197,7 @@ async def list_async(
def create(
self,
- params: "InvoiceItemService.CreateParams",
+ params: "InvoiceItemCreateParams",
options: Optional[RequestOptions] = None,
) -> InvoiceItem:
"""
@@ -510,7 +216,7 @@ def create(
async def create_async(
self,
- params: "InvoiceItemService.CreateParams",
+ params: "InvoiceItemCreateParams",
options: Optional[RequestOptions] = None,
) -> InvoiceItem:
"""
diff --git a/stripe/_invoice_line_item_service.py b/stripe/_invoice_line_item_service.py
index a095ad833..b5d2c43b8 100644
--- a/stripe/_invoice_line_item_service.py
+++ b/stripe/_invoice_line_item_service.py
@@ -5,272 +5,23 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._invoice_line_item_list_params import (
+ InvoiceLineItemListParams,
+ )
+ from stripe.params._invoice_line_item_update_params import (
+ InvoiceLineItemUpdateParams,
+ )
-class InvoiceLineItemService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class UpdateParams(TypedDict):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
- """
- discountable: NotRequired[bool]
- """
- Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.
- """
- discounts: NotRequired[
- "Literal['']|List[InvoiceLineItemService.UpdateParamsDiscount]"
- ]
- """
- The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data.
- """
- period: NotRequired["InvoiceLineItemService.UpdateParamsPeriod"]
- """
- The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
- """
- price_data: NotRequired["InvoiceLineItemService.UpdateParamsPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- pricing: NotRequired["InvoiceLineItemService.UpdateParamsPricing"]
- """
- The pricing information for the invoice item.
- """
- quantity: NotRequired[int]
- """
- Non-negative integer. The quantity of units for the line item.
- """
- tax_amounts: NotRequired[
- "Literal['']|List[InvoiceLineItemService.UpdateParamsTaxAmount]"
- ]
- """
- A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has [tax_rates](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-tax_rates) or if the invoice has [default_tax_rates](https://stripe.com/docs/api/invoices/object#invoice_object-default_tax_rates) or uses [automatic tax](https://stripe.com/docs/tax/invoicing). Pass an empty string to remove previously defined tax amounts.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the line item. When set, the `default_tax_rates` on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.
- """
-
- class UpdateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class UpdateParamsPeriod(TypedDict):
- end: int
- """
- The end of the period, which must be greater than or equal to the start. This value is inclusive.
- """
- start: int
- """
- The start of the period. This value is inclusive.
- """
-
- class UpdateParamsPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: NotRequired[str]
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
- """
- product_data: NotRequired[
- "InvoiceLineItemService.UpdateParamsPriceDataProductData"
- ]
- """
- Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class UpdateParamsPriceDataProductData(TypedDict):
- description: NotRequired[str]
- """
- The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
- """
- images: NotRequired[List[str]]
- """
- A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The product's name, meant to be displayable to the customer.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- unit_label: NotRequired[str]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
- """
-
- class UpdateParamsPricing(TypedDict):
- price: NotRequired[str]
- """
- The ID of the price object.
- """
-
- class UpdateParamsTaxAmount(TypedDict):
- amount: int
- """
- The amount, in cents (or local equivalent), of the tax.
- """
- tax_rate_data: (
- "InvoiceLineItemService.UpdateParamsTaxAmountTaxRateData"
- )
- """
- Data to find or create a TaxRate object.
-
- Stripe automatically creates or reuses a TaxRate object for each tax amount. If the `tax_rate_data` exactly matches a previous value, Stripe will reuse the TaxRate object. TaxRate objects created automatically by Stripe are immediately archived, do not appear in the line item's `tax_rates`, and cannot be directly added to invoices, payments, or line items.
- """
- taxability_reason: NotRequired[
- Literal[
- "customer_exempt",
- "not_collecting",
- "not_subject_to_tax",
- "not_supported",
- "portion_product_exempt",
- "portion_reduced_rated",
- "portion_standard_rated",
- "product_exempt",
- "product_exempt_holiday",
- "proportionally_rated",
- "reduced_rated",
- "reverse_charge",
- "standard_rated",
- "taxable_basis_reduced",
- "zero_rated",
- ]
- ]
- """
- The reasoning behind this tax, for example, if the product is tax exempt.
- """
- taxable_amount: int
- """
- The amount on which tax is calculated, in cents (or local equivalent).
- """
-
- class UpdateParamsTaxAmountTaxRateData(TypedDict):
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
- """
- display_name: str
- """
- The display name of the tax rate, which will be shown to users.
- """
- inclusive: bool
- """
- This specifies if the tax rate is inclusive or exclusive.
- """
- jurisdiction: NotRequired[str]
- """
- The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer's invoice.
- """
- jurisdiction_level: NotRequired[
- Literal[
- "city", "country", "county", "district", "multiple", "state"
- ]
- ]
- """
- The level of the jurisdiction that imposes this tax rate.
- """
- percentage: float
- """
- The statutory tax rate percent. This field accepts decimal values between 0 and 100 inclusive with at most 4 decimal places. To accommodate fixed-amount taxes, set the percentage to zero. Stripe will not display zero percentages on the invoice unless the `amount` of the tax is also zero.
- """
- state: NotRequired[str]
- """
- [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, "NY" for New York, United States.
- """
- tax_type: NotRequired[
- Literal[
- "amusement_tax",
- "communications_tax",
- "gst",
- "hst",
- "igst",
- "jct",
- "lease_tax",
- "pst",
- "qst",
- "retail_delivery_fee",
- "rst",
- "sales_tax",
- "service_tax",
- "vat",
- ]
- ]
- """
- The high-level tax type, such as `vat` or `sales_tax`.
- """
+class InvoiceLineItemService(StripeService):
def list(
self,
invoice: str,
- params: Optional["InvoiceLineItemService.ListParams"] = None,
+ params: Optional["InvoiceLineItemListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[InvoiceLineItem]:
"""
@@ -292,7 +43,7 @@ def list(
async def list_async(
self,
invoice: str,
- params: Optional["InvoiceLineItemService.ListParams"] = None,
+ params: Optional["InvoiceLineItemListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[InvoiceLineItem]:
"""
@@ -315,7 +66,7 @@ def update(
self,
invoice: str,
line_item_id: str,
- params: Optional["InvoiceLineItemService.UpdateParams"] = None,
+ params: Optional["InvoiceLineItemUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoiceLineItem:
"""
@@ -342,7 +93,7 @@ async def update_async(
self,
invoice: str,
line_item_id: str,
- params: Optional["InvoiceLineItemService.UpdateParams"] = None,
+ params: Optional["InvoiceLineItemUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoiceLineItem:
"""
diff --git a/stripe/_invoice_payment.py b/stripe/_invoice_payment.py
index 5a9b72be1..c67d45c27 100644
--- a/stripe/_invoice_payment.py
+++ b/stripe/_invoice_payment.py
@@ -3,21 +3,20 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
-from typing import ClassVar, List, Optional
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Optional
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._charge import Charge
from stripe._invoice import Invoice
from stripe._payment_intent import PaymentIntent
+ from stripe.params._invoice_payment_list_params import (
+ InvoicePaymentListParams,
+ )
+ from stripe.params._invoice_payment_retrieve_params import (
+ InvoicePaymentRetrieveParams,
+ )
class InvoicePayment(ListableAPIResource["InvoicePayment"]):
@@ -58,52 +57,6 @@ class StatusTransitions(StripeObject):
The time that the payment succeeded.
"""
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice: NotRequired[str]
- """
- The identifier of the invoice whose payments to return.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payment: NotRequired["InvoicePayment.ListParamsPayment"]
- """
- The payment details of the invoice payments to return.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["canceled", "open", "paid"]]
- """
- The status of the invoice payments to return.
- """
-
- class ListParamsPayment(TypedDict):
- payment_intent: NotRequired[str]
- """
- Only return invoice payments associated by this payment intent ID.
- """
- type: Literal["payment_intent"]
- """
- Only return invoice payments associated by this payment type.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount_paid: Optional[int]
"""
Amount that was actually paid for this invoice, in cents (or local equivalent). This field is null until the payment is `paid`. This amount can be less than the `amount_requested` if the PaymentIntent's `amount_received` is not sufficient to pay all of the invoices that it is attached to.
@@ -149,7 +102,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["InvoicePayment.ListParams"]
+ cls, **params: Unpack["InvoicePaymentListParams"]
) -> ListObject["InvoicePayment"]:
"""
When retrieving an invoice, there is an includable payments property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of payments.
@@ -169,7 +122,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["InvoicePayment.ListParams"]
+ cls, **params: Unpack["InvoicePaymentListParams"]
) -> ListObject["InvoicePayment"]:
"""
When retrieving an invoice, there is an includable payments property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of payments.
@@ -189,7 +142,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["InvoicePayment.RetrieveParams"]
+ cls, id: str, **params: Unpack["InvoicePaymentRetrieveParams"]
) -> "InvoicePayment":
"""
Retrieves the invoice payment with the given ID.
@@ -200,7 +153,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["InvoicePayment.RetrieveParams"]
+ cls, id: str, **params: Unpack["InvoicePaymentRetrieveParams"]
) -> "InvoicePayment":
"""
Retrieves the invoice payment with the given ID.
diff --git a/stripe/_invoice_payment_service.py b/stripe/_invoice_payment_service.py
index d723b8e25..2db3c93a7 100644
--- a/stripe/_invoice_payment_service.py
+++ b/stripe/_invoice_payment_service.py
@@ -5,60 +5,22 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._invoice_payment_list_params import (
+ InvoicePaymentListParams,
+ )
+ from stripe.params._invoice_payment_retrieve_params import (
+ InvoicePaymentRetrieveParams,
+ )
-class InvoicePaymentService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice: NotRequired[str]
- """
- The identifier of the invoice whose payments to return.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payment: NotRequired["InvoicePaymentService.ListParamsPayment"]
- """
- The payment details of the invoice payments to return.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["canceled", "open", "paid"]]
- """
- The status of the invoice payments to return.
- """
-
- class ListParamsPayment(TypedDict):
- payment_intent: NotRequired[str]
- """
- Only return invoice payments associated by this payment intent ID.
- """
- type: Literal["payment_intent"]
- """
- Only return invoice payments associated by this payment type.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class InvoicePaymentService(StripeService):
def list(
self,
- params: Optional["InvoicePaymentService.ListParams"] = None,
+ params: Optional["InvoicePaymentListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[InvoicePayment]:
"""
@@ -77,7 +39,7 @@ def list(
async def list_async(
self,
- params: Optional["InvoicePaymentService.ListParams"] = None,
+ params: Optional["InvoicePaymentListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[InvoicePayment]:
"""
@@ -97,7 +59,7 @@ async def list_async(
def retrieve(
self,
invoice_payment: str,
- params: Optional["InvoicePaymentService.RetrieveParams"] = None,
+ params: Optional["InvoicePaymentRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoicePayment:
"""
@@ -119,7 +81,7 @@ def retrieve(
async def retrieve_async(
self,
invoice_payment: str,
- params: Optional["InvoicePaymentService.RetrieveParams"] = None,
+ params: Optional["InvoicePaymentRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoicePayment:
"""
diff --git a/stripe/_invoice_rendering_template.py b/stripe/_invoice_rendering_template.py
index 5d7dc7e2f..93965201c 100644
--- a/stripe/_invoice_rendering_template.py
+++ b/stripe/_invoice_rendering_template.py
@@ -2,10 +2,23 @@
# File generated from our OpenAPI spec
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import Literal, NotRequired, Unpack
+from typing import ClassVar, Dict, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._invoice_rendering_template_archive_params import (
+ InvoiceRenderingTemplateArchiveParams,
+ )
+ from stripe.params._invoice_rendering_template_list_params import (
+ InvoiceRenderingTemplateListParams,
+ )
+ from stripe.params._invoice_rendering_template_retrieve_params import (
+ InvoiceRenderingTemplateRetrieveParams,
+ )
+ from stripe.params._invoice_rendering_template_unarchive_params import (
+ InvoiceRenderingTemplateUnarchiveParams,
+ )
class InvoiceRenderingTemplate(
@@ -19,45 +32,6 @@ class InvoiceRenderingTemplate(
OBJECT_NAME: ClassVar[Literal["invoice_rendering_template"]] = (
"invoice_rendering_template"
)
-
- class ArchiveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["active", "archived"]]
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- version: NotRequired[int]
-
- class UnarchiveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -95,7 +69,7 @@ class UnarchiveParams(RequestOptions):
def _cls_archive(
cls,
template: str,
- **params: Unpack["InvoiceRenderingTemplate.ArchiveParams"],
+ **params: Unpack["InvoiceRenderingTemplateArchiveParams"],
) -> "InvoiceRenderingTemplate":
"""
Updates the status of an invoice rendering template to ‘archived' so no new Stripe objects (customers, invoices, etc.) can reference it. The template can also no longer be updated. However, if the template is already set on a Stripe object, it will continue to be applied on invoices generated by it.
@@ -115,7 +89,7 @@ def _cls_archive(
@staticmethod
def archive(
template: str,
- **params: Unpack["InvoiceRenderingTemplate.ArchiveParams"],
+ **params: Unpack["InvoiceRenderingTemplateArchiveParams"],
) -> "InvoiceRenderingTemplate":
"""
Updates the status of an invoice rendering template to ‘archived' so no new Stripe objects (customers, invoices, etc.) can reference it. The template can also no longer be updated. However, if the template is already set on a Stripe object, it will continue to be applied on invoices generated by it.
@@ -124,7 +98,7 @@ def archive(
@overload
def archive(
- self, **params: Unpack["InvoiceRenderingTemplate.ArchiveParams"]
+ self, **params: Unpack["InvoiceRenderingTemplateArchiveParams"]
) -> "InvoiceRenderingTemplate":
"""
Updates the status of an invoice rendering template to ‘archived' so no new Stripe objects (customers, invoices, etc.) can reference it. The template can also no longer be updated. However, if the template is already set on a Stripe object, it will continue to be applied on invoices generated by it.
@@ -133,7 +107,7 @@ def archive(
@class_method_variant("_cls_archive")
def archive( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["InvoiceRenderingTemplate.ArchiveParams"]
+ self, **params: Unpack["InvoiceRenderingTemplateArchiveParams"]
) -> "InvoiceRenderingTemplate":
"""
Updates the status of an invoice rendering template to ‘archived' so no new Stripe objects (customers, invoices, etc.) can reference it. The template can also no longer be updated. However, if the template is already set on a Stripe object, it will continue to be applied on invoices generated by it.
@@ -153,7 +127,7 @@ def archive( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_archive_async(
cls,
template: str,
- **params: Unpack["InvoiceRenderingTemplate.ArchiveParams"],
+ **params: Unpack["InvoiceRenderingTemplateArchiveParams"],
) -> "InvoiceRenderingTemplate":
"""
Updates the status of an invoice rendering template to ‘archived' so no new Stripe objects (customers, invoices, etc.) can reference it. The template can also no longer be updated. However, if the template is already set on a Stripe object, it will continue to be applied on invoices generated by it.
@@ -173,7 +147,7 @@ async def _cls_archive_async(
@staticmethod
async def archive_async(
template: str,
- **params: Unpack["InvoiceRenderingTemplate.ArchiveParams"],
+ **params: Unpack["InvoiceRenderingTemplateArchiveParams"],
) -> "InvoiceRenderingTemplate":
"""
Updates the status of an invoice rendering template to ‘archived' so no new Stripe objects (customers, invoices, etc.) can reference it. The template can also no longer be updated. However, if the template is already set on a Stripe object, it will continue to be applied on invoices generated by it.
@@ -182,7 +156,7 @@ async def archive_async(
@overload
async def archive_async(
- self, **params: Unpack["InvoiceRenderingTemplate.ArchiveParams"]
+ self, **params: Unpack["InvoiceRenderingTemplateArchiveParams"]
) -> "InvoiceRenderingTemplate":
"""
Updates the status of an invoice rendering template to ‘archived' so no new Stripe objects (customers, invoices, etc.) can reference it. The template can also no longer be updated. However, if the template is already set on a Stripe object, it will continue to be applied on invoices generated by it.
@@ -191,7 +165,7 @@ async def archive_async(
@class_method_variant("_cls_archive_async")
async def archive_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["InvoiceRenderingTemplate.ArchiveParams"]
+ self, **params: Unpack["InvoiceRenderingTemplateArchiveParams"]
) -> "InvoiceRenderingTemplate":
"""
Updates the status of an invoice rendering template to ‘archived' so no new Stripe objects (customers, invoices, etc.) can reference it. The template can also no longer be updated. However, if the template is already set on a Stripe object, it will continue to be applied on invoices generated by it.
@@ -209,7 +183,7 @@ async def archive_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["InvoiceRenderingTemplate.ListParams"]
+ cls, **params: Unpack["InvoiceRenderingTemplateListParams"]
) -> ListObject["InvoiceRenderingTemplate"]:
"""
List all templates, ordered by creation date, with the most recently created template appearing first.
@@ -229,7 +203,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["InvoiceRenderingTemplate.ListParams"]
+ cls, **params: Unpack["InvoiceRenderingTemplateListParams"]
) -> ListObject["InvoiceRenderingTemplate"]:
"""
List all templates, ordered by creation date, with the most recently created template appearing first.
@@ -251,7 +225,7 @@ async def list_async(
def retrieve(
cls,
id: str,
- **params: Unpack["InvoiceRenderingTemplate.RetrieveParams"],
+ **params: Unpack["InvoiceRenderingTemplateRetrieveParams"],
) -> "InvoiceRenderingTemplate":
"""
Retrieves an invoice rendering template with the given ID. It by default returns the latest version of the template. Optionally, specify a version to see previous versions.
@@ -264,7 +238,7 @@ def retrieve(
async def retrieve_async(
cls,
id: str,
- **params: Unpack["InvoiceRenderingTemplate.RetrieveParams"],
+ **params: Unpack["InvoiceRenderingTemplateRetrieveParams"],
) -> "InvoiceRenderingTemplate":
"""
Retrieves an invoice rendering template with the given ID. It by default returns the latest version of the template. Optionally, specify a version to see previous versions.
@@ -277,7 +251,7 @@ async def retrieve_async(
def _cls_unarchive(
cls,
template: str,
- **params: Unpack["InvoiceRenderingTemplate.UnarchiveParams"],
+ **params: Unpack["InvoiceRenderingTemplateUnarchiveParams"],
) -> "InvoiceRenderingTemplate":
"""
Unarchive an invoice rendering template so it can be used on new Stripe objects again.
@@ -297,7 +271,7 @@ def _cls_unarchive(
@staticmethod
def unarchive(
template: str,
- **params: Unpack["InvoiceRenderingTemplate.UnarchiveParams"],
+ **params: Unpack["InvoiceRenderingTemplateUnarchiveParams"],
) -> "InvoiceRenderingTemplate":
"""
Unarchive an invoice rendering template so it can be used on new Stripe objects again.
@@ -306,7 +280,7 @@ def unarchive(
@overload
def unarchive(
- self, **params: Unpack["InvoiceRenderingTemplate.UnarchiveParams"]
+ self, **params: Unpack["InvoiceRenderingTemplateUnarchiveParams"]
) -> "InvoiceRenderingTemplate":
"""
Unarchive an invoice rendering template so it can be used on new Stripe objects again.
@@ -315,7 +289,7 @@ def unarchive(
@class_method_variant("_cls_unarchive")
def unarchive( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["InvoiceRenderingTemplate.UnarchiveParams"]
+ self, **params: Unpack["InvoiceRenderingTemplateUnarchiveParams"]
) -> "InvoiceRenderingTemplate":
"""
Unarchive an invoice rendering template so it can be used on new Stripe objects again.
@@ -335,7 +309,7 @@ def unarchive( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_unarchive_async(
cls,
template: str,
- **params: Unpack["InvoiceRenderingTemplate.UnarchiveParams"],
+ **params: Unpack["InvoiceRenderingTemplateUnarchiveParams"],
) -> "InvoiceRenderingTemplate":
"""
Unarchive an invoice rendering template so it can be used on new Stripe objects again.
@@ -355,7 +329,7 @@ async def _cls_unarchive_async(
@staticmethod
async def unarchive_async(
template: str,
- **params: Unpack["InvoiceRenderingTemplate.UnarchiveParams"],
+ **params: Unpack["InvoiceRenderingTemplateUnarchiveParams"],
) -> "InvoiceRenderingTemplate":
"""
Unarchive an invoice rendering template so it can be used on new Stripe objects again.
@@ -364,7 +338,7 @@ async def unarchive_async(
@overload
async def unarchive_async(
- self, **params: Unpack["InvoiceRenderingTemplate.UnarchiveParams"]
+ self, **params: Unpack["InvoiceRenderingTemplateUnarchiveParams"]
) -> "InvoiceRenderingTemplate":
"""
Unarchive an invoice rendering template so it can be used on new Stripe objects again.
@@ -373,7 +347,7 @@ async def unarchive_async(
@class_method_variant("_cls_unarchive_async")
async def unarchive_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["InvoiceRenderingTemplate.UnarchiveParams"]
+ self, **params: Unpack["InvoiceRenderingTemplateUnarchiveParams"]
) -> "InvoiceRenderingTemplate":
"""
Unarchive an invoice rendering template so it can be used on new Stripe objects again.
diff --git a/stripe/_invoice_rendering_template_service.py b/stripe/_invoice_rendering_template_service.py
index 71a738c9e..b61ef1067 100644
--- a/stripe/_invoice_rendering_template_service.py
+++ b/stripe/_invoice_rendering_template_service.py
@@ -5,52 +5,28 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._invoice_rendering_template_archive_params import (
+ InvoiceRenderingTemplateArchiveParams,
+ )
+ from stripe.params._invoice_rendering_template_list_params import (
+ InvoiceRenderingTemplateListParams,
+ )
+ from stripe.params._invoice_rendering_template_retrieve_params import (
+ InvoiceRenderingTemplateRetrieveParams,
+ )
+ from stripe.params._invoice_rendering_template_unarchive_params import (
+ InvoiceRenderingTemplateUnarchiveParams,
+ )
-class InvoiceRenderingTemplateService(StripeService):
- class ArchiveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["active", "archived"]]
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- version: NotRequired[int]
-
- class UnarchiveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class InvoiceRenderingTemplateService(StripeService):
def list(
self,
- params: Optional["InvoiceRenderingTemplateService.ListParams"] = None,
+ params: Optional["InvoiceRenderingTemplateListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[InvoiceRenderingTemplate]:
"""
@@ -69,7 +45,7 @@ def list(
async def list_async(
self,
- params: Optional["InvoiceRenderingTemplateService.ListParams"] = None,
+ params: Optional["InvoiceRenderingTemplateListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[InvoiceRenderingTemplate]:
"""
@@ -89,9 +65,7 @@ async def list_async(
def retrieve(
self,
template: str,
- params: Optional[
- "InvoiceRenderingTemplateService.RetrieveParams"
- ] = None,
+ params: Optional["InvoiceRenderingTemplateRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoiceRenderingTemplate:
"""
@@ -113,9 +87,7 @@ def retrieve(
async def retrieve_async(
self,
template: str,
- params: Optional[
- "InvoiceRenderingTemplateService.RetrieveParams"
- ] = None,
+ params: Optional["InvoiceRenderingTemplateRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoiceRenderingTemplate:
"""
@@ -137,9 +109,7 @@ async def retrieve_async(
def archive(
self,
template: str,
- params: Optional[
- "InvoiceRenderingTemplateService.ArchiveParams"
- ] = None,
+ params: Optional["InvoiceRenderingTemplateArchiveParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoiceRenderingTemplate:
"""
@@ -161,9 +131,7 @@ def archive(
async def archive_async(
self,
template: str,
- params: Optional[
- "InvoiceRenderingTemplateService.ArchiveParams"
- ] = None,
+ params: Optional["InvoiceRenderingTemplateArchiveParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoiceRenderingTemplate:
"""
@@ -185,9 +153,7 @@ async def archive_async(
def unarchive(
self,
template: str,
- params: Optional[
- "InvoiceRenderingTemplateService.UnarchiveParams"
- ] = None,
+ params: Optional["InvoiceRenderingTemplateUnarchiveParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoiceRenderingTemplate:
"""
@@ -209,9 +175,7 @@ def unarchive(
async def unarchive_async(
self,
template: str,
- params: Optional[
- "InvoiceRenderingTemplateService.UnarchiveParams"
- ] = None,
+ params: Optional["InvoiceRenderingTemplateUnarchiveParams"] = None,
options: Optional[RequestOptions] = None,
) -> InvoiceRenderingTemplate:
"""
diff --git a/stripe/_invoice_service.py b/stripe/_invoice_service.py
index 97535bc5e..19798e728 100644
--- a/stripe/_invoice_service.py
+++ b/stripe/_invoice_service.py
@@ -7,8 +7,42 @@
from stripe._search_result_object import SearchResultObject
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._invoice_add_lines_params import InvoiceAddLinesParams
+ from stripe.params._invoice_attach_payment_params import (
+ InvoiceAttachPaymentParams,
+ )
+ from stripe.params._invoice_create_params import InvoiceCreateParams
+ from stripe.params._invoice_create_preview_params import (
+ InvoiceCreatePreviewParams,
+ )
+ from stripe.params._invoice_delete_params import InvoiceDeleteParams
+ from stripe.params._invoice_finalize_invoice_params import (
+ InvoiceFinalizeInvoiceParams,
+ )
+ from stripe.params._invoice_list_params import InvoiceListParams
+ from stripe.params._invoice_mark_uncollectible_params import (
+ InvoiceMarkUncollectibleParams,
+ )
+ from stripe.params._invoice_pay_params import InvoicePayParams
+ from stripe.params._invoice_remove_lines_params import (
+ InvoiceRemoveLinesParams,
+ )
+ from stripe.params._invoice_retrieve_params import InvoiceRetrieveParams
+ from stripe.params._invoice_search_params import InvoiceSearchParams
+ from stripe.params._invoice_send_invoice_params import (
+ InvoiceSendInvoiceParams,
+ )
+ from stripe.params._invoice_update_lines_params import (
+ InvoiceUpdateLinesParams,
+ )
+ from stripe.params._invoice_update_params import InvoiceUpdateParams
+ from stripe.params._invoice_void_invoice_params import (
+ InvoiceVoidInvoiceParams,
+ )
class InvoiceService(StripeService):
@@ -16,3085 +50,10 @@ def __init__(self, requestor):
super().__init__(requestor)
self.line_items = InvoiceLineItemService(self._requestor)
- class AddLinesParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- lines: List["InvoiceService.AddLinesParamsLine"]
- """
- The line items to add.
- """
-
- class AddLinesParamsLine(TypedDict):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
- """
- discountable: NotRequired[bool]
- """
- Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.
- """
- discounts: NotRequired[
- "Literal['']|List[InvoiceService.AddLinesParamsLineDiscount]"
- ]
- """
- The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
- """
- invoice_item: NotRequired[str]
- """
- ID of an unassigned invoice item to assign to this invoice. If not provided, a new item will be created.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired["InvoiceService.AddLinesParamsLinePeriod"]
- """
- The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
- """
- price_data: NotRequired["InvoiceService.AddLinesParamsLinePriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- pricing: NotRequired["InvoiceService.AddLinesParamsLinePricing"]
- """
- The pricing information for the invoice item.
- """
- quantity: NotRequired[int]
- """
- Non-negative integer. The quantity of units for the line item.
- """
- tax_amounts: NotRequired[
- "Literal['']|List[InvoiceService.AddLinesParamsLineTaxAmount]"
- ]
- """
- A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has [tax_rates](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-tax_rates) or if the invoice has [default_tax_rates](https://stripe.com/docs/api/invoices/object#invoice_object-default_tax_rates) or uses [automatic tax](https://stripe.com/docs/tax/invoicing). Pass an empty string to remove previously defined tax amounts.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the line item. When set, the `default_tax_rates` on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.
- """
-
- class AddLinesParamsLineDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class AddLinesParamsLinePeriod(TypedDict):
- end: int
- """
- The end of the period, which must be greater than or equal to the start. This value is inclusive.
- """
- start: int
- """
- The start of the period. This value is inclusive.
- """
-
- class AddLinesParamsLinePriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: NotRequired[str]
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
- """
- product_data: NotRequired[
- "InvoiceService.AddLinesParamsLinePriceDataProductData"
- ]
- """
- Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class AddLinesParamsLinePriceDataProductData(TypedDict):
- description: NotRequired[str]
- """
- The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
- """
- images: NotRequired[List[str]]
- """
- A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The product's name, meant to be displayable to the customer.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- unit_label: NotRequired[str]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
- """
-
- class AddLinesParamsLinePricing(TypedDict):
- price: NotRequired[str]
- """
- The ID of the price object.
- """
-
- class AddLinesParamsLineTaxAmount(TypedDict):
- amount: int
- """
- The amount, in cents (or local equivalent), of the tax.
- """
- tax_rate_data: "InvoiceService.AddLinesParamsLineTaxAmountTaxRateData"
- """
- Data to find or create a TaxRate object.
-
- Stripe automatically creates or reuses a TaxRate object for each tax amount. If the `tax_rate_data` exactly matches a previous value, Stripe will reuse the TaxRate object. TaxRate objects created automatically by Stripe are immediately archived, do not appear in the line item's `tax_rates`, and cannot be directly added to invoices, payments, or line items.
- """
- taxability_reason: NotRequired[
- Literal[
- "customer_exempt",
- "not_collecting",
- "not_subject_to_tax",
- "not_supported",
- "portion_product_exempt",
- "portion_reduced_rated",
- "portion_standard_rated",
- "product_exempt",
- "product_exempt_holiday",
- "proportionally_rated",
- "reduced_rated",
- "reverse_charge",
- "standard_rated",
- "taxable_basis_reduced",
- "zero_rated",
- ]
- ]
- """
- The reasoning behind this tax, for example, if the product is tax exempt.
- """
- taxable_amount: int
- """
- The amount on which tax is calculated, in cents (or local equivalent).
- """
-
- class AddLinesParamsLineTaxAmountTaxRateData(TypedDict):
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
- """
- display_name: str
- """
- The display name of the tax rate, which will be shown to users.
- """
- inclusive: bool
- """
- This specifies if the tax rate is inclusive or exclusive.
- """
- jurisdiction: NotRequired[str]
- """
- The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer's invoice.
- """
- jurisdiction_level: NotRequired[
- Literal[
- "city", "country", "county", "district", "multiple", "state"
- ]
- ]
- """
- The level of the jurisdiction that imposes this tax rate.
- """
- percentage: float
- """
- The statutory tax rate percent. This field accepts decimal values between 0 and 100 inclusive with at most 4 decimal places. To accommodate fixed-amount taxes, set the percentage to zero. Stripe will not display zero percentages on the invoice unless the `amount` of the tax is also zero.
- """
- state: NotRequired[str]
- """
- [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, "NY" for New York, United States.
- """
- tax_type: NotRequired[
- Literal[
- "amusement_tax",
- "communications_tax",
- "gst",
- "hst",
- "igst",
- "jct",
- "lease_tax",
- "pst",
- "qst",
- "retail_delivery_fee",
- "rst",
- "sales_tax",
- "service_tax",
- "vat",
- ]
- ]
- """
- The high-level tax type, such as `vat` or `sales_tax`.
- """
-
- class AttachPaymentParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- payment_intent: NotRequired[str]
- """
- The ID of the PaymentIntent to attach to the invoice.
- """
-
- class CreateParams(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
- """
- application_fee_amount: NotRequired[int]
- """
- A fee in cents (or local equivalent) that will be applied to the invoice and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the Stripe-Account header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/billing/invoices/connect#collecting-fees).
- """
- auto_advance: NotRequired[bool]
- """
- 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. Defaults to false.
- """
- automatic_tax: NotRequired["InvoiceService.CreateParamsAutomaticTax"]
- """
- Settings for automatic tax lookup for this invoice.
- """
- automatically_finalizes_at: NotRequired[int]
- """
- The time when this invoice should be scheduled to finalize (up to 5 years in the future). The invoice is finalized at this time if it's still in draft state.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`.
- """
- currency: NotRequired[str]
- """
- The currency to create this invoice in. Defaults to that of `customer` if not specified.
- """
- custom_fields: NotRequired[
- "Literal['']|List[InvoiceService.CreateParamsCustomField]"
- ]
- """
- A list of up to 4 custom fields to be displayed on the invoice.
- """
- customer: NotRequired[str]
- """
- The ID of the customer who will be billed.
- """
- days_until_due: NotRequired[int]
- """
- The number of days from when the invoice is created until it is due. Valid only for invoices where `collection_method=send_invoice`.
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.
- """
- default_source: NotRequired[str]
- """
- ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.
- """
- default_tax_rates: NotRequired[List[str]]
- """
- The tax rates that will apply to any line item that does not have `tax_rates` set.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.
- """
- discounts: NotRequired[
- "Literal['']|List[InvoiceService.CreateParamsDiscount]"
- ]
- """
- The coupons and promotion codes to redeem into discounts for the invoice. If not specified, inherits the discount from the invoice's customer. Pass an empty string to avoid inheriting any discounts.
- """
- due_date: NotRequired[int]
- """
- The date on which payment for this invoice is due. Valid only for invoices where `collection_method=send_invoice`.
- """
- effective_at: NotRequired[int]
- """
- The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- footer: NotRequired[str]
- """
- Footer to be displayed on the invoice.
- """
- from_invoice: NotRequired["InvoiceService.CreateParamsFromInvoice"]
- """
- Revise an existing invoice. The new invoice will be created in `status=draft`. See the [revision documentation](https://stripe.com/docs/invoicing/invoice-revisions) for more details.
- """
- issuer: NotRequired["InvoiceService.CreateParamsIssuer"]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- number: NotRequired[str]
- """
- Set the number for this invoice. If no number is present then a number will be assigned automatically when the invoice is finalized. In many markets, regulations require invoices to be unique, sequential and / or gapless. You are responsible for ensuring this is true across all your different invoicing systems in the event that you edit the invoice number using our API. If you use only Stripe for your invoices and do not change invoice numbers, Stripe handles this aspect of compliance for you automatically.
- """
- on_behalf_of: NotRequired[str]
- """
- The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
- """
- payment_settings: NotRequired[
- "InvoiceService.CreateParamsPaymentSettings"
- ]
- """
- Configuration settings for the PaymentIntent that is generated when the invoice is finalized.
- """
- pending_invoice_items_behavior: NotRequired[
- Literal["exclude", "include"]
- ]
- """
- How to handle pending invoice items on invoice creation. Defaults to `exclude` if the parameter is omitted.
- """
- rendering: NotRequired["InvoiceService.CreateParamsRendering"]
- """
- The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.
- """
- shipping_cost: NotRequired["InvoiceService.CreateParamsShippingCost"]
- """
- Settings for the cost of shipping for this invoice.
- """
- shipping_details: NotRequired[
- "InvoiceService.CreateParamsShippingDetails"
- ]
- """
- Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer.
- """
- statement_descriptor: NotRequired[str]
- """
- Extra information about a charge for the customer's credit card statement. It must contain at least one letter. If not specified and this invoice is part of a subscription, the default `statement_descriptor` will be set to the first subscription item's product's `statement_descriptor`.
- """
- subscription: NotRequired[str]
- """
- The ID of the subscription to invoice, if any. If set, the created invoice will only include pending invoice items for that subscription. The subscription's billing cycle and regular subscription events won't be affected.
- """
- transfer_data: NotRequired["InvoiceService.CreateParamsTransferData"]
- """
- If specified, the funds from the invoice will be transferred to the destination and the ID of the resulting transfer will be found on the invoice's charge.
- """
-
- class CreateParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Whether Stripe automatically computes tax on this invoice. Note that incompatible invoice items (invoice items with manually specified [tax rates](https://stripe.com/docs/api/tax_rates), negative amounts, or `tax_behavior=unspecified`) cannot be added to automatic tax invoices.
- """
- liability: NotRequired[
- "InvoiceService.CreateParamsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreateParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsCustomField(TypedDict):
- name: str
- """
- The name of the custom field. This may be up to 40 characters.
- """
- value: str
- """
- The value of the custom field. This may be up to 140 characters.
- """
-
- class CreateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsFromInvoice(TypedDict):
- action: Literal["revision"]
- """
- The relation between the new invoice and the original invoice. Currently, only 'revision' is permitted
- """
- invoice: str
- """
- The `id` of the invoice that will be cloned.
- """
-
- class CreateParamsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsPaymentSettings(TypedDict):
- default_mandate: NotRequired["Literal['']|str"]
- """
- ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the invoice's default_payment_method or default_source, if set.
- """
- payment_method_options: NotRequired[
- "InvoiceService.CreateParamsPaymentSettingsPaymentMethodOptions"
- ]
- """
- Payment-method-specific configuration to provide to the invoice's PaymentIntent.
- """
- payment_method_types: NotRequired[
- "Literal['']|List[Literal['ach_credit_transfer', 'ach_debit', 'acss_debit', 'affirm', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'jp_credit_transfer', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'link', 'multibanco', 'naver_pay', 'nz_bank_account', 'p24', 'payco', 'paynow', 'paypal', 'promptpay', 'revolut_pay', 'sepa_credit_transfer', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
- ]
- """
- The list of payment method types (e.g. card) to provide to the invoice's PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice's default payment method, the subscription's default payment method, the customer's default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice).
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "Literal['']|InvoiceService.CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebit"
- ]
- """
- If paying by `acss_debit`, this sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice's PaymentIntent.
- """
- bancontact: NotRequired[
- "Literal['']|InvoiceService.CreateParamsPaymentSettingsPaymentMethodOptionsBancontact"
- ]
- """
- If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the invoice's PaymentIntent.
- """
- card: NotRequired[
- "Literal['']|InvoiceService.CreateParamsPaymentSettingsPaymentMethodOptionsCard"
- ]
- """
- If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the invoice's PaymentIntent.
- """
- customer_balance: NotRequired[
- "Literal['']|InvoiceService.CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance"
- ]
- """
- If paying by `customer_balance`, this sub-hash contains details about the Bank transfer payment method options to pass to the invoice's PaymentIntent.
- """
- konbini: NotRequired[
- "Literal['']|InvoiceService.CreateParamsPaymentSettingsPaymentMethodOptionsKonbini"
- ]
- """
- If paying by `konbini`, this sub-hash contains details about the Konbini payment method options to pass to the invoice's PaymentIntent.
- """
- sepa_debit: NotRequired[
- "Literal['']|InvoiceService.CreateParamsPaymentSettingsPaymentMethodOptionsSepaDebit"
- ]
- """
- If paying by `sepa_debit`, this sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice's PaymentIntent.
- """
- us_bank_account: NotRequired[
- "Literal['']|InvoiceService.CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If paying by `us_bank_account`, this sub-hash contains details about the ACH direct debit payment method options to pass to the invoice's PaymentIntent.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebit(TypedDict):
- mandate_options: NotRequired[
- "InvoiceService.CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions(
- TypedDict,
- ):
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsBancontact(TypedDict):
- preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
- """
- Preferred language of the Bancontact authorization page that the customer is redirected to.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCard(TypedDict):
- installments: NotRequired[
- "InvoiceService.CreateParamsPaymentSettingsPaymentMethodOptionsCardInstallments"
- ]
- """
- Installment configuration for payments attempted on this invoice.
-
- For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCardInstallments(
- TypedDict,
- ):
- enabled: NotRequired[bool]
- """
- Setting to true enables installments for this invoice.
- Setting to false will prevent any selected plan from applying to a payment.
- """
- plan: NotRequired[
- "Literal['']|InvoiceService.CreateParamsPaymentSettingsPaymentMethodOptionsCardInstallmentsPlan"
- ]
- """
- The selected installment plan to use for this invoice.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCardInstallmentsPlan(
- TypedDict,
- ):
- count: NotRequired[int]
- """
- For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
- """
- interval: NotRequired[Literal["month"]]
- """
- For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
- One of `month`.
- """
- type: Literal["bonus", "fixed_count", "revolving"]
- """
- Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance(
- TypedDict,
- ):
- bank_transfer: NotRequired[
- "InvoiceService.CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[str]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "InvoiceService.CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for eu_bank_transfer funding type.
- """
- type: NotRequired[str]
- """
- The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsKonbini(TypedDict):
- pass
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsSepaDebit(TypedDict):
- pass
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount(
- TypedDict,
- ):
- financial_connections: NotRequired[
- "InvoiceService.CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "InvoiceService.CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class CreateParamsRendering(TypedDict):
- amount_tax_display: NotRequired[
- "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
- ]
- """
- How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
- """
- pdf: NotRequired["InvoiceService.CreateParamsRenderingPdf"]
- """
- Invoice pdf rendering options
- """
- template: NotRequired[str]
- """
- ID of the invoice rendering template to use for this invoice.
- """
- template_version: NotRequired["Literal['']|int"]
- """
- The specific version of invoice rendering template to use for this invoice.
- """
-
- class CreateParamsRenderingPdf(TypedDict):
- page_size: NotRequired[Literal["a4", "auto", "letter"]]
- """
- Page size for invoice PDF. Can be set to `a4`, `letter`, or `auto`.
- If set to `auto`, invoice PDF page size defaults to `a4` for customers with
- Japanese locale and `letter` for customers with other locales.
- """
-
- class CreateParamsShippingCost(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the shipping rate to use for this order.
- """
- shipping_rate_data: NotRequired[
- "InvoiceService.CreateParamsShippingCostShippingRateData"
- ]
- """
- Parameters to create a new ad-hoc shipping rate for this order.
- """
-
- class CreateParamsShippingCostShippingRateData(TypedDict):
- delivery_estimate: NotRequired[
- "InvoiceService.CreateParamsShippingCostShippingRateDataDeliveryEstimate"
- ]
- """
- The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- display_name: str
- """
- The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- fixed_amount: NotRequired[
- "InvoiceService.CreateParamsShippingCostShippingRateDataFixedAmount"
- ]
- """
- Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
- """
- type: NotRequired[Literal["fixed_amount"]]
- """
- The type of calculation to use on the shipping rate.
- """
-
- class CreateParamsShippingCostShippingRateDataDeliveryEstimate(TypedDict):
- maximum: NotRequired[
- "InvoiceService.CreateParamsShippingCostShippingRateDataDeliveryEstimateMaximum"
- ]
- """
- The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
- """
- minimum: NotRequired[
- "InvoiceService.CreateParamsShippingCostShippingRateDataDeliveryEstimateMinimum"
- ]
- """
- The lower bound of the estimated range. If empty, represents no lower bound.
- """
-
- class CreateParamsShippingCostShippingRateDataDeliveryEstimateMaximum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class CreateParamsShippingCostShippingRateDataDeliveryEstimateMinimum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class CreateParamsShippingCostShippingRateDataFixedAmount(TypedDict):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- currency_options: NotRequired[
- Dict[
- str,
- "InvoiceService.CreateParamsShippingCostShippingRateDataFixedAmountCurrencyOptions",
- ]
- ]
- """
- Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class CreateParamsShippingCostShippingRateDataFixedAmountCurrencyOptions(
- TypedDict,
- ):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
-
- class CreateParamsShippingDetails(TypedDict):
- address: "InvoiceService.CreateParamsShippingDetailsAddress"
- """
- Shipping address
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Recipient phone (including extension)
- """
-
- class CreateParamsShippingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class CreatePreviewParams(TypedDict):
- automatic_tax: NotRequired[
- "InvoiceService.CreatePreviewParamsAutomaticTax"
- ]
- """
- Settings for automatic tax lookup for this invoice preview.
- """
- currency: NotRequired[str]
- """
- The currency to preview this invoice in. Defaults to that of `customer` if not specified.
- """
- customer: NotRequired[str]
- """
- The identifier of the customer whose upcoming invoice you'd like to retrieve. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.
- """
- customer_details: NotRequired[
- "InvoiceService.CreatePreviewParamsCustomerDetails"
- ]
- """
- Details about the customer you want to invoice or overrides for an existing customer. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.
- """
- discounts: NotRequired[
- "Literal['']|List[InvoiceService.CreatePreviewParamsDiscount]"
- ]
- """
- The coupons to redeem into discounts for the invoice preview. If not specified, inherits the discount from the subscription or customer. This works for both coupons directly applied to an invoice and coupons applied to a subscription. Pass an empty string to avoid inheriting any discounts.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_items: NotRequired[
- List["InvoiceService.CreatePreviewParamsInvoiceItem"]
- ]
- """
- List of invoice items to add or update in the upcoming invoice preview (up to 250).
- """
- issuer: NotRequired["InvoiceService.CreatePreviewParamsIssuer"]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
- """
- preview_mode: NotRequired[Literal["next", "recurring"]]
- """
- Customizes the types of values to include when calculating the invoice. Defaults to `next` if unspecified.
- """
- schedule: NotRequired[str]
- """
- The identifier of the schedule whose upcoming invoice you'd like to retrieve. Cannot be used with subscription or subscription fields.
- """
- schedule_details: NotRequired[
- "InvoiceService.CreatePreviewParamsScheduleDetails"
- ]
- """
- The schedule creation or modification params to apply as a preview. Cannot be used with `subscription` or `subscription_` prefixed fields.
- """
- subscription: NotRequired[str]
- """
- The identifier of the subscription for which you'd like to retrieve the upcoming invoice. If not provided, but a `subscription_details.items` is provided, you will preview creating a subscription with those items. If neither `subscription` nor `subscription_details.items` is provided, you will retrieve the next upcoming invoice from among the customer's subscriptions.
- """
- subscription_details: NotRequired[
- "InvoiceService.CreatePreviewParamsSubscriptionDetails"
- ]
- """
- The subscription creation or modification params to apply as a preview. Cannot be used with `schedule` or `schedule_details` fields.
- """
-
- class CreatePreviewParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Whether Stripe automatically computes tax on this invoice. Note that incompatible invoice items (invoice items with manually specified [tax rates](https://stripe.com/docs/api/tax_rates), negative amounts, or `tax_behavior=unspecified`) cannot be added to automatic tax invoices.
- """
- liability: NotRequired[
- "InvoiceService.CreatePreviewParamsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreatePreviewParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreatePreviewParamsCustomerDetails(TypedDict):
- address: NotRequired[
- "Literal['']|InvoiceService.CreatePreviewParamsCustomerDetailsAddress"
- ]
- """
- The customer's address.
- """
- shipping: NotRequired[
- "Literal['']|InvoiceService.CreatePreviewParamsCustomerDetailsShipping"
- ]
- """
- The customer's shipping information. Appears on invoices emailed to this customer.
- """
- tax: NotRequired[
- "InvoiceService.CreatePreviewParamsCustomerDetailsTax"
- ]
- """
- Tax details about the customer.
- """
- tax_exempt: NotRequired[
- "Literal['']|Literal['exempt', 'none', 'reverse']"
- ]
- """
- The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
- """
- tax_ids: NotRequired[
- List["InvoiceService.CreatePreviewParamsCustomerDetailsTaxId"]
- ]
- """
- The customer's tax IDs.
- """
-
- class CreatePreviewParamsCustomerDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreatePreviewParamsCustomerDetailsShipping(TypedDict):
- address: (
- "InvoiceService.CreatePreviewParamsCustomerDetailsShippingAddress"
- )
- """
- Customer shipping address.
- """
- name: str
- """
- Customer name.
- """
- phone: NotRequired[str]
- """
- Customer phone (including extension).
- """
-
- class CreatePreviewParamsCustomerDetailsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreatePreviewParamsCustomerDetailsTax(TypedDict):
- ip_address: NotRequired["Literal['']|str"]
- """
- A recent IP address of the customer used for tax reporting and tax location inference. Stripe recommends updating the IP address when a new PaymentMethod is attached or the address field on the customer is updated. We recommend against updating this field more frequently since it could result in unexpected tax location/reporting outcomes.
- """
-
- class CreatePreviewParamsCustomerDetailsTaxId(TypedDict):
- type: Literal[
- "ad_nrt",
- "ae_trn",
- "al_tin",
- "am_tin",
- "ao_tin",
- "ar_cuit",
- "au_abn",
- "au_arn",
- "aw_tin",
- "az_tin",
- "ba_tin",
- "bb_tin",
- "bd_bin",
- "bf_ifu",
- "bg_uic",
- "bh_vat",
- "bj_ifu",
- "bo_tin",
- "br_cnpj",
- "br_cpf",
- "bs_tin",
- "by_tin",
- "ca_bn",
- "ca_gst_hst",
- "ca_pst_bc",
- "ca_pst_mb",
- "ca_pst_sk",
- "ca_qst",
- "cd_nif",
- "ch_uid",
- "ch_vat",
- "cl_tin",
- "cm_niu",
- "cn_tin",
- "co_nit",
- "cr_tin",
- "cv_nif",
- "de_stn",
- "do_rcn",
- "ec_ruc",
- "eg_tin",
- "es_cif",
- "et_tin",
- "eu_oss_vat",
- "eu_vat",
- "gb_vat",
- "ge_vat",
- "gn_nif",
- "hk_br",
- "hr_oib",
- "hu_tin",
- "id_npwp",
- "il_vat",
- "in_gst",
- "is_vat",
- "jp_cn",
- "jp_rn",
- "jp_trn",
- "ke_pin",
- "kg_tin",
- "kh_tin",
- "kr_brn",
- "kz_bin",
- "la_tin",
- "li_uid",
- "li_vat",
- "ma_vat",
- "md_vat",
- "me_pib",
- "mk_vat",
- "mr_nif",
- "mx_rfc",
- "my_frp",
- "my_itn",
- "my_sst",
- "ng_tin",
- "no_vat",
- "no_voec",
- "np_pan",
- "nz_gst",
- "om_vat",
- "pe_ruc",
- "ph_tin",
- "ro_tin",
- "rs_pib",
- "ru_inn",
- "ru_kpp",
- "sa_vat",
- "sg_gst",
- "sg_uen",
- "si_tin",
- "sn_ninea",
- "sr_fin",
- "sv_nit",
- "th_vat",
- "tj_tin",
- "tr_tin",
- "tw_vat",
- "tz_vat",
- "ua_vat",
- "ug_tin",
- "us_ein",
- "uy_ruc",
- "uz_tin",
- "uz_vat",
- "ve_rif",
- "vn_tin",
- "za_vat",
- "zm_tin",
- "zw_tin",
- ]
- """
- Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
- """
- value: str
- """
- Value of the tax ID.
- """
-
- class CreatePreviewParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreatePreviewParamsInvoiceItem(TypedDict):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) of previewed invoice item.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Only applicable to new invoice items.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
- """
- discountable: NotRequired[bool]
- """
- Explicitly controls whether discounts apply to this invoice item. Defaults to true, except for negative invoice items.
- """
- discounts: NotRequired[
- "Literal['']|List[InvoiceService.CreatePreviewParamsInvoiceItemDiscount]"
- ]
- """
- The coupons to redeem into discounts for the invoice item in the preview.
- """
- invoiceitem: NotRequired[str]
- """
- The ID of the invoice item to update in preview. If not specified, a new invoice item will be added to the preview of the upcoming invoice.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired[
- "InvoiceService.CreatePreviewParamsInvoiceItemPeriod"
- ]
- """
- The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired[
- "InvoiceService.CreatePreviewParamsInvoiceItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Non-negative integer. The quantity of units for the invoice item.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- tax_code: NotRequired["Literal['']|str"]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates that apply to the item. When set, any `default_tax_rates` do not apply to this item.
- """
- unit_amount: NotRequired[int]
- """
- The integer unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This unit_amount will be multiplied by the quantity to get the full amount. If you want to apply a credit to the customer's account, pass a negative unit_amount.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreatePreviewParamsInvoiceItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreatePreviewParamsInvoiceItemPeriod(TypedDict):
- end: int
- """
- The end of the period, which must be greater than or equal to the start. This value is inclusive.
- """
- start: int
- """
- The start of the period. This value is inclusive.
- """
-
- class CreatePreviewParamsInvoiceItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreatePreviewParamsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreatePreviewParamsScheduleDetails(TypedDict):
- billing_mode: NotRequired[
- "InvoiceService.CreatePreviewParamsScheduleDetailsBillingMode"
- ]
- """
- Controls how prorations and invoices for subscriptions are calculated and orchestrated.
- """
- end_behavior: NotRequired[Literal["cancel", "release"]]
- """
- Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
- """
- phases: NotRequired[
- List["InvoiceService.CreatePreviewParamsScheduleDetailsPhase"]
- ]
- """
- List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- In cases where the `schedule_details` params update the currently active phase, specifies if and how to prorate at the time of the request.
- """
-
- class CreatePreviewParamsScheduleDetailsBillingMode(TypedDict):
- flexible: NotRequired[
- "InvoiceService.CreatePreviewParamsScheduleDetailsBillingModeFlexible"
- ]
- """
- Configure behavior for flexible billing mode.
- """
- type: Literal["classic", "flexible"]
- """
- Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
- """
-
- class CreatePreviewParamsScheduleDetailsBillingModeFlexible(TypedDict):
- proration_discounts: NotRequired[Literal["included", "itemized"]]
- """
- Controls how invoices and invoice items display proration amounts and discount amounts.
- """
-
- class CreatePreviewParamsScheduleDetailsPhase(TypedDict):
- add_invoice_items: NotRequired[
- List[
- "InvoiceService.CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItem"
- ]
- ]
- """
- A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
- """
- application_fee_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- automatic_tax: NotRequired[
- "InvoiceService.CreatePreviewParamsScheduleDetailsPhaseAutomaticTax"
- ]
- """
- Automatic tax settings for this phase.
- """
- billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
- """
- Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
- """
- billing_thresholds: NotRequired[
- "Literal['']|InvoiceService.CreatePreviewParamsScheduleDetailsPhaseBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
- """
- description: NotRequired["Literal['']|str"]
- """
- Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- discounts: NotRequired[
- "Literal['']|List[InvoiceService.CreatePreviewParamsScheduleDetailsPhaseDiscount]"
- ]
- """
- The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
- """
- duration: NotRequired[
- "InvoiceService.CreatePreviewParamsScheduleDetailsPhaseDuration"
- ]
- """
- The number of intervals the phase should last. If set, `end_date` must not be set.
- """
- end_date: NotRequired["int|Literal['now']"]
- """
- The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
- """
- invoice_settings: NotRequired[
- "InvoiceService.CreatePreviewParamsScheduleDetailsPhaseInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- items: List[
- "InvoiceService.CreatePreviewParamsScheduleDetailsPhaseItem"
- ]
- """
- List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The account on behalf of which to charge, for each of the associated subscription's invoices.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. It's different from the request-level [proration_behavior](https://stripe.com/docs/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration (item price, quantity, etc.) of the current phase.
- """
- start_date: NotRequired["int|Literal['now']"]
- """
- The date at which this phase of the subscription schedule starts or `now`. Must be set on the first phase.
- """
- transfer_data: NotRequired[
- "InvoiceService.CreatePreviewParamsScheduleDetailsPhaseTransferData"
- ]
- """
- The data with which to automatically create a Transfer for each of the associated subscription's invoices.
- """
- trial: NotRequired[bool]
- """
- If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
- """
- trial_end: NotRequired["int|Literal['now']"]
- """
- Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItem(TypedDict):
- discounts: NotRequired[
- List[
- "InvoiceService.CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemDiscount"
- ]
- ]
- """
- The coupons to redeem into discounts for the item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired[
- "InvoiceService.CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriod"
- ]
- """
- The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired[
- "InvoiceService.CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item. Defaults to 1.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemDiscount(
- TypedDict,
- ):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriod(
- TypedDict,
- ):
- end: "InvoiceService.CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriodEnd"
- """
- End of the invoice item period.
- """
- start: "InvoiceService.CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriodStart"
- """
- Start of the invoice item period.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriodEnd(
- TypedDict,
- ):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
- """
- type: Literal["min_item_period_end", "phase_end", "timestamp"]
- """
- Select how to calculate the end of the invoice item period.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriodStart(
- TypedDict,
- ):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
- """
- type: Literal["max_item_period_start", "phase_start", "timestamp"]
- """
- Select how to calculate the start of the invoice item period.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPriceData(
- TypedDict,
- ):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
- liability: NotRequired[
- "InvoiceService.CreatePreviewParamsScheduleDetailsPhaseAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseAutomaticTaxLiability(
- TypedDict,
- ):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseBillingThresholds(TypedDict):
- amount_gte: NotRequired[int]
- """
- Monetary threshold that triggers the subscription to advance to a new billing period
- """
- reset_billing_cycle_anchor: NotRequired[bool]
- """
- Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseDuration(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies phase duration. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The multiplier applied to the interval.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseInvoiceSettings(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
- """
- days_until_due: NotRequired[int]
- """
- Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
- """
- issuer: NotRequired[
- "InvoiceService.CreatePreviewParamsScheduleDetailsPhaseInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseInvoiceSettingsIssuer(
- TypedDict,
- ):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseItem(TypedDict):
- billing_thresholds: NotRequired[
- "Literal['']|InvoiceService.CreatePreviewParamsScheduleDetailsPhaseItemBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- discounts: NotRequired[
- "Literal['']|List[InvoiceService.CreatePreviewParamsScheduleDetailsPhaseItemDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
- """
- plan: NotRequired[str]
- """
- The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
- """
- price: NotRequired[str]
- """
- The ID of the price object.
- """
- price_data: NotRequired[
- "InvoiceService.CreatePreviewParamsScheduleDetailsPhaseItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- quantity: NotRequired[int]
- """
- Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseItemBillingThresholds(
- TypedDict,
- ):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: "InvoiceService.CreatePreviewParamsScheduleDetailsPhaseItemPriceDataRecurring"
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseItemPriceDataRecurring(
- TypedDict,
- ):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class CreatePreviewParamsScheduleDetailsPhaseTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class CreatePreviewParamsSubscriptionDetails(TypedDict):
- billing_cycle_anchor: NotRequired["Literal['now', 'unchanged']|int"]
- """
- For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`.
- """
- billing_mode: NotRequired[
- "InvoiceService.CreatePreviewParamsSubscriptionDetailsBillingMode"
- ]
- """
- Controls how prorations and invoices for subscriptions are calculated and orchestrated.
- """
- cancel_at: NotRequired[
- "Literal['']|int|Literal['max_period_end', 'min_period_end']"
- ]
- """
- A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
- """
- cancel_at_period_end: NotRequired[bool]
- """
- Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`.
- """
- cancel_now: NotRequired[bool]
- """
- This simulates the subscription being canceled or expired immediately.
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set.
- """
- items: NotRequired[
- List["InvoiceService.CreatePreviewParamsSubscriptionDetailsItem"]
- ]
- """
- A list of up to 20 subscription items, each with an attached price.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
- """
- proration_date: NotRequired[int]
- """
- If previewing an update to a subscription, and doing proration, `subscription_details.proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period and within the current phase of the schedule backing this subscription, if the schedule exists. If set, `subscription`, and one of `subscription_details.items`, or `subscription_details.trial_end` are required. Also, `subscription_details.proration_behavior` cannot be set to 'none'.
- """
- resume_at: NotRequired[Literal["now"]]
- """
- For paused subscriptions, setting `subscription_details.resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed.
- """
- start_date: NotRequired[int]
- """
- Date a subscription is intended to start (can be future or past).
- """
- trial_end: NotRequired["Literal['now']|int"]
- """
- If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_details.items` or `subscription` is required.
- """
-
- class CreatePreviewParamsSubscriptionDetailsBillingMode(TypedDict):
- flexible: NotRequired[
- "InvoiceService.CreatePreviewParamsSubscriptionDetailsBillingModeFlexible"
- ]
- """
- Configure behavior for flexible billing mode.
- """
- type: Literal["classic", "flexible"]
- """
- Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
- """
-
- class CreatePreviewParamsSubscriptionDetailsBillingModeFlexible(TypedDict):
- proration_discounts: NotRequired[Literal["included", "itemized"]]
- """
- Controls how invoices and invoice items display proration amounts and discount amounts.
- """
-
- class CreatePreviewParamsSubscriptionDetailsItem(TypedDict):
- billing_thresholds: NotRequired[
- "Literal['']|InvoiceService.CreatePreviewParamsSubscriptionDetailsItemBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- clear_usage: NotRequired[bool]
- """
- Delete all usage for a given subscription item. You must pass this when deleting a usage records subscription item. `clear_usage` has no effect if the plan has a billing meter attached.
- """
- deleted: NotRequired[bool]
- """
- A flag that, if set to `true`, will delete the specified item.
- """
- discounts: NotRequired[
- "Literal['']|List[InvoiceService.CreatePreviewParamsSubscriptionDetailsItemDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- id: NotRequired[str]
- """
- Subscription item to update.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- plan: NotRequired[str]
- """
- Plan ID for this item, as a string.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
- """
- price_data: NotRequired[
- "InvoiceService.CreatePreviewParamsSubscriptionDetailsItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class CreatePreviewParamsSubscriptionDetailsItemBillingThresholds(
- TypedDict,
- ):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class CreatePreviewParamsSubscriptionDetailsItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreatePreviewParamsSubscriptionDetailsItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: "InvoiceService.CreatePreviewParamsSubscriptionDetailsItemPriceDataRecurring"
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreatePreviewParamsSubscriptionDetailsItemPriceDataRecurring(
- TypedDict,
- ):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class FinalizeInvoiceParams(TypedDict):
- auto_advance: NotRequired[bool]
- """
- 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.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(TypedDict):
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- The collection method of the invoice to retrieve. Either `charge_automatically` or `send_invoice`.
- """
- created: NotRequired["InvoiceService.ListParamsCreated|int"]
- """
- Only return invoices that were created during the given date interval.
- """
- customer: NotRequired[str]
- """
- Only return invoices for the customer specified by this customer ID.
- """
- due_date: NotRequired["InvoiceService.ListParamsDueDate|int"]
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["draft", "open", "paid", "uncollectible", "void"]
- ]
- """
- The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview)
- """
- subscription: NotRequired[str]
- """
- Only return invoices for the subscription specified by this subscription ID.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsDueDate(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class MarkUncollectibleParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class PayParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- forgive: NotRequired[bool]
- """
- In cases where the source used to pay the invoice has insufficient funds, passing `forgive=true` controls whether a charge should be attempted for the full amount available on the source, up to the amount to fully pay the invoice. This effectively forgives the difference between the amount available on the source and the amount due.
-
- Passing `forgive=false` will fail the charge if the source hasn't been pre-funded with the right amount. An example for this case is with ACH Credit Transfers and wires: if the amount wired is less than the amount due by a small amount, you might want to forgive the difference. Defaults to `false`.
- """
- mandate: NotRequired["Literal['']|str"]
- """
- ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the payment_method param or the invoice's default_payment_method or default_source, if set.
- """
- off_session: NotRequired[bool]
- """
- Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `true` (off-session).
- """
- paid_out_of_band: NotRequired[bool]
- """
- Boolean representing whether an invoice is paid outside of Stripe. This will result in no charge being made. Defaults to `false`.
- """
- payment_method: NotRequired[str]
- """
- A PaymentMethod to be charged. The PaymentMethod must be the ID of a PaymentMethod belonging to the customer associated with the invoice being paid.
- """
- source: NotRequired[str]
- """
- A payment source to be charged. The source must be the ID of a source belonging to the customer associated with the invoice being paid.
- """
-
- class RemoveLinesParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- lines: List["InvoiceService.RemoveLinesParamsLine"]
- """
- The line items to remove.
- """
-
- class RemoveLinesParamsLine(TypedDict):
- behavior: Literal["delete", "unassign"]
- """
- Either `delete` or `unassign`. Deleted line items are permanently deleted. Unassigned line items can be reassigned to an invoice.
- """
- id: str
- """
- ID of an existing line item to remove from this invoice.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SearchParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- page: NotRequired[str]
- """
- A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
- """
- query: str
- """
- The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for invoices](https://stripe.com/docs/search#query-fields-for-invoices).
- """
-
- class SendInvoiceParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateLinesParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data.
- """
- lines: List["InvoiceService.UpdateLinesParamsLine"]
- """
- The line items to update.
- """
-
- class UpdateLinesParamsLine(TypedDict):
- amount: NotRequired[int]
- """
- The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
- """
- discountable: NotRequired[bool]
- """
- Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.
- """
- discounts: NotRequired[
- "Literal['']|List[InvoiceService.UpdateLinesParamsLineDiscount]"
- ]
- """
- The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
- """
- id: str
- """
- ID of an existing line item on the invoice.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data.
- """
- period: NotRequired["InvoiceService.UpdateLinesParamsLinePeriod"]
- """
- The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
- """
- price_data: NotRequired[
- "InvoiceService.UpdateLinesParamsLinePriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- pricing: NotRequired["InvoiceService.UpdateLinesParamsLinePricing"]
- """
- The pricing information for the invoice item.
- """
- quantity: NotRequired[int]
- """
- Non-negative integer. The quantity of units for the line item.
- """
- tax_amounts: NotRequired[
- "Literal['']|List[InvoiceService.UpdateLinesParamsLineTaxAmount]"
- ]
- """
- A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has [tax_rates](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-tax_rates) or if the invoice has [default_tax_rates](https://stripe.com/docs/api/invoices/object#invoice_object-default_tax_rates) or uses [automatic tax](https://stripe.com/docs/tax/invoicing). Pass an empty string to remove previously defined tax amounts.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the line item. When set, the `default_tax_rates` on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.
- """
-
- class UpdateLinesParamsLineDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class UpdateLinesParamsLinePeriod(TypedDict):
- end: int
- """
- The end of the period, which must be greater than or equal to the start. This value is inclusive.
- """
- start: int
- """
- The start of the period. This value is inclusive.
- """
-
- class UpdateLinesParamsLinePriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: NotRequired[str]
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
- """
- product_data: NotRequired[
- "InvoiceService.UpdateLinesParamsLinePriceDataProductData"
- ]
- """
- Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class UpdateLinesParamsLinePriceDataProductData(TypedDict):
- description: NotRequired[str]
- """
- The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
- """
- images: NotRequired[List[str]]
- """
- A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The product's name, meant to be displayable to the customer.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- unit_label: NotRequired[str]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
- """
-
- class UpdateLinesParamsLinePricing(TypedDict):
- price: NotRequired[str]
- """
- The ID of the price object.
- """
-
- class UpdateLinesParamsLineTaxAmount(TypedDict):
- amount: int
- """
- The amount, in cents (or local equivalent), of the tax.
- """
- tax_rate_data: (
- "InvoiceService.UpdateLinesParamsLineTaxAmountTaxRateData"
- )
- """
- Data to find or create a TaxRate object.
-
- Stripe automatically creates or reuses a TaxRate object for each tax amount. If the `tax_rate_data` exactly matches a previous value, Stripe will reuse the TaxRate object. TaxRate objects created automatically by Stripe are immediately archived, do not appear in the line item's `tax_rates`, and cannot be directly added to invoices, payments, or line items.
- """
- taxability_reason: NotRequired[
- Literal[
- "customer_exempt",
- "not_collecting",
- "not_subject_to_tax",
- "not_supported",
- "portion_product_exempt",
- "portion_reduced_rated",
- "portion_standard_rated",
- "product_exempt",
- "product_exempt_holiday",
- "proportionally_rated",
- "reduced_rated",
- "reverse_charge",
- "standard_rated",
- "taxable_basis_reduced",
- "zero_rated",
- ]
- ]
- """
- The reasoning behind this tax, for example, if the product is tax exempt.
- """
- taxable_amount: int
- """
- The amount on which tax is calculated, in cents (or local equivalent).
- """
-
- class UpdateLinesParamsLineTaxAmountTaxRateData(TypedDict):
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
- """
- display_name: str
- """
- The display name of the tax rate, which will be shown to users.
- """
- inclusive: bool
- """
- This specifies if the tax rate is inclusive or exclusive.
- """
- jurisdiction: NotRequired[str]
- """
- The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer's invoice.
- """
- jurisdiction_level: NotRequired[
- Literal[
- "city", "country", "county", "district", "multiple", "state"
- ]
- ]
- """
- The level of the jurisdiction that imposes this tax rate.
- """
- percentage: float
- """
- The statutory tax rate percent. This field accepts decimal values between 0 and 100 inclusive with at most 4 decimal places. To accommodate fixed-amount taxes, set the percentage to zero. Stripe will not display zero percentages on the invoice unless the `amount` of the tax is also zero.
- """
- state: NotRequired[str]
- """
- [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, "NY" for New York, United States.
- """
- tax_type: NotRequired[
- Literal[
- "amusement_tax",
- "communications_tax",
- "gst",
- "hst",
- "igst",
- "jct",
- "lease_tax",
- "pst",
- "qst",
- "retail_delivery_fee",
- "rst",
- "sales_tax",
- "service_tax",
- "vat",
- ]
- ]
- """
- The high-level tax type, such as `vat` or `sales_tax`.
- """
-
- class UpdateParams(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
- """
- application_fee_amount: NotRequired[int]
- """
- A fee in cents (or local equivalent) that will be applied to the invoice and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the Stripe-Account header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/billing/invoices/connect#collecting-fees).
- """
- auto_advance: NotRequired[bool]
- """
- Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice.
- """
- automatic_tax: NotRequired["InvoiceService.UpdateParamsAutomaticTax"]
- """
- Settings for automatic tax lookup for this invoice.
- """
- automatically_finalizes_at: NotRequired[int]
- """
- The time when this invoice should be scheduled to finalize (up to 5 years in the future). The invoice is finalized at this time if it's still in draft state. To turn off automatic finalization, set `auto_advance` to false.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices.
- """
- custom_fields: NotRequired[
- "Literal['']|List[InvoiceService.UpdateParamsCustomField]"
- ]
- """
- A list of up to 4 custom fields to be displayed on the invoice. If a value for `custom_fields` is specified, the list specified will replace the existing custom field list on this invoice. Pass an empty string to remove previously-defined fields.
- """
- days_until_due: NotRequired[int]
- """
- The number of days from which the invoice is created until it is due. Only valid for invoices where `collection_method=send_invoice`. This field can only be updated on `draft` invoices.
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.
- """
- default_source: NotRequired["Literal['']|str"]
- """
- ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates that will apply to any line item that does not have `tax_rates` set. Pass an empty string to remove previously-defined tax rates.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.
- """
- discounts: NotRequired[
- "Literal['']|List[InvoiceService.UpdateParamsDiscount]"
- ]
- """
- The discounts that will apply to the invoice. Pass an empty string to remove previously-defined discounts.
- """
- due_date: NotRequired[int]
- """
- The date on which payment for this invoice is due. Only valid for invoices where `collection_method=send_invoice`. This field can only be updated on `draft` invoices.
- """
- effective_at: NotRequired["Literal['']|int"]
- """
- The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- footer: NotRequired[str]
- """
- Footer to be displayed on the invoice.
- """
- issuer: NotRequired["InvoiceService.UpdateParamsIssuer"]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- number: NotRequired["Literal['']|str"]
- """
- Set the number for this invoice. If no number is present then a number will be assigned automatically when the invoice is finalized. In many markets, regulations require invoices to be unique, sequential and / or gapless. You are responsible for ensuring this is true across all your different invoicing systems in the event that you edit the invoice number using our API. If you use only Stripe for your invoices and do not change invoice numbers, Stripe handles this aspect of compliance for you automatically.
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
- """
- payment_settings: NotRequired[
- "InvoiceService.UpdateParamsPaymentSettings"
- ]
- """
- Configuration settings for the PaymentIntent that is generated when the invoice is finalized.
- """
- rendering: NotRequired["InvoiceService.UpdateParamsRendering"]
- """
- The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.
- """
- shipping_cost: NotRequired[
- "Literal['']|InvoiceService.UpdateParamsShippingCost"
- ]
- """
- Settings for the cost of shipping for this invoice.
- """
- shipping_details: NotRequired[
- "Literal['']|InvoiceService.UpdateParamsShippingDetails"
- ]
- """
- Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer.
- """
- statement_descriptor: NotRequired[str]
- """
- Extra information about a charge for the customer's credit card statement. It must contain at least one letter. If not specified and this invoice is part of a subscription, the default `statement_descriptor` will be set to the first subscription item's product's `statement_descriptor`.
- """
- transfer_data: NotRequired[
- "Literal['']|InvoiceService.UpdateParamsTransferData"
- ]
- """
- If specified, the funds from the invoice will be transferred to the destination and the ID of the resulting transfer will be found on the invoice's charge. This will be unset if you POST an empty value.
- """
-
- class UpdateParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Whether Stripe automatically computes tax on this invoice. Note that incompatible invoice items (invoice items with manually specified [tax rates](https://stripe.com/docs/api/tax_rates), negative amounts, or `tax_behavior=unspecified`) cannot be added to automatic tax invoices.
- """
- liability: NotRequired[
- "InvoiceService.UpdateParamsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class UpdateParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class UpdateParamsCustomField(TypedDict):
- name: str
- """
- The name of the custom field. This may be up to 40 characters.
- """
- value: str
- """
- The value of the custom field. This may be up to 140 characters.
- """
-
- class UpdateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class UpdateParamsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class UpdateParamsPaymentSettings(TypedDict):
- default_mandate: NotRequired["Literal['']|str"]
- """
- ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the invoice's default_payment_method or default_source, if set.
- """
- payment_method_options: NotRequired[
- "InvoiceService.UpdateParamsPaymentSettingsPaymentMethodOptions"
- ]
- """
- Payment-method-specific configuration to provide to the invoice's PaymentIntent.
- """
- payment_method_types: NotRequired[
- "Literal['']|List[Literal['ach_credit_transfer', 'ach_debit', 'acss_debit', 'affirm', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'jp_credit_transfer', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'link', 'multibanco', 'naver_pay', 'nz_bank_account', 'p24', 'payco', 'paynow', 'paypal', 'promptpay', 'revolut_pay', 'sepa_credit_transfer', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
- ]
- """
- The list of payment method types (e.g. card) to provide to the invoice's PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice's default payment method, the subscription's default payment method, the customer's default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice).
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "Literal['']|InvoiceService.UpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebit"
- ]
- """
- If paying by `acss_debit`, this sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice's PaymentIntent.
- """
- bancontact: NotRequired[
- "Literal['']|InvoiceService.UpdateParamsPaymentSettingsPaymentMethodOptionsBancontact"
- ]
- """
- If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the invoice's PaymentIntent.
- """
- card: NotRequired[
- "Literal['']|InvoiceService.UpdateParamsPaymentSettingsPaymentMethodOptionsCard"
- ]
- """
- If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the invoice's PaymentIntent.
- """
- customer_balance: NotRequired[
- "Literal['']|InvoiceService.UpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance"
- ]
- """
- If paying by `customer_balance`, this sub-hash contains details about the Bank transfer payment method options to pass to the invoice's PaymentIntent.
- """
- konbini: NotRequired[
- "Literal['']|InvoiceService.UpdateParamsPaymentSettingsPaymentMethodOptionsKonbini"
- ]
- """
- If paying by `konbini`, this sub-hash contains details about the Konbini payment method options to pass to the invoice's PaymentIntent.
- """
- sepa_debit: NotRequired[
- "Literal['']|InvoiceService.UpdateParamsPaymentSettingsPaymentMethodOptionsSepaDebit"
- ]
- """
- If paying by `sepa_debit`, this sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice's PaymentIntent.
- """
- us_bank_account: NotRequired[
- "Literal['']|InvoiceService.UpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If paying by `us_bank_account`, this sub-hash contains details about the ACH direct debit payment method options to pass to the invoice's PaymentIntent.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebit(TypedDict):
- mandate_options: NotRequired[
- "InvoiceService.UpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions(
- TypedDict,
- ):
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsBancontact(TypedDict):
- preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
- """
- Preferred language of the Bancontact authorization page that the customer is redirected to.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsCard(TypedDict):
- installments: NotRequired[
- "InvoiceService.UpdateParamsPaymentSettingsPaymentMethodOptionsCardInstallments"
- ]
- """
- Installment configuration for payments attempted on this invoice.
-
- For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsCardInstallments(
- TypedDict,
- ):
- enabled: NotRequired[bool]
- """
- Setting to true enables installments for this invoice.
- Setting to false will prevent any selected plan from applying to a payment.
- """
- plan: NotRequired[
- "Literal['']|InvoiceService.UpdateParamsPaymentSettingsPaymentMethodOptionsCardInstallmentsPlan"
- ]
- """
- The selected installment plan to use for this invoice.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsCardInstallmentsPlan(
- TypedDict,
- ):
- count: NotRequired[int]
- """
- For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
- """
- interval: NotRequired[Literal["month"]]
- """
- For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
- One of `month`.
- """
- type: Literal["bonus", "fixed_count", "revolving"]
- """
- Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance(
- TypedDict,
- ):
- bank_transfer: NotRequired[
- "InvoiceService.UpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[str]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "InvoiceService.UpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for eu_bank_transfer funding type.
- """
- type: NotRequired[str]
- """
- The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsKonbini(TypedDict):
- pass
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsSepaDebit(TypedDict):
- pass
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount(
- TypedDict,
- ):
- financial_connections: NotRequired[
- "InvoiceService.UpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "InvoiceService.UpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class UpdateParamsRendering(TypedDict):
- amount_tax_display: NotRequired[
- "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
- ]
- """
- How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
- """
- pdf: NotRequired["InvoiceService.UpdateParamsRenderingPdf"]
- """
- Invoice pdf rendering options
- """
- template: NotRequired[str]
- """
- ID of the invoice rendering template to use for this invoice.
- """
- template_version: NotRequired["Literal['']|int"]
- """
- The specific version of invoice rendering template to use for this invoice.
- """
-
- class UpdateParamsRenderingPdf(TypedDict):
- page_size: NotRequired[Literal["a4", "auto", "letter"]]
- """
- Page size for invoice PDF. Can be set to `a4`, `letter`, or `auto`.
- If set to `auto`, invoice PDF page size defaults to `a4` for customers with
- Japanese locale and `letter` for customers with other locales.
- """
-
- class UpdateParamsShippingCost(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the shipping rate to use for this order.
- """
- shipping_rate_data: NotRequired[
- "InvoiceService.UpdateParamsShippingCostShippingRateData"
- ]
- """
- Parameters to create a new ad-hoc shipping rate for this order.
- """
-
- class UpdateParamsShippingCostShippingRateData(TypedDict):
- delivery_estimate: NotRequired[
- "InvoiceService.UpdateParamsShippingCostShippingRateDataDeliveryEstimate"
- ]
- """
- The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- display_name: str
- """
- The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- fixed_amount: NotRequired[
- "InvoiceService.UpdateParamsShippingCostShippingRateDataFixedAmount"
- ]
- """
- Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
- """
- type: NotRequired[Literal["fixed_amount"]]
- """
- The type of calculation to use on the shipping rate.
- """
-
- class UpdateParamsShippingCostShippingRateDataDeliveryEstimate(TypedDict):
- maximum: NotRequired[
- "InvoiceService.UpdateParamsShippingCostShippingRateDataDeliveryEstimateMaximum"
- ]
- """
- The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
- """
- minimum: NotRequired[
- "InvoiceService.UpdateParamsShippingCostShippingRateDataDeliveryEstimateMinimum"
- ]
- """
- The lower bound of the estimated range. If empty, represents no lower bound.
- """
-
- class UpdateParamsShippingCostShippingRateDataDeliveryEstimateMaximum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class UpdateParamsShippingCostShippingRateDataDeliveryEstimateMinimum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class UpdateParamsShippingCostShippingRateDataFixedAmount(TypedDict):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- currency_options: NotRequired[
- Dict[
- str,
- "InvoiceService.UpdateParamsShippingCostShippingRateDataFixedAmountCurrencyOptions",
- ]
- ]
- """
- Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class UpdateParamsShippingCostShippingRateDataFixedAmountCurrencyOptions(
- TypedDict,
- ):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
-
- class UpdateParamsShippingDetails(TypedDict):
- address: "InvoiceService.UpdateParamsShippingDetailsAddress"
- """
- Shipping address
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Recipient phone (including extension)
- """
-
- class UpdateParamsShippingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class VoidInvoiceParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
def delete(
self,
invoice: str,
- params: Optional["InvoiceService.DeleteParams"] = None,
+ params: Optional["InvoiceDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3114,7 +73,7 @@ def delete(
async def delete_async(
self,
invoice: str,
- params: Optional["InvoiceService.DeleteParams"] = None,
+ params: Optional["InvoiceDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3134,7 +93,7 @@ async def delete_async(
def retrieve(
self,
invoice: str,
- params: Optional["InvoiceService.RetrieveParams"] = None,
+ params: Optional["InvoiceRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3154,7 +113,7 @@ def retrieve(
async def retrieve_async(
self,
invoice: str,
- params: Optional["InvoiceService.RetrieveParams"] = None,
+ params: Optional["InvoiceRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3174,7 +133,7 @@ async def retrieve_async(
def update(
self,
invoice: str,
- params: Optional["InvoiceService.UpdateParams"] = None,
+ params: Optional["InvoiceUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3199,7 +158,7 @@ def update(
async def update_async(
self,
invoice: str,
- params: Optional["InvoiceService.UpdateParams"] = None,
+ params: Optional["InvoiceUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3223,7 +182,7 @@ async def update_async(
def list(
self,
- params: Optional["InvoiceService.ListParams"] = None,
+ params: Optional["InvoiceListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Invoice]:
"""
@@ -3242,7 +201,7 @@ def list(
async def list_async(
self,
- params: Optional["InvoiceService.ListParams"] = None,
+ params: Optional["InvoiceListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Invoice]:
"""
@@ -3261,7 +220,7 @@ async def list_async(
def create(
self,
- params: Optional["InvoiceService.CreateParams"] = None,
+ params: Optional["InvoiceCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3280,7 +239,7 @@ def create(
async def create_async(
self,
- params: Optional["InvoiceService.CreateParams"] = None,
+ params: Optional["InvoiceCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3299,7 +258,7 @@ async def create_async(
def search(
self,
- params: "InvoiceService.SearchParams",
+ params: "InvoiceSearchParams",
options: Optional[RequestOptions] = None,
) -> SearchResultObject[Invoice]:
"""
@@ -3321,7 +280,7 @@ def search(
async def search_async(
self,
- params: "InvoiceService.SearchParams",
+ params: "InvoiceSearchParams",
options: Optional[RequestOptions] = None,
) -> SearchResultObject[Invoice]:
"""
@@ -3344,7 +303,7 @@ async def search_async(
def add_lines(
self,
invoice: str,
- params: "InvoiceService.AddLinesParams",
+ params: "InvoiceAddLinesParams",
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3366,7 +325,7 @@ def add_lines(
async def add_lines_async(
self,
invoice: str,
- params: "InvoiceService.AddLinesParams",
+ params: "InvoiceAddLinesParams",
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3388,7 +347,7 @@ async def add_lines_async(
def attach_payment(
self,
invoice: str,
- params: Optional["InvoiceService.AttachPaymentParams"] = None,
+ params: Optional["InvoiceAttachPaymentParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3419,7 +378,7 @@ def attach_payment(
async def attach_payment_async(
self,
invoice: str,
- params: Optional["InvoiceService.AttachPaymentParams"] = None,
+ params: Optional["InvoiceAttachPaymentParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3450,7 +409,7 @@ async def attach_payment_async(
def finalize_invoice(
self,
invoice: str,
- params: Optional["InvoiceService.FinalizeInvoiceParams"] = None,
+ params: Optional["InvoiceFinalizeInvoiceParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3472,7 +431,7 @@ def finalize_invoice(
async def finalize_invoice_async(
self,
invoice: str,
- params: Optional["InvoiceService.FinalizeInvoiceParams"] = None,
+ params: Optional["InvoiceFinalizeInvoiceParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3494,7 +453,7 @@ async def finalize_invoice_async(
def mark_uncollectible(
self,
invoice: str,
- params: Optional["InvoiceService.MarkUncollectibleParams"] = None,
+ params: Optional["InvoiceMarkUncollectibleParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3516,7 +475,7 @@ def mark_uncollectible(
async def mark_uncollectible_async(
self,
invoice: str,
- params: Optional["InvoiceService.MarkUncollectibleParams"] = None,
+ params: Optional["InvoiceMarkUncollectibleParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3538,7 +497,7 @@ async def mark_uncollectible_async(
def pay(
self,
invoice: str,
- params: Optional["InvoiceService.PayParams"] = None,
+ params: Optional["InvoicePayParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3560,7 +519,7 @@ def pay(
async def pay_async(
self,
invoice: str,
- params: Optional["InvoiceService.PayParams"] = None,
+ params: Optional["InvoicePayParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3582,7 +541,7 @@ async def pay_async(
def remove_lines(
self,
invoice: str,
- params: "InvoiceService.RemoveLinesParams",
+ params: "InvoiceRemoveLinesParams",
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3604,7 +563,7 @@ def remove_lines(
async def remove_lines_async(
self,
invoice: str,
- params: "InvoiceService.RemoveLinesParams",
+ params: "InvoiceRemoveLinesParams",
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3626,7 +585,7 @@ async def remove_lines_async(
def send_invoice(
self,
invoice: str,
- params: Optional["InvoiceService.SendInvoiceParams"] = None,
+ params: Optional["InvoiceSendInvoiceParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3650,7 +609,7 @@ def send_invoice(
async def send_invoice_async(
self,
invoice: str,
- params: Optional["InvoiceService.SendInvoiceParams"] = None,
+ params: Optional["InvoiceSendInvoiceParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3674,7 +633,7 @@ async def send_invoice_async(
def update_lines(
self,
invoice: str,
- params: "InvoiceService.UpdateLinesParams",
+ params: "InvoiceUpdateLinesParams",
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3696,7 +655,7 @@ def update_lines(
async def update_lines_async(
self,
invoice: str,
- params: "InvoiceService.UpdateLinesParams",
+ params: "InvoiceUpdateLinesParams",
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3718,7 +677,7 @@ async def update_lines_async(
def void_invoice(
self,
invoice: str,
- params: Optional["InvoiceService.VoidInvoiceParams"] = None,
+ params: Optional["InvoiceVoidInvoiceParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3742,7 +701,7 @@ def void_invoice(
async def void_invoice_async(
self,
invoice: str,
- params: Optional["InvoiceService.VoidInvoiceParams"] = None,
+ params: Optional["InvoiceVoidInvoiceParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3765,7 +724,7 @@ async def void_invoice_async(
def create_preview(
self,
- params: Optional["InvoiceService.CreatePreviewParams"] = None,
+ params: Optional["InvoiceCreatePreviewParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
@@ -3792,7 +751,7 @@ def create_preview(
async def create_preview_async(
self,
- params: Optional["InvoiceService.CreatePreviewParams"] = None,
+ params: Optional["InvoiceCreatePreviewParams"] = None,
options: Optional[RequestOptions] = None,
) -> Invoice:
"""
diff --git a/stripe/_mandate.py b/stripe/_mandate.py
index 147923dd3..41cdf5f64 100644
--- a/stripe/_mandate.py
+++ b/stripe/_mandate.py
@@ -2,13 +2,13 @@
# File generated from our OpenAPI spec
from stripe._api_resource import APIResource
from stripe._expandable_field import ExpandableField
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from typing import ClassVar, List, Optional
-from typing_extensions import Literal, NotRequired, Unpack, TYPE_CHECKING
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._payment_method import PaymentMethod
+ from stripe.params._mandate_retrieve_params import MandateRetrieveParams
class Mandate(APIResource["Mandate"]):
@@ -205,12 +205,6 @@ class SingleUse(StripeObject):
The currency of the payment on a single use mandate.
"""
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
customer_acceptance: CustomerAcceptance
id: str
"""
@@ -246,7 +240,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Mandate.RetrieveParams"]
+ cls, id: str, **params: Unpack["MandateRetrieveParams"]
) -> "Mandate":
"""
Retrieves a Mandate object.
@@ -257,7 +251,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Mandate.RetrieveParams"]
+ cls, id: str, **params: Unpack["MandateRetrieveParams"]
) -> "Mandate":
"""
Retrieves a Mandate object.
diff --git a/stripe/_mandate_service.py b/stripe/_mandate_service.py
index 2b70aeaf6..530e1ea53 100644
--- a/stripe/_mandate_service.py
+++ b/stripe/_mandate_service.py
@@ -4,21 +4,18 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._mandate_retrieve_params import MandateRetrieveParams
-class MandateService(StripeService):
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class MandateService(StripeService):
def retrieve(
self,
mandate: str,
- params: Optional["MandateService.RetrieveParams"] = None,
+ params: Optional["MandateRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Mandate:
"""
@@ -38,7 +35,7 @@ def retrieve(
async def retrieve_async(
self,
mandate: str,
- params: Optional["MandateService.RetrieveParams"] = None,
+ params: Optional["MandateRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Mandate:
"""
diff --git a/stripe/_payment_intent.py b/stripe/_payment_intent.py
index cb507820e..9681f7558 100644
--- a/stripe/_payment_intent.py
+++ b/stripe/_payment_intent.py
@@ -4,7 +4,6 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._search_result_object import SearchResultObject
from stripe._searchable_api_resource import SearchableAPIResource
from stripe._stripe_object import StripeObject
@@ -22,13 +21,7 @@
cast,
overload,
)
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account
@@ -41,6 +34,39 @@
from stripe._review import Review
from stripe._setup_intent import SetupIntent
from stripe._source import Source
+ from stripe.params._payment_intent_apply_customer_balance_params import (
+ PaymentIntentApplyCustomerBalanceParams,
+ )
+ from stripe.params._payment_intent_cancel_params import (
+ PaymentIntentCancelParams,
+ )
+ from stripe.params._payment_intent_capture_params import (
+ PaymentIntentCaptureParams,
+ )
+ from stripe.params._payment_intent_confirm_params import (
+ PaymentIntentConfirmParams,
+ )
+ from stripe.params._payment_intent_create_params import (
+ PaymentIntentCreateParams,
+ )
+ from stripe.params._payment_intent_increment_authorization_params import (
+ PaymentIntentIncrementAuthorizationParams,
+ )
+ from stripe.params._payment_intent_list_params import (
+ PaymentIntentListParams,
+ )
+ from stripe.params._payment_intent_modify_params import (
+ PaymentIntentModifyParams,
+ )
+ from stripe.params._payment_intent_retrieve_params import (
+ PaymentIntentRetrieveParams,
+ )
+ from stripe.params._payment_intent_search_params import (
+ PaymentIntentSearchParams,
+ )
+ from stripe.params._payment_intent_verify_microdeposits_params import (
+ PaymentIntentVerifyMicrodepositsParams,
+ )
class PaymentIntent(
@@ -2602,8873 +2628,231 @@ class TransferData(StripeObject):
The account (if any) that the payment is attributed to for tax reporting, and where funds from the payment are transferred to after payment success.
"""
- class ApplyCustomerBalanceParams(RequestOptions):
- amount: NotRequired[int]
- """
- Amount that you intend to apply to this PaymentIntent from the customer's cash balance. If the PaymentIntent was created by an Invoice, the full amount of the PaymentIntent is applied regardless of this parameter.
+ amount: int
+ """
+ Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
+ """
+ amount_capturable: int
+ """
+ Amount that can be captured from this PaymentIntent.
+ """
+ amount_details: Optional[AmountDetails]
+ amount_received: int
+ """
+ Amount that this PaymentIntent collects.
+ """
+ application: Optional[ExpandableField["Application"]]
+ """
+ ID of the Connect application that created the PaymentIntent.
+ """
+ application_fee_amount: Optional[int]
+ """
+ The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+ automatic_payment_methods: Optional[AutomaticPaymentMethods]
+ """
+ Settings to configure compatible payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods)
+ """
+ canceled_at: Optional[int]
+ """
+ Populated when `status` is `canceled`, this is the time at which the PaymentIntent was canceled. Measured in seconds since the Unix epoch.
+ """
+ cancellation_reason: Optional[
+ Literal[
+ "abandoned",
+ "automatic",
+ "duplicate",
+ "expired",
+ "failed_invoice",
+ "fraudulent",
+ "requested_by_customer",
+ "void_invoice",
+ ]
+ ]
+ """
+ Reason for cancellation of this PaymentIntent, either user-provided (`duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`) or generated by Stripe internally (`failed_invoice`, `void_invoice`, `automatic`, or `expired`).
+ """
+ capture_method: Literal["automatic", "automatic_async", "manual"]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ client_secret: Optional[str]
+ """
+ The client secret of this PaymentIntent. Used for client-side retrieval using a publishable key.
- A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (for example, 100 cents to charge 1 USD or 100 to charge 100 JPY, a zero-decimal currency). The maximum amount is the amount of the PaymentIntent.
+ The client secret can be used to complete a payment from your frontend. It should not be stored, logged, or exposed to anyone other than the customer. Make sure that you have TLS enabled on any page that includes the client secret.
- When you omit the amount, it defaults to the remaining amount requested on the PaymentIntent.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+ Refer to our docs to [accept a payment](https://stripe.com/docs/payments/accept-a-payment?ui=elements) and learn about how `client_secret` should be handled.
+ """
+ confirmation_method: Literal["automatic", "manual"]
+ """
+ Describes whether we can confirm this PaymentIntent automatically, or if it requires customer action to confirm the payment.
+ """
+ created: int
+ """
+ Time at which the object was created. Measured in seconds since the Unix epoch.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ customer: Optional[ExpandableField["Customer"]]
+ """
+ ID of the Customer this PaymentIntent belongs to, if one exists.
- class CancelParams(RequestOptions):
- cancellation_reason: NotRequired[
+ Payment methods attached to other Customers cannot be used with this PaymentIntent.
+
+ If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.
+ """
+ description: Optional[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ excluded_payment_method_types: Optional[
+ List[
Literal[
- "abandoned", "duplicate", "fraudulent", "requested_by_customer"
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "card",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
]
]
- """
- Reason for canceling this PaymentIntent. Possible values are: `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CaptureParams(RequestOptions):
- amount_to_capture: NotRequired[int]
- """
- The amount to capture from the PaymentIntent, which must be less than or equal to the original amount. Defaults to the full `amount_capturable` if it's not provided.
- """
- application_fee_amount: NotRequired[int]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- final_capture: NotRequired[bool]
- """
- Defaults to `true`. When capturing a PaymentIntent, setting `final_capture` to `false` notifies Stripe to not release the remaining uncaptured funds to make sure that they're captured in future requests. You can only use this setting when [multicapture](https://stripe.com/docs/payments/multicapture) is available for PaymentIntents.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- statement_descriptor: NotRequired[str]
- """
- Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
+ ]
+ """
+ The list of payment method types to exclude from use with this payment.
+ """
+ id: str
+ """
+ Unique identifier for the object.
+ """
+ last_payment_error: Optional[LastPaymentError]
+ """
+ The payment error encountered in the previous PaymentIntent confirmation. It will be cleared if the PaymentIntent is later updated for any reason.
+ """
+ latest_charge: Optional[ExpandableField["Charge"]]
+ """
+ ID of the latest [Charge object](https://stripe.com/docs/api/charges) created by this PaymentIntent. This property is `null` until PaymentIntent confirmation is attempted.
+ """
+ livemode: bool
+ """
+ Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
+ """
+ metadata: Dict[str, str]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Learn more about [storing information in metadata](https://stripe.com/docs/payments/payment-intents/creating-payment-intents#storing-information-in-metadata).
+ """
+ next_action: Optional[NextAction]
+ """
+ If present, this property tells you what actions you need to take in order for your customer to fulfill a payment using the provided source.
+ """
+ object: Literal["payment_intent"]
+ """
+ String representing the object's type. Objects of the same type share the same value.
+ """
+ on_behalf_of: Optional[ExpandableField["Account"]]
+ """
+ The account (if any) for which the funds of the PaymentIntent are intended. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts) for details.
+ """
+ payment_method: Optional[ExpandableField["PaymentMethod"]]
+ """
+ ID of the payment method used in this PaymentIntent.
+ """
+ payment_method_configuration_details: Optional[
+ PaymentMethodConfigurationDetails
+ ]
+ """
+ Information about the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) used for this PaymentIntent.
+ """
+ payment_method_options: Optional[PaymentMethodOptions]
+ """
+ Payment-method-specific configuration for this PaymentIntent.
+ """
+ payment_method_types: List[str]
+ """
+ The list of payment method types (e.g. card) that this PaymentIntent is allowed to use. A comprehensive list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
+ """
+ presentment_details: Optional[PresentmentDetails]
+ processing: Optional[Processing]
+ """
+ If present, this property tells you about the processing state of the payment.
+ """
+ receipt_email: Optional[str]
+ """
+ Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
+ """
+ review: Optional[ExpandableField["Review"]]
+ """
+ ID of the review associated with this PaymentIntent, if any.
+ """
+ setup_future_usage: Optional[Literal["off_session", "on_session"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
- Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
- """
- statement_descriptor_suffix: NotRequired[str]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
- """
- transfer_data: NotRequired["PaymentIntent.CaptureParamsTransferData"]
- """
- The parameters that you can use to automatically create a transfer after the payment
- is captured. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
- class CaptureParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when a charge succeeds.
- """
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
- class ConfirmParams(RequestOptions):
- capture_method: NotRequired[
- Literal["automatic", "automatic_async", "manual"]
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+ shipping: Optional[Shipping]
+ """
+ Shipping information for this PaymentIntent.
+ """
+ source: Optional[
+ ExpandableField[
+ Union["Account", "BankAccount", "CardResource", "Source"]
]
- """
- Controls when the funds will be captured from the customer's account.
- """
- confirmation_token: NotRequired[str]
- """
- ID of the ConfirmationToken used to confirm this PaymentIntent.
-
- If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
- """
- error_on_requires_action: NotRequired[bool]
- """
- Set to `true` to fail the payment attempt if the PaymentIntent transitions into `requires_action`. This parameter is intended for simpler integrations that do not handle customer actions, like [saving cards without authentication](https://stripe.com/docs/payments/save-card-without-authentication).
- """
- excluded_payment_method_types: NotRequired[
- "Literal['']|List[Literal['acss_debit', 'affirm', 'afterpay_clearpay', 'alipay', 'alma', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'billie', 'blik', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'mb_way', 'mobilepay', 'multibanco', 'naver_pay', 'nz_bank_account', 'oxxo', 'p24', 'pay_by_bank', 'payco', 'paynow', 'paypal', 'pix', 'promptpay', 'revolut_pay', 'samsung_pay', 'satispay', 'sepa_debit', 'sofort', 'swish', 'twint', 'us_bank_account', 'wechat_pay', 'zip']]"
- ]
- """
- The list of payment method types to exclude from use with this payment.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- mandate: NotRequired[str]
- """
- ID of the mandate that's used for this payment.
- """
- mandate_data: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsMandateData"
- ]
- off_session: NotRequired["bool|Literal['one_off', 'recurring']"]
- """
- Set to `true` to indicate that the customer isn't in your checkout flow during this payment attempt and can't authenticate. Use this parameter in scenarios where you collect card details and [charge them later](https://stripe.com/docs/payments/cards/charging-saved-cards).
- """
- payment_method: NotRequired[str]
- """
- ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods/transitioning#compatibility) object) to attach to this PaymentIntent.
- If the payment method is attached to a Customer, it must match the [customer](https://stripe.com/docs/api#create_payment_intent-customer) that is set on this PaymentIntent.
- """
- payment_method_data: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodData"
- ]
- """
- If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
- in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
- property on the PaymentIntent.
- """
- payment_method_options: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptions"
- ]
- """
- Payment method-specific configuration for this PaymentIntent.
- """
- payment_method_types: NotRequired[List[str]]
- """
- The list of payment method types (for example, a card) that this PaymentIntent can use. Use `automatic_payment_methods` to manage payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
- """
- radar_options: NotRequired["PaymentIntent.ConfirmParamsRadarOptions"]
- """
- Options to configure Radar. Learn more about [Radar Sessions](https://stripe.com/docs/radar/radar-session).
- """
- receipt_email: NotRequired["Literal['']|str"]
- """
- Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
- """
- return_url: NotRequired[str]
- """
- The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site.
- If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
- This parameter is only used for cards and other redirect-based payment methods.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- shipping: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsShipping"
- ]
- """
- Shipping information for this PaymentIntent.
- """
- use_stripe_sdk: NotRequired[bool]
- """
- Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
- """
-
- class ConfirmParamsMandateData(TypedDict):
- customer_acceptance: NotRequired[
- "PaymentIntent.ConfirmParamsMandateDataCustomerAcceptance"
- ]
- """
- This hash contains details about the customer acceptance of the Mandate.
- """
-
- class ConfirmParamsMandateDataCustomerAcceptance(TypedDict):
- accepted_at: NotRequired[int]
- """
- The time at which the customer accepted the Mandate.
- """
- offline: NotRequired[
- "PaymentIntent.ConfirmParamsMandateDataCustomerAcceptanceOffline"
- ]
- """
- If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
- """
- online: NotRequired[
- "PaymentIntent.ConfirmParamsMandateDataCustomerAcceptanceOnline"
- ]
- """
- If this is a Mandate accepted online, this hash contains details about the online acceptance.
- """
- type: Literal["offline", "online"]
- """
- The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
- """
-
- class ConfirmParamsMandateDataCustomerAcceptanceOffline(TypedDict):
- pass
-
- class ConfirmParamsMandateDataCustomerAcceptanceOnline(TypedDict):
- ip_address: NotRequired[str]
- """
- The IP address from which the Mandate was accepted by the customer.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the Mandate was accepted by the customer.
- """
-
- class ConfirmParamsPaymentMethodData(TypedDict):
- acss_debit: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataAcssDebit"
- ]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataAlipay"
- ]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired["PaymentIntent.ConfirmParamsPaymentMethodDataAlma"]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataAmazonPay"
- ]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataAuBecsDebit"
- ]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired["PaymentIntent.ConfirmParamsPaymentMethodDataBlik"]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- cashapp: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataCrypto"
- ]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer_balance: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired["PaymentIntent.ConfirmParamsPaymentMethodDataEps"]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- fpx: NotRequired["PaymentIntent.ConfirmParamsPaymentMethodDataFpx"]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired["PaymentIntent.ConfirmParamsPaymentMethodDataIdeal"]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired["PaymentIntent.ConfirmParamsPaymentMethodDataLink"]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataMbWay"
- ]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataMobilepay"
- ]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataNzBankAccount"
- ]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired["PaymentIntent.ConfirmParamsPaymentMethodDataOxxo"]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired["PaymentIntent.ConfirmParamsPaymentMethodDataP24"]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired["PaymentIntent.ConfirmParamsPaymentMethodDataPayco"]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- paynow: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired["PaymentIntent.ConfirmParamsPaymentMethodDataPix"]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataRadarOptions"
- ]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired["PaymentIntent.ConfirmParamsPaymentMethodDataSwish"]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired["PaymentIntent.ConfirmParamsPaymentMethodDataTwint"]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataWechatPay"
- ]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired["PaymentIntent.ConfirmParamsPaymentMethodDataZip"]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class ConfirmParamsPaymentMethodDataAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataAffirm(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAfterpayClearpay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAlipay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAlma(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAmazonPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class ConfirmParamsPaymentMethodDataBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class ConfirmParamsPaymentMethodDataBancontact(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataBillie(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class ConfirmParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ConfirmParamsPaymentMethodDataBlik(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class ConfirmParamsPaymentMethodDataCashapp(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataCrypto(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataCustomerBalance(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataGiropay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataGrabpay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class ConfirmParamsPaymentMethodDataInteracPresent(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataKakaoPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataKlarna(TypedDict):
- dob: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodDataKlarnaDob"
- ]
- """
- Customer's date of birth
- """
-
- class ConfirmParamsPaymentMethodDataKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class ConfirmParamsPaymentMethodDataKonbini(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataKrCard(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataLink(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataMbWay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataMobilepay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataMultibanco(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class ConfirmParamsPaymentMethodDataNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class ConfirmParamsPaymentMethodDataOxxo(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataPayByBank(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPayco(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPaynow(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPaypal(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPix(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPromptpay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class ConfirmParamsPaymentMethodDataRevolutPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataSamsungPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataSatispay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class ConfirmParamsPaymentMethodDataSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class ConfirmParamsPaymentMethodDataSwish(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataTwint(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class ConfirmParamsPaymentMethodDataWechatPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataZip(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsAcssDebit"
- ]
- """
- If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
- """
- affirm: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
- """
- afterpay_clearpay: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsAfterpayClearpay"
- ]
- """
- If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
- """
- alipay: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsAlipay"
- ]
- """
- If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
- """
- alma: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsAlma"
- ]
- """
- If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
- """
- amazon_pay: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsAmazonPay"
- ]
- """
- If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
- """
- au_becs_debit: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsAuBecsDebit"
- ]
- """
- If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
- """
- bacs_debit: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
- """
- bancontact: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
- """
- billie: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
- """
- blik: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsBlik"
- ]
- """
- If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
- """
- boleto: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
- """
- card: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsCard"
- ]
- """
- Configuration for any card payments attempted on this PaymentIntent.
- """
- card_present: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsCardPresent"
- ]
- """
- If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
- """
- cashapp: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
- """
- crypto: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsCrypto"
- ]
- """
- If this is a `crypto` PaymentMethod, this sub-hash contains details about the Crypto payment method options.
- """
- customer_balance: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsCustomerBalance"
- ]
- """
- If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
- """
- eps: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsEps"
- ]
- """
- If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
- """
- fpx: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsFpx"
- ]
- """
- If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
- """
- giropay: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
- """
- grabpay: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
- """
- ideal: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsIdeal"
- ]
- """
- If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
- """
- interac_present: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsInteracPresent"
- ]
- """
- If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
- """
- kakao_pay: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
- """
- klarna: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
- """
- konbini: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
- """
- kr_card: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
- """
- link: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsLink"
- ]
- """
- If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
- """
- mb_way: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsMbWay"
- ]
- """
- If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
- """
- mobilepay: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsMobilepay"
- ]
- """
- If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
- """
- multibanco: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
- """
- naver_pay: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
- """
- nz_bank_account: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsNzBankAccount"
- ]
- """
- If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
- """
- oxxo: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsOxxo"
- ]
- """
- If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
- """
- p24: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsP24"
- ]
- """
- If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
- """
- pay_by_bank: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
- """
- payco: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsPayco"
- ]
- """
- If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
- """
- paynow: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
- """
- paypal: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
- """
- pix: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsPix"
- ]
- """
- If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
- """
- promptpay: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
- """
- revolut_pay: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
- """
- samsung_pay: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
- """
- satispay: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
- """
- sepa_debit: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
- """
- sofort: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
- """
- swish: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsSwish"
- ]
- """
- If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
- """
- twint: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsTwint"
- ]
- """
- If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
- """
- us_bank_account: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
- """
- wechat_pay: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsWechatPay"
- ]
- """
- If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
- """
- zip: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsZip"
- ]
- """
- If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
- """
-
- class ConfirmParamsPaymentMethodOptionsAcssDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class ConfirmParamsPaymentMethodOptionsAcssDebitMandateOptions(TypedDict):
- custom_mandate_url: NotRequired["Literal['']|str"]
- """
- A URL for custom mandate text to render during confirmation step.
- The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
- or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
- """
- interval_description: NotRequired[str]
- """
- Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
- """
- payment_schedule: NotRequired[
- Literal["combined", "interval", "sporadic"]
- ]
- """
- Payment schedule for the mandate.
- """
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class ConfirmParamsPaymentMethodOptionsAffirm(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- preferred_locale: NotRequired[str]
- """
- Preferred language of the Affirm authorization page that the customer is redirected to.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsAfterpayClearpay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- reference: NotRequired[str]
- """
- An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
- This field differs from the statement descriptor and item name.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsAlipay(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsAlma(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class ConfirmParamsPaymentMethodOptionsAmazonPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class ConfirmParamsPaymentMethodOptionsAuBecsDebit(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class ConfirmParamsPaymentMethodOptionsBacsDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsBacsDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class ConfirmParamsPaymentMethodOptionsBacsDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
- """
-
- class ConfirmParamsPaymentMethodOptionsBancontact(TypedDict):
- preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
- """
- Preferred language of the Bancontact authorization page that the customer is redirected to.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsBillie(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class ConfirmParamsPaymentMethodOptionsBlik(TypedDict):
- code: NotRequired[str]
- """
- The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
- """
- setup_future_usage: NotRequired["Literal['']|Literal['none']"]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsBoleto(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCard(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- cvc_token: NotRequired[str]
- """
- A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
- """
- installments: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsCardInstallments"
- ]
- """
- Installment configuration for payments attempted on this PaymentIntent.
-
- For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
- """
- mandate_options: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- moto: NotRequired[bool]
- """
- When specified, this parameter indicates that a transaction will be marked
- as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
- parameter can only be provided during confirmation.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
- """
- request_extended_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
- """
- request_incremental_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
- """
- request_multicapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
- """
- request_overcapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
- require_cvc_recollection: NotRequired[bool]
- """
- When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- statement_descriptor_suffix_kana: NotRequired["Literal['']|str"]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that's set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
- """
- statement_descriptor_suffix_kanji: NotRequired["Literal['']|str"]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that's set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
- """
- three_d_secure: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsCardThreeDSecure"
- ]
- """
- If 3D Secure authentication was performed with a third-party provider,
- the authentication details to use for this payment.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardInstallments(TypedDict):
- enabled: NotRequired[bool]
- """
- Setting to true enables installments for this PaymentIntent.
- This will cause the response to contain a list of available installment plans.
- Setting to false will prevent any selected plan from applying to a charge.
- """
- plan: NotRequired[
- "Literal['']|PaymentIntent.ConfirmParamsPaymentMethodOptionsCardInstallmentsPlan"
- ]
- """
- The selected installment plan to use for this payment attempt.
- This parameter can only be provided during confirmation.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardInstallmentsPlan(TypedDict):
- count: NotRequired[int]
- """
- For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
- """
- interval: NotRequired[Literal["month"]]
- """
- For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
- One of `month`.
- """
- type: Literal["bonus", "fixed_count", "revolving"]
- """
- Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardMandateOptions(TypedDict):
- amount: int
- """
- Amount to be charged for future payments.
- """
- amount_type: Literal["fixed", "maximum"]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
- end_date: NotRequired[int]
- """
- End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
- """
- interval: Literal["day", "month", "sporadic", "week", "year"]
- """
- Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
- """
- reference: str
- """
- Unique identifier for the mandate or subscription.
- """
- start_date: int
- """
- Start date of the mandate or subscription. Start date should not be lesser than yesterday.
- """
- supported_types: NotRequired[List[Literal["india"]]]
- """
- Specifies the type of mandates supported. Possible values are `india`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardPresent(TypedDict):
- request_extended_authorization: NotRequired[bool]
- """
- Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
- """
- request_incremental_authorization_support: NotRequired[bool]
- """
- Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
- """
- routing: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsCardPresentRouting"
- ]
- """
- Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardPresentRouting(TypedDict):
- requested_priority: NotRequired[Literal["domestic", "international"]]
- """
- Routing requested priority
- """
-
- class ConfirmParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
- ares_trans_status: NotRequired[
- Literal["A", "C", "I", "N", "R", "U", "Y"]
- ]
- """
- The `transStatus` returned from the card Issuer's ACS in the ARes.
- """
- cryptogram: str
- """
- The cryptogram, also known as the "authentication value" (AAV, CAVV or
- AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
- (Most 3D Secure providers will return the base64-encoded version, which
- is what you should specify here.)
- """
- electronic_commerce_indicator: NotRequired[
- Literal["01", "02", "05", "06", "07"]
- ]
- """
- The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
- provider and indicates what degree of authentication was performed.
- """
- exemption_indicator: NotRequired[Literal["low_risk", "none"]]
- """
- The exemption requested via 3DS and accepted by the issuer at authentication time.
- """
- network_options: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
- ]
- """
- Network specific 3DS fields. Network specific arguments require an
- explicit card brand choice. The parameter `payment_method_options.card.network``
- must be populated accordingly
- """
- requestor_challenge_indicator: NotRequired[str]
- """
- The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
- AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
- """
- transaction_id: str
- """
- For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
- Transaction ID (dsTransID).
- """
- version: Literal["1.0.2", "2.1.0", "2.2.0"]
- """
- The version of 3D Secure that was performed.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
- TypedDict,
- ):
- cartes_bancaires: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
- ]
- """
- Cartes Bancaires-specific 3DS fields.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
- TypedDict,
- ):
- cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
- """
- The cryptogram calculation algorithm used by the card Issuer's ACS
- to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
- messageExtension: CB-AVALGO
- """
- cb_exemption: NotRequired[str]
- """
- The exemption indicator returned from Cartes Bancaires in the ARes.
- message extension: CB-EXEMPTION; string (4 characters)
- This is a 3 byte bitmap (low significant byte first and most significant
- bit first) that has been Base64 encoded
- """
- cb_score: NotRequired[int]
- """
- The risk score returned from Cartes Bancaires in the ARes.
- message extension: CB-SCORE; numeric value 0-99
- """
-
- class ConfirmParamsPaymentMethodOptionsCashapp(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCrypto(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCustomerBalance(TypedDict):
- bank_transfer: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[Literal["bank_transfer"]]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for the eu_bank_transfer funding type.
- """
- requested_address_types: NotRequired[
- List[
- Literal[
- "aba",
- "iban",
- "sepa",
- "sort_code",
- "spei",
- "swift",
- "zengin",
- ]
- ]
- ]
- """
- List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
-
- Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
- """
- type: Literal[
- "eu_bank_transfer",
- "gb_bank_transfer",
- "jp_bank_transfer",
- "mx_bank_transfer",
- "us_bank_transfer",
- ]
- """
- The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class ConfirmParamsPaymentMethodOptionsEps(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsFpx(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsGiropay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsGrabpay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsIdeal(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsInteracPresent(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodOptionsKakaoPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarna(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- on_demand: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsKlarnaOnDemand"
- ]
- """
- On-demand details if setting up or charging an on-demand payment.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-CH",
- "de-DE",
- "el-GR",
- "en-AT",
- "en-AU",
- "en-BE",
- "en-CA",
- "en-CH",
- "en-CZ",
- "en-DE",
- "en-DK",
- "en-ES",
- "en-FI",
- "en-FR",
- "en-GB",
- "en-GR",
- "en-IE",
- "en-IT",
- "en-NL",
- "en-NO",
- "en-NZ",
- "en-PL",
- "en-PT",
- "en-RO",
- "en-SE",
- "en-US",
- "es-ES",
- "es-US",
- "fi-FI",
- "fr-BE",
- "fr-CA",
- "fr-CH",
- "fr-FR",
- "it-CH",
- "it-IT",
- "nb-NO",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "ro-RO",
- "sv-FI",
- "sv-SE",
- ]
- ]
- """
- Preferred language of the Klarna authorization page that the customer is redirected to
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- subscriptions: NotRequired[
- "Literal['']|List[PaymentIntent.ConfirmParamsPaymentMethodOptionsKlarnaSubscription]"
- ]
- """
- Subscription details if setting up or charging a subscription.
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
- average_amount: NotRequired[int]
- """
- Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- maximum_amount: NotRequired[int]
- """
- The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- minimum_amount: NotRequired[int]
- """
- The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
- """
- Interval at which the customer is making purchases
- """
- purchase_interval_count: NotRequired[int]
- """
- The number of `purchase_interval` between charges
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Unit of time between subscription charges.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
- """
- name: NotRequired[str]
- """
- Name for subscription.
- """
- next_billing: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
- ]
- """
- Describes the upcoming charge for this subscription.
- """
- reference: str
- """
- A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
- TypedDict,
- ):
- amount: int
- """
- The amount of the next charge for the subscription.
- """
- date: str
- """
- The date of the next charge for the subscription in YYYY-MM-DD format.
- """
-
- class ConfirmParamsPaymentMethodOptionsKonbini(TypedDict):
- confirmation_number: NotRequired["Literal['']|str"]
- """
- An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
- """
- expires_after_days: NotRequired["Literal['']|int"]
- """
- The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
- """
- expires_at: NotRequired["Literal['']|int"]
- """
- The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsKrCard(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class ConfirmParamsPaymentMethodOptionsLink(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- persistent_token: NotRequired[str]
- """
- [Deprecated] This is a legacy parameter that no longer has any function.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsMbWay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsMobilepay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsMultibanco(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsNaverPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class ConfirmParamsPaymentMethodOptionsNzBankAccount(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class ConfirmParamsPaymentMethodOptionsOxxo(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsP24(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- tos_shown_and_accepted: NotRequired[bool]
- """
- Confirm that the payer has accepted the P24 terms and conditions.
- """
-
- class ConfirmParamsPaymentMethodOptionsPayByBank(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodOptionsPayco(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class ConfirmParamsPaymentMethodOptionsPaynow(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsPaypal(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds will be captured from the customer's account.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-DE",
- "de-LU",
- "el-GR",
- "en-GB",
- "en-US",
- "es-ES",
- "fi-FI",
- "fr-BE",
- "fr-FR",
- "fr-LU",
- "hu-HU",
- "it-IT",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "sk-SK",
- "sv-SE",
- ]
- ]
- """
- [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
- """
- reference: NotRequired[str]
- """
- A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
- """
- risk_correlation_id: NotRequired[str]
- """
- The risk correlation ID for an on-session payment using a saved PayPal payment method.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsPix(TypedDict):
- amount_includes_iof: NotRequired[Literal["always", "never"]]
- """
- Determines if the amount includes the IOF tax. Defaults to `never`.
- """
- expires_after_seconds: NotRequired[int]
- """
- The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
- """
- expires_at: NotRequired[int]
- """
- The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsPromptpay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsRevolutPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class ConfirmParamsPaymentMethodOptionsSamsungPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class ConfirmParamsPaymentMethodOptionsSatispay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class ConfirmParamsPaymentMethodOptionsSepaDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsSepaDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class ConfirmParamsPaymentMethodOptionsSepaDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
- """
-
- class ConfirmParamsPaymentMethodOptionsSofort(TypedDict):
- preferred_language: NotRequired[
- "Literal['']|Literal['de', 'en', 'es', 'fr', 'it', 'nl', 'pl']"
- ]
- """
- Language shown to the payer on redirect.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsSwish(TypedDict):
- reference: NotRequired["Literal['']|str"]
- """
- A reference for this payment to be displayed in the Swish app.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsTwint(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccount(TypedDict):
- financial_connections: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- mandate_options: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsUsBankAccountMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- networks: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsUsBankAccountNetworks"
- ]
- """
- Additional fields for network related functions
- """
- preferred_settlement_speed: NotRequired[
- "Literal['']|Literal['fastest', 'standard']"
- ]
- """
- Preferred transaction settlement speed
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "PaymentIntent.ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
- return_url: NotRequired[str]
- """
- For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountMandateOptions(
- TypedDict,
- ):
- collection_method: NotRequired["Literal['']|Literal['paper']"]
- """
- The method used to collect offline mandate customer acceptance.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountNetworks(TypedDict):
- requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
- """
- Triggers validations to run across the selected networks
- """
-
- class ConfirmParamsPaymentMethodOptionsWechatPay(TypedDict):
- app_id: NotRequired[str]
- """
- The app ID registered with WeChat Pay. Only required when client is ios or android.
- """
- client: NotRequired[Literal["android", "ios", "web"]]
- """
- The client type that the end customer will pay from
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsZip(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class ConfirmParamsShipping(TypedDict):
- address: "PaymentIntent.ConfirmParamsShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class ConfirmParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParams(RequestOptions):
- amount: int
- """
- Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
- """
- application_fee_amount: NotRequired[int]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- automatic_payment_methods: NotRequired[
- "PaymentIntent.CreateParamsAutomaticPaymentMethods"
- ]
- """
- When you enable this parameter, this PaymentIntent accepts payment methods that you enable in the Dashboard and that are compatible with this PaymentIntent's other parameters.
- """
- capture_method: NotRequired[
- Literal["automatic", "automatic_async", "manual"]
- ]
- """
- Controls when the funds will be captured from the customer's account.
- """
- confirm: NotRequired[bool]
- """
- Set to `true` to attempt to [confirm this PaymentIntent](https://stripe.com/docs/api/payment_intents/confirm) immediately. This parameter defaults to `false`. When creating and confirming a PaymentIntent at the same time, you can also provide the parameters available in the [Confirm API](https://stripe.com/docs/api/payment_intents/confirm).
- """
- confirmation_method: NotRequired[Literal["automatic", "manual"]]
- """
- Describes whether we can confirm this PaymentIntent automatically, or if it requires customer action to confirm the payment.
- """
- confirmation_token: NotRequired[str]
- """
- ID of the ConfirmationToken used to confirm this PaymentIntent.
-
- If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: NotRequired[str]
- """
- ID of the Customer this PaymentIntent belongs to, if one exists.
-
- Payment methods attached to other Customers cannot be used with this PaymentIntent.
-
- If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- error_on_requires_action: NotRequired[bool]
- """
- Set to `true` to fail the payment attempt if the PaymentIntent transitions into `requires_action`. Use this parameter for simpler integrations that don't handle customer actions, such as [saving cards without authentication](https://stripe.com/docs/payments/save-card-without-authentication). This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
- """
- excluded_payment_method_types: NotRequired[
- List[
- Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "card",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- ]
- ]
- """
- The list of payment method types to exclude from use with this payment.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- mandate: NotRequired[str]
- """
- ID of the mandate that's used for this payment. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
- """
- mandate_data: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsMandateData"
- ]
- """
- This hash contains details about the Mandate to create. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- off_session: NotRequired["bool|Literal['one_off', 'recurring']"]
- """
- Set to `true` to indicate that the customer isn't in your checkout flow during this payment attempt and can't authenticate. Use this parameter in scenarios where you collect card details and [charge them later](https://stripe.com/docs/payments/cards/charging-saved-cards). This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
- """
- on_behalf_of: NotRequired[str]
- """
- The Stripe account ID that these funds are intended for. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- payment_method: NotRequired[str]
- """
- ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods#compatibility) object) to attach to this PaymentIntent.
-
- If you don't provide the `payment_method` parameter or the `source` parameter with `confirm=true`, `source` automatically populates with `customer.default_source` to improve migration for users of the Charges API. We recommend that you explicitly provide the `payment_method` moving forward.
- If the payment method is attached to a Customer, you must also provide the ID of that Customer as the [customer](https://stripe.com/docs/api#create_payment_intent-customer) parameter of this PaymentIntent.
- end
- """
- payment_method_configuration: NotRequired[str]
- """
- The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this PaymentIntent.
- """
- payment_method_data: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodData"
- ]
- """
- If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
- in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
- property on the PaymentIntent.
- """
- payment_method_options: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptions"
- ]
- """
- Payment method-specific configuration for this PaymentIntent.
- """
- payment_method_types: NotRequired[List[str]]
- """
- The list of payment method types (for example, a card) that this PaymentIntent can use. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
- """
- radar_options: NotRequired["PaymentIntent.CreateParamsRadarOptions"]
- """
- Options to configure Radar. Learn more about [Radar Sessions](https://stripe.com/docs/radar/radar-session).
- """
- receipt_email: NotRequired[str]
- """
- Email address to send the receipt to. If you specify `receipt_email` for a payment in live mode, you send a receipt regardless of your [email settings](https://dashboard.stripe.com/account/emails).
- """
- return_url: NotRequired[str]
- """
- The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
- """
- setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- shipping: NotRequired["PaymentIntent.CreateParamsShipping"]
- """
- Shipping information for this PaymentIntent.
- """
- statement_descriptor: NotRequired[str]
- """
- Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
-
- Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
- """
- statement_descriptor_suffix: NotRequired[str]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
- """
- transfer_data: NotRequired["PaymentIntent.CreateParamsTransferData"]
- """
- The parameters that you can use to automatically create a Transfer.
- Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies the resulting payment as part of a group. Learn more about the [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers).
- """
- use_stripe_sdk: NotRequired[bool]
- """
- Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
- """
-
- class CreateParamsAutomaticPaymentMethods(TypedDict):
- allow_redirects: NotRequired[Literal["always", "never"]]
- """
- Controls whether this PaymentIntent will accept redirect-based payment methods.
-
- Redirect-based payment methods may require your customer to be redirected to a payment method's app or site for authentication or additional steps. To [confirm](https://stripe.com/docs/api/payment_intents/confirm) this PaymentIntent, you may be required to provide a `return_url` to redirect customers back to your site after they authenticate or complete the payment.
- """
- enabled: bool
- """
- Whether this feature is enabled.
- """
-
- class CreateParamsMandateData(TypedDict):
- customer_acceptance: (
- "PaymentIntent.CreateParamsMandateDataCustomerAcceptance"
- )
- """
- This hash contains details about the customer acceptance of the Mandate.
- """
-
- class CreateParamsMandateDataCustomerAcceptance(TypedDict):
- accepted_at: NotRequired[int]
- """
- The time at which the customer accepted the Mandate.
- """
- offline: NotRequired[
- "PaymentIntent.CreateParamsMandateDataCustomerAcceptanceOffline"
- ]
- """
- If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
- """
- online: NotRequired[
- "PaymentIntent.CreateParamsMandateDataCustomerAcceptanceOnline"
- ]
- """
- If this is a Mandate accepted online, this hash contains details about the online acceptance.
- """
- type: Literal["offline", "online"]
- """
- The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
- """
-
- class CreateParamsMandateDataCustomerAcceptanceOffline(TypedDict):
- pass
-
- class CreateParamsMandateDataCustomerAcceptanceOnline(TypedDict):
- ip_address: str
- """
- The IP address from which the Mandate was accepted by the customer.
- """
- user_agent: str
- """
- The user agent of the browser from which the Mandate was accepted by the customer.
- """
-
- class CreateParamsPaymentMethodData(TypedDict):
- acss_debit: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataAcssDebit"
- ]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataAlipay"
- ]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired["PaymentIntent.CreateParamsPaymentMethodDataAlma"]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataAmazonPay"
- ]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataAuBecsDebit"
- ]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired["PaymentIntent.CreateParamsPaymentMethodDataBlik"]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- cashapp: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataCrypto"
- ]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer_balance: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired["PaymentIntent.CreateParamsPaymentMethodDataEps"]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- fpx: NotRequired["PaymentIntent.CreateParamsPaymentMethodDataFpx"]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired["PaymentIntent.CreateParamsPaymentMethodDataIdeal"]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired["PaymentIntent.CreateParamsPaymentMethodDataLink"]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired["PaymentIntent.CreateParamsPaymentMethodDataMbWay"]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataMobilepay"
- ]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataNzBankAccount"
- ]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired["PaymentIntent.CreateParamsPaymentMethodDataOxxo"]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired["PaymentIntent.CreateParamsPaymentMethodDataP24"]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired["PaymentIntent.CreateParamsPaymentMethodDataPayco"]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- paynow: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired["PaymentIntent.CreateParamsPaymentMethodDataPix"]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataRadarOptions"
- ]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired["PaymentIntent.CreateParamsPaymentMethodDataSwish"]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired["PaymentIntent.CreateParamsPaymentMethodDataTwint"]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataWechatPay"
- ]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired["PaymentIntent.CreateParamsPaymentMethodDataZip"]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class CreateParamsPaymentMethodDataAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class CreateParamsPaymentMethodDataAffirm(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAfterpayClearpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAlipay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAlma(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAmazonPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class CreateParamsPaymentMethodDataBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class CreateParamsPaymentMethodDataBancontact(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBillie(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class CreateParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsPaymentMethodDataBlik(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class CreateParamsPaymentMethodDataCashapp(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataCrypto(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataCustomerBalance(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataGiropay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataGrabpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class CreateParamsPaymentMethodDataInteracPresent(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKakaoPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKlarna(TypedDict):
- dob: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodDataKlarnaDob"
- ]
- """
- Customer's date of birth
- """
-
- class CreateParamsPaymentMethodDataKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsPaymentMethodDataKonbini(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKrCard(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataLink(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMbWay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMobilepay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMultibanco(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class CreateParamsPaymentMethodDataNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class CreateParamsPaymentMethodDataOxxo(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataPayByBank(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPayco(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPaynow(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPaypal(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPix(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPromptpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class CreateParamsPaymentMethodDataRevolutPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSamsungPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSatispay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class CreateParamsPaymentMethodDataSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class CreateParamsPaymentMethodDataSwish(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataTwint(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class CreateParamsPaymentMethodDataWechatPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataZip(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsAcssDebit"
- ]
- """
- If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
- """
- affirm: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
- """
- afterpay_clearpay: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsAfterpayClearpay"
- ]
- """
- If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
- """
- alipay: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsAlipay"
- ]
- """
- If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
- """
- alma: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsAlma"
- ]
- """
- If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
- """
- amazon_pay: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsAmazonPay"
- ]
- """
- If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
- """
- au_becs_debit: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsAuBecsDebit"
- ]
- """
- If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
- """
- bacs_debit: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
- """
- bancontact: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
- """
- billie: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
- """
- blik: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsBlik"
- ]
- """
- If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
- """
- boleto: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
- """
- card: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsCard"
- ]
- """
- Configuration for any card payments attempted on this PaymentIntent.
- """
- card_present: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsCardPresent"
- ]
- """
- If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
- """
- cashapp: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
- """
- crypto: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsCrypto"
- ]
- """
- If this is a `crypto` PaymentMethod, this sub-hash contains details about the Crypto payment method options.
- """
- customer_balance: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsCustomerBalance"
- ]
- """
- If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
- """
- eps: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsEps"
- ]
- """
- If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
- """
- fpx: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsFpx"
- ]
- """
- If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
- """
- giropay: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
- """
- grabpay: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
- """
- ideal: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsIdeal"
- ]
- """
- If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
- """
- interac_present: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsInteracPresent"
- ]
- """
- If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
- """
- kakao_pay: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
- """
- klarna: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
- """
- konbini: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
- """
- kr_card: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
- """
- link: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsLink"
- ]
- """
- If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
- """
- mb_way: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsMbWay"
- ]
- """
- If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
- """
- mobilepay: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsMobilepay"
- ]
- """
- If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
- """
- multibanco: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
- """
- naver_pay: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
- """
- nz_bank_account: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsNzBankAccount"
- ]
- """
- If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
- """
- oxxo: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsOxxo"
- ]
- """
- If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
- """
- p24: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsP24"
- ]
- """
- If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
- """
- pay_by_bank: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
- """
- payco: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsPayco"
- ]
- """
- If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
- """
- paynow: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
- """
- paypal: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
- """
- pix: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsPix"
- ]
- """
- If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
- """
- promptpay: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
- """
- revolut_pay: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
- """
- samsung_pay: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
- """
- satispay: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
- """
- sepa_debit: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
- """
- sofort: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
- """
- swish: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsSwish"
- ]
- """
- If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
- """
- twint: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsTwint"
- ]
- """
- If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
- """
- us_bank_account: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
- """
- wechat_pay: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsWechatPay"
- ]
- """
- If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
- """
- zip: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsZip"
- ]
- """
- If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
- """
-
- class CreateParamsPaymentMethodOptionsAcssDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class CreateParamsPaymentMethodOptionsAcssDebitMandateOptions(TypedDict):
- custom_mandate_url: NotRequired["Literal['']|str"]
- """
- A URL for custom mandate text to render during confirmation step.
- The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
- or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
- """
- interval_description: NotRequired[str]
- """
- Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
- """
- payment_schedule: NotRequired[
- Literal["combined", "interval", "sporadic"]
- ]
- """
- Payment schedule for the mandate.
- """
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class CreateParamsPaymentMethodOptionsAffirm(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- preferred_locale: NotRequired[str]
- """
- Preferred language of the Affirm authorization page that the customer is redirected to.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsAfterpayClearpay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- reference: NotRequired[str]
- """
- An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
- This field differs from the statement descriptor and item name.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsAlipay(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsAlma(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class CreateParamsPaymentMethodOptionsAmazonPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsAuBecsDebit(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class CreateParamsPaymentMethodOptionsBacsDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsBacsDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class CreateParamsPaymentMethodOptionsBacsDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
- """
-
- class CreateParamsPaymentMethodOptionsBancontact(TypedDict):
- preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
- """
- Preferred language of the Bancontact authorization page that the customer is redirected to.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsBillie(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class CreateParamsPaymentMethodOptionsBlik(TypedDict):
- code: NotRequired[str]
- """
- The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
- """
- setup_future_usage: NotRequired["Literal['']|Literal['none']"]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsBoleto(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsCard(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- cvc_token: NotRequired[str]
- """
- A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
- """
- installments: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsCardInstallments"
- ]
- """
- Installment configuration for payments attempted on this PaymentIntent.
-
- For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
- """
- mandate_options: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- moto: NotRequired[bool]
- """
- When specified, this parameter indicates that a transaction will be marked
- as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
- parameter can only be provided during confirmation.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
- """
- request_extended_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
- """
- request_incremental_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
- """
- request_multicapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
- """
- request_overcapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
- require_cvc_recollection: NotRequired[bool]
- """
- When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- statement_descriptor_suffix_kana: NotRequired["Literal['']|str"]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that's set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
- """
- statement_descriptor_suffix_kanji: NotRequired["Literal['']|str"]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that's set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
- """
- three_d_secure: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsCardThreeDSecure"
- ]
- """
- If 3D Secure authentication was performed with a third-party provider,
- the authentication details to use for this payment.
- """
-
- class CreateParamsPaymentMethodOptionsCardInstallments(TypedDict):
- enabled: NotRequired[bool]
- """
- Setting to true enables installments for this PaymentIntent.
- This will cause the response to contain a list of available installment plans.
- Setting to false will prevent any selected plan from applying to a charge.
- """
- plan: NotRequired[
- "Literal['']|PaymentIntent.CreateParamsPaymentMethodOptionsCardInstallmentsPlan"
- ]
- """
- The selected installment plan to use for this payment attempt.
- This parameter can only be provided during confirmation.
- """
-
- class CreateParamsPaymentMethodOptionsCardInstallmentsPlan(TypedDict):
- count: NotRequired[int]
- """
- For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
- """
- interval: NotRequired[Literal["month"]]
- """
- For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
- One of `month`.
- """
- type: Literal["bonus", "fixed_count", "revolving"]
- """
- Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
- """
-
- class CreateParamsPaymentMethodOptionsCardMandateOptions(TypedDict):
- amount: int
- """
- Amount to be charged for future payments.
- """
- amount_type: Literal["fixed", "maximum"]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
- end_date: NotRequired[int]
- """
- End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
- """
- interval: Literal["day", "month", "sporadic", "week", "year"]
- """
- Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
- """
- reference: str
- """
- Unique identifier for the mandate or subscription.
- """
- start_date: int
- """
- Start date of the mandate or subscription. Start date should not be lesser than yesterday.
- """
- supported_types: NotRequired[List[Literal["india"]]]
- """
- Specifies the type of mandates supported. Possible values are `india`.
- """
-
- class CreateParamsPaymentMethodOptionsCardPresent(TypedDict):
- request_extended_authorization: NotRequired[bool]
- """
- Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
- """
- request_incremental_authorization_support: NotRequired[bool]
- """
- Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
- """
- routing: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsCardPresentRouting"
- ]
- """
- Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
- """
-
- class CreateParamsPaymentMethodOptionsCardPresentRouting(TypedDict):
- requested_priority: NotRequired[Literal["domestic", "international"]]
- """
- Routing requested priority
- """
-
- class CreateParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
- ares_trans_status: NotRequired[
- Literal["A", "C", "I", "N", "R", "U", "Y"]
- ]
- """
- The `transStatus` returned from the card Issuer's ACS in the ARes.
- """
- cryptogram: str
- """
- The cryptogram, also known as the "authentication value" (AAV, CAVV or
- AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
- (Most 3D Secure providers will return the base64-encoded version, which
- is what you should specify here.)
- """
- electronic_commerce_indicator: NotRequired[
- Literal["01", "02", "05", "06", "07"]
- ]
- """
- The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
- provider and indicates what degree of authentication was performed.
- """
- exemption_indicator: NotRequired[Literal["low_risk", "none"]]
- """
- The exemption requested via 3DS and accepted by the issuer at authentication time.
- """
- network_options: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
- ]
- """
- Network specific 3DS fields. Network specific arguments require an
- explicit card brand choice. The parameter `payment_method_options.card.network``
- must be populated accordingly
- """
- requestor_challenge_indicator: NotRequired[str]
- """
- The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
- AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
- """
- transaction_id: str
- """
- For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
- Transaction ID (dsTransID).
- """
- version: Literal["1.0.2", "2.1.0", "2.2.0"]
- """
- The version of 3D Secure that was performed.
- """
-
- class CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
- TypedDict,
- ):
- cartes_bancaires: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
- ]
- """
- Cartes Bancaires-specific 3DS fields.
- """
-
- class CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
- TypedDict,
- ):
- cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
- """
- The cryptogram calculation algorithm used by the card Issuer's ACS
- to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
- messageExtension: CB-AVALGO
- """
- cb_exemption: NotRequired[str]
- """
- The exemption indicator returned from Cartes Bancaires in the ARes.
- message extension: CB-EXEMPTION; string (4 characters)
- This is a 3 byte bitmap (low significant byte first and most significant
- bit first) that has been Base64 encoded
- """
- cb_score: NotRequired[int]
- """
- The risk score returned from Cartes Bancaires in the ARes.
- message extension: CB-SCORE; numeric value 0-99
- """
-
- class CreateParamsPaymentMethodOptionsCashapp(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsCrypto(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsCustomerBalance(TypedDict):
- bank_transfer: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[Literal["bank_transfer"]]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for the eu_bank_transfer funding type.
- """
- requested_address_types: NotRequired[
- List[
- Literal[
- "aba",
- "iban",
- "sepa",
- "sort_code",
- "spei",
- "swift",
- "zengin",
- ]
- ]
- ]
- """
- List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
-
- Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
- """
- type: Literal[
- "eu_bank_transfer",
- "gb_bank_transfer",
- "jp_bank_transfer",
- "mx_bank_transfer",
- "us_bank_transfer",
- ]
- """
- The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
- """
-
- class CreateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class CreateParamsPaymentMethodOptionsEps(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsFpx(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsGiropay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsGrabpay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsIdeal(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsInteracPresent(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptionsKakaoPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsKlarna(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- on_demand: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsKlarnaOnDemand"
- ]
- """
- On-demand details if setting up or charging an on-demand payment.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-CH",
- "de-DE",
- "el-GR",
- "en-AT",
- "en-AU",
- "en-BE",
- "en-CA",
- "en-CH",
- "en-CZ",
- "en-DE",
- "en-DK",
- "en-ES",
- "en-FI",
- "en-FR",
- "en-GB",
- "en-GR",
- "en-IE",
- "en-IT",
- "en-NL",
- "en-NO",
- "en-NZ",
- "en-PL",
- "en-PT",
- "en-RO",
- "en-SE",
- "en-US",
- "es-ES",
- "es-US",
- "fi-FI",
- "fr-BE",
- "fr-CA",
- "fr-CH",
- "fr-FR",
- "it-CH",
- "it-IT",
- "nb-NO",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "ro-RO",
- "sv-FI",
- "sv-SE",
- ]
- ]
- """
- Preferred language of the Klarna authorization page that the customer is redirected to
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- subscriptions: NotRequired[
- "Literal['']|List[PaymentIntent.CreateParamsPaymentMethodOptionsKlarnaSubscription]"
- ]
- """
- Subscription details if setting up or charging a subscription.
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
- average_amount: NotRequired[int]
- """
- Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- maximum_amount: NotRequired[int]
- """
- The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- minimum_amount: NotRequired[int]
- """
- The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
- """
- Interval at which the customer is making purchases
- """
- purchase_interval_count: NotRequired[int]
- """
- The number of `purchase_interval` between charges
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Unit of time between subscription charges.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
- """
- name: NotRequired[str]
- """
- Name for subscription.
- """
- next_billing: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
- ]
- """
- Describes the upcoming charge for this subscription.
- """
- reference: str
- """
- A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
- TypedDict,
- ):
- amount: int
- """
- The amount of the next charge for the subscription.
- """
- date: str
- """
- The date of the next charge for the subscription in YYYY-MM-DD format.
- """
-
- class CreateParamsPaymentMethodOptionsKonbini(TypedDict):
- confirmation_number: NotRequired["Literal['']|str"]
- """
- An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
- """
- expires_after_days: NotRequired["Literal['']|int"]
- """
- The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
- """
- expires_at: NotRequired["Literal['']|int"]
- """
- The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsKrCard(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsLink(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- persistent_token: NotRequired[str]
- """
- [Deprecated] This is a legacy parameter that no longer has any function.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsMbWay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsMobilepay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsMultibanco(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsNaverPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsNzBankAccount(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class CreateParamsPaymentMethodOptionsOxxo(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsP24(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- tos_shown_and_accepted: NotRequired[bool]
- """
- Confirm that the payer has accepted the P24 terms and conditions.
- """
-
- class CreateParamsPaymentMethodOptionsPayByBank(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptionsPayco(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class CreateParamsPaymentMethodOptionsPaynow(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsPaypal(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds will be captured from the customer's account.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-DE",
- "de-LU",
- "el-GR",
- "en-GB",
- "en-US",
- "es-ES",
- "fi-FI",
- "fr-BE",
- "fr-FR",
- "fr-LU",
- "hu-HU",
- "it-IT",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "sk-SK",
- "sv-SE",
- ]
- ]
- """
- [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
- """
- reference: NotRequired[str]
- """
- A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
- """
- risk_correlation_id: NotRequired[str]
- """
- The risk correlation ID for an on-session payment using a saved PayPal payment method.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsPix(TypedDict):
- amount_includes_iof: NotRequired[Literal["always", "never"]]
- """
- Determines if the amount includes the IOF tax. Defaults to `never`.
- """
- expires_after_seconds: NotRequired[int]
- """
- The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
- """
- expires_at: NotRequired[int]
- """
- The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsPromptpay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsRevolutPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsSamsungPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class CreateParamsPaymentMethodOptionsSatispay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class CreateParamsPaymentMethodOptionsSepaDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsSepaDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class CreateParamsPaymentMethodOptionsSepaDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
- """
-
- class CreateParamsPaymentMethodOptionsSofort(TypedDict):
- preferred_language: NotRequired[
- "Literal['']|Literal['de', 'en', 'es', 'fr', 'it', 'nl', 'pl']"
- ]
- """
- Language shown to the payer on redirect.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsSwish(TypedDict):
- reference: NotRequired["Literal['']|str"]
- """
- A reference for this payment to be displayed in the Swish app.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsTwint(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccount(TypedDict):
- financial_connections: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- mandate_options: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsUsBankAccountMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- networks: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsUsBankAccountNetworks"
- ]
- """
- Additional fields for network related functions
- """
- preferred_settlement_speed: NotRequired[
- "Literal['']|Literal['fastest', 'standard']"
- ]
- """
- Preferred transaction settlement speed
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "PaymentIntent.CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
- return_url: NotRequired[str]
- """
- For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountMandateOptions(
- TypedDict,
- ):
- collection_method: NotRequired["Literal['']|Literal['paper']"]
- """
- The method used to collect offline mandate customer acceptance.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountNetworks(TypedDict):
- requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
- """
- Triggers validations to run across the selected networks
- """
-
- class CreateParamsPaymentMethodOptionsWechatPay(TypedDict):
- app_id: NotRequired[str]
- """
- The app ID registered with WeChat Pay. Only required when client is ios or android.
- """
- client: NotRequired[Literal["android", "ios", "web"]]
- """
- The client type that the end customer will pay from
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsZip(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class CreateParamsShipping(TypedDict):
- address: "PaymentIntent.CreateParamsShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class CreateParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when a charge succeeds.
- The amount is capped at the total transaction amount and if no amount is set,
- the full amount is transferred.
-
- If you intend to collect a fee and you need a more robust reporting experience, using
- [application_fee_amount](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-application_fee_amount)
- might be a better fit for your integration.
- """
- destination: str
- """
- If specified, successful charges will be attributed to the destination
- account for tax reporting, and the funds from charges will be transferred
- to the destination account. The ID of the resulting transfer will be
- returned on the successful charge's `transfer` field.
- """
-
- class IncrementAuthorizationParams(RequestOptions):
- amount: int
- """
- The updated total amount that you intend to collect from the cardholder. This amount must be greater than the currently authorized amount.
- """
- application_fee_amount: NotRequired[int]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- statement_descriptor: NotRequired[str]
- """
- Text that appears on the customer's statement as the statement descriptor for a non-card or card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
- """
- transfer_data: NotRequired[
- "PaymentIntent.IncrementAuthorizationParamsTransferData"
- ]
- """
- The parameters used to automatically create a transfer after the payment is captured.
- Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
-
- class IncrementAuthorizationParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when a charge succeeds.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["PaymentIntent.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp or a dictionary with a number of different query options.
- """
- customer: NotRequired[str]
- """
- Only return PaymentIntents for the customer that this customer ID specifies.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- amount: NotRequired[int]
- """
- Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
- """
- application_fee_amount: NotRequired["Literal['']|int"]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- capture_method: NotRequired[
- Literal["automatic", "automatic_async", "manual"]
- ]
- """
- Controls when the funds will be captured from the customer's account.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: NotRequired[str]
- """
- ID of the Customer this PaymentIntent belongs to, if one exists.
-
- Payment methods attached to other Customers cannot be used with this PaymentIntent.
-
- If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- excluded_payment_method_types: NotRequired[
- "Literal['']|List[Literal['acss_debit', 'affirm', 'afterpay_clearpay', 'alipay', 'alma', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'billie', 'blik', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'mb_way', 'mobilepay', 'multibanco', 'naver_pay', 'nz_bank_account', 'oxxo', 'p24', 'pay_by_bank', 'payco', 'paynow', 'paypal', 'pix', 'promptpay', 'revolut_pay', 'samsung_pay', 'satispay', 'sepa_debit', 'sofort', 'swish', 'twint', 'us_bank_account', 'wechat_pay', 'zip']]"
- ]
- """
- The list of payment method types to exclude from use with this payment.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- payment_method: NotRequired[str]
- """
- ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods/transitioning#compatibility) object) to attach to this PaymentIntent. To unset this field to null, pass in an empty string.
- """
- payment_method_configuration: NotRequired[str]
- """
- The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this PaymentIntent.
- """
- payment_method_data: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodData"
- ]
- """
- If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
- in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
- property on the PaymentIntent.
- """
- payment_method_options: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptions"
- ]
- """
- Payment-method-specific configuration for this PaymentIntent.
- """
- payment_method_types: NotRequired[List[str]]
- """
- The list of payment method types (for example, card) that this PaymentIntent can use. Use `automatic_payment_methods` to manage payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
- """
- receipt_email: NotRequired["Literal['']|str"]
- """
- Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- shipping: NotRequired["Literal['']|PaymentIntent.ModifyParamsShipping"]
- """
- Shipping information for this PaymentIntent.
- """
- statement_descriptor: NotRequired[str]
- """
- Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
-
- Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
- """
- statement_descriptor_suffix: NotRequired[str]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
- """
- transfer_data: NotRequired["PaymentIntent.ModifyParamsTransferData"]
- """
- Use this parameter to automatically create a Transfer when the payment succeeds. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies the resulting payment as part of a group. You can only provide `transfer_group` if it hasn't been set. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
-
- class ModifyParamsPaymentMethodData(TypedDict):
- acss_debit: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataAcssDebit"
- ]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataAlipay"
- ]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired["PaymentIntent.ModifyParamsPaymentMethodDataAlma"]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataAmazonPay"
- ]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataAuBecsDebit"
- ]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired["PaymentIntent.ModifyParamsPaymentMethodDataBlik"]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- cashapp: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataCrypto"
- ]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer_balance: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired["PaymentIntent.ModifyParamsPaymentMethodDataEps"]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- fpx: NotRequired["PaymentIntent.ModifyParamsPaymentMethodDataFpx"]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired["PaymentIntent.ModifyParamsPaymentMethodDataIdeal"]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired["PaymentIntent.ModifyParamsPaymentMethodDataLink"]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired["PaymentIntent.ModifyParamsPaymentMethodDataMbWay"]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataMobilepay"
- ]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataNzBankAccount"
- ]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired["PaymentIntent.ModifyParamsPaymentMethodDataOxxo"]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired["PaymentIntent.ModifyParamsPaymentMethodDataP24"]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired["PaymentIntent.ModifyParamsPaymentMethodDataPayco"]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- paynow: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired["PaymentIntent.ModifyParamsPaymentMethodDataPix"]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataRadarOptions"
- ]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired["PaymentIntent.ModifyParamsPaymentMethodDataSwish"]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired["PaymentIntent.ModifyParamsPaymentMethodDataTwint"]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataWechatPay"
- ]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired["PaymentIntent.ModifyParamsPaymentMethodDataZip"]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class ModifyParamsPaymentMethodDataAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class ModifyParamsPaymentMethodDataAffirm(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataAfterpayClearpay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataAlipay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataAlma(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataAmazonPay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class ModifyParamsPaymentMethodDataBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class ModifyParamsPaymentMethodDataBancontact(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataBillie(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class ModifyParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ModifyParamsPaymentMethodDataBlik(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class ModifyParamsPaymentMethodDataCashapp(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataCrypto(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataCustomerBalance(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class ModifyParamsPaymentMethodDataFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class ModifyParamsPaymentMethodDataGiropay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataGrabpay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class ModifyParamsPaymentMethodDataInteracPresent(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataKakaoPay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataKlarna(TypedDict):
- dob: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodDataKlarnaDob"
- ]
- """
- Customer's date of birth
- """
-
- class ModifyParamsPaymentMethodDataKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class ModifyParamsPaymentMethodDataKonbini(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataKrCard(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataLink(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataMbWay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataMobilepay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataMultibanco(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class ModifyParamsPaymentMethodDataNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class ModifyParamsPaymentMethodDataOxxo(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class ModifyParamsPaymentMethodDataPayByBank(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataPayco(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataPaynow(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataPaypal(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataPix(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataPromptpay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class ModifyParamsPaymentMethodDataRevolutPay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataSamsungPay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataSatispay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class ModifyParamsPaymentMethodDataSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class ModifyParamsPaymentMethodDataSwish(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataTwint(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class ModifyParamsPaymentMethodDataWechatPay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataZip(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsAcssDebit"
- ]
- """
- If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
- """
- affirm: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
- """
- afterpay_clearpay: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsAfterpayClearpay"
- ]
- """
- If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
- """
- alipay: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsAlipay"
- ]
- """
- If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
- """
- alma: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsAlma"
- ]
- """
- If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
- """
- amazon_pay: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsAmazonPay"
- ]
- """
- If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
- """
- au_becs_debit: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsAuBecsDebit"
- ]
- """
- If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
- """
- bacs_debit: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
- """
- bancontact: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
- """
- billie: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
- """
- blik: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsBlik"
- ]
- """
- If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
- """
- boleto: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
- """
- card: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsCard"
- ]
- """
- Configuration for any card payments attempted on this PaymentIntent.
- """
- card_present: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsCardPresent"
- ]
- """
- If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
- """
- cashapp: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
- """
- crypto: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsCrypto"
- ]
- """
- If this is a `crypto` PaymentMethod, this sub-hash contains details about the Crypto payment method options.
- """
- customer_balance: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsCustomerBalance"
- ]
- """
- If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
- """
- eps: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsEps"
- ]
- """
- If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
- """
- fpx: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsFpx"
- ]
- """
- If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
- """
- giropay: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
- """
- grabpay: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
- """
- ideal: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsIdeal"
- ]
- """
- If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
- """
- interac_present: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsInteracPresent"
- ]
- """
- If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
- """
- kakao_pay: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
- """
- klarna: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
- """
- konbini: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
- """
- kr_card: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
- """
- link: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsLink"
- ]
- """
- If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
- """
- mb_way: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsMbWay"
- ]
- """
- If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
- """
- mobilepay: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsMobilepay"
- ]
- """
- If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
- """
- multibanco: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
- """
- naver_pay: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
- """
- nz_bank_account: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsNzBankAccount"
- ]
- """
- If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
- """
- oxxo: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsOxxo"
- ]
- """
- If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
- """
- p24: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsP24"
- ]
- """
- If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
- """
- pay_by_bank: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
- """
- payco: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsPayco"
- ]
- """
- If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
- """
- paynow: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
- """
- paypal: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
- """
- pix: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsPix"
- ]
- """
- If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
- """
- promptpay: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
- """
- revolut_pay: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
- """
- samsung_pay: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
- """
- satispay: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
- """
- sepa_debit: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
- """
- sofort: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
- """
- swish: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsSwish"
- ]
- """
- If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
- """
- twint: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsTwint"
- ]
- """
- If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
- """
- us_bank_account: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
- """
- wechat_pay: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsWechatPay"
- ]
- """
- If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
- """
- zip: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsZip"
- ]
- """
- If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
- """
-
- class ModifyParamsPaymentMethodOptionsAcssDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class ModifyParamsPaymentMethodOptionsAcssDebitMandateOptions(TypedDict):
- custom_mandate_url: NotRequired["Literal['']|str"]
- """
- A URL for custom mandate text to render during confirmation step.
- The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
- or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
- """
- interval_description: NotRequired[str]
- """
- Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
- """
- payment_schedule: NotRequired[
- Literal["combined", "interval", "sporadic"]
- ]
- """
- Payment schedule for the mandate.
- """
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class ModifyParamsPaymentMethodOptionsAffirm(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- preferred_locale: NotRequired[str]
- """
- Preferred language of the Affirm authorization page that the customer is redirected to.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsAfterpayClearpay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- reference: NotRequired[str]
- """
- An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
- This field differs from the statement descriptor and item name.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsAlipay(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsAlma(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class ModifyParamsPaymentMethodOptionsAmazonPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class ModifyParamsPaymentMethodOptionsAuBecsDebit(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class ModifyParamsPaymentMethodOptionsBacsDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsBacsDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class ModifyParamsPaymentMethodOptionsBacsDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
- """
-
- class ModifyParamsPaymentMethodOptionsBancontact(TypedDict):
- preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
- """
- Preferred language of the Bancontact authorization page that the customer is redirected to.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsBillie(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class ModifyParamsPaymentMethodOptionsBlik(TypedDict):
- code: NotRequired[str]
- """
- The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
- """
- setup_future_usage: NotRequired["Literal['']|Literal['none']"]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsBoleto(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsCard(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- cvc_token: NotRequired[str]
- """
- A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
- """
- installments: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsCardInstallments"
- ]
- """
- Installment configuration for payments attempted on this PaymentIntent.
-
- For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
- """
- mandate_options: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- moto: NotRequired[bool]
- """
- When specified, this parameter indicates that a transaction will be marked
- as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
- parameter can only be provided during confirmation.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
- """
- request_extended_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
- """
- request_incremental_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
- """
- request_multicapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
- """
- request_overcapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
- require_cvc_recollection: NotRequired[bool]
- """
- When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- statement_descriptor_suffix_kana: NotRequired["Literal['']|str"]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that's set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
- """
- statement_descriptor_suffix_kanji: NotRequired["Literal['']|str"]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that's set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
- """
- three_d_secure: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsCardThreeDSecure"
- ]
- """
- If 3D Secure authentication was performed with a third-party provider,
- the authentication details to use for this payment.
- """
-
- class ModifyParamsPaymentMethodOptionsCardInstallments(TypedDict):
- enabled: NotRequired[bool]
- """
- Setting to true enables installments for this PaymentIntent.
- This will cause the response to contain a list of available installment plans.
- Setting to false will prevent any selected plan from applying to a charge.
- """
- plan: NotRequired[
- "Literal['']|PaymentIntent.ModifyParamsPaymentMethodOptionsCardInstallmentsPlan"
- ]
- """
- The selected installment plan to use for this payment attempt.
- This parameter can only be provided during confirmation.
- """
-
- class ModifyParamsPaymentMethodOptionsCardInstallmentsPlan(TypedDict):
- count: NotRequired[int]
- """
- For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
- """
- interval: NotRequired[Literal["month"]]
- """
- For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
- One of `month`.
- """
- type: Literal["bonus", "fixed_count", "revolving"]
- """
- Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
- """
-
- class ModifyParamsPaymentMethodOptionsCardMandateOptions(TypedDict):
- amount: int
- """
- Amount to be charged for future payments.
- """
- amount_type: Literal["fixed", "maximum"]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
- end_date: NotRequired[int]
- """
- End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
- """
- interval: Literal["day", "month", "sporadic", "week", "year"]
- """
- Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
- """
- reference: str
- """
- Unique identifier for the mandate or subscription.
- """
- start_date: int
- """
- Start date of the mandate or subscription. Start date should not be lesser than yesterday.
- """
- supported_types: NotRequired[List[Literal["india"]]]
- """
- Specifies the type of mandates supported. Possible values are `india`.
- """
-
- class ModifyParamsPaymentMethodOptionsCardPresent(TypedDict):
- request_extended_authorization: NotRequired[bool]
- """
- Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
- """
- request_incremental_authorization_support: NotRequired[bool]
- """
- Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
- """
- routing: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsCardPresentRouting"
- ]
- """
- Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
- """
-
- class ModifyParamsPaymentMethodOptionsCardPresentRouting(TypedDict):
- requested_priority: NotRequired[Literal["domestic", "international"]]
- """
- Routing requested priority
- """
-
- class ModifyParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
- ares_trans_status: NotRequired[
- Literal["A", "C", "I", "N", "R", "U", "Y"]
- ]
- """
- The `transStatus` returned from the card Issuer's ACS in the ARes.
- """
- cryptogram: str
- """
- The cryptogram, also known as the "authentication value" (AAV, CAVV or
- AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
- (Most 3D Secure providers will return the base64-encoded version, which
- is what you should specify here.)
- """
- electronic_commerce_indicator: NotRequired[
- Literal["01", "02", "05", "06", "07"]
- ]
- """
- The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
- provider and indicates what degree of authentication was performed.
- """
- exemption_indicator: NotRequired[Literal["low_risk", "none"]]
- """
- The exemption requested via 3DS and accepted by the issuer at authentication time.
- """
- network_options: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
- ]
- """
- Network specific 3DS fields. Network specific arguments require an
- explicit card brand choice. The parameter `payment_method_options.card.network``
- must be populated accordingly
- """
- requestor_challenge_indicator: NotRequired[str]
- """
- The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
- AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
- """
- transaction_id: str
- """
- For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
- Transaction ID (dsTransID).
- """
- version: Literal["1.0.2", "2.1.0", "2.2.0"]
- """
- The version of 3D Secure that was performed.
- """
-
- class ModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
- TypedDict,
- ):
- cartes_bancaires: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
- ]
- """
- Cartes Bancaires-specific 3DS fields.
- """
-
- class ModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
- TypedDict,
- ):
- cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
- """
- The cryptogram calculation algorithm used by the card Issuer's ACS
- to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
- messageExtension: CB-AVALGO
- """
- cb_exemption: NotRequired[str]
- """
- The exemption indicator returned from Cartes Bancaires in the ARes.
- message extension: CB-EXEMPTION; string (4 characters)
- This is a 3 byte bitmap (low significant byte first and most significant
- bit first) that has been Base64 encoded
- """
- cb_score: NotRequired[int]
- """
- The risk score returned from Cartes Bancaires in the ARes.
- message extension: CB-SCORE; numeric value 0-99
- """
-
- class ModifyParamsPaymentMethodOptionsCashapp(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsCrypto(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsCustomerBalance(TypedDict):
- bank_transfer: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[Literal["bank_transfer"]]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for the eu_bank_transfer funding type.
- """
- requested_address_types: NotRequired[
- List[
- Literal[
- "aba",
- "iban",
- "sepa",
- "sort_code",
- "spei",
- "swift",
- "zengin",
- ]
- ]
- ]
- """
- List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
-
- Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
- """
- type: Literal[
- "eu_bank_transfer",
- "gb_bank_transfer",
- "jp_bank_transfer",
- "mx_bank_transfer",
- "us_bank_transfer",
- ]
- """
- The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
- """
-
- class ModifyParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class ModifyParamsPaymentMethodOptionsEps(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsFpx(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsGiropay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsGrabpay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsIdeal(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsInteracPresent(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodOptionsKakaoPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class ModifyParamsPaymentMethodOptionsKlarna(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- on_demand: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsKlarnaOnDemand"
- ]
- """
- On-demand details if setting up or charging an on-demand payment.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-CH",
- "de-DE",
- "el-GR",
- "en-AT",
- "en-AU",
- "en-BE",
- "en-CA",
- "en-CH",
- "en-CZ",
- "en-DE",
- "en-DK",
- "en-ES",
- "en-FI",
- "en-FR",
- "en-GB",
- "en-GR",
- "en-IE",
- "en-IT",
- "en-NL",
- "en-NO",
- "en-NZ",
- "en-PL",
- "en-PT",
- "en-RO",
- "en-SE",
- "en-US",
- "es-ES",
- "es-US",
- "fi-FI",
- "fr-BE",
- "fr-CA",
- "fr-CH",
- "fr-FR",
- "it-CH",
- "it-IT",
- "nb-NO",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "ro-RO",
- "sv-FI",
- "sv-SE",
- ]
- ]
- """
- Preferred language of the Klarna authorization page that the customer is redirected to
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- subscriptions: NotRequired[
- "Literal['']|List[PaymentIntent.ModifyParamsPaymentMethodOptionsKlarnaSubscription]"
- ]
- """
- Subscription details if setting up or charging a subscription.
- """
-
- class ModifyParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
- average_amount: NotRequired[int]
- """
- Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- maximum_amount: NotRequired[int]
- """
- The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- minimum_amount: NotRequired[int]
- """
- The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
- """
- Interval at which the customer is making purchases
- """
- purchase_interval_count: NotRequired[int]
- """
- The number of `purchase_interval` between charges
- """
-
- class ModifyParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Unit of time between subscription charges.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
- """
- name: NotRequired[str]
- """
- Name for subscription.
- """
- next_billing: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
- ]
- """
- Describes the upcoming charge for this subscription.
- """
- reference: str
- """
- A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
- """
-
- class ModifyParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
- TypedDict,
- ):
- amount: int
- """
- The amount of the next charge for the subscription.
- """
- date: str
- """
- The date of the next charge for the subscription in YYYY-MM-DD format.
- """
-
- class ModifyParamsPaymentMethodOptionsKonbini(TypedDict):
- confirmation_number: NotRequired["Literal['']|str"]
- """
- An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
- """
- expires_after_days: NotRequired["Literal['']|int"]
- """
- The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
- """
- expires_at: NotRequired["Literal['']|int"]
- """
- The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsKrCard(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class ModifyParamsPaymentMethodOptionsLink(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- persistent_token: NotRequired[str]
- """
- [Deprecated] This is a legacy parameter that no longer has any function.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsMbWay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsMobilepay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsMultibanco(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsNaverPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class ModifyParamsPaymentMethodOptionsNzBankAccount(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class ModifyParamsPaymentMethodOptionsOxxo(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsP24(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- tos_shown_and_accepted: NotRequired[bool]
- """
- Confirm that the payer has accepted the P24 terms and conditions.
- """
-
- class ModifyParamsPaymentMethodOptionsPayByBank(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodOptionsPayco(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class ModifyParamsPaymentMethodOptionsPaynow(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsPaypal(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds will be captured from the customer's account.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-DE",
- "de-LU",
- "el-GR",
- "en-GB",
- "en-US",
- "es-ES",
- "fi-FI",
- "fr-BE",
- "fr-FR",
- "fr-LU",
- "hu-HU",
- "it-IT",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "sk-SK",
- "sv-SE",
- ]
- ]
- """
- [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
- """
- reference: NotRequired[str]
- """
- A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
- """
- risk_correlation_id: NotRequired[str]
- """
- The risk correlation ID for an on-session payment using a saved PayPal payment method.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsPix(TypedDict):
- amount_includes_iof: NotRequired[Literal["always", "never"]]
- """
- Determines if the amount includes the IOF tax. Defaults to `never`.
- """
- expires_after_seconds: NotRequired[int]
- """
- The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
- """
- expires_at: NotRequired[int]
- """
- The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsPromptpay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsRevolutPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class ModifyParamsPaymentMethodOptionsSamsungPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class ModifyParamsPaymentMethodOptionsSatispay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class ModifyParamsPaymentMethodOptionsSepaDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsSepaDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class ModifyParamsPaymentMethodOptionsSepaDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
- """
-
- class ModifyParamsPaymentMethodOptionsSofort(TypedDict):
- preferred_language: NotRequired[
- "Literal['']|Literal['de', 'en', 'es', 'fr', 'it', 'nl', 'pl']"
- ]
- """
- Language shown to the payer on redirect.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsSwish(TypedDict):
- reference: NotRequired["Literal['']|str"]
- """
- A reference for this payment to be displayed in the Swish app.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsTwint(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsUsBankAccount(TypedDict):
- financial_connections: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- mandate_options: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsUsBankAccountMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- networks: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsUsBankAccountNetworks"
- ]
- """
- Additional fields for network related functions
- """
- preferred_settlement_speed: NotRequired[
- "Literal['']|Literal['fastest', 'standard']"
- ]
- """
- Preferred transaction settlement speed
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class ModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "PaymentIntent.ModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
- return_url: NotRequired[str]
- """
- For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
- """
-
- class ModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class ModifyParamsPaymentMethodOptionsUsBankAccountMandateOptions(
- TypedDict,
- ):
- collection_method: NotRequired["Literal['']|Literal['paper']"]
- """
- The method used to collect offline mandate customer acceptance.
- """
-
- class ModifyParamsPaymentMethodOptionsUsBankAccountNetworks(TypedDict):
- requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
- """
- Triggers validations to run across the selected networks
- """
-
- class ModifyParamsPaymentMethodOptionsWechatPay(TypedDict):
- app_id: NotRequired[str]
- """
- The app ID registered with WeChat Pay. Only required when client is ios or android.
- """
- client: NotRequired[Literal["android", "ios", "web"]]
- """
- The client type that the end customer will pay from
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsPaymentMethodOptionsZip(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ModifyParamsShipping(TypedDict):
- address: "PaymentIntent.ModifyParamsShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class ModifyParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ModifyParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when a charge succeeds.
- """
-
- class RetrieveParams(RequestOptions):
- client_secret: NotRequired[str]
- """
- The client secret of the PaymentIntent. We require it if you use a publishable key to retrieve the source.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SearchParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- page: NotRequired[str]
- """
- A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
- """
- query: str
- """
- The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for payment intents](https://stripe.com/docs/search#query-fields-for-payment-intents).
- """
-
- class VerifyMicrodepositsParams(RequestOptions):
- amounts: NotRequired[List[int]]
- """
- Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.
- """
- descriptor_code: NotRequired[str]
- """
- A six-character code starting with SM present in the microdeposit sent to the bank account.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- amount: int
- """
- Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
- """
- amount_capturable: int
- """
- Amount that can be captured from this PaymentIntent.
- """
- amount_details: Optional[AmountDetails]
- amount_received: int
- """
- Amount that this PaymentIntent collects.
- """
- application: Optional[ExpandableField["Application"]]
- """
- ID of the Connect application that created the PaymentIntent.
- """
- application_fee_amount: Optional[int]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- automatic_payment_methods: Optional[AutomaticPaymentMethods]
- """
- Settings to configure compatible payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods)
- """
- canceled_at: Optional[int]
- """
- Populated when `status` is `canceled`, this is the time at which the PaymentIntent was canceled. Measured in seconds since the Unix epoch.
- """
- cancellation_reason: Optional[
- Literal[
- "abandoned",
- "automatic",
- "duplicate",
- "expired",
- "failed_invoice",
- "fraudulent",
- "requested_by_customer",
- "void_invoice",
- ]
- ]
- """
- Reason for cancellation of this PaymentIntent, either user-provided (`duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`) or generated by Stripe internally (`failed_invoice`, `void_invoice`, `automatic`, or `expired`).
- """
- capture_method: Literal["automatic", "automatic_async", "manual"]
- """
- Controls when the funds will be captured from the customer's account.
- """
- client_secret: Optional[str]
- """
- The client secret of this PaymentIntent. Used for client-side retrieval using a publishable key.
-
- The client secret can be used to complete a payment from your frontend. It should not be stored, logged, or exposed to anyone other than the customer. Make sure that you have TLS enabled on any page that includes the client secret.
-
- Refer to our docs to [accept a payment](https://stripe.com/docs/payments/accept-a-payment?ui=elements) and learn about how `client_secret` should be handled.
- """
- confirmation_method: Literal["automatic", "manual"]
- """
- Describes whether we can confirm this PaymentIntent automatically, or if it requires customer action to confirm the payment.
- """
- created: int
- """
- Time at which the object was created. Measured in seconds since the Unix epoch.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: Optional[ExpandableField["Customer"]]
- """
- ID of the Customer this PaymentIntent belongs to, if one exists.
-
- Payment methods attached to other Customers cannot be used with this PaymentIntent.
-
- If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.
- """
- description: Optional[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- excluded_payment_method_types: Optional[
- List[
- Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "card",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- ]
- ]
- """
- The list of payment method types to exclude from use with this payment.
- """
- id: str
- """
- Unique identifier for the object.
- """
- last_payment_error: Optional[LastPaymentError]
- """
- The payment error encountered in the previous PaymentIntent confirmation. It will be cleared if the PaymentIntent is later updated for any reason.
- """
- latest_charge: Optional[ExpandableField["Charge"]]
- """
- ID of the latest [Charge object](https://stripe.com/docs/api/charges) created by this PaymentIntent. This property is `null` until PaymentIntent confirmation is attempted.
- """
- livemode: bool
- """
- Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
- """
- metadata: Dict[str, str]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Learn more about [storing information in metadata](https://stripe.com/docs/payments/payment-intents/creating-payment-intents#storing-information-in-metadata).
- """
- next_action: Optional[NextAction]
- """
- If present, this property tells you what actions you need to take in order for your customer to fulfill a payment using the provided source.
- """
- object: Literal["payment_intent"]
- """
- String representing the object's type. Objects of the same type share the same value.
- """
- on_behalf_of: Optional[ExpandableField["Account"]]
- """
- The account (if any) for which the funds of the PaymentIntent are intended. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts) for details.
- """
- payment_method: Optional[ExpandableField["PaymentMethod"]]
- """
- ID of the payment method used in this PaymentIntent.
- """
- payment_method_configuration_details: Optional[
- PaymentMethodConfigurationDetails
- ]
- """
- Information about the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) used for this PaymentIntent.
- """
- payment_method_options: Optional[PaymentMethodOptions]
- """
- Payment-method-specific configuration for this PaymentIntent.
- """
- payment_method_types: List[str]
- """
- The list of payment method types (e.g. card) that this PaymentIntent is allowed to use. A comprehensive list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
- """
- presentment_details: Optional[PresentmentDetails]
- processing: Optional[Processing]
- """
- If present, this property tells you about the processing state of the payment.
- """
- receipt_email: Optional[str]
- """
- Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
- """
- review: Optional[ExpandableField["Review"]]
- """
- ID of the review associated with this PaymentIntent, if any.
- """
- setup_future_usage: Optional[Literal["off_session", "on_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- shipping: Optional[Shipping]
- """
- Shipping information for this PaymentIntent.
- """
- source: Optional[
- ExpandableField[
- Union["Account", "BankAccount", "CardResource", "Source"]
- ]
- ]
- """
- This is a legacy field that will be removed in the future. It is the ID of the Source object that is associated with this PaymentIntent, if one was supplied.
- """
- statement_descriptor: Optional[str]
- """
- Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
+ ]
+ """
+ This is a legacy field that will be removed in the future. It is the ID of the Source object that is associated with this PaymentIntent, if one was supplied.
+ """
+ statement_descriptor: Optional[str]
+ """
+ Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
"""
@@ -11501,7 +2885,7 @@ class VerifyMicrodepositsParams(RequestOptions):
def _cls_apply_customer_balance(
cls,
intent: str,
- **params: Unpack["PaymentIntent.ApplyCustomerBalanceParams"],
+ **params: Unpack["PaymentIntentApplyCustomerBalanceParams"],
) -> "PaymentIntent":
"""
Manually reconcile the remaining amount for a customer_balance PaymentIntent.
@@ -11521,7 +2905,7 @@ def _cls_apply_customer_balance(
@staticmethod
def apply_customer_balance(
intent: str,
- **params: Unpack["PaymentIntent.ApplyCustomerBalanceParams"],
+ **params: Unpack["PaymentIntentApplyCustomerBalanceParams"],
) -> "PaymentIntent":
"""
Manually reconcile the remaining amount for a customer_balance PaymentIntent.
@@ -11530,7 +2914,7 @@ def apply_customer_balance(
@overload
def apply_customer_balance(
- self, **params: Unpack["PaymentIntent.ApplyCustomerBalanceParams"]
+ self, **params: Unpack["PaymentIntentApplyCustomerBalanceParams"]
) -> "PaymentIntent":
"""
Manually reconcile the remaining amount for a customer_balance PaymentIntent.
@@ -11539,7 +2923,7 @@ def apply_customer_balance(
@class_method_variant("_cls_apply_customer_balance")
def apply_customer_balance( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentIntent.ApplyCustomerBalanceParams"]
+ self, **params: Unpack["PaymentIntentApplyCustomerBalanceParams"]
) -> "PaymentIntent":
"""
Manually reconcile the remaining amount for a customer_balance PaymentIntent.
@@ -11559,7 +2943,7 @@ def apply_customer_balance( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_apply_customer_balance_async(
cls,
intent: str,
- **params: Unpack["PaymentIntent.ApplyCustomerBalanceParams"],
+ **params: Unpack["PaymentIntentApplyCustomerBalanceParams"],
) -> "PaymentIntent":
"""
Manually reconcile the remaining amount for a customer_balance PaymentIntent.
@@ -11579,7 +2963,7 @@ async def _cls_apply_customer_balance_async(
@staticmethod
async def apply_customer_balance_async(
intent: str,
- **params: Unpack["PaymentIntent.ApplyCustomerBalanceParams"],
+ **params: Unpack["PaymentIntentApplyCustomerBalanceParams"],
) -> "PaymentIntent":
"""
Manually reconcile the remaining amount for a customer_balance PaymentIntent.
@@ -11588,7 +2972,7 @@ async def apply_customer_balance_async(
@overload
async def apply_customer_balance_async(
- self, **params: Unpack["PaymentIntent.ApplyCustomerBalanceParams"]
+ self, **params: Unpack["PaymentIntentApplyCustomerBalanceParams"]
) -> "PaymentIntent":
"""
Manually reconcile the remaining amount for a customer_balance PaymentIntent.
@@ -11597,7 +2981,7 @@ async def apply_customer_balance_async(
@class_method_variant("_cls_apply_customer_balance_async")
async def apply_customer_balance_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentIntent.ApplyCustomerBalanceParams"]
+ self, **params: Unpack["PaymentIntentApplyCustomerBalanceParams"]
) -> "PaymentIntent":
"""
Manually reconcile the remaining amount for a customer_balance PaymentIntent.
@@ -11615,7 +2999,7 @@ async def apply_customer_balance_async( # pyright: ignore[reportGeneralTypeIssu
@classmethod
def _cls_cancel(
- cls, intent: str, **params: Unpack["PaymentIntent.CancelParams"]
+ 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.
@@ -11638,7 +3022,7 @@ def _cls_cancel(
@overload
@staticmethod
def cancel(
- intent: str, **params: Unpack["PaymentIntent.CancelParams"]
+ 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.
@@ -11651,7 +3035,7 @@ def cancel(
@overload
def cancel(
- self, **params: Unpack["PaymentIntent.CancelParams"]
+ self, **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.
@@ -11664,7 +3048,7 @@ def cancel(
@class_method_variant("_cls_cancel")
def cancel( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentIntent.CancelParams"]
+ self, **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.
@@ -11686,7 +3070,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_cancel_async(
- cls, intent: str, **params: Unpack["PaymentIntent.CancelParams"]
+ 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.
@@ -11709,7 +3093,7 @@ async def _cls_cancel_async(
@overload
@staticmethod
async def cancel_async(
- intent: str, **params: Unpack["PaymentIntent.CancelParams"]
+ 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.
@@ -11722,7 +3106,7 @@ async def cancel_async(
@overload
async def cancel_async(
- self, **params: Unpack["PaymentIntent.CancelParams"]
+ self, **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.
@@ -11735,7 +3119,7 @@ async def cancel_async(
@class_method_variant("_cls_cancel_async")
async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentIntent.CancelParams"]
+ self, **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.
@@ -11757,7 +3141,7 @@ async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_capture(
- cls, intent: str, **params: Unpack["PaymentIntent.CaptureParams"]
+ cls, intent: str, **params: Unpack["PaymentIntentCaptureParams"]
) -> "PaymentIntent":
"""
Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture.
@@ -11780,7 +3164,7 @@ def _cls_capture(
@overload
@staticmethod
def capture(
- intent: str, **params: Unpack["PaymentIntent.CaptureParams"]
+ intent: str, **params: Unpack["PaymentIntentCaptureParams"]
) -> "PaymentIntent":
"""
Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture.
@@ -11793,7 +3177,7 @@ def capture(
@overload
def capture(
- self, **params: Unpack["PaymentIntent.CaptureParams"]
+ self, **params: Unpack["PaymentIntentCaptureParams"]
) -> "PaymentIntent":
"""
Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture.
@@ -11806,7 +3190,7 @@ def capture(
@class_method_variant("_cls_capture")
def capture( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentIntent.CaptureParams"]
+ self, **params: Unpack["PaymentIntentCaptureParams"]
) -> "PaymentIntent":
"""
Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture.
@@ -11828,7 +3212,7 @@ def capture( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_capture_async(
- cls, intent: str, **params: Unpack["PaymentIntent.CaptureParams"]
+ cls, intent: str, **params: Unpack["PaymentIntentCaptureParams"]
) -> "PaymentIntent":
"""
Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture.
@@ -11851,7 +3235,7 @@ async def _cls_capture_async(
@overload
@staticmethod
async def capture_async(
- intent: str, **params: Unpack["PaymentIntent.CaptureParams"]
+ intent: str, **params: Unpack["PaymentIntentCaptureParams"]
) -> "PaymentIntent":
"""
Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture.
@@ -11864,7 +3248,7 @@ async def capture_async(
@overload
async def capture_async(
- self, **params: Unpack["PaymentIntent.CaptureParams"]
+ self, **params: Unpack["PaymentIntentCaptureParams"]
) -> "PaymentIntent":
"""
Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture.
@@ -11877,7 +3261,7 @@ async def capture_async(
@class_method_variant("_cls_capture_async")
async def capture_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentIntent.CaptureParams"]
+ self, **params: Unpack["PaymentIntentCaptureParams"]
) -> "PaymentIntent":
"""
Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture.
@@ -11899,7 +3283,7 @@ async def capture_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_confirm(
- cls, intent: str, **params: Unpack["PaymentIntent.ConfirmParams"]
+ cls, intent: str, **params: Unpack["PaymentIntentConfirmParams"]
) -> "PaymentIntent":
"""
Confirm that your customer intends to pay with current or provided
@@ -11947,7 +3331,7 @@ def _cls_confirm(
@overload
@staticmethod
def confirm(
- intent: str, **params: Unpack["PaymentIntent.ConfirmParams"]
+ intent: str, **params: Unpack["PaymentIntentConfirmParams"]
) -> "PaymentIntent":
"""
Confirm that your customer intends to pay with current or provided
@@ -11985,7 +3369,7 @@ def confirm(
@overload
def confirm(
- self, **params: Unpack["PaymentIntent.ConfirmParams"]
+ self, **params: Unpack["PaymentIntentConfirmParams"]
) -> "PaymentIntent":
"""
Confirm that your customer intends to pay with current or provided
@@ -12023,7 +3407,7 @@ def confirm(
@class_method_variant("_cls_confirm")
def confirm( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentIntent.ConfirmParams"]
+ self, **params: Unpack["PaymentIntentConfirmParams"]
) -> "PaymentIntent":
"""
Confirm that your customer intends to pay with current or provided
@@ -12070,7 +3454,7 @@ def confirm( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_confirm_async(
- cls, intent: str, **params: Unpack["PaymentIntent.ConfirmParams"]
+ cls, intent: str, **params: Unpack["PaymentIntentConfirmParams"]
) -> "PaymentIntent":
"""
Confirm that your customer intends to pay with current or provided
@@ -12118,7 +3502,7 @@ async def _cls_confirm_async(
@overload
@staticmethod
async def confirm_async(
- intent: str, **params: Unpack["PaymentIntent.ConfirmParams"]
+ intent: str, **params: Unpack["PaymentIntentConfirmParams"]
) -> "PaymentIntent":
"""
Confirm that your customer intends to pay with current or provided
@@ -12156,7 +3540,7 @@ async def confirm_async(
@overload
async def confirm_async(
- self, **params: Unpack["PaymentIntent.ConfirmParams"]
+ self, **params: Unpack["PaymentIntentConfirmParams"]
) -> "PaymentIntent":
"""
Confirm that your customer intends to pay with current or provided
@@ -12194,7 +3578,7 @@ async def confirm_async(
@class_method_variant("_cls_confirm_async")
async def confirm_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentIntent.ConfirmParams"]
+ self, **params: Unpack["PaymentIntentConfirmParams"]
) -> "PaymentIntent":
"""
Confirm that your customer intends to pay with current or provided
@@ -12241,7 +3625,7 @@ async def confirm_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def create(
- cls, **params: Unpack["PaymentIntent.CreateParams"]
+ cls, **params: Unpack["PaymentIntentCreateParams"]
) -> "PaymentIntent":
"""
Creates a PaymentIntent object.
@@ -12266,7 +3650,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["PaymentIntent.CreateParams"]
+ cls, **params: Unpack["PaymentIntentCreateParams"]
) -> "PaymentIntent":
"""
Creates a PaymentIntent object.
@@ -12293,7 +3677,7 @@ async def create_async(
def _cls_increment_authorization(
cls,
intent: str,
- **params: Unpack["PaymentIntent.IncrementAuthorizationParams"],
+ **params: Unpack["PaymentIntentIncrementAuthorizationParams"],
) -> "PaymentIntent":
"""
Perform an incremental authorization on an eligible
@@ -12336,7 +3720,7 @@ def _cls_increment_authorization(
@staticmethod
def increment_authorization(
intent: str,
- **params: Unpack["PaymentIntent.IncrementAuthorizationParams"],
+ **params: Unpack["PaymentIntentIncrementAuthorizationParams"],
) -> "PaymentIntent":
"""
Perform an incremental authorization on an eligible
@@ -12368,7 +3752,7 @@ def increment_authorization(
@overload
def increment_authorization(
- self, **params: Unpack["PaymentIntent.IncrementAuthorizationParams"]
+ self, **params: Unpack["PaymentIntentIncrementAuthorizationParams"]
) -> "PaymentIntent":
"""
Perform an incremental authorization on an eligible
@@ -12400,7 +3784,7 @@ def increment_authorization(
@class_method_variant("_cls_increment_authorization")
def increment_authorization( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentIntent.IncrementAuthorizationParams"]
+ self, **params: Unpack["PaymentIntentIncrementAuthorizationParams"]
) -> "PaymentIntent":
"""
Perform an incremental authorization on an eligible
@@ -12443,7 +3827,7 @@ def increment_authorization( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_increment_authorization_async(
cls,
intent: str,
- **params: Unpack["PaymentIntent.IncrementAuthorizationParams"],
+ **params: Unpack["PaymentIntentIncrementAuthorizationParams"],
) -> "PaymentIntent":
"""
Perform an incremental authorization on an eligible
@@ -12486,7 +3870,7 @@ async def _cls_increment_authorization_async(
@staticmethod
async def increment_authorization_async(
intent: str,
- **params: Unpack["PaymentIntent.IncrementAuthorizationParams"],
+ **params: Unpack["PaymentIntentIncrementAuthorizationParams"],
) -> "PaymentIntent":
"""
Perform an incremental authorization on an eligible
@@ -12518,7 +3902,7 @@ async def increment_authorization_async(
@overload
async def increment_authorization_async(
- self, **params: Unpack["PaymentIntent.IncrementAuthorizationParams"]
+ self, **params: Unpack["PaymentIntentIncrementAuthorizationParams"]
) -> "PaymentIntent":
"""
Perform an incremental authorization on an eligible
@@ -12550,7 +3934,7 @@ async def increment_authorization_async(
@class_method_variant("_cls_increment_authorization_async")
async def increment_authorization_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentIntent.IncrementAuthorizationParams"]
+ self, **params: Unpack["PaymentIntentIncrementAuthorizationParams"]
) -> "PaymentIntent":
"""
Perform an incremental authorization on an eligible
@@ -12591,7 +3975,7 @@ async def increment_authorization_async( # pyright: ignore[reportGeneralTypeIss
@classmethod
def list(
- cls, **params: Unpack["PaymentIntent.ListParams"]
+ cls, **params: Unpack["PaymentIntentListParams"]
) -> ListObject["PaymentIntent"]:
"""
Returns a list of PaymentIntents.
@@ -12611,7 +3995,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["PaymentIntent.ListParams"]
+ cls, **params: Unpack["PaymentIntentListParams"]
) -> ListObject["PaymentIntent"]:
"""
Returns a list of PaymentIntents.
@@ -12631,7 +4015,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["PaymentIntent.ModifyParams"]
+ cls, id: str, **params: Unpack["PaymentIntentModifyParams"]
) -> "PaymentIntent":
"""
Updates properties on a PaymentIntent object without confirming.
@@ -12654,7 +4038,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["PaymentIntent.ModifyParams"]
+ cls, id: str, **params: Unpack["PaymentIntentModifyParams"]
) -> "PaymentIntent":
"""
Updates properties on a PaymentIntent object without confirming.
@@ -12677,7 +4061,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["PaymentIntent.RetrieveParams"]
+ cls, id: str, **params: Unpack["PaymentIntentRetrieveParams"]
) -> "PaymentIntent":
"""
Retrieves the details of a PaymentIntent that has previously been created.
@@ -12692,7 +4076,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["PaymentIntent.RetrieveParams"]
+ cls, id: str, **params: Unpack["PaymentIntentRetrieveParams"]
) -> "PaymentIntent":
"""
Retrieves the details of a PaymentIntent that has previously been created.
@@ -12709,7 +4093,7 @@ async def retrieve_async(
def _cls_verify_microdeposits(
cls,
intent: str,
- **params: Unpack["PaymentIntent.VerifyMicrodepositsParams"],
+ **params: Unpack["PaymentIntentVerifyMicrodepositsParams"],
) -> "PaymentIntent":
"""
Verifies microdeposits on a PaymentIntent object.
@@ -12728,8 +4112,7 @@ def _cls_verify_microdeposits(
@overload
@staticmethod
def verify_microdeposits(
- intent: str,
- **params: Unpack["PaymentIntent.VerifyMicrodepositsParams"],
+ intent: str, **params: Unpack["PaymentIntentVerifyMicrodepositsParams"]
) -> "PaymentIntent":
"""
Verifies microdeposits on a PaymentIntent object.
@@ -12738,7 +4121,7 @@ def verify_microdeposits(
@overload
def verify_microdeposits(
- self, **params: Unpack["PaymentIntent.VerifyMicrodepositsParams"]
+ self, **params: Unpack["PaymentIntentVerifyMicrodepositsParams"]
) -> "PaymentIntent":
"""
Verifies microdeposits on a PaymentIntent object.
@@ -12747,7 +4130,7 @@ def verify_microdeposits(
@class_method_variant("_cls_verify_microdeposits")
def verify_microdeposits( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentIntent.VerifyMicrodepositsParams"]
+ self, **params: Unpack["PaymentIntentVerifyMicrodepositsParams"]
) -> "PaymentIntent":
"""
Verifies microdeposits on a PaymentIntent object.
@@ -12767,7 +4150,7 @@ def verify_microdeposits( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_verify_microdeposits_async(
cls,
intent: str,
- **params: Unpack["PaymentIntent.VerifyMicrodepositsParams"],
+ **params: Unpack["PaymentIntentVerifyMicrodepositsParams"],
) -> "PaymentIntent":
"""
Verifies microdeposits on a PaymentIntent object.
@@ -12786,8 +4169,7 @@ async def _cls_verify_microdeposits_async(
@overload
@staticmethod
async def verify_microdeposits_async(
- intent: str,
- **params: Unpack["PaymentIntent.VerifyMicrodepositsParams"],
+ intent: str, **params: Unpack["PaymentIntentVerifyMicrodepositsParams"]
) -> "PaymentIntent":
"""
Verifies microdeposits on a PaymentIntent object.
@@ -12796,7 +4178,7 @@ async def verify_microdeposits_async(
@overload
async def verify_microdeposits_async(
- self, **params: Unpack["PaymentIntent.VerifyMicrodepositsParams"]
+ self, **params: Unpack["PaymentIntentVerifyMicrodepositsParams"]
) -> "PaymentIntent":
"""
Verifies microdeposits on a PaymentIntent object.
@@ -12805,7 +4187,7 @@ async def verify_microdeposits_async(
@class_method_variant("_cls_verify_microdeposits_async")
async def verify_microdeposits_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentIntent.VerifyMicrodepositsParams"]
+ self, **params: Unpack["PaymentIntentVerifyMicrodepositsParams"]
) -> "PaymentIntent":
"""
Verifies microdeposits on a PaymentIntent object.
@@ -12823,7 +4205,7 @@ async def verify_microdeposits_async( # pyright: ignore[reportGeneralTypeIssues
@classmethod
def search(
- cls, *args, **kwargs: Unpack["PaymentIntent.SearchParams"]
+ cls, *args, **kwargs: Unpack["PaymentIntentSearchParams"]
) -> SearchResultObject["PaymentIntent"]:
"""
Search for PaymentIntents you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
@@ -12837,7 +4219,7 @@ def search(
@classmethod
async def search_async(
- cls, *args, **kwargs: Unpack["PaymentIntent.SearchParams"]
+ cls, *args, **kwargs: Unpack["PaymentIntentSearchParams"]
) -> SearchResultObject["PaymentIntent"]:
"""
Search for PaymentIntents you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
@@ -12851,13 +4233,13 @@ async def search_async(
@classmethod
def search_auto_paging_iter(
- cls, *args, **kwargs: Unpack["PaymentIntent.SearchParams"]
+ cls, *args, **kwargs: Unpack["PaymentIntentSearchParams"]
) -> Iterator["PaymentIntent"]:
return cls.search(*args, **kwargs).auto_paging_iter()
@classmethod
async def search_auto_paging_iter_async(
- cls, *args, **kwargs: Unpack["PaymentIntent.SearchParams"]
+ cls, *args, **kwargs: Unpack["PaymentIntentSearchParams"]
) -> AsyncIterator["PaymentIntent"]:
return (await cls.search_async(*args, **kwargs)).auto_paging_iter()
diff --git a/stripe/_payment_intent_service.py b/stripe/_payment_intent_service.py
index 456526f2e..cc3f7dc69 100644
--- a/stripe/_payment_intent_service.py
+++ b/stripe/_payment_intent_service.py
@@ -6,8750 +6,49 @@
from stripe._search_result_object import SearchResultObject
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._payment_intent_apply_customer_balance_params import (
+ PaymentIntentApplyCustomerBalanceParams,
+ )
+ from stripe.params._payment_intent_cancel_params import (
+ PaymentIntentCancelParams,
+ )
+ from stripe.params._payment_intent_capture_params import (
+ PaymentIntentCaptureParams,
+ )
+ from stripe.params._payment_intent_confirm_params import (
+ PaymentIntentConfirmParams,
+ )
+ from stripe.params._payment_intent_create_params import (
+ PaymentIntentCreateParams,
+ )
+ from stripe.params._payment_intent_increment_authorization_params import (
+ PaymentIntentIncrementAuthorizationParams,
+ )
+ from stripe.params._payment_intent_list_params import (
+ PaymentIntentListParams,
+ )
+ from stripe.params._payment_intent_retrieve_params import (
+ PaymentIntentRetrieveParams,
+ )
+ from stripe.params._payment_intent_search_params import (
+ PaymentIntentSearchParams,
+ )
+ from stripe.params._payment_intent_update_params import (
+ PaymentIntentUpdateParams,
+ )
+ from stripe.params._payment_intent_verify_microdeposits_params import (
+ PaymentIntentVerifyMicrodepositsParams,
+ )
class PaymentIntentService(StripeService):
- class ApplyCustomerBalanceParams(TypedDict):
- amount: NotRequired[int]
- """
- Amount that you intend to apply to this PaymentIntent from the customer's cash balance. If the PaymentIntent was created by an Invoice, the full amount of the PaymentIntent is applied regardless of this parameter.
-
- A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (for example, 100 cents to charge 1 USD or 100 to charge 100 JPY, a zero-decimal currency). The maximum amount is the amount of the PaymentIntent.
-
- When you omit the amount, it defaults to the remaining amount requested on the PaymentIntent.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CancelParams(TypedDict):
- cancellation_reason: NotRequired[
- Literal[
- "abandoned", "duplicate", "fraudulent", "requested_by_customer"
- ]
- ]
- """
- Reason for canceling this PaymentIntent. Possible values are: `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CaptureParams(TypedDict):
- amount_to_capture: NotRequired[int]
- """
- The amount to capture from the PaymentIntent, which must be less than or equal to the original amount. Defaults to the full `amount_capturable` if it's not provided.
- """
- application_fee_amount: NotRequired[int]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- final_capture: NotRequired[bool]
- """
- Defaults to `true`. When capturing a PaymentIntent, setting `final_capture` to `false` notifies Stripe to not release the remaining uncaptured funds to make sure that they're captured in future requests. You can only use this setting when [multicapture](https://stripe.com/docs/payments/multicapture) is available for PaymentIntents.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- statement_descriptor: NotRequired[str]
- """
- Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
-
- Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
- """
- statement_descriptor_suffix: NotRequired[str]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
- """
- transfer_data: NotRequired[
- "PaymentIntentService.CaptureParamsTransferData"
- ]
- """
- The parameters that you can use to automatically create a transfer after the payment
- is captured. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
-
- class CaptureParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when a charge succeeds.
- """
-
- class ConfirmParams(TypedDict):
- capture_method: NotRequired[
- Literal["automatic", "automatic_async", "manual"]
- ]
- """
- Controls when the funds will be captured from the customer's account.
- """
- confirmation_token: NotRequired[str]
- """
- ID of the ConfirmationToken used to confirm this PaymentIntent.
-
- If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
- """
- error_on_requires_action: NotRequired[bool]
- """
- Set to `true` to fail the payment attempt if the PaymentIntent transitions into `requires_action`. This parameter is intended for simpler integrations that do not handle customer actions, like [saving cards without authentication](https://stripe.com/docs/payments/save-card-without-authentication).
- """
- excluded_payment_method_types: NotRequired[
- "Literal['']|List[Literal['acss_debit', 'affirm', 'afterpay_clearpay', 'alipay', 'alma', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'billie', 'blik', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'mb_way', 'mobilepay', 'multibanco', 'naver_pay', 'nz_bank_account', 'oxxo', 'p24', 'pay_by_bank', 'payco', 'paynow', 'paypal', 'pix', 'promptpay', 'revolut_pay', 'samsung_pay', 'satispay', 'sepa_debit', 'sofort', 'swish', 'twint', 'us_bank_account', 'wechat_pay', 'zip']]"
- ]
- """
- The list of payment method types to exclude from use with this payment.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- mandate: NotRequired[str]
- """
- ID of the mandate that's used for this payment.
- """
- mandate_data: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsMandateData"
- ]
- off_session: NotRequired["bool|Literal['one_off', 'recurring']"]
- """
- Set to `true` to indicate that the customer isn't in your checkout flow during this payment attempt and can't authenticate. Use this parameter in scenarios where you collect card details and [charge them later](https://stripe.com/docs/payments/cards/charging-saved-cards).
- """
- payment_method: NotRequired[str]
- """
- ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods/transitioning#compatibility) object) to attach to this PaymentIntent.
- If the payment method is attached to a Customer, it must match the [customer](https://stripe.com/docs/api#create_payment_intent-customer) that is set on this PaymentIntent.
- """
- payment_method_data: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodData"
- ]
- """
- If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
- in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
- property on the PaymentIntent.
- """
- payment_method_options: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptions"
- ]
- """
- Payment method-specific configuration for this PaymentIntent.
- """
- payment_method_types: NotRequired[List[str]]
- """
- The list of payment method types (for example, a card) that this PaymentIntent can use. Use `automatic_payment_methods` to manage payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
- """
- radar_options: NotRequired[
- "PaymentIntentService.ConfirmParamsRadarOptions"
- ]
- """
- Options to configure Radar. Learn more about [Radar Sessions](https://stripe.com/docs/radar/radar-session).
- """
- receipt_email: NotRequired["Literal['']|str"]
- """
- Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
- """
- return_url: NotRequired[str]
- """
- The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site.
- If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
- This parameter is only used for cards and other redirect-based payment methods.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- shipping: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsShipping"
- ]
- """
- Shipping information for this PaymentIntent.
- """
- use_stripe_sdk: NotRequired[bool]
- """
- Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
- """
-
- class ConfirmParamsMandateData(TypedDict):
- customer_acceptance: NotRequired[
- "PaymentIntentService.ConfirmParamsMandateDataCustomerAcceptance"
- ]
- """
- This hash contains details about the customer acceptance of the Mandate.
- """
-
- class ConfirmParamsMandateDataCustomerAcceptance(TypedDict):
- accepted_at: NotRequired[int]
- """
- The time at which the customer accepted the Mandate.
- """
- offline: NotRequired[
- "PaymentIntentService.ConfirmParamsMandateDataCustomerAcceptanceOffline"
- ]
- """
- If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
- """
- online: NotRequired[
- "PaymentIntentService.ConfirmParamsMandateDataCustomerAcceptanceOnline"
- ]
- """
- If this is a Mandate accepted online, this hash contains details about the online acceptance.
- """
- type: Literal["offline", "online"]
- """
- The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
- """
-
- class ConfirmParamsMandateDataCustomerAcceptanceOffline(TypedDict):
- pass
-
- class ConfirmParamsMandateDataCustomerAcceptanceOnline(TypedDict):
- ip_address: NotRequired[str]
- """
- The IP address from which the Mandate was accepted by the customer.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the Mandate was accepted by the customer.
- """
-
- class ConfirmParamsPaymentMethodData(TypedDict):
- acss_debit: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataAcssDebit"
- ]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataAlipay"
- ]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataAlma"
- ]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataAmazonPay"
- ]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataAuBecsDebit"
- ]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataBlik"
- ]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- cashapp: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataCrypto"
- ]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer_balance: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataEps"
- ]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- fpx: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataFpx"
- ]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataIdeal"
- ]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataLink"
- ]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataMbWay"
- ]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataMobilepay"
- ]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataNzBankAccount"
- ]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataOxxo"
- ]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataP24"
- ]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataPayco"
- ]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- paynow: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataPix"
- ]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataRadarOptions"
- ]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataSwish"
- ]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataTwint"
- ]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataWechatPay"
- ]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataZip"
- ]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class ConfirmParamsPaymentMethodDataAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataAffirm(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAfterpayClearpay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAlipay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAlma(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAmazonPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class ConfirmParamsPaymentMethodDataBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class ConfirmParamsPaymentMethodDataBancontact(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataBillie(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class ConfirmParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ConfirmParamsPaymentMethodDataBlik(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class ConfirmParamsPaymentMethodDataCashapp(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataCrypto(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataCustomerBalance(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataGiropay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataGrabpay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class ConfirmParamsPaymentMethodDataInteracPresent(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataKakaoPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataKlarna(TypedDict):
- dob: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodDataKlarnaDob"
- ]
- """
- Customer's date of birth
- """
-
- class ConfirmParamsPaymentMethodDataKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class ConfirmParamsPaymentMethodDataKonbini(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataKrCard(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataLink(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataMbWay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataMobilepay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataMultibanco(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class ConfirmParamsPaymentMethodDataNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class ConfirmParamsPaymentMethodDataOxxo(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataPayByBank(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPayco(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPaynow(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPaypal(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPix(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPromptpay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class ConfirmParamsPaymentMethodDataRevolutPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataSamsungPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataSatispay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class ConfirmParamsPaymentMethodDataSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class ConfirmParamsPaymentMethodDataSwish(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataTwint(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class ConfirmParamsPaymentMethodDataWechatPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataZip(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsAcssDebit"
- ]
- """
- If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
- """
- affirm: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
- """
- afterpay_clearpay: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsAfterpayClearpay"
- ]
- """
- If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
- """
- alipay: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsAlipay"
- ]
- """
- If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
- """
- alma: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsAlma"
- ]
- """
- If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
- """
- amazon_pay: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsAmazonPay"
- ]
- """
- If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
- """
- au_becs_debit: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsAuBecsDebit"
- ]
- """
- If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
- """
- bacs_debit: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
- """
- bancontact: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
- """
- billie: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
- """
- blik: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsBlik"
- ]
- """
- If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
- """
- boleto: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
- """
- card: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsCard"
- ]
- """
- Configuration for any card payments attempted on this PaymentIntent.
- """
- card_present: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsCardPresent"
- ]
- """
- If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
- """
- cashapp: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
- """
- crypto: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsCrypto"
- ]
- """
- If this is a `crypto` PaymentMethod, this sub-hash contains details about the Crypto payment method options.
- """
- customer_balance: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsCustomerBalance"
- ]
- """
- If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
- """
- eps: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsEps"
- ]
- """
- If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
- """
- fpx: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsFpx"
- ]
- """
- If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
- """
- giropay: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
- """
- grabpay: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
- """
- ideal: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsIdeal"
- ]
- """
- If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
- """
- interac_present: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsInteracPresent"
- ]
- """
- If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
- """
- kakao_pay: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
- """
- klarna: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
- """
- konbini: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
- """
- kr_card: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
- """
- link: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsLink"
- ]
- """
- If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
- """
- mb_way: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsMbWay"
- ]
- """
- If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
- """
- mobilepay: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsMobilepay"
- ]
- """
- If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
- """
- multibanco: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
- """
- naver_pay: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
- """
- nz_bank_account: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsNzBankAccount"
- ]
- """
- If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
- """
- oxxo: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsOxxo"
- ]
- """
- If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
- """
- p24: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsP24"
- ]
- """
- If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
- """
- pay_by_bank: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
- """
- payco: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsPayco"
- ]
- """
- If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
- """
- paynow: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
- """
- paypal: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
- """
- pix: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsPix"
- ]
- """
- If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
- """
- promptpay: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
- """
- revolut_pay: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
- """
- samsung_pay: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
- """
- satispay: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
- """
- sepa_debit: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
- """
- sofort: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
- """
- swish: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsSwish"
- ]
- """
- If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
- """
- twint: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsTwint"
- ]
- """
- If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
- """
- us_bank_account: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
- """
- wechat_pay: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsWechatPay"
- ]
- """
- If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
- """
- zip: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsZip"
- ]
- """
- If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
- """
-
- class ConfirmParamsPaymentMethodOptionsAcssDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class ConfirmParamsPaymentMethodOptionsAcssDebitMandateOptions(TypedDict):
- custom_mandate_url: NotRequired["Literal['']|str"]
- """
- A URL for custom mandate text to render during confirmation step.
- The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
- or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
- """
- interval_description: NotRequired[str]
- """
- Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
- """
- payment_schedule: NotRequired[
- Literal["combined", "interval", "sporadic"]
- ]
- """
- Payment schedule for the mandate.
- """
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class ConfirmParamsPaymentMethodOptionsAffirm(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- preferred_locale: NotRequired[str]
- """
- Preferred language of the Affirm authorization page that the customer is redirected to.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsAfterpayClearpay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- reference: NotRequired[str]
- """
- An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
- This field differs from the statement descriptor and item name.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsAlipay(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsAlma(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class ConfirmParamsPaymentMethodOptionsAmazonPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class ConfirmParamsPaymentMethodOptionsAuBecsDebit(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class ConfirmParamsPaymentMethodOptionsBacsDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsBacsDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class ConfirmParamsPaymentMethodOptionsBacsDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
- """
-
- class ConfirmParamsPaymentMethodOptionsBancontact(TypedDict):
- preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
- """
- Preferred language of the Bancontact authorization page that the customer is redirected to.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsBillie(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class ConfirmParamsPaymentMethodOptionsBlik(TypedDict):
- code: NotRequired[str]
- """
- The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
- """
- setup_future_usage: NotRequired["Literal['']|Literal['none']"]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsBoleto(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCard(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- cvc_token: NotRequired[str]
- """
- A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
- """
- installments: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsCardInstallments"
- ]
- """
- Installment configuration for payments attempted on this PaymentIntent.
-
- For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
- """
- mandate_options: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- moto: NotRequired[bool]
- """
- When specified, this parameter indicates that a transaction will be marked
- as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
- parameter can only be provided during confirmation.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
- """
- request_extended_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
- """
- request_incremental_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
- """
- request_multicapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
- """
- request_overcapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
- require_cvc_recollection: NotRequired[bool]
- """
- When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- statement_descriptor_suffix_kana: NotRequired["Literal['']|str"]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that's set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
- """
- statement_descriptor_suffix_kanji: NotRequired["Literal['']|str"]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that's set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
- """
- three_d_secure: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsCardThreeDSecure"
- ]
- """
- If 3D Secure authentication was performed with a third-party provider,
- the authentication details to use for this payment.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardInstallments(TypedDict):
- enabled: NotRequired[bool]
- """
- Setting to true enables installments for this PaymentIntent.
- This will cause the response to contain a list of available installment plans.
- Setting to false will prevent any selected plan from applying to a charge.
- """
- plan: NotRequired[
- "Literal['']|PaymentIntentService.ConfirmParamsPaymentMethodOptionsCardInstallmentsPlan"
- ]
- """
- The selected installment plan to use for this payment attempt.
- This parameter can only be provided during confirmation.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardInstallmentsPlan(TypedDict):
- count: NotRequired[int]
- """
- For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
- """
- interval: NotRequired[Literal["month"]]
- """
- For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
- One of `month`.
- """
- type: Literal["bonus", "fixed_count", "revolving"]
- """
- Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardMandateOptions(TypedDict):
- amount: int
- """
- Amount to be charged for future payments.
- """
- amount_type: Literal["fixed", "maximum"]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
- end_date: NotRequired[int]
- """
- End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
- """
- interval: Literal["day", "month", "sporadic", "week", "year"]
- """
- Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
- """
- reference: str
- """
- Unique identifier for the mandate or subscription.
- """
- start_date: int
- """
- Start date of the mandate or subscription. Start date should not be lesser than yesterday.
- """
- supported_types: NotRequired[List[Literal["india"]]]
- """
- Specifies the type of mandates supported. Possible values are `india`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardPresent(TypedDict):
- request_extended_authorization: NotRequired[bool]
- """
- Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
- """
- request_incremental_authorization_support: NotRequired[bool]
- """
- Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
- """
- routing: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsCardPresentRouting"
- ]
- """
- Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardPresentRouting(TypedDict):
- requested_priority: NotRequired[Literal["domestic", "international"]]
- """
- Routing requested priority
- """
-
- class ConfirmParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
- ares_trans_status: NotRequired[
- Literal["A", "C", "I", "N", "R", "U", "Y"]
- ]
- """
- The `transStatus` returned from the card Issuer's ACS in the ARes.
- """
- cryptogram: str
- """
- The cryptogram, also known as the "authentication value" (AAV, CAVV or
- AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
- (Most 3D Secure providers will return the base64-encoded version, which
- is what you should specify here.)
- """
- electronic_commerce_indicator: NotRequired[
- Literal["01", "02", "05", "06", "07"]
- ]
- """
- The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
- provider and indicates what degree of authentication was performed.
- """
- exemption_indicator: NotRequired[Literal["low_risk", "none"]]
- """
- The exemption requested via 3DS and accepted by the issuer at authentication time.
- """
- network_options: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
- ]
- """
- Network specific 3DS fields. Network specific arguments require an
- explicit card brand choice. The parameter `payment_method_options.card.network``
- must be populated accordingly
- """
- requestor_challenge_indicator: NotRequired[str]
- """
- The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
- AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
- """
- transaction_id: str
- """
- For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
- Transaction ID (dsTransID).
- """
- version: Literal["1.0.2", "2.1.0", "2.2.0"]
- """
- The version of 3D Secure that was performed.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
- TypedDict,
- ):
- cartes_bancaires: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
- ]
- """
- Cartes Bancaires-specific 3DS fields.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
- TypedDict,
- ):
- cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
- """
- The cryptogram calculation algorithm used by the card Issuer's ACS
- to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
- messageExtension: CB-AVALGO
- """
- cb_exemption: NotRequired[str]
- """
- The exemption indicator returned from Cartes Bancaires in the ARes.
- message extension: CB-EXEMPTION; string (4 characters)
- This is a 3 byte bitmap (low significant byte first and most significant
- bit first) that has been Base64 encoded
- """
- cb_score: NotRequired[int]
- """
- The risk score returned from Cartes Bancaires in the ARes.
- message extension: CB-SCORE; numeric value 0-99
- """
-
- class ConfirmParamsPaymentMethodOptionsCashapp(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCrypto(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCustomerBalance(TypedDict):
- bank_transfer: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[Literal["bank_transfer"]]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for the eu_bank_transfer funding type.
- """
- requested_address_types: NotRequired[
- List[
- Literal[
- "aba",
- "iban",
- "sepa",
- "sort_code",
- "spei",
- "swift",
- "zengin",
- ]
- ]
- ]
- """
- List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
-
- Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
- """
- type: Literal[
- "eu_bank_transfer",
- "gb_bank_transfer",
- "jp_bank_transfer",
- "mx_bank_transfer",
- "us_bank_transfer",
- ]
- """
- The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class ConfirmParamsPaymentMethodOptionsEps(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsFpx(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsGiropay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsGrabpay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsIdeal(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsInteracPresent(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodOptionsKakaoPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarna(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- on_demand: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsKlarnaOnDemand"
- ]
- """
- On-demand details if setting up or charging an on-demand payment.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-CH",
- "de-DE",
- "el-GR",
- "en-AT",
- "en-AU",
- "en-BE",
- "en-CA",
- "en-CH",
- "en-CZ",
- "en-DE",
- "en-DK",
- "en-ES",
- "en-FI",
- "en-FR",
- "en-GB",
- "en-GR",
- "en-IE",
- "en-IT",
- "en-NL",
- "en-NO",
- "en-NZ",
- "en-PL",
- "en-PT",
- "en-RO",
- "en-SE",
- "en-US",
- "es-ES",
- "es-US",
- "fi-FI",
- "fr-BE",
- "fr-CA",
- "fr-CH",
- "fr-FR",
- "it-CH",
- "it-IT",
- "nb-NO",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "ro-RO",
- "sv-FI",
- "sv-SE",
- ]
- ]
- """
- Preferred language of the Klarna authorization page that the customer is redirected to
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- subscriptions: NotRequired[
- "Literal['']|List[PaymentIntentService.ConfirmParamsPaymentMethodOptionsKlarnaSubscription]"
- ]
- """
- Subscription details if setting up or charging a subscription.
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
- average_amount: NotRequired[int]
- """
- Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- maximum_amount: NotRequired[int]
- """
- The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- minimum_amount: NotRequired[int]
- """
- The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
- """
- Interval at which the customer is making purchases
- """
- purchase_interval_count: NotRequired[int]
- """
- The number of `purchase_interval` between charges
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Unit of time between subscription charges.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
- """
- name: NotRequired[str]
- """
- Name for subscription.
- """
- next_billing: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
- ]
- """
- Describes the upcoming charge for this subscription.
- """
- reference: str
- """
- A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
- TypedDict,
- ):
- amount: int
- """
- The amount of the next charge for the subscription.
- """
- date: str
- """
- The date of the next charge for the subscription in YYYY-MM-DD format.
- """
-
- class ConfirmParamsPaymentMethodOptionsKonbini(TypedDict):
- confirmation_number: NotRequired["Literal['']|str"]
- """
- An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
- """
- expires_after_days: NotRequired["Literal['']|int"]
- """
- The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
- """
- expires_at: NotRequired["Literal['']|int"]
- """
- The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsKrCard(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class ConfirmParamsPaymentMethodOptionsLink(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- persistent_token: NotRequired[str]
- """
- [Deprecated] This is a legacy parameter that no longer has any function.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsMbWay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsMobilepay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsMultibanco(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsNaverPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class ConfirmParamsPaymentMethodOptionsNzBankAccount(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class ConfirmParamsPaymentMethodOptionsOxxo(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsP24(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- tos_shown_and_accepted: NotRequired[bool]
- """
- Confirm that the payer has accepted the P24 terms and conditions.
- """
-
- class ConfirmParamsPaymentMethodOptionsPayByBank(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodOptionsPayco(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class ConfirmParamsPaymentMethodOptionsPaynow(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsPaypal(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds will be captured from the customer's account.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-DE",
- "de-LU",
- "el-GR",
- "en-GB",
- "en-US",
- "es-ES",
- "fi-FI",
- "fr-BE",
- "fr-FR",
- "fr-LU",
- "hu-HU",
- "it-IT",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "sk-SK",
- "sv-SE",
- ]
- ]
- """
- [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
- """
- reference: NotRequired[str]
- """
- A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
- """
- risk_correlation_id: NotRequired[str]
- """
- The risk correlation ID for an on-session payment using a saved PayPal payment method.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsPix(TypedDict):
- amount_includes_iof: NotRequired[Literal["always", "never"]]
- """
- Determines if the amount includes the IOF tax. Defaults to `never`.
- """
- expires_after_seconds: NotRequired[int]
- """
- The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
- """
- expires_at: NotRequired[int]
- """
- The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsPromptpay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsRevolutPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class ConfirmParamsPaymentMethodOptionsSamsungPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class ConfirmParamsPaymentMethodOptionsSatispay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class ConfirmParamsPaymentMethodOptionsSepaDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsSepaDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class ConfirmParamsPaymentMethodOptionsSepaDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
- """
-
- class ConfirmParamsPaymentMethodOptionsSofort(TypedDict):
- preferred_language: NotRequired[
- "Literal['']|Literal['de', 'en', 'es', 'fr', 'it', 'nl', 'pl']"
- ]
- """
- Language shown to the payer on redirect.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsSwish(TypedDict):
- reference: NotRequired["Literal['']|str"]
- """
- A reference for this payment to be displayed in the Swish app.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsTwint(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccount(TypedDict):
- financial_connections: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- mandate_options: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsUsBankAccountMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- networks: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsUsBankAccountNetworks"
- ]
- """
- Additional fields for network related functions
- """
- preferred_settlement_speed: NotRequired[
- "Literal['']|Literal['fastest', 'standard']"
- ]
- """
- Preferred transaction settlement speed
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "PaymentIntentService.ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
- return_url: NotRequired[str]
- """
- For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountMandateOptions(
- TypedDict,
- ):
- collection_method: NotRequired["Literal['']|Literal['paper']"]
- """
- The method used to collect offline mandate customer acceptance.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountNetworks(TypedDict):
- requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
- """
- Triggers validations to run across the selected networks
- """
-
- class ConfirmParamsPaymentMethodOptionsWechatPay(TypedDict):
- app_id: NotRequired[str]
- """
- The app ID registered with WeChat Pay. Only required when client is ios or android.
- """
- client: NotRequired[Literal["android", "ios", "web"]]
- """
- The client type that the end customer will pay from
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsPaymentMethodOptionsZip(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class ConfirmParamsRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class ConfirmParamsShipping(TypedDict):
- address: "PaymentIntentService.ConfirmParamsShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class ConfirmParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParams(TypedDict):
- amount: int
- """
- Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
- """
- application_fee_amount: NotRequired[int]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- automatic_payment_methods: NotRequired[
- "PaymentIntentService.CreateParamsAutomaticPaymentMethods"
- ]
- """
- When you enable this parameter, this PaymentIntent accepts payment methods that you enable in the Dashboard and that are compatible with this PaymentIntent's other parameters.
- """
- capture_method: NotRequired[
- Literal["automatic", "automatic_async", "manual"]
- ]
- """
- Controls when the funds will be captured from the customer's account.
- """
- confirm: NotRequired[bool]
- """
- Set to `true` to attempt to [confirm this PaymentIntent](https://stripe.com/docs/api/payment_intents/confirm) immediately. This parameter defaults to `false`. When creating and confirming a PaymentIntent at the same time, you can also provide the parameters available in the [Confirm API](https://stripe.com/docs/api/payment_intents/confirm).
- """
- confirmation_method: NotRequired[Literal["automatic", "manual"]]
- """
- Describes whether we can confirm this PaymentIntent automatically, or if it requires customer action to confirm the payment.
- """
- confirmation_token: NotRequired[str]
- """
- ID of the ConfirmationToken used to confirm this PaymentIntent.
-
- If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: NotRequired[str]
- """
- ID of the Customer this PaymentIntent belongs to, if one exists.
-
- Payment methods attached to other Customers cannot be used with this PaymentIntent.
-
- If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- error_on_requires_action: NotRequired[bool]
- """
- Set to `true` to fail the payment attempt if the PaymentIntent transitions into `requires_action`. Use this parameter for simpler integrations that don't handle customer actions, such as [saving cards without authentication](https://stripe.com/docs/payments/save-card-without-authentication). This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
- """
- excluded_payment_method_types: NotRequired[
- List[
- Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "card",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- ]
- ]
- """
- The list of payment method types to exclude from use with this payment.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- mandate: NotRequired[str]
- """
- ID of the mandate that's used for this payment. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
- """
- mandate_data: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsMandateData"
- ]
- """
- This hash contains details about the Mandate to create. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- off_session: NotRequired["bool|Literal['one_off', 'recurring']"]
- """
- Set to `true` to indicate that the customer isn't in your checkout flow during this payment attempt and can't authenticate. Use this parameter in scenarios where you collect card details and [charge them later](https://stripe.com/docs/payments/cards/charging-saved-cards). This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
- """
- on_behalf_of: NotRequired[str]
- """
- The Stripe account ID that these funds are intended for. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- payment_method: NotRequired[str]
- """
- ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods#compatibility) object) to attach to this PaymentIntent.
-
- If you don't provide the `payment_method` parameter or the `source` parameter with `confirm=true`, `source` automatically populates with `customer.default_source` to improve migration for users of the Charges API. We recommend that you explicitly provide the `payment_method` moving forward.
- If the payment method is attached to a Customer, you must also provide the ID of that Customer as the [customer](https://stripe.com/docs/api#create_payment_intent-customer) parameter of this PaymentIntent.
- end
- """
- payment_method_configuration: NotRequired[str]
- """
- The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this PaymentIntent.
- """
- payment_method_data: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodData"
- ]
- """
- If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
- in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
- property on the PaymentIntent.
- """
- payment_method_options: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptions"
- ]
- """
- Payment method-specific configuration for this PaymentIntent.
- """
- payment_method_types: NotRequired[List[str]]
- """
- The list of payment method types (for example, a card) that this PaymentIntent can use. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
- """
- radar_options: NotRequired[
- "PaymentIntentService.CreateParamsRadarOptions"
- ]
- """
- Options to configure Radar. Learn more about [Radar Sessions](https://stripe.com/docs/radar/radar-session).
- """
- receipt_email: NotRequired[str]
- """
- Email address to send the receipt to. If you specify `receipt_email` for a payment in live mode, you send a receipt regardless of your [email settings](https://dashboard.stripe.com/account/emails).
- """
- return_url: NotRequired[str]
- """
- The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
- """
- setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- shipping: NotRequired["PaymentIntentService.CreateParamsShipping"]
- """
- Shipping information for this PaymentIntent.
- """
- statement_descriptor: NotRequired[str]
- """
- Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
-
- Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
- """
- statement_descriptor_suffix: NotRequired[str]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
- """
- transfer_data: NotRequired[
- "PaymentIntentService.CreateParamsTransferData"
- ]
- """
- The parameters that you can use to automatically create a Transfer.
- Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies the resulting payment as part of a group. Learn more about the [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers).
- """
- use_stripe_sdk: NotRequired[bool]
- """
- Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
- """
-
- class CreateParamsAutomaticPaymentMethods(TypedDict):
- allow_redirects: NotRequired[Literal["always", "never"]]
- """
- Controls whether this PaymentIntent will accept redirect-based payment methods.
-
- Redirect-based payment methods may require your customer to be redirected to a payment method's app or site for authentication or additional steps. To [confirm](https://stripe.com/docs/api/payment_intents/confirm) this PaymentIntent, you may be required to provide a `return_url` to redirect customers back to your site after they authenticate or complete the payment.
- """
- enabled: bool
- """
- Whether this feature is enabled.
- """
-
- class CreateParamsMandateData(TypedDict):
- customer_acceptance: (
- "PaymentIntentService.CreateParamsMandateDataCustomerAcceptance"
- )
- """
- This hash contains details about the customer acceptance of the Mandate.
- """
-
- class CreateParamsMandateDataCustomerAcceptance(TypedDict):
- accepted_at: NotRequired[int]
- """
- The time at which the customer accepted the Mandate.
- """
- offline: NotRequired[
- "PaymentIntentService.CreateParamsMandateDataCustomerAcceptanceOffline"
- ]
- """
- If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
- """
- online: NotRequired[
- "PaymentIntentService.CreateParamsMandateDataCustomerAcceptanceOnline"
- ]
- """
- If this is a Mandate accepted online, this hash contains details about the online acceptance.
- """
- type: Literal["offline", "online"]
- """
- The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
- """
-
- class CreateParamsMandateDataCustomerAcceptanceOffline(TypedDict):
- pass
-
- class CreateParamsMandateDataCustomerAcceptanceOnline(TypedDict):
- ip_address: str
- """
- The IP address from which the Mandate was accepted by the customer.
- """
- user_agent: str
- """
- The user agent of the browser from which the Mandate was accepted by the customer.
- """
-
- class CreateParamsPaymentMethodData(TypedDict):
- acss_debit: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataAcssDebit"
- ]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataAlipay"
- ]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataAlma"
- ]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataAmazonPay"
- ]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataAuBecsDebit"
- ]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataBlik"
- ]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- cashapp: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataCrypto"
- ]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer_balance: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataEps"
- ]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- fpx: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataFpx"
- ]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataIdeal"
- ]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataLink"
- ]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataMbWay"
- ]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataMobilepay"
- ]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataNzBankAccount"
- ]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataOxxo"
- ]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataP24"
- ]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataPayco"
- ]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- paynow: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataPix"
- ]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataRadarOptions"
- ]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataSwish"
- ]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataTwint"
- ]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataWechatPay"
- ]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataZip"
- ]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class CreateParamsPaymentMethodDataAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class CreateParamsPaymentMethodDataAffirm(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAfterpayClearpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAlipay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAlma(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAmazonPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class CreateParamsPaymentMethodDataBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class CreateParamsPaymentMethodDataBancontact(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBillie(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class CreateParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsPaymentMethodDataBlik(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class CreateParamsPaymentMethodDataCashapp(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataCrypto(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataCustomerBalance(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataGiropay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataGrabpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class CreateParamsPaymentMethodDataInteracPresent(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKakaoPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKlarna(TypedDict):
- dob: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodDataKlarnaDob"
- ]
- """
- Customer's date of birth
- """
-
- class CreateParamsPaymentMethodDataKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsPaymentMethodDataKonbini(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKrCard(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataLink(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMbWay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMobilepay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMultibanco(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class CreateParamsPaymentMethodDataNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class CreateParamsPaymentMethodDataOxxo(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataPayByBank(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPayco(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPaynow(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPaypal(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPix(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPromptpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class CreateParamsPaymentMethodDataRevolutPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSamsungPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSatispay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class CreateParamsPaymentMethodDataSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class CreateParamsPaymentMethodDataSwish(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataTwint(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class CreateParamsPaymentMethodDataWechatPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataZip(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsAcssDebit"
- ]
- """
- If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
- """
- affirm: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
- """
- afterpay_clearpay: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsAfterpayClearpay"
- ]
- """
- If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
- """
- alipay: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsAlipay"
- ]
- """
- If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
- """
- alma: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsAlma"
- ]
- """
- If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
- """
- amazon_pay: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsAmazonPay"
- ]
- """
- If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
- """
- au_becs_debit: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsAuBecsDebit"
- ]
- """
- If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
- """
- bacs_debit: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
- """
- bancontact: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
- """
- billie: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
- """
- blik: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsBlik"
- ]
- """
- If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
- """
- boleto: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
- """
- card: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsCard"
- ]
- """
- Configuration for any card payments attempted on this PaymentIntent.
- """
- card_present: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsCardPresent"
- ]
- """
- If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
- """
- cashapp: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
- """
- crypto: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsCrypto"
- ]
- """
- If this is a `crypto` PaymentMethod, this sub-hash contains details about the Crypto payment method options.
- """
- customer_balance: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsCustomerBalance"
- ]
- """
- If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
- """
- eps: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsEps"
- ]
- """
- If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
- """
- fpx: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsFpx"
- ]
- """
- If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
- """
- giropay: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
- """
- grabpay: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
- """
- ideal: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsIdeal"
- ]
- """
- If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
- """
- interac_present: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsInteracPresent"
- ]
- """
- If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
- """
- kakao_pay: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
- """
- klarna: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
- """
- konbini: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
- """
- kr_card: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
- """
- link: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsLink"
- ]
- """
- If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
- """
- mb_way: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsMbWay"
- ]
- """
- If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
- """
- mobilepay: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsMobilepay"
- ]
- """
- If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
- """
- multibanco: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
- """
- naver_pay: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
- """
- nz_bank_account: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsNzBankAccount"
- ]
- """
- If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
- """
- oxxo: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsOxxo"
- ]
- """
- If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
- """
- p24: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsP24"
- ]
- """
- If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
- """
- pay_by_bank: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
- """
- payco: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsPayco"
- ]
- """
- If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
- """
- paynow: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
- """
- paypal: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
- """
- pix: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsPix"
- ]
- """
- If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
- """
- promptpay: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
- """
- revolut_pay: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
- """
- samsung_pay: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
- """
- satispay: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
- """
- sepa_debit: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
- """
- sofort: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
- """
- swish: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsSwish"
- ]
- """
- If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
- """
- twint: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsTwint"
- ]
- """
- If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
- """
- us_bank_account: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
- """
- wechat_pay: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsWechatPay"
- ]
- """
- If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
- """
- zip: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsZip"
- ]
- """
- If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
- """
-
- class CreateParamsPaymentMethodOptionsAcssDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class CreateParamsPaymentMethodOptionsAcssDebitMandateOptions(TypedDict):
- custom_mandate_url: NotRequired["Literal['']|str"]
- """
- A URL for custom mandate text to render during confirmation step.
- The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
- or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
- """
- interval_description: NotRequired[str]
- """
- Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
- """
- payment_schedule: NotRequired[
- Literal["combined", "interval", "sporadic"]
- ]
- """
- Payment schedule for the mandate.
- """
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class CreateParamsPaymentMethodOptionsAffirm(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- preferred_locale: NotRequired[str]
- """
- Preferred language of the Affirm authorization page that the customer is redirected to.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsAfterpayClearpay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- reference: NotRequired[str]
- """
- An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
- This field differs from the statement descriptor and item name.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsAlipay(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsAlma(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class CreateParamsPaymentMethodOptionsAmazonPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsAuBecsDebit(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class CreateParamsPaymentMethodOptionsBacsDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsBacsDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class CreateParamsPaymentMethodOptionsBacsDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
- """
-
- class CreateParamsPaymentMethodOptionsBancontact(TypedDict):
- preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
- """
- Preferred language of the Bancontact authorization page that the customer is redirected to.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsBillie(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class CreateParamsPaymentMethodOptionsBlik(TypedDict):
- code: NotRequired[str]
- """
- The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
- """
- setup_future_usage: NotRequired["Literal['']|Literal['none']"]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsBoleto(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsCard(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- cvc_token: NotRequired[str]
- """
- A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
- """
- installments: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsCardInstallments"
- ]
- """
- Installment configuration for payments attempted on this PaymentIntent.
-
- For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
- """
- mandate_options: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- moto: NotRequired[bool]
- """
- When specified, this parameter indicates that a transaction will be marked
- as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
- parameter can only be provided during confirmation.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
- """
- request_extended_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
- """
- request_incremental_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
- """
- request_multicapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
- """
- request_overcapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
- require_cvc_recollection: NotRequired[bool]
- """
- When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- statement_descriptor_suffix_kana: NotRequired["Literal['']|str"]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that's set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
- """
- statement_descriptor_suffix_kanji: NotRequired["Literal['']|str"]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that's set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
- """
- three_d_secure: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsCardThreeDSecure"
- ]
- """
- If 3D Secure authentication was performed with a third-party provider,
- the authentication details to use for this payment.
- """
-
- class CreateParamsPaymentMethodOptionsCardInstallments(TypedDict):
- enabled: NotRequired[bool]
- """
- Setting to true enables installments for this PaymentIntent.
- This will cause the response to contain a list of available installment plans.
- Setting to false will prevent any selected plan from applying to a charge.
- """
- plan: NotRequired[
- "Literal['']|PaymentIntentService.CreateParamsPaymentMethodOptionsCardInstallmentsPlan"
- ]
- """
- The selected installment plan to use for this payment attempt.
- This parameter can only be provided during confirmation.
- """
-
- class CreateParamsPaymentMethodOptionsCardInstallmentsPlan(TypedDict):
- count: NotRequired[int]
- """
- For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
- """
- interval: NotRequired[Literal["month"]]
- """
- For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
- One of `month`.
- """
- type: Literal["bonus", "fixed_count", "revolving"]
- """
- Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
- """
-
- class CreateParamsPaymentMethodOptionsCardMandateOptions(TypedDict):
- amount: int
- """
- Amount to be charged for future payments.
- """
- amount_type: Literal["fixed", "maximum"]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
- end_date: NotRequired[int]
- """
- End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
- """
- interval: Literal["day", "month", "sporadic", "week", "year"]
- """
- Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
- """
- reference: str
- """
- Unique identifier for the mandate or subscription.
- """
- start_date: int
- """
- Start date of the mandate or subscription. Start date should not be lesser than yesterday.
- """
- supported_types: NotRequired[List[Literal["india"]]]
- """
- Specifies the type of mandates supported. Possible values are `india`.
- """
-
- class CreateParamsPaymentMethodOptionsCardPresent(TypedDict):
- request_extended_authorization: NotRequired[bool]
- """
- Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
- """
- request_incremental_authorization_support: NotRequired[bool]
- """
- Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
- """
- routing: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsCardPresentRouting"
- ]
- """
- Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
- """
-
- class CreateParamsPaymentMethodOptionsCardPresentRouting(TypedDict):
- requested_priority: NotRequired[Literal["domestic", "international"]]
- """
- Routing requested priority
- """
-
- class CreateParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
- ares_trans_status: NotRequired[
- Literal["A", "C", "I", "N", "R", "U", "Y"]
- ]
- """
- The `transStatus` returned from the card Issuer's ACS in the ARes.
- """
- cryptogram: str
- """
- The cryptogram, also known as the "authentication value" (AAV, CAVV or
- AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
- (Most 3D Secure providers will return the base64-encoded version, which
- is what you should specify here.)
- """
- electronic_commerce_indicator: NotRequired[
- Literal["01", "02", "05", "06", "07"]
- ]
- """
- The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
- provider and indicates what degree of authentication was performed.
- """
- exemption_indicator: NotRequired[Literal["low_risk", "none"]]
- """
- The exemption requested via 3DS and accepted by the issuer at authentication time.
- """
- network_options: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
- ]
- """
- Network specific 3DS fields. Network specific arguments require an
- explicit card brand choice. The parameter `payment_method_options.card.network``
- must be populated accordingly
- """
- requestor_challenge_indicator: NotRequired[str]
- """
- The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
- AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
- """
- transaction_id: str
- """
- For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
- Transaction ID (dsTransID).
- """
- version: Literal["1.0.2", "2.1.0", "2.2.0"]
- """
- The version of 3D Secure that was performed.
- """
-
- class CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
- TypedDict,
- ):
- cartes_bancaires: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
- ]
- """
- Cartes Bancaires-specific 3DS fields.
- """
-
- class CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
- TypedDict,
- ):
- cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
- """
- The cryptogram calculation algorithm used by the card Issuer's ACS
- to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
- messageExtension: CB-AVALGO
- """
- cb_exemption: NotRequired[str]
- """
- The exemption indicator returned from Cartes Bancaires in the ARes.
- message extension: CB-EXEMPTION; string (4 characters)
- This is a 3 byte bitmap (low significant byte first and most significant
- bit first) that has been Base64 encoded
- """
- cb_score: NotRequired[int]
- """
- The risk score returned from Cartes Bancaires in the ARes.
- message extension: CB-SCORE; numeric value 0-99
- """
-
- class CreateParamsPaymentMethodOptionsCashapp(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsCrypto(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsCustomerBalance(TypedDict):
- bank_transfer: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[Literal["bank_transfer"]]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for the eu_bank_transfer funding type.
- """
- requested_address_types: NotRequired[
- List[
- Literal[
- "aba",
- "iban",
- "sepa",
- "sort_code",
- "spei",
- "swift",
- "zengin",
- ]
- ]
- ]
- """
- List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
-
- Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
- """
- type: Literal[
- "eu_bank_transfer",
- "gb_bank_transfer",
- "jp_bank_transfer",
- "mx_bank_transfer",
- "us_bank_transfer",
- ]
- """
- The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
- """
-
- class CreateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class CreateParamsPaymentMethodOptionsEps(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsFpx(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsGiropay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsGrabpay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsIdeal(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsInteracPresent(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptionsKakaoPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsKlarna(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- on_demand: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsKlarnaOnDemand"
- ]
- """
- On-demand details if setting up or charging an on-demand payment.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-CH",
- "de-DE",
- "el-GR",
- "en-AT",
- "en-AU",
- "en-BE",
- "en-CA",
- "en-CH",
- "en-CZ",
- "en-DE",
- "en-DK",
- "en-ES",
- "en-FI",
- "en-FR",
- "en-GB",
- "en-GR",
- "en-IE",
- "en-IT",
- "en-NL",
- "en-NO",
- "en-NZ",
- "en-PL",
- "en-PT",
- "en-RO",
- "en-SE",
- "en-US",
- "es-ES",
- "es-US",
- "fi-FI",
- "fr-BE",
- "fr-CA",
- "fr-CH",
- "fr-FR",
- "it-CH",
- "it-IT",
- "nb-NO",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "ro-RO",
- "sv-FI",
- "sv-SE",
- ]
- ]
- """
- Preferred language of the Klarna authorization page that the customer is redirected to
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- subscriptions: NotRequired[
- "Literal['']|List[PaymentIntentService.CreateParamsPaymentMethodOptionsKlarnaSubscription]"
- ]
- """
- Subscription details if setting up or charging a subscription.
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
- average_amount: NotRequired[int]
- """
- Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- maximum_amount: NotRequired[int]
- """
- The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- minimum_amount: NotRequired[int]
- """
- The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
- """
- Interval at which the customer is making purchases
- """
- purchase_interval_count: NotRequired[int]
- """
- The number of `purchase_interval` between charges
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Unit of time between subscription charges.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
- """
- name: NotRequired[str]
- """
- Name for subscription.
- """
- next_billing: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
- ]
- """
- Describes the upcoming charge for this subscription.
- """
- reference: str
- """
- A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
- TypedDict,
- ):
- amount: int
- """
- The amount of the next charge for the subscription.
- """
- date: str
- """
- The date of the next charge for the subscription in YYYY-MM-DD format.
- """
-
- class CreateParamsPaymentMethodOptionsKonbini(TypedDict):
- confirmation_number: NotRequired["Literal['']|str"]
- """
- An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
- """
- expires_after_days: NotRequired["Literal['']|int"]
- """
- The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
- """
- expires_at: NotRequired["Literal['']|int"]
- """
- The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsKrCard(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsLink(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- persistent_token: NotRequired[str]
- """
- [Deprecated] This is a legacy parameter that no longer has any function.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsMbWay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsMobilepay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsMultibanco(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsNaverPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsNzBankAccount(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class CreateParamsPaymentMethodOptionsOxxo(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsP24(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- tos_shown_and_accepted: NotRequired[bool]
- """
- Confirm that the payer has accepted the P24 terms and conditions.
- """
-
- class CreateParamsPaymentMethodOptionsPayByBank(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptionsPayco(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class CreateParamsPaymentMethodOptionsPaynow(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsPaypal(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds will be captured from the customer's account.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-DE",
- "de-LU",
- "el-GR",
- "en-GB",
- "en-US",
- "es-ES",
- "fi-FI",
- "fr-BE",
- "fr-FR",
- "fr-LU",
- "hu-HU",
- "it-IT",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "sk-SK",
- "sv-SE",
- ]
- ]
- """
- [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
- """
- reference: NotRequired[str]
- """
- A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
- """
- risk_correlation_id: NotRequired[str]
- """
- The risk correlation ID for an on-session payment using a saved PayPal payment method.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsPix(TypedDict):
- amount_includes_iof: NotRequired[Literal["always", "never"]]
- """
- Determines if the amount includes the IOF tax. Defaults to `never`.
- """
- expires_after_seconds: NotRequired[int]
- """
- The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
- """
- expires_at: NotRequired[int]
- """
- The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsPromptpay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsRevolutPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsSamsungPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class CreateParamsPaymentMethodOptionsSatispay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class CreateParamsPaymentMethodOptionsSepaDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsSepaDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class CreateParamsPaymentMethodOptionsSepaDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
- """
-
- class CreateParamsPaymentMethodOptionsSofort(TypedDict):
- preferred_language: NotRequired[
- "Literal['']|Literal['de', 'en', 'es', 'fr', 'it', 'nl', 'pl']"
- ]
- """
- Language shown to the payer on redirect.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsSwish(TypedDict):
- reference: NotRequired["Literal['']|str"]
- """
- A reference for this payment to be displayed in the Swish app.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsTwint(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccount(TypedDict):
- financial_connections: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- mandate_options: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsUsBankAccountMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- networks: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsUsBankAccountNetworks"
- ]
- """
- Additional fields for network related functions
- """
- preferred_settlement_speed: NotRequired[
- "Literal['']|Literal['fastest', 'standard']"
- ]
- """
- Preferred transaction settlement speed
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "PaymentIntentService.CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
- return_url: NotRequired[str]
- """
- For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountMandateOptions(
- TypedDict,
- ):
- collection_method: NotRequired["Literal['']|Literal['paper']"]
- """
- The method used to collect offline mandate customer acceptance.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountNetworks(TypedDict):
- requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
- """
- Triggers validations to run across the selected networks
- """
-
- class CreateParamsPaymentMethodOptionsWechatPay(TypedDict):
- app_id: NotRequired[str]
- """
- The app ID registered with WeChat Pay. Only required when client is ios or android.
- """
- client: NotRequired[Literal["android", "ios", "web"]]
- """
- The client type that the end customer will pay from
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsZip(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class CreateParamsShipping(TypedDict):
- address: "PaymentIntentService.CreateParamsShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class CreateParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when a charge succeeds.
- The amount is capped at the total transaction amount and if no amount is set,
- the full amount is transferred.
-
- If you intend to collect a fee and you need a more robust reporting experience, using
- [application_fee_amount](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-application_fee_amount)
- might be a better fit for your integration.
- """
- destination: str
- """
- If specified, successful charges will be attributed to the destination
- account for tax reporting, and the funds from charges will be transferred
- to the destination account. The ID of the resulting transfer will be
- returned on the successful charge's `transfer` field.
- """
-
- class IncrementAuthorizationParams(TypedDict):
- amount: int
- """
- The updated total amount that you intend to collect from the cardholder. This amount must be greater than the currently authorized amount.
- """
- application_fee_amount: NotRequired[int]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- statement_descriptor: NotRequired[str]
- """
- Text that appears on the customer's statement as the statement descriptor for a non-card or card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
- """
- transfer_data: NotRequired[
- "PaymentIntentService.IncrementAuthorizationParamsTransferData"
- ]
- """
- The parameters used to automatically create a transfer after the payment is captured.
- Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
-
- class IncrementAuthorizationParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when a charge succeeds.
- """
-
- class ListParams(TypedDict):
- created: NotRequired["PaymentIntentService.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp or a dictionary with a number of different query options.
- """
- customer: NotRequired[str]
- """
- Only return PaymentIntents for the customer that this customer ID specifies.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- client_secret: NotRequired[str]
- """
- The client secret of the PaymentIntent. We require it if you use a publishable key to retrieve the source.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SearchParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- page: NotRequired[str]
- """
- A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
- """
- query: str
- """
- The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for payment intents](https://stripe.com/docs/search#query-fields-for-payment-intents).
- """
-
- class UpdateParams(TypedDict):
- amount: NotRequired[int]
- """
- Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
- """
- application_fee_amount: NotRequired["Literal['']|int"]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- capture_method: NotRequired[
- Literal["automatic", "automatic_async", "manual"]
- ]
- """
- Controls when the funds will be captured from the customer's account.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: NotRequired[str]
- """
- ID of the Customer this PaymentIntent belongs to, if one exists.
-
- Payment methods attached to other Customers cannot be used with this PaymentIntent.
-
- If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- excluded_payment_method_types: NotRequired[
- "Literal['']|List[Literal['acss_debit', 'affirm', 'afterpay_clearpay', 'alipay', 'alma', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'billie', 'blik', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'mb_way', 'mobilepay', 'multibanco', 'naver_pay', 'nz_bank_account', 'oxxo', 'p24', 'pay_by_bank', 'payco', 'paynow', 'paypal', 'pix', 'promptpay', 'revolut_pay', 'samsung_pay', 'satispay', 'sepa_debit', 'sofort', 'swish', 'twint', 'us_bank_account', 'wechat_pay', 'zip']]"
- ]
- """
- The list of payment method types to exclude from use with this payment.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- payment_method: NotRequired[str]
- """
- ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods/transitioning#compatibility) object) to attach to this PaymentIntent. To unset this field to null, pass in an empty string.
- """
- payment_method_configuration: NotRequired[str]
- """
- The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this PaymentIntent.
- """
- payment_method_data: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodData"
- ]
- """
- If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
- in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
- property on the PaymentIntent.
- """
- payment_method_options: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptions"
- ]
- """
- Payment-method-specific configuration for this PaymentIntent.
- """
- payment_method_types: NotRequired[List[str]]
- """
- The list of payment method types (for example, card) that this PaymentIntent can use. Use `automatic_payment_methods` to manage payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
- """
- receipt_email: NotRequired["Literal['']|str"]
- """
- Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- shipping: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsShipping"
- ]
- """
- Shipping information for this PaymentIntent.
- """
- statement_descriptor: NotRequired[str]
- """
- Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
-
- Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
- """
- statement_descriptor_suffix: NotRequired[str]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
- """
- transfer_data: NotRequired[
- "PaymentIntentService.UpdateParamsTransferData"
- ]
- """
- Use this parameter to automatically create a Transfer when the payment succeeds. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies the resulting payment as part of a group. You can only provide `transfer_group` if it hasn't been set. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
-
- class UpdateParamsPaymentMethodData(TypedDict):
- acss_debit: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataAcssDebit"
- ]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataAlipay"
- ]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataAlma"
- ]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataAmazonPay"
- ]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataAuBecsDebit"
- ]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataBlik"
- ]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- cashapp: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataCrypto"
- ]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer_balance: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataEps"
- ]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- fpx: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataFpx"
- ]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataIdeal"
- ]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataLink"
- ]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataMbWay"
- ]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataMobilepay"
- ]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataNzBankAccount"
- ]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataOxxo"
- ]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataP24"
- ]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataPayco"
- ]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- paynow: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataPix"
- ]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataRadarOptions"
- ]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataSwish"
- ]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataTwint"
- ]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataWechatPay"
- ]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataZip"
- ]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class UpdateParamsPaymentMethodDataAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class UpdateParamsPaymentMethodDataAffirm(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataAfterpayClearpay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataAlipay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataAlma(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataAmazonPay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class UpdateParamsPaymentMethodDataBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class UpdateParamsPaymentMethodDataBancontact(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataBillie(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class UpdateParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsPaymentMethodDataBlik(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class UpdateParamsPaymentMethodDataCashapp(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataCrypto(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataCustomerBalance(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class UpdateParamsPaymentMethodDataFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class UpdateParamsPaymentMethodDataGiropay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataGrabpay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class UpdateParamsPaymentMethodDataInteracPresent(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataKakaoPay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataKlarna(TypedDict):
- dob: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodDataKlarnaDob"
- ]
- """
- Customer's date of birth
- """
-
- class UpdateParamsPaymentMethodDataKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class UpdateParamsPaymentMethodDataKonbini(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataKrCard(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataLink(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataMbWay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataMobilepay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataMultibanco(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class UpdateParamsPaymentMethodDataNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class UpdateParamsPaymentMethodDataOxxo(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class UpdateParamsPaymentMethodDataPayByBank(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataPayco(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataPaynow(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataPaypal(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataPix(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataPromptpay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class UpdateParamsPaymentMethodDataRevolutPay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataSamsungPay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataSatispay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class UpdateParamsPaymentMethodDataSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class UpdateParamsPaymentMethodDataSwish(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataTwint(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class UpdateParamsPaymentMethodDataWechatPay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataZip(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsAcssDebit"
- ]
- """
- If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
- """
- affirm: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
- """
- afterpay_clearpay: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsAfterpayClearpay"
- ]
- """
- If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
- """
- alipay: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsAlipay"
- ]
- """
- If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
- """
- alma: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsAlma"
- ]
- """
- If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
- """
- amazon_pay: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsAmazonPay"
- ]
- """
- If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
- """
- au_becs_debit: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsAuBecsDebit"
- ]
- """
- If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
- """
- bacs_debit: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
- """
- bancontact: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
- """
- billie: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
- """
- blik: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsBlik"
- ]
- """
- If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
- """
- boleto: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
- """
- card: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsCard"
- ]
- """
- Configuration for any card payments attempted on this PaymentIntent.
- """
- card_present: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsCardPresent"
- ]
- """
- If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
- """
- cashapp: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
- """
- crypto: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsCrypto"
- ]
- """
- If this is a `crypto` PaymentMethod, this sub-hash contains details about the Crypto payment method options.
- """
- customer_balance: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsCustomerBalance"
- ]
- """
- If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
- """
- eps: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsEps"
- ]
- """
- If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
- """
- fpx: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsFpx"
- ]
- """
- If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
- """
- giropay: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
- """
- grabpay: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
- """
- ideal: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsIdeal"
- ]
- """
- If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
- """
- interac_present: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsInteracPresent"
- ]
- """
- If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
- """
- kakao_pay: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
- """
- klarna: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
- """
- konbini: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
- """
- kr_card: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
- """
- link: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsLink"
- ]
- """
- If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
- """
- mb_way: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsMbWay"
- ]
- """
- If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
- """
- mobilepay: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsMobilepay"
- ]
- """
- If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
- """
- multibanco: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
- """
- naver_pay: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
- """
- nz_bank_account: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsNzBankAccount"
- ]
- """
- If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
- """
- oxxo: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsOxxo"
- ]
- """
- If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
- """
- p24: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsP24"
- ]
- """
- If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
- """
- pay_by_bank: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
- """
- payco: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsPayco"
- ]
- """
- If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
- """
- paynow: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
- """
- paypal: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
- """
- pix: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsPix"
- ]
- """
- If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
- """
- promptpay: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
- """
- revolut_pay: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
- """
- samsung_pay: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
- """
- satispay: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
- """
- sepa_debit: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
- """
- sofort: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
- """
- swish: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsSwish"
- ]
- """
- If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
- """
- twint: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsTwint"
- ]
- """
- If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
- """
- us_bank_account: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
- """
- wechat_pay: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsWechatPay"
- ]
- """
- If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
- """
- zip: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsZip"
- ]
- """
- If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
- """
-
- class UpdateParamsPaymentMethodOptionsAcssDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class UpdateParamsPaymentMethodOptionsAcssDebitMandateOptions(TypedDict):
- custom_mandate_url: NotRequired["Literal['']|str"]
- """
- A URL for custom mandate text to render during confirmation step.
- The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
- or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
- """
- interval_description: NotRequired[str]
- """
- Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
- """
- payment_schedule: NotRequired[
- Literal["combined", "interval", "sporadic"]
- ]
- """
- Payment schedule for the mandate.
- """
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class UpdateParamsPaymentMethodOptionsAffirm(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- preferred_locale: NotRequired[str]
- """
- Preferred language of the Affirm authorization page that the customer is redirected to.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsAfterpayClearpay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- reference: NotRequired[str]
- """
- An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
- This field differs from the statement descriptor and item name.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsAlipay(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsAlma(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class UpdateParamsPaymentMethodOptionsAmazonPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class UpdateParamsPaymentMethodOptionsAuBecsDebit(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class UpdateParamsPaymentMethodOptionsBacsDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsBacsDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class UpdateParamsPaymentMethodOptionsBacsDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
- """
-
- class UpdateParamsPaymentMethodOptionsBancontact(TypedDict):
- preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
- """
- Preferred language of the Bancontact authorization page that the customer is redirected to.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsBillie(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class UpdateParamsPaymentMethodOptionsBlik(TypedDict):
- code: NotRequired[str]
- """
- The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
- """
- setup_future_usage: NotRequired["Literal['']|Literal['none']"]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsBoleto(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsCard(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- cvc_token: NotRequired[str]
- """
- A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
- """
- installments: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsCardInstallments"
- ]
- """
- Installment configuration for payments attempted on this PaymentIntent.
-
- For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
- """
- mandate_options: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- moto: NotRequired[bool]
- """
- When specified, this parameter indicates that a transaction will be marked
- as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
- parameter can only be provided during confirmation.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
- """
- request_extended_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
- """
- request_incremental_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
- """
- request_multicapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
- """
- request_overcapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
- require_cvc_recollection: NotRequired[bool]
- """
- When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- statement_descriptor_suffix_kana: NotRequired["Literal['']|str"]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that's set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
- """
- statement_descriptor_suffix_kanji: NotRequired["Literal['']|str"]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that's set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
- """
- three_d_secure: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsCardThreeDSecure"
- ]
- """
- If 3D Secure authentication was performed with a third-party provider,
- the authentication details to use for this payment.
- """
-
- class UpdateParamsPaymentMethodOptionsCardInstallments(TypedDict):
- enabled: NotRequired[bool]
- """
- Setting to true enables installments for this PaymentIntent.
- This will cause the response to contain a list of available installment plans.
- Setting to false will prevent any selected plan from applying to a charge.
- """
- plan: NotRequired[
- "Literal['']|PaymentIntentService.UpdateParamsPaymentMethodOptionsCardInstallmentsPlan"
- ]
- """
- The selected installment plan to use for this payment attempt.
- This parameter can only be provided during confirmation.
- """
-
- class UpdateParamsPaymentMethodOptionsCardInstallmentsPlan(TypedDict):
- count: NotRequired[int]
- """
- For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
- """
- interval: NotRequired[Literal["month"]]
- """
- For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
- One of `month`.
- """
- type: Literal["bonus", "fixed_count", "revolving"]
- """
- Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
- """
-
- class UpdateParamsPaymentMethodOptionsCardMandateOptions(TypedDict):
- amount: int
- """
- Amount to be charged for future payments.
- """
- amount_type: Literal["fixed", "maximum"]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
- end_date: NotRequired[int]
- """
- End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
- """
- interval: Literal["day", "month", "sporadic", "week", "year"]
- """
- Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
- """
- reference: str
- """
- Unique identifier for the mandate or subscription.
- """
- start_date: int
- """
- Start date of the mandate or subscription. Start date should not be lesser than yesterday.
- """
- supported_types: NotRequired[List[Literal["india"]]]
- """
- Specifies the type of mandates supported. Possible values are `india`.
- """
-
- class UpdateParamsPaymentMethodOptionsCardPresent(TypedDict):
- request_extended_authorization: NotRequired[bool]
- """
- Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
- """
- request_incremental_authorization_support: NotRequired[bool]
- """
- Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
- """
- routing: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsCardPresentRouting"
- ]
- """
- Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
- """
-
- class UpdateParamsPaymentMethodOptionsCardPresentRouting(TypedDict):
- requested_priority: NotRequired[Literal["domestic", "international"]]
- """
- Routing requested priority
- """
-
- class UpdateParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
- ares_trans_status: NotRequired[
- Literal["A", "C", "I", "N", "R", "U", "Y"]
- ]
- """
- The `transStatus` returned from the card Issuer's ACS in the ARes.
- """
- cryptogram: str
- """
- The cryptogram, also known as the "authentication value" (AAV, CAVV or
- AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
- (Most 3D Secure providers will return the base64-encoded version, which
- is what you should specify here.)
- """
- electronic_commerce_indicator: NotRequired[
- Literal["01", "02", "05", "06", "07"]
- ]
- """
- The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
- provider and indicates what degree of authentication was performed.
- """
- exemption_indicator: NotRequired[Literal["low_risk", "none"]]
- """
- The exemption requested via 3DS and accepted by the issuer at authentication time.
- """
- network_options: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
- ]
- """
- Network specific 3DS fields. Network specific arguments require an
- explicit card brand choice. The parameter `payment_method_options.card.network``
- must be populated accordingly
- """
- requestor_challenge_indicator: NotRequired[str]
- """
- The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
- AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
- """
- transaction_id: str
- """
- For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
- Transaction ID (dsTransID).
- """
- version: Literal["1.0.2", "2.1.0", "2.2.0"]
- """
- The version of 3D Secure that was performed.
- """
-
- class UpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
- TypedDict,
- ):
- cartes_bancaires: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
- ]
- """
- Cartes Bancaires-specific 3DS fields.
- """
-
- class UpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
- TypedDict,
- ):
- cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
- """
- The cryptogram calculation algorithm used by the card Issuer's ACS
- to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
- messageExtension: CB-AVALGO
- """
- cb_exemption: NotRequired[str]
- """
- The exemption indicator returned from Cartes Bancaires in the ARes.
- message extension: CB-EXEMPTION; string (4 characters)
- This is a 3 byte bitmap (low significant byte first and most significant
- bit first) that has been Base64 encoded
- """
- cb_score: NotRequired[int]
- """
- The risk score returned from Cartes Bancaires in the ARes.
- message extension: CB-SCORE; numeric value 0-99
- """
-
- class UpdateParamsPaymentMethodOptionsCashapp(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsCrypto(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsCustomerBalance(TypedDict):
- bank_transfer: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[Literal["bank_transfer"]]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for the eu_bank_transfer funding type.
- """
- requested_address_types: NotRequired[
- List[
- Literal[
- "aba",
- "iban",
- "sepa",
- "sort_code",
- "spei",
- "swift",
- "zengin",
- ]
- ]
- ]
- """
- List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
-
- Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
- """
- type: Literal[
- "eu_bank_transfer",
- "gb_bank_transfer",
- "jp_bank_transfer",
- "mx_bank_transfer",
- "us_bank_transfer",
- ]
- """
- The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
- """
-
- class UpdateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class UpdateParamsPaymentMethodOptionsEps(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsFpx(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsGiropay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsGrabpay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsIdeal(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsInteracPresent(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodOptionsKakaoPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class UpdateParamsPaymentMethodOptionsKlarna(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- on_demand: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsKlarnaOnDemand"
- ]
- """
- On-demand details if setting up or charging an on-demand payment.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-CH",
- "de-DE",
- "el-GR",
- "en-AT",
- "en-AU",
- "en-BE",
- "en-CA",
- "en-CH",
- "en-CZ",
- "en-DE",
- "en-DK",
- "en-ES",
- "en-FI",
- "en-FR",
- "en-GB",
- "en-GR",
- "en-IE",
- "en-IT",
- "en-NL",
- "en-NO",
- "en-NZ",
- "en-PL",
- "en-PT",
- "en-RO",
- "en-SE",
- "en-US",
- "es-ES",
- "es-US",
- "fi-FI",
- "fr-BE",
- "fr-CA",
- "fr-CH",
- "fr-FR",
- "it-CH",
- "it-IT",
- "nb-NO",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "ro-RO",
- "sv-FI",
- "sv-SE",
- ]
- ]
- """
- Preferred language of the Klarna authorization page that the customer is redirected to
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- subscriptions: NotRequired[
- "Literal['']|List[PaymentIntentService.UpdateParamsPaymentMethodOptionsKlarnaSubscription]"
- ]
- """
- Subscription details if setting up or charging a subscription.
- """
-
- class UpdateParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
- average_amount: NotRequired[int]
- """
- Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- maximum_amount: NotRequired[int]
- """
- The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- minimum_amount: NotRequired[int]
- """
- The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
- """
- Interval at which the customer is making purchases
- """
- purchase_interval_count: NotRequired[int]
- """
- The number of `purchase_interval` between charges
- """
-
- class UpdateParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Unit of time between subscription charges.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
- """
- name: NotRequired[str]
- """
- Name for subscription.
- """
- next_billing: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
- ]
- """
- Describes the upcoming charge for this subscription.
- """
- reference: str
- """
- A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
- """
-
- class UpdateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
- TypedDict,
- ):
- amount: int
- """
- The amount of the next charge for the subscription.
- """
- date: str
- """
- The date of the next charge for the subscription in YYYY-MM-DD format.
- """
-
- class UpdateParamsPaymentMethodOptionsKonbini(TypedDict):
- confirmation_number: NotRequired["Literal['']|str"]
- """
- An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
- """
- expires_after_days: NotRequired["Literal['']|int"]
- """
- The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
- """
- expires_at: NotRequired["Literal['']|int"]
- """
- The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsKrCard(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class UpdateParamsPaymentMethodOptionsLink(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- persistent_token: NotRequired[str]
- """
- [Deprecated] This is a legacy parameter that no longer has any function.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsMbWay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsMobilepay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsMultibanco(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsNaverPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class UpdateParamsPaymentMethodOptionsNzBankAccount(TypedDict):
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class UpdateParamsPaymentMethodOptionsOxxo(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsP24(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- tos_shown_and_accepted: NotRequired[bool]
- """
- Confirm that the payer has accepted the P24 terms and conditions.
- """
-
- class UpdateParamsPaymentMethodOptionsPayByBank(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodOptionsPayco(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class UpdateParamsPaymentMethodOptionsPaynow(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsPaypal(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds will be captured from the customer's account.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-DE",
- "de-LU",
- "el-GR",
- "en-GB",
- "en-US",
- "es-ES",
- "fi-FI",
- "fr-BE",
- "fr-FR",
- "fr-LU",
- "hu-HU",
- "it-IT",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "sk-SK",
- "sv-SE",
- ]
- ]
- """
- [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
- """
- reference: NotRequired[str]
- """
- A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
- """
- risk_correlation_id: NotRequired[str]
- """
- The risk correlation ID for an on-session payment using a saved PayPal payment method.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsPix(TypedDict):
- amount_includes_iof: NotRequired[Literal["always", "never"]]
- """
- Determines if the amount includes the IOF tax. Defaults to `never`.
- """
- expires_after_seconds: NotRequired[int]
- """
- The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
- """
- expires_at: NotRequired[int]
- """
- The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsPromptpay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsRevolutPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class UpdateParamsPaymentMethodOptionsSamsungPay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class UpdateParamsPaymentMethodOptionsSatispay(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds are captured from the customer's account.
-
- If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
-
- If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
- """
-
- class UpdateParamsPaymentMethodOptionsSepaDebit(TypedDict):
- mandate_options: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsSepaDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class UpdateParamsPaymentMethodOptionsSepaDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
- """
-
- class UpdateParamsPaymentMethodOptionsSofort(TypedDict):
- preferred_language: NotRequired[
- "Literal['']|Literal['de', 'en', 'es', 'fr', 'it', 'nl', 'pl']"
- ]
- """
- Language shown to the payer on redirect.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsSwish(TypedDict):
- reference: NotRequired["Literal['']|str"]
- """
- A reference for this payment to be displayed in the Swish app.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsTwint(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsUsBankAccount(TypedDict):
- financial_connections: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- mandate_options: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsUsBankAccountMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- networks: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsUsBankAccountNetworks"
- ]
- """
- Additional fields for network related functions
- """
- preferred_settlement_speed: NotRequired[
- "Literal['']|Literal['fastest', 'standard']"
- ]
- """
- Preferred transaction settlement speed
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session', 'on_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class UpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "PaymentIntentService.UpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
- return_url: NotRequired[str]
- """
- For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
- """
-
- class UpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class UpdateParamsPaymentMethodOptionsUsBankAccountMandateOptions(
- TypedDict,
- ):
- collection_method: NotRequired["Literal['']|Literal['paper']"]
- """
- The method used to collect offline mandate customer acceptance.
- """
-
- class UpdateParamsPaymentMethodOptionsUsBankAccountNetworks(TypedDict):
- requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
- """
- Triggers validations to run across the selected networks
- """
-
- class UpdateParamsPaymentMethodOptionsWechatPay(TypedDict):
- app_id: NotRequired[str]
- """
- The app ID registered with WeChat Pay. Only required when client is ios or android.
- """
- client: NotRequired[Literal["android", "ios", "web"]]
- """
- The client type that the end customer will pay from
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsPaymentMethodOptionsZip(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class UpdateParamsShipping(TypedDict):
- address: "PaymentIntentService.UpdateParamsShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class UpdateParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when a charge succeeds.
- """
-
- class VerifyMicrodepositsParams(TypedDict):
- amounts: NotRequired[List[int]]
- """
- Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.
- """
- descriptor_code: NotRequired[str]
- """
- A six-character code starting with SM present in the microdeposit sent to the bank account.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
def list(
self,
- params: Optional["PaymentIntentService.ListParams"] = None,
+ params: Optional["PaymentIntentListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PaymentIntent]:
"""
@@ -8768,7 +67,7 @@ def list(
async def list_async(
self,
- params: Optional["PaymentIntentService.ListParams"] = None,
+ params: Optional["PaymentIntentListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PaymentIntent]:
"""
@@ -8787,7 +86,7 @@ async def list_async(
def create(
self,
- params: "PaymentIntentService.CreateParams",
+ params: "PaymentIntentCreateParams",
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -8815,7 +114,7 @@ def create(
async def create_async(
self,
- params: "PaymentIntentService.CreateParams",
+ params: "PaymentIntentCreateParams",
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -8844,7 +143,7 @@ async def create_async(
def retrieve(
self,
intent: str,
- params: Optional["PaymentIntentService.RetrieveParams"] = None,
+ params: Optional["PaymentIntentRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -8870,7 +169,7 @@ def retrieve(
async def retrieve_async(
self,
intent: str,
- params: Optional["PaymentIntentService.RetrieveParams"] = None,
+ params: Optional["PaymentIntentRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -8896,7 +195,7 @@ async def retrieve_async(
def update(
self,
intent: str,
- params: Optional["PaymentIntentService.UpdateParams"] = None,
+ params: Optional["PaymentIntentUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -8924,7 +223,7 @@ def update(
async def update_async(
self,
intent: str,
- params: Optional["PaymentIntentService.UpdateParams"] = None,
+ params: Optional["PaymentIntentUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -8951,7 +250,7 @@ async def update_async(
def search(
self,
- params: "PaymentIntentService.SearchParams",
+ params: "PaymentIntentSearchParams",
options: Optional[RequestOptions] = None,
) -> SearchResultObject[PaymentIntent]:
"""
@@ -8973,7 +272,7 @@ def search(
async def search_async(
self,
- params: "PaymentIntentService.SearchParams",
+ params: "PaymentIntentSearchParams",
options: Optional[RequestOptions] = None,
) -> SearchResultObject[PaymentIntent]:
"""
@@ -8996,9 +295,7 @@ async def search_async(
def apply_customer_balance(
self,
intent: str,
- params: Optional[
- "PaymentIntentService.ApplyCustomerBalanceParams"
- ] = None,
+ params: Optional["PaymentIntentApplyCustomerBalanceParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -9020,9 +317,7 @@ def apply_customer_balance(
async def apply_customer_balance_async(
self,
intent: str,
- params: Optional[
- "PaymentIntentService.ApplyCustomerBalanceParams"
- ] = None,
+ params: Optional["PaymentIntentApplyCustomerBalanceParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -9044,7 +339,7 @@ async def apply_customer_balance_async(
def cancel(
self,
intent: str,
- params: Optional["PaymentIntentService.CancelParams"] = None,
+ params: Optional["PaymentIntentCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -9070,7 +365,7 @@ def cancel(
async def cancel_async(
self,
intent: str,
- params: Optional["PaymentIntentService.CancelParams"] = None,
+ params: Optional["PaymentIntentCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -9096,7 +391,7 @@ async def cancel_async(
def capture(
self,
intent: str,
- params: Optional["PaymentIntentService.CaptureParams"] = None,
+ params: Optional["PaymentIntentCaptureParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -9122,7 +417,7 @@ def capture(
async def capture_async(
self,
intent: str,
- params: Optional["PaymentIntentService.CaptureParams"] = None,
+ params: Optional["PaymentIntentCaptureParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -9148,7 +443,7 @@ async def capture_async(
def confirm(
self,
intent: str,
- params: Optional["PaymentIntentService.ConfirmParams"] = None,
+ params: Optional["PaymentIntentConfirmParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -9199,7 +494,7 @@ def confirm(
async def confirm_async(
self,
intent: str,
- params: Optional["PaymentIntentService.ConfirmParams"] = None,
+ params: Optional["PaymentIntentConfirmParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -9250,7 +545,7 @@ async def confirm_async(
def increment_authorization(
self,
intent: str,
- params: "PaymentIntentService.IncrementAuthorizationParams",
+ params: "PaymentIntentIncrementAuthorizationParams",
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -9295,7 +590,7 @@ def increment_authorization(
async def increment_authorization_async(
self,
intent: str,
- params: "PaymentIntentService.IncrementAuthorizationParams",
+ params: "PaymentIntentIncrementAuthorizationParams",
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -9340,9 +635,7 @@ async def increment_authorization_async(
def verify_microdeposits(
self,
intent: str,
- params: Optional[
- "PaymentIntentService.VerifyMicrodepositsParams"
- ] = None,
+ params: Optional["PaymentIntentVerifyMicrodepositsParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
@@ -9364,9 +657,7 @@ def verify_microdeposits(
async def verify_microdeposits_async(
self,
intent: str,
- params: Optional[
- "PaymentIntentService.VerifyMicrodepositsParams"
- ] = None,
+ params: Optional["PaymentIntentVerifyMicrodepositsParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentIntent:
"""
diff --git a/stripe/_payment_link.py b/stripe/_payment_link.py
index d91bf87b6..a99b47cf1 100644
--- a/stripe/_payment_link.py
+++ b/stripe/_payment_link.py
@@ -4,18 +4,11 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account
@@ -23,6 +16,19 @@
from stripe._line_item import LineItem
from stripe._shipping_rate import ShippingRate
from stripe._tax_id import TaxId
+ from stripe.params._payment_link_create_params import (
+ PaymentLinkCreateParams,
+ )
+ from stripe.params._payment_link_list_line_items_params import (
+ PaymentLinkListLineItemsParams,
+ )
+ from stripe.params._payment_link_list_params import PaymentLinkListParams
+ from stripe.params._payment_link_modify_params import (
+ PaymentLinkModifyParams,
+ )
+ from stripe.params._payment_link_retrieve_params import (
+ PaymentLinkRetrieveParams,
+ )
class PaymentLink(
@@ -715,1851 +721,6 @@ class TransferData(StripeObject):
The connected account receiving the transfer.
"""
- class CreateParams(RequestOptions):
- after_completion: NotRequired[
- "PaymentLink.CreateParamsAfterCompletion"
- ]
- """
- Behavior after the purchase is complete.
- """
- allow_promotion_codes: NotRequired[bool]
- """
- Enables user redeemable promotion codes.
- """
- application_fee_amount: NotRequired[int]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. Can only be applied when there are no line items with recurring prices.
- """
- application_fee_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
- """
- automatic_tax: NotRequired["PaymentLink.CreateParamsAutomaticTax"]
- """
- Configuration for automatic tax collection.
- """
- billing_address_collection: NotRequired[Literal["auto", "required"]]
- """
- Configuration for collecting the customer's billing address. Defaults to `auto`.
- """
- consent_collection: NotRequired[
- "PaymentLink.CreateParamsConsentCollection"
- ]
- """
- Configure fields to gather active consent from customers.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies) and supported by each line item's price.
- """
- custom_fields: NotRequired[List["PaymentLink.CreateParamsCustomField"]]
- """
- Collect additional information from your customer using custom fields. Up to 3 fields are supported.
- """
- custom_text: NotRequired["PaymentLink.CreateParamsCustomText"]
- """
- Display additional text for your customers using custom text.
- """
- customer_creation: NotRequired[Literal["always", "if_required"]]
- """
- Configures whether [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link create a [Customer](https://stripe.com/docs/api/customers).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- inactive_message: NotRequired[str]
- """
- The custom message to be displayed to a customer when a payment link is no longer active.
- """
- invoice_creation: NotRequired[
- "PaymentLink.CreateParamsInvoiceCreation"
- ]
- """
- Generate a post-purchase Invoice for one-time payments.
- """
- line_items: List["PaymentLink.CreateParamsLineItem"]
- """
- The line items representing what is being sold. Each line item represents an item being sold. Up to 20 line items are supported.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. Metadata associated with this Payment Link will automatically be copied to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
- """
- on_behalf_of: NotRequired[str]
- """
- The account on behalf of which to charge.
- """
- optional_items: NotRequired[
- List["PaymentLink.CreateParamsOptionalItem"]
- ]
- """
- A list of optional items the customer can add to their order at checkout. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices).
- There is a maximum of 10 optional items allowed on a payment link, and the existing limits on the number of line items allowed on a payment link apply to the combined number of line items and optional items.
- There is a maximum of 20 combined line items and optional items.
- """
- payment_intent_data: NotRequired[
- "PaymentLink.CreateParamsPaymentIntentData"
- ]
- """
- A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
- """
- payment_method_collection: NotRequired[
- Literal["always", "if_required"]
- ]
- """
- Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.This may occur if the Checkout Session includes a free trial or a discount.
-
- Can only be set in `subscription` mode. Defaults to `always`.
-
- 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[
- List[
- Literal[
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "card",
- "cashapp",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "klarna",
- "konbini",
- "link",
- "mobilepay",
- "multibanco",
- "oxxo",
- "p24",
- "pay_by_bank",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- ]
- ]
- """
- The list of payment method types that customers can use. If no value is passed, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods) (20+ payment methods [supported](https://stripe.com/docs/payments/payment-methods/integration-options#payment-method-product-support)).
- """
- phone_number_collection: NotRequired[
- "PaymentLink.CreateParamsPhoneNumberCollection"
- ]
- """
- Controls phone number collection settings during checkout.
-
- We recommend that you review your privacy policy and check with your legal contacts.
- """
- restrictions: NotRequired["PaymentLink.CreateParamsRestrictions"]
- """
- Settings that restrict the usage of a payment link.
- """
- shipping_address_collection: NotRequired[
- "PaymentLink.CreateParamsShippingAddressCollection"
- ]
- """
- Configuration for collecting the customer's shipping address.
- """
- shipping_options: NotRequired[
- List["PaymentLink.CreateParamsShippingOption"]
- ]
- """
- The shipping rate options to apply to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
- """
- submit_type: NotRequired[
- Literal["auto", "book", "donate", "pay", "subscribe"]
- ]
- """
- Describes the type of transaction being performed in order to customize relevant text on the page, such as the submit button. Changing this value will also affect the hostname in the [url](https://stripe.com/docs/api/payment_links/payment_links/object#url) property (example: `donate.stripe.com`).
- """
- subscription_data: NotRequired[
- "PaymentLink.CreateParamsSubscriptionData"
- ]
- """
- 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.CreateParamsTaxIdCollection"
- ]
- """
- Controls tax ID collection during checkout.
- """
- transfer_data: NotRequired["PaymentLink.CreateParamsTransferData"]
- """
- The account (if any) the payments will be attributed to for tax reporting, and where funds from each payment will be transferred to.
- """
-
- class CreateParamsAfterCompletion(TypedDict):
- hosted_confirmation: NotRequired[
- "PaymentLink.CreateParamsAfterCompletionHostedConfirmation"
- ]
- """
- Configuration when `type=hosted_confirmation`.
- """
- redirect: NotRequired[
- "PaymentLink.CreateParamsAfterCompletionRedirect"
- ]
- """
- Configuration when `type=redirect`.
- """
- type: Literal["hosted_confirmation", "redirect"]
- """
- The specified behavior after the purchase is complete. Either `redirect` or `hosted_confirmation`.
- """
-
- class CreateParamsAfterCompletionHostedConfirmation(TypedDict):
- custom_message: NotRequired[str]
- """
- A custom message to display to the customer after the purchase is complete.
- """
-
- class CreateParamsAfterCompletionRedirect(TypedDict):
- url: str
- """
- The URL the customer will be redirected to after the purchase is complete. You can embed `{CHECKOUT_SESSION_ID}` into the URL to have the `id` of the completed [checkout session](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-id) included.
- """
-
- class CreateParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
-
- Enabling this parameter causes the payment link to collect any billing address information necessary for tax calculation.
- """
- liability: NotRequired["PaymentLink.CreateParamsAutomaticTaxLiability"]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreateParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsConsentCollection(TypedDict):
- payment_method_reuse_agreement: NotRequired[
- "PaymentLink.CreateParamsConsentCollectionPaymentMethodReuseAgreement"
- ]
- """
- Determines the display of payment method reuse agreement text in the UI. If set to `hidden`, it will hide legal text related to the reuse of a payment method.
- """
- promotions: NotRequired[Literal["auto", "none"]]
- """
- If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
- Session will determine whether to display an option to opt into promotional communication
- from the merchant depending on the customer's locale. Only available to US merchants.
- """
- terms_of_service: NotRequired[Literal["none", "required"]]
- """
- If set to `required`, it requires customers to check a terms of service checkbox before being able to pay.
- There must be a valid terms of service URL set in your [Dashboard settings](https://dashboard.stripe.com/settings/public).
- """
-
- class CreateParamsConsentCollectionPaymentMethodReuseAgreement(TypedDict):
- position: Literal["auto", "hidden"]
- """
- Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's
- defaults will be used. When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
- """
-
- class CreateParamsCustomField(TypedDict):
- dropdown: NotRequired["PaymentLink.CreateParamsCustomFieldDropdown"]
- """
- Configuration for `type=dropdown` fields.
- """
- key: str
- """
- String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
- """
- label: "PaymentLink.CreateParamsCustomFieldLabel"
- """
- The label for the field, displayed to the customer.
- """
- numeric: NotRequired["PaymentLink.CreateParamsCustomFieldNumeric"]
- """
- Configuration for `type=numeric` fields.
- """
- optional: NotRequired[bool]
- """
- Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
- """
- text: NotRequired["PaymentLink.CreateParamsCustomFieldText"]
- """
- Configuration for `type=text` fields.
- """
- type: Literal["dropdown", "numeric", "text"]
- """
- The type of the field.
- """
-
- class CreateParamsCustomFieldDropdown(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
- """
- options: List["PaymentLink.CreateParamsCustomFieldDropdownOption"]
- """
- The options available for the customer to select. Up to 200 options allowed.
- """
-
- class CreateParamsCustomFieldDropdownOption(TypedDict):
- label: str
- """
- The label for the option, displayed to the customer. Up to 100 characters.
- """
- value: str
- """
- The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
- """
-
- class CreateParamsCustomFieldLabel(TypedDict):
- custom: str
- """
- Custom text for the label, displayed to the customer. Up to 50 characters.
- """
- type: Literal["custom"]
- """
- The type of the label.
- """
-
- class CreateParamsCustomFieldNumeric(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.
- """
- maximum_length: NotRequired[int]
- """
- The maximum character length constraint for the customer's input.
- """
- minimum_length: NotRequired[int]
- """
- The minimum character length requirement for the customer's input.
- """
-
- class CreateParamsCustomFieldText(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.
- """
- maximum_length: NotRequired[int]
- """
- The maximum character length constraint for the customer's input.
- """
- minimum_length: NotRequired[int]
- """
- The minimum character length requirement for the customer's input.
- """
-
- class CreateParamsCustomText(TypedDict):
- after_submit: NotRequired[
- "Literal['']|PaymentLink.CreateParamsCustomTextAfterSubmit"
- ]
- """
- Custom text that should be displayed after the payment confirmation button.
- """
- shipping_address: NotRequired[
- "Literal['']|PaymentLink.CreateParamsCustomTextShippingAddress"
- ]
- """
- Custom text that should be displayed alongside shipping address collection.
- """
- submit: NotRequired[
- "Literal['']|PaymentLink.CreateParamsCustomTextSubmit"
- ]
- """
- Custom text that should be displayed alongside the payment confirmation button.
- """
- terms_of_service_acceptance: NotRequired[
- "Literal['']|PaymentLink.CreateParamsCustomTextTermsOfServiceAcceptance"
- ]
- """
- Custom text that should be displayed in place of the default terms of service agreement text.
- """
-
- class CreateParamsCustomTextAfterSubmit(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsCustomTextShippingAddress(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsCustomTextSubmit(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsCustomTextTermsOfServiceAcceptance(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsInvoiceCreation(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled
- """
- invoice_data: NotRequired[
- "PaymentLink.CreateParamsInvoiceCreationInvoiceData"
- ]
- """
- Invoice PDF configuration.
- """
-
- class CreateParamsInvoiceCreationInvoiceData(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the invoice.
- """
- custom_fields: NotRequired[
- "Literal['']|List[PaymentLink.CreateParamsInvoiceCreationInvoiceDataCustomField]"
- ]
- """
- Default custom fields to be displayed on invoices for this customer.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- footer: NotRequired[str]
- """
- Default footer to be displayed on invoices for this customer.
- """
- issuer: NotRequired[
- "PaymentLink.CreateParamsInvoiceCreationInvoiceDataIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- rendering_options: NotRequired[
- "Literal['']|PaymentLink.CreateParamsInvoiceCreationInvoiceDataRenderingOptions"
- ]
- """
- Default options for invoice PDF rendering for this customer.
- """
-
- class CreateParamsInvoiceCreationInvoiceDataCustomField(TypedDict):
- name: str
- """
- The name of the custom field. This may be up to 40 characters.
- """
- value: str
- """
- The value of the custom field. This may be up to 140 characters.
- """
-
- class CreateParamsInvoiceCreationInvoiceDataIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsInvoiceCreationInvoiceDataRenderingOptions(TypedDict):
- amount_tax_display: NotRequired[
- "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
- ]
- """
- How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
- """
- template: NotRequired[str]
- """
- ID of the invoice rendering template to use for this invoice.
- """
-
- class CreateParamsLineItem(TypedDict):
- adjustable_quantity: NotRequired[
- "PaymentLink.CreateParamsLineItemAdjustableQuantity"
- ]
- """
- When set, provides configuration for this item's quantity to be adjusted by the customer during checkout.
- """
- price: NotRequired[str]
- """
- The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired["PaymentLink.CreateParamsLineItemPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: int
- """
- The quantity of the line item being purchased.
- """
-
- class CreateParamsLineItemAdjustableQuantity(TypedDict):
- enabled: bool
- """
- Set to true if the quantity can be adjusted to any non-negative Integer.
- """
- maximum: NotRequired[int]
- """
- The maximum quantity the customer can purchase. By default this value is 99. You can specify a value up to 999999.
- """
- minimum: NotRequired[int]
- """
- The minimum quantity the customer can purchase. By default this value is 0. If there is only one item in the cart then that item's quantity cannot go down to 0.
- """
-
- class CreateParamsLineItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: NotRequired[str]
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
- """
- product_data: NotRequired[
- "PaymentLink.CreateParamsLineItemPriceDataProductData"
- ]
- """
- Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
- """
- recurring: NotRequired[
- "PaymentLink.CreateParamsLineItemPriceDataRecurring"
- ]
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsLineItemPriceDataProductData(TypedDict):
- description: NotRequired[str]
- """
- The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
- """
- images: NotRequired[List[str]]
- """
- A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The product's name, meant to be displayable to the customer.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- unit_label: NotRequired[str]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
- """
-
- class CreateParamsLineItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class CreateParamsOptionalItem(TypedDict):
- adjustable_quantity: NotRequired[
- "PaymentLink.CreateParamsOptionalItemAdjustableQuantity"
- ]
- """
- When set, provides configuration for the customer to adjust the quantity of the line item created when a customer chooses to add this optional item to their order.
- """
- price: str
- """
- The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object.
- """
- quantity: int
- """
- The initial quantity of the line item created when a customer chooses to add this optional item to their order.
- """
-
- class CreateParamsOptionalItemAdjustableQuantity(TypedDict):
- enabled: bool
- """
- Set to true if the quantity can be adjusted to any non-negative integer.
- """
- maximum: NotRequired[int]
- """
- The maximum quantity of this item the customer can purchase. By default this value is 99.
- """
- minimum: NotRequired[int]
- """
- The minimum quantity of this item the customer must purchase, if they choose to purchase it. Because this item is optional, the customer will always be able to remove it from their order, even if the `minimum` configured here is greater than 0. By default this value is 0.
- """
-
- class CreateParamsPaymentIntentData(TypedDict):
- capture_method: NotRequired[
- Literal["automatic", "automatic_async", "manual"]
- ]
- """
- Controls when the funds will be captured from the customer's account.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Payment Intents](https://stripe.com/docs/api/payment_intents) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
- """
- setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
- """
- Indicates that you intend to [make future payments](https://stripe.com/docs/payments/payment-intents#future-usage) with the payment method collected by this Checkout Session.
-
- When setting this to `on_session`, Checkout will show a notice to the customer that their payment details will be saved.
-
- When setting this to `off_session`, Checkout will show a notice to the customer that their payment details will be saved and used for future payments.
-
- If a Customer has been provided or Checkout creates a new Customer,Checkout will attach the payment method to the Customer.
-
- If Checkout does not create a Customer, the payment method is not attached to a Customer. To reuse the payment method, you can retrieve it from the Checkout Session's PaymentIntent.
-
- When processing card payments, Checkout also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as SCA.
- """
- statement_descriptor: NotRequired[str]
- """
- Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
-
- Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
- """
- statement_descriptor_suffix: NotRequired[str]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
- """
-
- class CreateParamsPhoneNumberCollection(TypedDict):
- enabled: bool
- """
- Set to `true` to enable phone number collection.
- """
-
- class CreateParamsRestrictions(TypedDict):
- completed_sessions: (
- "PaymentLink.CreateParamsRestrictionsCompletedSessions"
- )
- """
- Configuration for the `completed_sessions` restriction type.
- """
-
- class CreateParamsRestrictionsCompletedSessions(TypedDict):
- limit: int
- """
- The maximum number of checkout sessions that can be completed for the `completed_sessions` restriction to be met.
- """
-
- class CreateParamsShippingAddressCollection(TypedDict):
- allowed_countries: List[
- Literal[
- "AC",
- "AD",
- "AE",
- "AF",
- "AG",
- "AI",
- "AL",
- "AM",
- "AO",
- "AQ",
- "AR",
- "AT",
- "AU",
- "AW",
- "AX",
- "AZ",
- "BA",
- "BB",
- "BD",
- "BE",
- "BF",
- "BG",
- "BH",
- "BI",
- "BJ",
- "BL",
- "BM",
- "BN",
- "BO",
- "BQ",
- "BR",
- "BS",
- "BT",
- "BV",
- "BW",
- "BY",
- "BZ",
- "CA",
- "CD",
- "CF",
- "CG",
- "CH",
- "CI",
- "CK",
- "CL",
- "CM",
- "CN",
- "CO",
- "CR",
- "CV",
- "CW",
- "CY",
- "CZ",
- "DE",
- "DJ",
- "DK",
- "DM",
- "DO",
- "DZ",
- "EC",
- "EE",
- "EG",
- "EH",
- "ER",
- "ES",
- "ET",
- "FI",
- "FJ",
- "FK",
- "FO",
- "FR",
- "GA",
- "GB",
- "GD",
- "GE",
- "GF",
- "GG",
- "GH",
- "GI",
- "GL",
- "GM",
- "GN",
- "GP",
- "GQ",
- "GR",
- "GS",
- "GT",
- "GU",
- "GW",
- "GY",
- "HK",
- "HN",
- "HR",
- "HT",
- "HU",
- "ID",
- "IE",
- "IL",
- "IM",
- "IN",
- "IO",
- "IQ",
- "IS",
- "IT",
- "JE",
- "JM",
- "JO",
- "JP",
- "KE",
- "KG",
- "KH",
- "KI",
- "KM",
- "KN",
- "KR",
- "KW",
- "KY",
- "KZ",
- "LA",
- "LB",
- "LC",
- "LI",
- "LK",
- "LR",
- "LS",
- "LT",
- "LU",
- "LV",
- "LY",
- "MA",
- "MC",
- "MD",
- "ME",
- "MF",
- "MG",
- "MK",
- "ML",
- "MM",
- "MN",
- "MO",
- "MQ",
- "MR",
- "MS",
- "MT",
- "MU",
- "MV",
- "MW",
- "MX",
- "MY",
- "MZ",
- "NA",
- "NC",
- "NE",
- "NG",
- "NI",
- "NL",
- "NO",
- "NP",
- "NR",
- "NU",
- "NZ",
- "OM",
- "PA",
- "PE",
- "PF",
- "PG",
- "PH",
- "PK",
- "PL",
- "PM",
- "PN",
- "PR",
- "PS",
- "PT",
- "PY",
- "QA",
- "RE",
- "RO",
- "RS",
- "RU",
- "RW",
- "SA",
- "SB",
- "SC",
- "SD",
- "SE",
- "SG",
- "SH",
- "SI",
- "SJ",
- "SK",
- "SL",
- "SM",
- "SN",
- "SO",
- "SR",
- "SS",
- "ST",
- "SV",
- "SX",
- "SZ",
- "TA",
- "TC",
- "TD",
- "TF",
- "TG",
- "TH",
- "TJ",
- "TK",
- "TL",
- "TM",
- "TN",
- "TO",
- "TR",
- "TT",
- "TV",
- "TW",
- "TZ",
- "UA",
- "UG",
- "US",
- "UY",
- "UZ",
- "VA",
- "VC",
- "VE",
- "VG",
- "VN",
- "VU",
- "WF",
- "WS",
- "XK",
- "YE",
- "YT",
- "ZA",
- "ZM",
- "ZW",
- "ZZ",
- ]
- ]
- """
- An array of two-letter ISO country codes representing which countries Checkout should provide as options for
- shipping locations.
- """
-
- class CreateParamsShippingOption(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the Shipping Rate to use for this shipping option.
- """
-
- class CreateParamsSubscriptionData(TypedDict):
- description: NotRequired[str]
- """
- The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- invoice_settings: NotRequired[
- "PaymentLink.CreateParamsSubscriptionDataInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Subscriptions](https://stripe.com/docs/api/subscriptions) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
- """
- trial_period_days: NotRequired[int]
- """
- Integer representing the number of trial period days before the customer is charged for the first time. Has to be at least 1.
- """
- trial_settings: NotRequired[
- "PaymentLink.CreateParamsSubscriptionDataTrialSettings"
- ]
- """
- Settings related to subscription trials.
- """
-
- class CreateParamsSubscriptionDataInvoiceSettings(TypedDict):
- issuer: NotRequired[
- "PaymentLink.CreateParamsSubscriptionDataInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class CreateParamsSubscriptionDataInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsSubscriptionDataTrialSettings(TypedDict):
- end_behavior: (
- "PaymentLink.CreateParamsSubscriptionDataTrialSettingsEndBehavior"
- )
- """
- Defines how the subscription should behave when the user's free trial ends.
- """
-
- class CreateParamsSubscriptionDataTrialSettingsEndBehavior(TypedDict):
- missing_payment_method: Literal["cancel", "create_invoice", "pause"]
- """
- Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
- """
-
- class CreateParamsTaxIdCollection(TypedDict):
- enabled: bool
- """
- Enable tax ID collection during checkout. Defaults to `false`.
- """
- required: NotRequired[Literal["if_supported", "never"]]
- """
- Describes whether a tax ID is required during checkout. Defaults to `never`.
- """
-
- class CreateParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when a charge succeeds.
- """
- destination: str
- """
- If specified, successful charges will be attributed to the destination
- account for tax reporting, and the funds from charges will be transferred
- to the destination account. The ID of the resulting transfer will be
- returned on the successful charge's `transfer` field.
- """
-
- class ListLineItemsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParams(RequestOptions):
- active: NotRequired[bool]
- """
- Only return payment links that are active or inactive (e.g., pass `false` to list all inactive payment links).
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ModifyParams(RequestOptions):
- active: NotRequired[bool]
- """
- Whether the payment link's `url` is active. If `false`, customers visiting the URL will be shown a page saying that the link has been deactivated.
- """
- after_completion: NotRequired[
- "PaymentLink.ModifyParamsAfterCompletion"
- ]
- """
- Behavior after the purchase is complete.
- """
- allow_promotion_codes: NotRequired[bool]
- """
- Enables user redeemable promotion codes.
- """
- automatic_tax: NotRequired["PaymentLink.ModifyParamsAutomaticTax"]
- """
- Configuration for automatic tax collection.
- """
- billing_address_collection: NotRequired[Literal["auto", "required"]]
- """
- Configuration for collecting the customer's billing address. Defaults to `auto`.
- """
- custom_fields: NotRequired[
- "Literal['']|List[PaymentLink.ModifyParamsCustomField]"
- ]
- """
- Collect additional information from your customer using custom fields. Up to 3 fields are supported.
- """
- custom_text: NotRequired["PaymentLink.ModifyParamsCustomText"]
- """
- Display additional text for your customers using custom text.
- """
- customer_creation: NotRequired[Literal["always", "if_required"]]
- """
- Configures whether [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link create a [Customer](https://stripe.com/docs/api/customers).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- inactive_message: NotRequired["Literal['']|str"]
- """
- The custom message to be displayed to a customer when a payment link is no longer active.
- """
- invoice_creation: NotRequired[
- "PaymentLink.ModifyParamsInvoiceCreation"
- ]
- """
- Generate a post-purchase Invoice for one-time payments.
- """
- line_items: NotRequired[List["PaymentLink.ModifyParamsLineItem"]]
- """
- The line items representing what is being sold. Each line item represents an item being sold. Up to 20 line items are supported.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. Metadata associated with this Payment Link will automatically be copied to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
- """
- payment_intent_data: NotRequired[
- "PaymentLink.ModifyParamsPaymentIntentData"
- ]
- """
- A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
- """
- payment_method_collection: NotRequired[
- Literal["always", "if_required"]
- ]
- """
- Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.This may occur if the Checkout Session includes a free trial or a discount.
-
- Can only be set in `subscription` mode. Defaults to `always`.
-
- 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', 'alma', 'au_becs_debit', 'bacs_debit', 'bancontact', 'billie', 'blik', 'boleto', 'card', 'cashapp', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'klarna', 'konbini', 'link', 'mobilepay', 'multibanco', 'oxxo', 'p24', 'pay_by_bank', 'paynow', 'paypal', 'pix', 'promptpay', 'satispay', 'sepa_debit', 'sofort', 'swish', 'twint', 'us_bank_account', 'wechat_pay', 'zip']]"
- ]
- """
- 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).
- """
- phone_number_collection: NotRequired[
- "PaymentLink.ModifyParamsPhoneNumberCollection"
- ]
- """
- Controls phone number collection settings during checkout.
-
- We recommend that you review your privacy policy and check with your legal contacts.
- """
- restrictions: NotRequired[
- "Literal['']|PaymentLink.ModifyParamsRestrictions"
- ]
- """
- Settings that restrict the usage of a payment link.
- """
- shipping_address_collection: NotRequired[
- "Literal['']|PaymentLink.ModifyParamsShippingAddressCollection"
- ]
- """
- Configuration for collecting the customer's shipping address.
- """
- submit_type: NotRequired[
- Literal["auto", "book", "donate", "pay", "subscribe"]
- ]
- """
- Describes the type of transaction being performed in order to customize relevant text on the page, such as the submit button. Changing this value will also affect the hostname in the [url](https://stripe.com/docs/api/payment_links/payment_links/object#url) property (example: `donate.stripe.com`).
- """
- subscription_data: NotRequired[
- "PaymentLink.ModifyParamsSubscriptionData"
- ]
- """
- 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[
- "PaymentLink.ModifyParamsAfterCompletionHostedConfirmation"
- ]
- """
- Configuration when `type=hosted_confirmation`.
- """
- redirect: NotRequired[
- "PaymentLink.ModifyParamsAfterCompletionRedirect"
- ]
- """
- Configuration when `type=redirect`.
- """
- type: Literal["hosted_confirmation", "redirect"]
- """
- The specified behavior after the purchase is complete. Either `redirect` or `hosted_confirmation`.
- """
-
- class ModifyParamsAfterCompletionHostedConfirmation(TypedDict):
- custom_message: NotRequired[str]
- """
- A custom message to display to the customer after the purchase is complete.
- """
-
- class ModifyParamsAfterCompletionRedirect(TypedDict):
- url: str
- """
- The URL the customer will be redirected to after the purchase is complete. You can embed `{CHECKOUT_SESSION_ID}` into the URL to have the `id` of the completed [checkout session](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-id) included.
- """
-
- class ModifyParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
-
- Enabling this parameter causes the payment link to collect any billing address information necessary for tax calculation.
- """
- liability: NotRequired["PaymentLink.ModifyParamsAutomaticTaxLiability"]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class ModifyParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class ModifyParamsCustomField(TypedDict):
- dropdown: NotRequired["PaymentLink.ModifyParamsCustomFieldDropdown"]
- """
- Configuration for `type=dropdown` fields.
- """
- key: str
- """
- String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
- """
- label: "PaymentLink.ModifyParamsCustomFieldLabel"
- """
- The label for the field, displayed to the customer.
- """
- numeric: NotRequired["PaymentLink.ModifyParamsCustomFieldNumeric"]
- """
- Configuration for `type=numeric` fields.
- """
- optional: NotRequired[bool]
- """
- Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
- """
- text: NotRequired["PaymentLink.ModifyParamsCustomFieldText"]
- """
- Configuration for `type=text` fields.
- """
- type: Literal["dropdown", "numeric", "text"]
- """
- The type of the field.
- """
-
- class ModifyParamsCustomFieldDropdown(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
- """
- options: List["PaymentLink.ModifyParamsCustomFieldDropdownOption"]
- """
- The options available for the customer to select. Up to 200 options allowed.
- """
-
- class ModifyParamsCustomFieldDropdownOption(TypedDict):
- label: str
- """
- The label for the option, displayed to the customer. Up to 100 characters.
- """
- value: str
- """
- The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
- """
-
- class ModifyParamsCustomFieldLabel(TypedDict):
- custom: str
- """
- Custom text for the label, displayed to the customer. Up to 50 characters.
- """
- type: Literal["custom"]
- """
- The type of the label.
- """
-
- class ModifyParamsCustomFieldNumeric(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.
- """
- maximum_length: NotRequired[int]
- """
- The maximum character length constraint for the customer's input.
- """
- minimum_length: NotRequired[int]
- """
- The minimum character length requirement for the customer's input.
- """
-
- class ModifyParamsCustomFieldText(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.
- """
- maximum_length: NotRequired[int]
- """
- The maximum character length constraint for the customer's input.
- """
- minimum_length: NotRequired[int]
- """
- The minimum character length requirement for the customer's input.
- """
-
- class ModifyParamsCustomText(TypedDict):
- after_submit: NotRequired[
- "Literal['']|PaymentLink.ModifyParamsCustomTextAfterSubmit"
- ]
- """
- Custom text that should be displayed after the payment confirmation button.
- """
- shipping_address: NotRequired[
- "Literal['']|PaymentLink.ModifyParamsCustomTextShippingAddress"
- ]
- """
- Custom text that should be displayed alongside shipping address collection.
- """
- submit: NotRequired[
- "Literal['']|PaymentLink.ModifyParamsCustomTextSubmit"
- ]
- """
- Custom text that should be displayed alongside the payment confirmation button.
- """
- terms_of_service_acceptance: NotRequired[
- "Literal['']|PaymentLink.ModifyParamsCustomTextTermsOfServiceAcceptance"
- ]
- """
- Custom text that should be displayed in place of the default terms of service agreement text.
- """
-
- class ModifyParamsCustomTextAfterSubmit(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class ModifyParamsCustomTextShippingAddress(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class ModifyParamsCustomTextSubmit(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class ModifyParamsCustomTextTermsOfServiceAcceptance(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class ModifyParamsInvoiceCreation(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled
- """
- invoice_data: NotRequired[
- "PaymentLink.ModifyParamsInvoiceCreationInvoiceData"
- ]
- """
- Invoice PDF configuration.
- """
-
- class ModifyParamsInvoiceCreationInvoiceData(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the invoice.
- """
- custom_fields: NotRequired[
- "Literal['']|List[PaymentLink.ModifyParamsInvoiceCreationInvoiceDataCustomField]"
- ]
- """
- Default custom fields to be displayed on invoices for this customer.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- footer: NotRequired[str]
- """
- Default footer to be displayed on invoices for this customer.
- """
- issuer: NotRequired[
- "PaymentLink.ModifyParamsInvoiceCreationInvoiceDataIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- rendering_options: NotRequired[
- "Literal['']|PaymentLink.ModifyParamsInvoiceCreationInvoiceDataRenderingOptions"
- ]
- """
- Default options for invoice PDF rendering for this customer.
- """
-
- class ModifyParamsInvoiceCreationInvoiceDataCustomField(TypedDict):
- name: str
- """
- The name of the custom field. This may be up to 40 characters.
- """
- value: str
- """
- The value of the custom field. This may be up to 140 characters.
- """
-
- class ModifyParamsInvoiceCreationInvoiceDataIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class ModifyParamsInvoiceCreationInvoiceDataRenderingOptions(TypedDict):
- amount_tax_display: NotRequired[
- "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
- ]
- """
- How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
- """
- template: NotRequired[str]
- """
- ID of the invoice rendering template to use for this invoice.
- """
-
- class ModifyParamsLineItem(TypedDict):
- adjustable_quantity: NotRequired[
- "PaymentLink.ModifyParamsLineItemAdjustableQuantity"
- ]
- """
- When set, provides configuration for this item's quantity to be adjusted by the customer during checkout.
- """
- id: str
- """
- The ID of an existing line item on the payment link.
- """
- quantity: NotRequired[int]
- """
- The quantity of the line item being purchased.
- """
-
- class ModifyParamsLineItemAdjustableQuantity(TypedDict):
- enabled: bool
- """
- Set to true if the quantity can be adjusted to any non-negative Integer.
- """
- maximum: NotRequired[int]
- """
- The maximum quantity the customer can purchase. By default this value is 99. You can specify a value up to 999999.
- """
- minimum: NotRequired[int]
- """
- The minimum quantity the customer can purchase. By default this value is 0. If there is only one item in the cart then that item's quantity cannot go down to 0.
- """
-
- class ModifyParamsPaymentIntentData(TypedDict):
- description: NotRequired["Literal['']|str"]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Payment Intents](https://stripe.com/docs/api/payment_intents) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
- """
- statement_descriptor: NotRequired["Literal['']|str"]
- """
- Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
-
- Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
- """
- statement_descriptor_suffix: NotRequired["Literal['']|str"]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
- """
- transfer_group: NotRequired["Literal['']|str"]
- """
- A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
- """
-
- class ModifyParamsPhoneNumberCollection(TypedDict):
- enabled: bool
- """
- Set to `true` to enable phone number collection.
- """
-
- class ModifyParamsRestrictions(TypedDict):
- completed_sessions: (
- "PaymentLink.ModifyParamsRestrictionsCompletedSessions"
- )
- """
- Configuration for the `completed_sessions` restriction type.
- """
-
- class ModifyParamsRestrictionsCompletedSessions(TypedDict):
- limit: int
- """
- The maximum number of checkout sessions that can be completed for the `completed_sessions` restriction to be met.
- """
-
- class ModifyParamsShippingAddressCollection(TypedDict):
- allowed_countries: List[
- Literal[
- "AC",
- "AD",
- "AE",
- "AF",
- "AG",
- "AI",
- "AL",
- "AM",
- "AO",
- "AQ",
- "AR",
- "AT",
- "AU",
- "AW",
- "AX",
- "AZ",
- "BA",
- "BB",
- "BD",
- "BE",
- "BF",
- "BG",
- "BH",
- "BI",
- "BJ",
- "BL",
- "BM",
- "BN",
- "BO",
- "BQ",
- "BR",
- "BS",
- "BT",
- "BV",
- "BW",
- "BY",
- "BZ",
- "CA",
- "CD",
- "CF",
- "CG",
- "CH",
- "CI",
- "CK",
- "CL",
- "CM",
- "CN",
- "CO",
- "CR",
- "CV",
- "CW",
- "CY",
- "CZ",
- "DE",
- "DJ",
- "DK",
- "DM",
- "DO",
- "DZ",
- "EC",
- "EE",
- "EG",
- "EH",
- "ER",
- "ES",
- "ET",
- "FI",
- "FJ",
- "FK",
- "FO",
- "FR",
- "GA",
- "GB",
- "GD",
- "GE",
- "GF",
- "GG",
- "GH",
- "GI",
- "GL",
- "GM",
- "GN",
- "GP",
- "GQ",
- "GR",
- "GS",
- "GT",
- "GU",
- "GW",
- "GY",
- "HK",
- "HN",
- "HR",
- "HT",
- "HU",
- "ID",
- "IE",
- "IL",
- "IM",
- "IN",
- "IO",
- "IQ",
- "IS",
- "IT",
- "JE",
- "JM",
- "JO",
- "JP",
- "KE",
- "KG",
- "KH",
- "KI",
- "KM",
- "KN",
- "KR",
- "KW",
- "KY",
- "KZ",
- "LA",
- "LB",
- "LC",
- "LI",
- "LK",
- "LR",
- "LS",
- "LT",
- "LU",
- "LV",
- "LY",
- "MA",
- "MC",
- "MD",
- "ME",
- "MF",
- "MG",
- "MK",
- "ML",
- "MM",
- "MN",
- "MO",
- "MQ",
- "MR",
- "MS",
- "MT",
- "MU",
- "MV",
- "MW",
- "MX",
- "MY",
- "MZ",
- "NA",
- "NC",
- "NE",
- "NG",
- "NI",
- "NL",
- "NO",
- "NP",
- "NR",
- "NU",
- "NZ",
- "OM",
- "PA",
- "PE",
- "PF",
- "PG",
- "PH",
- "PK",
- "PL",
- "PM",
- "PN",
- "PR",
- "PS",
- "PT",
- "PY",
- "QA",
- "RE",
- "RO",
- "RS",
- "RU",
- "RW",
- "SA",
- "SB",
- "SC",
- "SD",
- "SE",
- "SG",
- "SH",
- "SI",
- "SJ",
- "SK",
- "SL",
- "SM",
- "SN",
- "SO",
- "SR",
- "SS",
- "ST",
- "SV",
- "SX",
- "SZ",
- "TA",
- "TC",
- "TD",
- "TF",
- "TG",
- "TH",
- "TJ",
- "TK",
- "TL",
- "TM",
- "TN",
- "TO",
- "TR",
- "TT",
- "TV",
- "TW",
- "TZ",
- "UA",
- "UG",
- "US",
- "UY",
- "UZ",
- "VA",
- "VC",
- "VE",
- "VG",
- "VN",
- "VU",
- "WF",
- "WS",
- "XK",
- "YE",
- "YT",
- "ZA",
- "ZM",
- "ZW",
- "ZZ",
- ]
- ]
- """
- An array of two-letter ISO country codes representing which countries Checkout should provide as options for
- shipping locations.
- """
-
- class ModifyParamsSubscriptionData(TypedDict):
- invoice_settings: NotRequired[
- "PaymentLink.ModifyParamsSubscriptionDataInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Subscriptions](https://stripe.com/docs/api/subscriptions) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
- """
- trial_period_days: NotRequired["Literal['']|int"]
- """
- Integer representing the number of trial period days before the customer is charged for the first time. Has to be at least 1.
- """
- trial_settings: NotRequired[
- "Literal['']|PaymentLink.ModifyParamsSubscriptionDataTrialSettings"
- ]
- """
- Settings related to subscription trials.
- """
-
- class ModifyParamsSubscriptionDataInvoiceSettings(TypedDict):
- issuer: NotRequired[
- "PaymentLink.ModifyParamsSubscriptionDataInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class ModifyParamsSubscriptionDataInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class ModifyParamsSubscriptionDataTrialSettings(TypedDict):
- end_behavior: (
- "PaymentLink.ModifyParamsSubscriptionDataTrialSettingsEndBehavior"
- )
- """
- Defines how the subscription should behave when the user's free trial ends.
- """
-
- class ModifyParamsSubscriptionDataTrialSettingsEndBehavior(TypedDict):
- missing_payment_method: Literal["cancel", "create_invoice", "pause"]
- """
- Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
- """
-
- class ModifyParamsTaxIdCollection(TypedDict):
- enabled: bool
- """
- Enable tax ID collection during checkout. Defaults to `false`.
- """
- required: NotRequired[Literal["if_supported", "never"]]
- """
- Describes whether a tax ID is required during checkout. Defaults to `never`.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
active: bool
"""
Whether the payment link's `url` is active. If `false`, customers visiting the URL will be shown a page saying that the link has been deactivated.
@@ -2726,7 +887,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["PaymentLink.CreateParams"]
+ cls, **params: Unpack["PaymentLinkCreateParams"]
) -> "PaymentLink":
"""
Creates a payment link.
@@ -2742,7 +903,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["PaymentLink.CreateParams"]
+ cls, **params: Unpack["PaymentLinkCreateParams"]
) -> "PaymentLink":
"""
Creates a payment link.
@@ -2758,7 +919,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["PaymentLink.ListParams"]
+ cls, **params: Unpack["PaymentLinkListParams"]
) -> ListObject["PaymentLink"]:
"""
Returns a list of your payment links.
@@ -2778,7 +939,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["PaymentLink.ListParams"]
+ cls, **params: Unpack["PaymentLinkListParams"]
) -> ListObject["PaymentLink"]:
"""
Returns a list of your payment links.
@@ -2800,7 +961,7 @@ async def list_async(
def _cls_list_line_items(
cls,
payment_link: str,
- **params: Unpack["PaymentLink.ListLineItemsParams"],
+ **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.
@@ -2819,7 +980,7 @@ def _cls_list_line_items(
@overload
@staticmethod
def list_line_items(
- payment_link: str, **params: Unpack["PaymentLink.ListLineItemsParams"]
+ 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.
@@ -2828,7 +989,7 @@ def list_line_items(
@overload
def list_line_items(
- self, **params: Unpack["PaymentLink.ListLineItemsParams"]
+ self, **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.
@@ -2837,7 +998,7 @@ def list_line_items(
@class_method_variant("_cls_list_line_items")
def list_line_items( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentLink.ListLineItemsParams"]
+ self, **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.
@@ -2857,7 +1018,7 @@ def list_line_items( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_list_line_items_async(
cls,
payment_link: str,
- **params: Unpack["PaymentLink.ListLineItemsParams"],
+ **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.
@@ -2876,7 +1037,7 @@ async def _cls_list_line_items_async(
@overload
@staticmethod
async def list_line_items_async(
- payment_link: str, **params: Unpack["PaymentLink.ListLineItemsParams"]
+ 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.
@@ -2885,7 +1046,7 @@ async def list_line_items_async(
@overload
async def list_line_items_async(
- self, **params: Unpack["PaymentLink.ListLineItemsParams"]
+ self, **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.
@@ -2894,7 +1055,7 @@ async def list_line_items_async(
@class_method_variant("_cls_list_line_items_async")
async def list_line_items_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentLink.ListLineItemsParams"]
+ self, **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.
@@ -2912,7 +1073,7 @@ async def list_line_items_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def modify(
- cls, id: str, **params: Unpack["PaymentLink.ModifyParams"]
+ cls, id: str, **params: Unpack["PaymentLinkModifyParams"]
) -> "PaymentLink":
"""
Updates a payment link.
@@ -2929,7 +1090,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["PaymentLink.ModifyParams"]
+ cls, id: str, **params: Unpack["PaymentLinkModifyParams"]
) -> "PaymentLink":
"""
Updates a payment link.
@@ -2946,7 +1107,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["PaymentLink.RetrieveParams"]
+ cls, id: str, **params: Unpack["PaymentLinkRetrieveParams"]
) -> "PaymentLink":
"""
Retrieve a payment link.
@@ -2957,7 +1118,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["PaymentLink.RetrieveParams"]
+ cls, id: str, **params: Unpack["PaymentLinkRetrieveParams"]
) -> "PaymentLink":
"""
Retrieve a payment link.
diff --git a/stripe/_payment_link_line_item_service.py b/stripe/_payment_link_line_item_service.py
index 5a659bc5f..83c1cb28f 100644
--- a/stripe/_payment_link_line_item_service.py
+++ b/stripe/_payment_link_line_item_service.py
@@ -5,33 +5,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._payment_link_line_item_list_params import (
+ PaymentLinkLineItemListParams,
+ )
-class PaymentLinkLineItemService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
+class PaymentLinkLineItemService(StripeService):
def list(
self,
payment_link: str,
- params: Optional["PaymentLinkLineItemService.ListParams"] = None,
+ params: Optional["PaymentLinkLineItemListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[LineItem]:
"""
@@ -53,7 +40,7 @@ def list(
async def list_async(
self,
payment_link: str,
- params: Optional["PaymentLinkLineItemService.ListParams"] = None,
+ 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 8839a6aba..8352eaab6 100644
--- a/stripe/_payment_link_service.py
+++ b/stripe/_payment_link_service.py
@@ -6,8 +6,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._payment_link_create_params import (
+ PaymentLinkCreateParams,
+ )
+ from stripe.params._payment_link_list_params import PaymentLinkListParams
+ from stripe.params._payment_link_retrieve_params import (
+ PaymentLinkRetrieveParams,
+ )
+ from stripe.params._payment_link_update_params import (
+ PaymentLinkUpdateParams,
+ )
class PaymentLinkService(StripeService):
@@ -15,1862 +27,9 @@ def __init__(self, requestor):
super().__init__(requestor)
self.line_items = PaymentLinkLineItemService(self._requestor)
- class CreateParams(TypedDict):
- after_completion: NotRequired[
- "PaymentLinkService.CreateParamsAfterCompletion"
- ]
- """
- Behavior after the purchase is complete.
- """
- allow_promotion_codes: NotRequired[bool]
- """
- Enables user redeemable promotion codes.
- """
- application_fee_amount: NotRequired[int]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. Can only be applied when there are no line items with recurring prices.
- """
- application_fee_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
- """
- automatic_tax: NotRequired[
- "PaymentLinkService.CreateParamsAutomaticTax"
- ]
- """
- Configuration for automatic tax collection.
- """
- billing_address_collection: NotRequired[Literal["auto", "required"]]
- """
- Configuration for collecting the customer's billing address. Defaults to `auto`.
- """
- consent_collection: NotRequired[
- "PaymentLinkService.CreateParamsConsentCollection"
- ]
- """
- Configure fields to gather active consent from customers.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies) and supported by each line item's price.
- """
- custom_fields: NotRequired[
- List["PaymentLinkService.CreateParamsCustomField"]
- ]
- """
- Collect additional information from your customer using custom fields. Up to 3 fields are supported.
- """
- custom_text: NotRequired["PaymentLinkService.CreateParamsCustomText"]
- """
- Display additional text for your customers using custom text.
- """
- customer_creation: NotRequired[Literal["always", "if_required"]]
- """
- Configures whether [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link create a [Customer](https://stripe.com/docs/api/customers).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- inactive_message: NotRequired[str]
- """
- The custom message to be displayed to a customer when a payment link is no longer active.
- """
- invoice_creation: NotRequired[
- "PaymentLinkService.CreateParamsInvoiceCreation"
- ]
- """
- Generate a post-purchase Invoice for one-time payments.
- """
- line_items: List["PaymentLinkService.CreateParamsLineItem"]
- """
- The line items representing what is being sold. Each line item represents an item being sold. Up to 20 line items are supported.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. Metadata associated with this Payment Link will automatically be copied to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
- """
- on_behalf_of: NotRequired[str]
- """
- The account on behalf of which to charge.
- """
- optional_items: NotRequired[
- List["PaymentLinkService.CreateParamsOptionalItem"]
- ]
- """
- A list of optional items the customer can add to their order at checkout. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices).
- There is a maximum of 10 optional items allowed on a payment link, and the existing limits on the number of line items allowed on a payment link apply to the combined number of line items and optional items.
- There is a maximum of 20 combined line items and optional items.
- """
- payment_intent_data: NotRequired[
- "PaymentLinkService.CreateParamsPaymentIntentData"
- ]
- """
- A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
- """
- payment_method_collection: NotRequired[
- Literal["always", "if_required"]
- ]
- """
- Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.This may occur if the Checkout Session includes a free trial or a discount.
-
- Can only be set in `subscription` mode. Defaults to `always`.
-
- 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[
- List[
- Literal[
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "card",
- "cashapp",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "klarna",
- "konbini",
- "link",
- "mobilepay",
- "multibanco",
- "oxxo",
- "p24",
- "pay_by_bank",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- ]
- ]
- """
- The list of payment method types that customers can use. If no value is passed, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods) (20+ payment methods [supported](https://stripe.com/docs/payments/payment-methods/integration-options#payment-method-product-support)).
- """
- phone_number_collection: NotRequired[
- "PaymentLinkService.CreateParamsPhoneNumberCollection"
- ]
- """
- Controls phone number collection settings during checkout.
-
- We recommend that you review your privacy policy and check with your legal contacts.
- """
- restrictions: NotRequired[
- "PaymentLinkService.CreateParamsRestrictions"
- ]
- """
- Settings that restrict the usage of a payment link.
- """
- shipping_address_collection: NotRequired[
- "PaymentLinkService.CreateParamsShippingAddressCollection"
- ]
- """
- Configuration for collecting the customer's shipping address.
- """
- shipping_options: NotRequired[
- List["PaymentLinkService.CreateParamsShippingOption"]
- ]
- """
- The shipping rate options to apply to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
- """
- submit_type: NotRequired[
- Literal["auto", "book", "donate", "pay", "subscribe"]
- ]
- """
- Describes the type of transaction being performed in order to customize relevant text on the page, such as the submit button. Changing this value will also affect the hostname in the [url](https://stripe.com/docs/api/payment_links/payment_links/object#url) property (example: `donate.stripe.com`).
- """
- subscription_data: NotRequired[
- "PaymentLinkService.CreateParamsSubscriptionData"
- ]
- """
- 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.CreateParamsTaxIdCollection"
- ]
- """
- Controls tax ID collection during checkout.
- """
- transfer_data: NotRequired[
- "PaymentLinkService.CreateParamsTransferData"
- ]
- """
- The account (if any) the payments will be attributed to for tax reporting, and where funds from each payment will be transferred to.
- """
-
- class CreateParamsAfterCompletion(TypedDict):
- hosted_confirmation: NotRequired[
- "PaymentLinkService.CreateParamsAfterCompletionHostedConfirmation"
- ]
- """
- Configuration when `type=hosted_confirmation`.
- """
- redirect: NotRequired[
- "PaymentLinkService.CreateParamsAfterCompletionRedirect"
- ]
- """
- Configuration when `type=redirect`.
- """
- type: Literal["hosted_confirmation", "redirect"]
- """
- The specified behavior after the purchase is complete. Either `redirect` or `hosted_confirmation`.
- """
-
- class CreateParamsAfterCompletionHostedConfirmation(TypedDict):
- custom_message: NotRequired[str]
- """
- A custom message to display to the customer after the purchase is complete.
- """
-
- class CreateParamsAfterCompletionRedirect(TypedDict):
- url: str
- """
- The URL the customer will be redirected to after the purchase is complete. You can embed `{CHECKOUT_SESSION_ID}` into the URL to have the `id` of the completed [checkout session](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-id) included.
- """
-
- class CreateParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
-
- Enabling this parameter causes the payment link to collect any billing address information necessary for tax calculation.
- """
- liability: NotRequired[
- "PaymentLinkService.CreateParamsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreateParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsConsentCollection(TypedDict):
- payment_method_reuse_agreement: NotRequired[
- "PaymentLinkService.CreateParamsConsentCollectionPaymentMethodReuseAgreement"
- ]
- """
- Determines the display of payment method reuse agreement text in the UI. If set to `hidden`, it will hide legal text related to the reuse of a payment method.
- """
- promotions: NotRequired[Literal["auto", "none"]]
- """
- If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
- Session will determine whether to display an option to opt into promotional communication
- from the merchant depending on the customer's locale. Only available to US merchants.
- """
- terms_of_service: NotRequired[Literal["none", "required"]]
- """
- If set to `required`, it requires customers to check a terms of service checkbox before being able to pay.
- There must be a valid terms of service URL set in your [Dashboard settings](https://dashboard.stripe.com/settings/public).
- """
-
- class CreateParamsConsentCollectionPaymentMethodReuseAgreement(TypedDict):
- position: Literal["auto", "hidden"]
- """
- Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's
- defaults will be used. When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
- """
-
- class CreateParamsCustomField(TypedDict):
- dropdown: NotRequired[
- "PaymentLinkService.CreateParamsCustomFieldDropdown"
- ]
- """
- Configuration for `type=dropdown` fields.
- """
- key: str
- """
- String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
- """
- label: "PaymentLinkService.CreateParamsCustomFieldLabel"
- """
- The label for the field, displayed to the customer.
- """
- numeric: NotRequired[
- "PaymentLinkService.CreateParamsCustomFieldNumeric"
- ]
- """
- Configuration for `type=numeric` fields.
- """
- optional: NotRequired[bool]
- """
- Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
- """
- text: NotRequired["PaymentLinkService.CreateParamsCustomFieldText"]
- """
- Configuration for `type=text` fields.
- """
- type: Literal["dropdown", "numeric", "text"]
- """
- The type of the field.
- """
-
- class CreateParamsCustomFieldDropdown(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
- """
- options: List[
- "PaymentLinkService.CreateParamsCustomFieldDropdownOption"
- ]
- """
- The options available for the customer to select. Up to 200 options allowed.
- """
-
- class CreateParamsCustomFieldDropdownOption(TypedDict):
- label: str
- """
- The label for the option, displayed to the customer. Up to 100 characters.
- """
- value: str
- """
- The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
- """
-
- class CreateParamsCustomFieldLabel(TypedDict):
- custom: str
- """
- Custom text for the label, displayed to the customer. Up to 50 characters.
- """
- type: Literal["custom"]
- """
- The type of the label.
- """
-
- class CreateParamsCustomFieldNumeric(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.
- """
- maximum_length: NotRequired[int]
- """
- The maximum character length constraint for the customer's input.
- """
- minimum_length: NotRequired[int]
- """
- The minimum character length requirement for the customer's input.
- """
-
- class CreateParamsCustomFieldText(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.
- """
- maximum_length: NotRequired[int]
- """
- The maximum character length constraint for the customer's input.
- """
- minimum_length: NotRequired[int]
- """
- The minimum character length requirement for the customer's input.
- """
-
- class CreateParamsCustomText(TypedDict):
- after_submit: NotRequired[
- "Literal['']|PaymentLinkService.CreateParamsCustomTextAfterSubmit"
- ]
- """
- Custom text that should be displayed after the payment confirmation button.
- """
- shipping_address: NotRequired[
- "Literal['']|PaymentLinkService.CreateParamsCustomTextShippingAddress"
- ]
- """
- Custom text that should be displayed alongside shipping address collection.
- """
- submit: NotRequired[
- "Literal['']|PaymentLinkService.CreateParamsCustomTextSubmit"
- ]
- """
- Custom text that should be displayed alongside the payment confirmation button.
- """
- terms_of_service_acceptance: NotRequired[
- "Literal['']|PaymentLinkService.CreateParamsCustomTextTermsOfServiceAcceptance"
- ]
- """
- Custom text that should be displayed in place of the default terms of service agreement text.
- """
-
- class CreateParamsCustomTextAfterSubmit(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsCustomTextShippingAddress(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsCustomTextSubmit(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsCustomTextTermsOfServiceAcceptance(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsInvoiceCreation(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled
- """
- invoice_data: NotRequired[
- "PaymentLinkService.CreateParamsInvoiceCreationInvoiceData"
- ]
- """
- Invoice PDF configuration.
- """
-
- class CreateParamsInvoiceCreationInvoiceData(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the invoice.
- """
- custom_fields: NotRequired[
- "Literal['']|List[PaymentLinkService.CreateParamsInvoiceCreationInvoiceDataCustomField]"
- ]
- """
- Default custom fields to be displayed on invoices for this customer.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- footer: NotRequired[str]
- """
- Default footer to be displayed on invoices for this customer.
- """
- issuer: NotRequired[
- "PaymentLinkService.CreateParamsInvoiceCreationInvoiceDataIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- rendering_options: NotRequired[
- "Literal['']|PaymentLinkService.CreateParamsInvoiceCreationInvoiceDataRenderingOptions"
- ]
- """
- Default options for invoice PDF rendering for this customer.
- """
-
- class CreateParamsInvoiceCreationInvoiceDataCustomField(TypedDict):
- name: str
- """
- The name of the custom field. This may be up to 40 characters.
- """
- value: str
- """
- The value of the custom field. This may be up to 140 characters.
- """
-
- class CreateParamsInvoiceCreationInvoiceDataIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsInvoiceCreationInvoiceDataRenderingOptions(TypedDict):
- amount_tax_display: NotRequired[
- "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
- ]
- """
- How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
- """
- template: NotRequired[str]
- """
- ID of the invoice rendering template to use for this invoice.
- """
-
- class CreateParamsLineItem(TypedDict):
- adjustable_quantity: NotRequired[
- "PaymentLinkService.CreateParamsLineItemAdjustableQuantity"
- ]
- """
- When set, provides configuration for this item's quantity to be adjusted by the customer during checkout.
- """
- price: NotRequired[str]
- """
- The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired[
- "PaymentLinkService.CreateParamsLineItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: int
- """
- The quantity of the line item being purchased.
- """
-
- class CreateParamsLineItemAdjustableQuantity(TypedDict):
- enabled: bool
- """
- Set to true if the quantity can be adjusted to any non-negative Integer.
- """
- maximum: NotRequired[int]
- """
- The maximum quantity the customer can purchase. By default this value is 99. You can specify a value up to 999999.
- """
- minimum: NotRequired[int]
- """
- The minimum quantity the customer can purchase. By default this value is 0. If there is only one item in the cart then that item's quantity cannot go down to 0.
- """
-
- class CreateParamsLineItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: NotRequired[str]
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
- """
- product_data: NotRequired[
- "PaymentLinkService.CreateParamsLineItemPriceDataProductData"
- ]
- """
- Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
- """
- recurring: NotRequired[
- "PaymentLinkService.CreateParamsLineItemPriceDataRecurring"
- ]
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsLineItemPriceDataProductData(TypedDict):
- description: NotRequired[str]
- """
- The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
- """
- images: NotRequired[List[str]]
- """
- A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The product's name, meant to be displayable to the customer.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- unit_label: NotRequired[str]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
- """
-
- class CreateParamsLineItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class CreateParamsOptionalItem(TypedDict):
- adjustable_quantity: NotRequired[
- "PaymentLinkService.CreateParamsOptionalItemAdjustableQuantity"
- ]
- """
- When set, provides configuration for the customer to adjust the quantity of the line item created when a customer chooses to add this optional item to their order.
- """
- price: str
- """
- The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object.
- """
- quantity: int
- """
- The initial quantity of the line item created when a customer chooses to add this optional item to their order.
- """
-
- class CreateParamsOptionalItemAdjustableQuantity(TypedDict):
- enabled: bool
- """
- Set to true if the quantity can be adjusted to any non-negative integer.
- """
- maximum: NotRequired[int]
- """
- The maximum quantity of this item the customer can purchase. By default this value is 99.
- """
- minimum: NotRequired[int]
- """
- The minimum quantity of this item the customer must purchase, if they choose to purchase it. Because this item is optional, the customer will always be able to remove it from their order, even if the `minimum` configured here is greater than 0. By default this value is 0.
- """
-
- class CreateParamsPaymentIntentData(TypedDict):
- capture_method: NotRequired[
- Literal["automatic", "automatic_async", "manual"]
- ]
- """
- Controls when the funds will be captured from the customer's account.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Payment Intents](https://stripe.com/docs/api/payment_intents) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
- """
- setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
- """
- Indicates that you intend to [make future payments](https://stripe.com/docs/payments/payment-intents#future-usage) with the payment method collected by this Checkout Session.
-
- When setting this to `on_session`, Checkout will show a notice to the customer that their payment details will be saved.
-
- When setting this to `off_session`, Checkout will show a notice to the customer that their payment details will be saved and used for future payments.
-
- If a Customer has been provided or Checkout creates a new Customer,Checkout will attach the payment method to the Customer.
-
- If Checkout does not create a Customer, the payment method is not attached to a Customer. To reuse the payment method, you can retrieve it from the Checkout Session's PaymentIntent.
-
- When processing card payments, Checkout also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as SCA.
- """
- statement_descriptor: NotRequired[str]
- """
- Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
-
- Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
- """
- statement_descriptor_suffix: NotRequired[str]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
- """
-
- class CreateParamsPhoneNumberCollection(TypedDict):
- enabled: bool
- """
- Set to `true` to enable phone number collection.
- """
-
- class CreateParamsRestrictions(TypedDict):
- completed_sessions: (
- "PaymentLinkService.CreateParamsRestrictionsCompletedSessions"
- )
- """
- Configuration for the `completed_sessions` restriction type.
- """
-
- class CreateParamsRestrictionsCompletedSessions(TypedDict):
- limit: int
- """
- The maximum number of checkout sessions that can be completed for the `completed_sessions` restriction to be met.
- """
-
- class CreateParamsShippingAddressCollection(TypedDict):
- allowed_countries: List[
- Literal[
- "AC",
- "AD",
- "AE",
- "AF",
- "AG",
- "AI",
- "AL",
- "AM",
- "AO",
- "AQ",
- "AR",
- "AT",
- "AU",
- "AW",
- "AX",
- "AZ",
- "BA",
- "BB",
- "BD",
- "BE",
- "BF",
- "BG",
- "BH",
- "BI",
- "BJ",
- "BL",
- "BM",
- "BN",
- "BO",
- "BQ",
- "BR",
- "BS",
- "BT",
- "BV",
- "BW",
- "BY",
- "BZ",
- "CA",
- "CD",
- "CF",
- "CG",
- "CH",
- "CI",
- "CK",
- "CL",
- "CM",
- "CN",
- "CO",
- "CR",
- "CV",
- "CW",
- "CY",
- "CZ",
- "DE",
- "DJ",
- "DK",
- "DM",
- "DO",
- "DZ",
- "EC",
- "EE",
- "EG",
- "EH",
- "ER",
- "ES",
- "ET",
- "FI",
- "FJ",
- "FK",
- "FO",
- "FR",
- "GA",
- "GB",
- "GD",
- "GE",
- "GF",
- "GG",
- "GH",
- "GI",
- "GL",
- "GM",
- "GN",
- "GP",
- "GQ",
- "GR",
- "GS",
- "GT",
- "GU",
- "GW",
- "GY",
- "HK",
- "HN",
- "HR",
- "HT",
- "HU",
- "ID",
- "IE",
- "IL",
- "IM",
- "IN",
- "IO",
- "IQ",
- "IS",
- "IT",
- "JE",
- "JM",
- "JO",
- "JP",
- "KE",
- "KG",
- "KH",
- "KI",
- "KM",
- "KN",
- "KR",
- "KW",
- "KY",
- "KZ",
- "LA",
- "LB",
- "LC",
- "LI",
- "LK",
- "LR",
- "LS",
- "LT",
- "LU",
- "LV",
- "LY",
- "MA",
- "MC",
- "MD",
- "ME",
- "MF",
- "MG",
- "MK",
- "ML",
- "MM",
- "MN",
- "MO",
- "MQ",
- "MR",
- "MS",
- "MT",
- "MU",
- "MV",
- "MW",
- "MX",
- "MY",
- "MZ",
- "NA",
- "NC",
- "NE",
- "NG",
- "NI",
- "NL",
- "NO",
- "NP",
- "NR",
- "NU",
- "NZ",
- "OM",
- "PA",
- "PE",
- "PF",
- "PG",
- "PH",
- "PK",
- "PL",
- "PM",
- "PN",
- "PR",
- "PS",
- "PT",
- "PY",
- "QA",
- "RE",
- "RO",
- "RS",
- "RU",
- "RW",
- "SA",
- "SB",
- "SC",
- "SD",
- "SE",
- "SG",
- "SH",
- "SI",
- "SJ",
- "SK",
- "SL",
- "SM",
- "SN",
- "SO",
- "SR",
- "SS",
- "ST",
- "SV",
- "SX",
- "SZ",
- "TA",
- "TC",
- "TD",
- "TF",
- "TG",
- "TH",
- "TJ",
- "TK",
- "TL",
- "TM",
- "TN",
- "TO",
- "TR",
- "TT",
- "TV",
- "TW",
- "TZ",
- "UA",
- "UG",
- "US",
- "UY",
- "UZ",
- "VA",
- "VC",
- "VE",
- "VG",
- "VN",
- "VU",
- "WF",
- "WS",
- "XK",
- "YE",
- "YT",
- "ZA",
- "ZM",
- "ZW",
- "ZZ",
- ]
- ]
- """
- An array of two-letter ISO country codes representing which countries Checkout should provide as options for
- shipping locations.
- """
-
- class CreateParamsShippingOption(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the Shipping Rate to use for this shipping option.
- """
-
- class CreateParamsSubscriptionData(TypedDict):
- description: NotRequired[str]
- """
- The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- invoice_settings: NotRequired[
- "PaymentLinkService.CreateParamsSubscriptionDataInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Subscriptions](https://stripe.com/docs/api/subscriptions) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
- """
- trial_period_days: NotRequired[int]
- """
- Integer representing the number of trial period days before the customer is charged for the first time. Has to be at least 1.
- """
- trial_settings: NotRequired[
- "PaymentLinkService.CreateParamsSubscriptionDataTrialSettings"
- ]
- """
- Settings related to subscription trials.
- """
-
- class CreateParamsSubscriptionDataInvoiceSettings(TypedDict):
- issuer: NotRequired[
- "PaymentLinkService.CreateParamsSubscriptionDataInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class CreateParamsSubscriptionDataInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsSubscriptionDataTrialSettings(TypedDict):
- end_behavior: "PaymentLinkService.CreateParamsSubscriptionDataTrialSettingsEndBehavior"
- """
- Defines how the subscription should behave when the user's free trial ends.
- """
-
- class CreateParamsSubscriptionDataTrialSettingsEndBehavior(TypedDict):
- missing_payment_method: Literal["cancel", "create_invoice", "pause"]
- """
- Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
- """
-
- class CreateParamsTaxIdCollection(TypedDict):
- enabled: bool
- """
- Enable tax ID collection during checkout. Defaults to `false`.
- """
- required: NotRequired[Literal["if_supported", "never"]]
- """
- Describes whether a tax ID is required during checkout. Defaults to `never`.
- """
-
- class CreateParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when a charge succeeds.
- """
- destination: str
- """
- If specified, successful charges will be attributed to the destination
- account for tax reporting, and the funds from charges will be transferred
- to the destination account. The ID of the resulting transfer will be
- returned on the successful charge's `transfer` field.
- """
-
- class ListParams(TypedDict):
- active: NotRequired[bool]
- """
- Only return payment links that are active or inactive (e.g., pass `false` to list all inactive payment links).
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- active: NotRequired[bool]
- """
- Whether the payment link's `url` is active. If `false`, customers visiting the URL will be shown a page saying that the link has been deactivated.
- """
- after_completion: NotRequired[
- "PaymentLinkService.UpdateParamsAfterCompletion"
- ]
- """
- Behavior after the purchase is complete.
- """
- allow_promotion_codes: NotRequired[bool]
- """
- Enables user redeemable promotion codes.
- """
- automatic_tax: NotRequired[
- "PaymentLinkService.UpdateParamsAutomaticTax"
- ]
- """
- Configuration for automatic tax collection.
- """
- billing_address_collection: NotRequired[Literal["auto", "required"]]
- """
- Configuration for collecting the customer's billing address. Defaults to `auto`.
- """
- custom_fields: NotRequired[
- "Literal['']|List[PaymentLinkService.UpdateParamsCustomField]"
- ]
- """
- Collect additional information from your customer using custom fields. Up to 3 fields are supported.
- """
- custom_text: NotRequired["PaymentLinkService.UpdateParamsCustomText"]
- """
- Display additional text for your customers using custom text.
- """
- customer_creation: NotRequired[Literal["always", "if_required"]]
- """
- Configures whether [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link create a [Customer](https://stripe.com/docs/api/customers).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- inactive_message: NotRequired["Literal['']|str"]
- """
- The custom message to be displayed to a customer when a payment link is no longer active.
- """
- invoice_creation: NotRequired[
- "PaymentLinkService.UpdateParamsInvoiceCreation"
- ]
- """
- Generate a post-purchase Invoice for one-time payments.
- """
- line_items: NotRequired[
- List["PaymentLinkService.UpdateParamsLineItem"]
- ]
- """
- The line items representing what is being sold. Each line item represents an item being sold. Up to 20 line items are supported.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. Metadata associated with this Payment Link will automatically be copied to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
- """
- payment_intent_data: NotRequired[
- "PaymentLinkService.UpdateParamsPaymentIntentData"
- ]
- """
- A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
- """
- payment_method_collection: NotRequired[
- Literal["always", "if_required"]
- ]
- """
- Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.This may occur if the Checkout Session includes a free trial or a discount.
-
- Can only be set in `subscription` mode. Defaults to `always`.
-
- 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', 'alma', 'au_becs_debit', 'bacs_debit', 'bancontact', 'billie', 'blik', 'boleto', 'card', 'cashapp', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'klarna', 'konbini', 'link', 'mobilepay', 'multibanco', 'oxxo', 'p24', 'pay_by_bank', 'paynow', 'paypal', 'pix', 'promptpay', 'satispay', 'sepa_debit', 'sofort', 'swish', 'twint', 'us_bank_account', 'wechat_pay', 'zip']]"
- ]
- """
- 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).
- """
- phone_number_collection: NotRequired[
- "PaymentLinkService.UpdateParamsPhoneNumberCollection"
- ]
- """
- Controls phone number collection settings during checkout.
-
- We recommend that you review your privacy policy and check with your legal contacts.
- """
- restrictions: NotRequired[
- "Literal['']|PaymentLinkService.UpdateParamsRestrictions"
- ]
- """
- Settings that restrict the usage of a payment link.
- """
- shipping_address_collection: NotRequired[
- "Literal['']|PaymentLinkService.UpdateParamsShippingAddressCollection"
- ]
- """
- Configuration for collecting the customer's shipping address.
- """
- submit_type: NotRequired[
- Literal["auto", "book", "donate", "pay", "subscribe"]
- ]
- """
- Describes the type of transaction being performed in order to customize relevant text on the page, such as the submit button. Changing this value will also affect the hostname in the [url](https://stripe.com/docs/api/payment_links/payment_links/object#url) property (example: `donate.stripe.com`).
- """
- subscription_data: NotRequired[
- "PaymentLinkService.UpdateParamsSubscriptionData"
- ]
- """
- 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[
- "PaymentLinkService.UpdateParamsAfterCompletionHostedConfirmation"
- ]
- """
- Configuration when `type=hosted_confirmation`.
- """
- redirect: NotRequired[
- "PaymentLinkService.UpdateParamsAfterCompletionRedirect"
- ]
- """
- Configuration when `type=redirect`.
- """
- type: Literal["hosted_confirmation", "redirect"]
- """
- The specified behavior after the purchase is complete. Either `redirect` or `hosted_confirmation`.
- """
-
- class UpdateParamsAfterCompletionHostedConfirmation(TypedDict):
- custom_message: NotRequired[str]
- """
- A custom message to display to the customer after the purchase is complete.
- """
-
- class UpdateParamsAfterCompletionRedirect(TypedDict):
- url: str
- """
- The URL the customer will be redirected to after the purchase is complete. You can embed `{CHECKOUT_SESSION_ID}` into the URL to have the `id` of the completed [checkout session](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-id) included.
- """
-
- class UpdateParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
-
- Enabling this parameter causes the payment link to collect any billing address information necessary for tax calculation.
- """
- liability: NotRequired[
- "PaymentLinkService.UpdateParamsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class UpdateParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class UpdateParamsCustomField(TypedDict):
- dropdown: NotRequired[
- "PaymentLinkService.UpdateParamsCustomFieldDropdown"
- ]
- """
- Configuration for `type=dropdown` fields.
- """
- key: str
- """
- String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
- """
- label: "PaymentLinkService.UpdateParamsCustomFieldLabel"
- """
- The label for the field, displayed to the customer.
- """
- numeric: NotRequired[
- "PaymentLinkService.UpdateParamsCustomFieldNumeric"
- ]
- """
- Configuration for `type=numeric` fields.
- """
- optional: NotRequired[bool]
- """
- Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
- """
- text: NotRequired["PaymentLinkService.UpdateParamsCustomFieldText"]
- """
- Configuration for `type=text` fields.
- """
- type: Literal["dropdown", "numeric", "text"]
- """
- The type of the field.
- """
-
- class UpdateParamsCustomFieldDropdown(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
- """
- options: List[
- "PaymentLinkService.UpdateParamsCustomFieldDropdownOption"
- ]
- """
- The options available for the customer to select. Up to 200 options allowed.
- """
-
- class UpdateParamsCustomFieldDropdownOption(TypedDict):
- label: str
- """
- The label for the option, displayed to the customer. Up to 100 characters.
- """
- value: str
- """
- The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
- """
-
- class UpdateParamsCustomFieldLabel(TypedDict):
- custom: str
- """
- Custom text for the label, displayed to the customer. Up to 50 characters.
- """
- type: Literal["custom"]
- """
- The type of the label.
- """
-
- class UpdateParamsCustomFieldNumeric(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.
- """
- maximum_length: NotRequired[int]
- """
- The maximum character length constraint for the customer's input.
- """
- minimum_length: NotRequired[int]
- """
- The minimum character length requirement for the customer's input.
- """
-
- class UpdateParamsCustomFieldText(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.
- """
- maximum_length: NotRequired[int]
- """
- The maximum character length constraint for the customer's input.
- """
- minimum_length: NotRequired[int]
- """
- The minimum character length requirement for the customer's input.
- """
-
- class UpdateParamsCustomText(TypedDict):
- after_submit: NotRequired[
- "Literal['']|PaymentLinkService.UpdateParamsCustomTextAfterSubmit"
- ]
- """
- Custom text that should be displayed after the payment confirmation button.
- """
- shipping_address: NotRequired[
- "Literal['']|PaymentLinkService.UpdateParamsCustomTextShippingAddress"
- ]
- """
- Custom text that should be displayed alongside shipping address collection.
- """
- submit: NotRequired[
- "Literal['']|PaymentLinkService.UpdateParamsCustomTextSubmit"
- ]
- """
- Custom text that should be displayed alongside the payment confirmation button.
- """
- terms_of_service_acceptance: NotRequired[
- "Literal['']|PaymentLinkService.UpdateParamsCustomTextTermsOfServiceAcceptance"
- ]
- """
- Custom text that should be displayed in place of the default terms of service agreement text.
- """
-
- class UpdateParamsCustomTextAfterSubmit(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class UpdateParamsCustomTextShippingAddress(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class UpdateParamsCustomTextSubmit(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class UpdateParamsCustomTextTermsOfServiceAcceptance(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class UpdateParamsInvoiceCreation(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled
- """
- invoice_data: NotRequired[
- "PaymentLinkService.UpdateParamsInvoiceCreationInvoiceData"
- ]
- """
- Invoice PDF configuration.
- """
-
- class UpdateParamsInvoiceCreationInvoiceData(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the invoice.
- """
- custom_fields: NotRequired[
- "Literal['']|List[PaymentLinkService.UpdateParamsInvoiceCreationInvoiceDataCustomField]"
- ]
- """
- Default custom fields to be displayed on invoices for this customer.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- footer: NotRequired[str]
- """
- Default footer to be displayed on invoices for this customer.
- """
- issuer: NotRequired[
- "PaymentLinkService.UpdateParamsInvoiceCreationInvoiceDataIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- rendering_options: NotRequired[
- "Literal['']|PaymentLinkService.UpdateParamsInvoiceCreationInvoiceDataRenderingOptions"
- ]
- """
- Default options for invoice PDF rendering for this customer.
- """
-
- class UpdateParamsInvoiceCreationInvoiceDataCustomField(TypedDict):
- name: str
- """
- The name of the custom field. This may be up to 40 characters.
- """
- value: str
- """
- The value of the custom field. This may be up to 140 characters.
- """
-
- class UpdateParamsInvoiceCreationInvoiceDataIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class UpdateParamsInvoiceCreationInvoiceDataRenderingOptions(TypedDict):
- amount_tax_display: NotRequired[
- "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
- ]
- """
- How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
- """
- template: NotRequired[str]
- """
- ID of the invoice rendering template to use for this invoice.
- """
-
- class UpdateParamsLineItem(TypedDict):
- adjustable_quantity: NotRequired[
- "PaymentLinkService.UpdateParamsLineItemAdjustableQuantity"
- ]
- """
- When set, provides configuration for this item's quantity to be adjusted by the customer during checkout.
- """
- id: str
- """
- The ID of an existing line item on the payment link.
- """
- quantity: NotRequired[int]
- """
- The quantity of the line item being purchased.
- """
-
- class UpdateParamsLineItemAdjustableQuantity(TypedDict):
- enabled: bool
- """
- Set to true if the quantity can be adjusted to any non-negative Integer.
- """
- maximum: NotRequired[int]
- """
- The maximum quantity the customer can purchase. By default this value is 99. You can specify a value up to 999999.
- """
- minimum: NotRequired[int]
- """
- The minimum quantity the customer can purchase. By default this value is 0. If there is only one item in the cart then that item's quantity cannot go down to 0.
- """
-
- class UpdateParamsPaymentIntentData(TypedDict):
- description: NotRequired["Literal['']|str"]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Payment Intents](https://stripe.com/docs/api/payment_intents) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
- """
- statement_descriptor: NotRequired["Literal['']|str"]
- """
- Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
-
- Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
- """
- statement_descriptor_suffix: NotRequired["Literal['']|str"]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
- """
- transfer_group: NotRequired["Literal['']|str"]
- """
- A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
- """
-
- class UpdateParamsPhoneNumberCollection(TypedDict):
- enabled: bool
- """
- Set to `true` to enable phone number collection.
- """
-
- class UpdateParamsRestrictions(TypedDict):
- completed_sessions: (
- "PaymentLinkService.UpdateParamsRestrictionsCompletedSessions"
- )
- """
- Configuration for the `completed_sessions` restriction type.
- """
-
- class UpdateParamsRestrictionsCompletedSessions(TypedDict):
- limit: int
- """
- The maximum number of checkout sessions that can be completed for the `completed_sessions` restriction to be met.
- """
-
- class UpdateParamsShippingAddressCollection(TypedDict):
- allowed_countries: List[
- Literal[
- "AC",
- "AD",
- "AE",
- "AF",
- "AG",
- "AI",
- "AL",
- "AM",
- "AO",
- "AQ",
- "AR",
- "AT",
- "AU",
- "AW",
- "AX",
- "AZ",
- "BA",
- "BB",
- "BD",
- "BE",
- "BF",
- "BG",
- "BH",
- "BI",
- "BJ",
- "BL",
- "BM",
- "BN",
- "BO",
- "BQ",
- "BR",
- "BS",
- "BT",
- "BV",
- "BW",
- "BY",
- "BZ",
- "CA",
- "CD",
- "CF",
- "CG",
- "CH",
- "CI",
- "CK",
- "CL",
- "CM",
- "CN",
- "CO",
- "CR",
- "CV",
- "CW",
- "CY",
- "CZ",
- "DE",
- "DJ",
- "DK",
- "DM",
- "DO",
- "DZ",
- "EC",
- "EE",
- "EG",
- "EH",
- "ER",
- "ES",
- "ET",
- "FI",
- "FJ",
- "FK",
- "FO",
- "FR",
- "GA",
- "GB",
- "GD",
- "GE",
- "GF",
- "GG",
- "GH",
- "GI",
- "GL",
- "GM",
- "GN",
- "GP",
- "GQ",
- "GR",
- "GS",
- "GT",
- "GU",
- "GW",
- "GY",
- "HK",
- "HN",
- "HR",
- "HT",
- "HU",
- "ID",
- "IE",
- "IL",
- "IM",
- "IN",
- "IO",
- "IQ",
- "IS",
- "IT",
- "JE",
- "JM",
- "JO",
- "JP",
- "KE",
- "KG",
- "KH",
- "KI",
- "KM",
- "KN",
- "KR",
- "KW",
- "KY",
- "KZ",
- "LA",
- "LB",
- "LC",
- "LI",
- "LK",
- "LR",
- "LS",
- "LT",
- "LU",
- "LV",
- "LY",
- "MA",
- "MC",
- "MD",
- "ME",
- "MF",
- "MG",
- "MK",
- "ML",
- "MM",
- "MN",
- "MO",
- "MQ",
- "MR",
- "MS",
- "MT",
- "MU",
- "MV",
- "MW",
- "MX",
- "MY",
- "MZ",
- "NA",
- "NC",
- "NE",
- "NG",
- "NI",
- "NL",
- "NO",
- "NP",
- "NR",
- "NU",
- "NZ",
- "OM",
- "PA",
- "PE",
- "PF",
- "PG",
- "PH",
- "PK",
- "PL",
- "PM",
- "PN",
- "PR",
- "PS",
- "PT",
- "PY",
- "QA",
- "RE",
- "RO",
- "RS",
- "RU",
- "RW",
- "SA",
- "SB",
- "SC",
- "SD",
- "SE",
- "SG",
- "SH",
- "SI",
- "SJ",
- "SK",
- "SL",
- "SM",
- "SN",
- "SO",
- "SR",
- "SS",
- "ST",
- "SV",
- "SX",
- "SZ",
- "TA",
- "TC",
- "TD",
- "TF",
- "TG",
- "TH",
- "TJ",
- "TK",
- "TL",
- "TM",
- "TN",
- "TO",
- "TR",
- "TT",
- "TV",
- "TW",
- "TZ",
- "UA",
- "UG",
- "US",
- "UY",
- "UZ",
- "VA",
- "VC",
- "VE",
- "VG",
- "VN",
- "VU",
- "WF",
- "WS",
- "XK",
- "YE",
- "YT",
- "ZA",
- "ZM",
- "ZW",
- "ZZ",
- ]
- ]
- """
- An array of two-letter ISO country codes representing which countries Checkout should provide as options for
- shipping locations.
- """
-
- class UpdateParamsSubscriptionData(TypedDict):
- invoice_settings: NotRequired[
- "PaymentLinkService.UpdateParamsSubscriptionDataInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Subscriptions](https://stripe.com/docs/api/subscriptions) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
- """
- trial_period_days: NotRequired["Literal['']|int"]
- """
- Integer representing the number of trial period days before the customer is charged for the first time. Has to be at least 1.
- """
- trial_settings: NotRequired[
- "Literal['']|PaymentLinkService.UpdateParamsSubscriptionDataTrialSettings"
- ]
- """
- Settings related to subscription trials.
- """
-
- class UpdateParamsSubscriptionDataInvoiceSettings(TypedDict):
- issuer: NotRequired[
- "PaymentLinkService.UpdateParamsSubscriptionDataInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class UpdateParamsSubscriptionDataInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class UpdateParamsSubscriptionDataTrialSettings(TypedDict):
- end_behavior: "PaymentLinkService.UpdateParamsSubscriptionDataTrialSettingsEndBehavior"
- """
- Defines how the subscription should behave when the user's free trial ends.
- """
-
- class UpdateParamsSubscriptionDataTrialSettingsEndBehavior(TypedDict):
- missing_payment_method: Literal["cancel", "create_invoice", "pause"]
- """
- Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
- """
-
- class UpdateParamsTaxIdCollection(TypedDict):
- enabled: bool
- """
- Enable tax ID collection during checkout. Defaults to `false`.
- """
- required: NotRequired[Literal["if_supported", "never"]]
- """
- Describes whether a tax ID is required during checkout. Defaults to `never`.
- """
-
def list(
self,
- params: Optional["PaymentLinkService.ListParams"] = None,
+ params: Optional["PaymentLinkListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PaymentLink]:
"""
@@ -1889,7 +48,7 @@ def list(
async def list_async(
self,
- params: Optional["PaymentLinkService.ListParams"] = None,
+ params: Optional["PaymentLinkListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PaymentLink]:
"""
@@ -1908,7 +67,7 @@ async def list_async(
def create(
self,
- params: "PaymentLinkService.CreateParams",
+ params: "PaymentLinkCreateParams",
options: Optional[RequestOptions] = None,
) -> PaymentLink:
"""
@@ -1927,7 +86,7 @@ def create(
async def create_async(
self,
- params: "PaymentLinkService.CreateParams",
+ params: "PaymentLinkCreateParams",
options: Optional[RequestOptions] = None,
) -> PaymentLink:
"""
@@ -1947,7 +106,7 @@ async def create_async(
def retrieve(
self,
payment_link: str,
- params: Optional["PaymentLinkService.RetrieveParams"] = None,
+ params: Optional["PaymentLinkRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentLink:
"""
@@ -1969,7 +128,7 @@ def retrieve(
async def retrieve_async(
self,
payment_link: str,
- params: Optional["PaymentLinkService.RetrieveParams"] = None,
+ params: Optional["PaymentLinkRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentLink:
"""
@@ -1991,7 +150,7 @@ async def retrieve_async(
def update(
self,
payment_link: str,
- params: Optional["PaymentLinkService.UpdateParams"] = None,
+ params: Optional["PaymentLinkUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentLink:
"""
@@ -2013,7 +172,7 @@ def update(
async def update_async(
self,
payment_link: str,
- params: Optional["PaymentLinkService.UpdateParams"] = None,
+ params: Optional["PaymentLinkUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentLink:
"""
diff --git a/stripe/_payment_method.py b/stripe/_payment_method.py
index 40c60c7f5..ecca24e78 100644
--- a/stripe/_payment_method.py
+++ b/stripe/_payment_method.py
@@ -4,23 +4,34 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._charge import Charge
from stripe._customer import Customer
from stripe._setup_attempt import SetupAttempt
+ from stripe.params._payment_method_attach_params import (
+ PaymentMethodAttachParams,
+ )
+ from stripe.params._payment_method_create_params import (
+ PaymentMethodCreateParams,
+ )
+ from stripe.params._payment_method_detach_params import (
+ PaymentMethodDetachParams,
+ )
+ from stripe.params._payment_method_list_params import (
+ PaymentMethodListParams,
+ )
+ from stripe.params._payment_method_modify_params import (
+ PaymentMethodModifyParams,
+ )
+ from stripe.params._payment_method_retrieve_params import (
+ PaymentMethodRetrieveParams,
+ )
class PaymentMethod(
@@ -1345,963 +1356,6 @@ class WechatPay(StripeObject):
class Zip(StripeObject):
pass
- class AttachParams(RequestOptions):
- customer: str
- """
- The ID of the customer to which to attach the PaymentMethod.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(RequestOptions):
- acss_debit: NotRequired["PaymentMethod.CreateParamsAcssDebit"]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired["PaymentMethod.CreateParamsAffirm"]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "PaymentMethod.CreateParamsAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired["PaymentMethod.CreateParamsAlipay"]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired["PaymentMethod.CreateParamsAlma"]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired["PaymentMethod.CreateParamsAmazonPay"]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired["PaymentMethod.CreateParamsAuBecsDebit"]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired["PaymentMethod.CreateParamsBacsDebit"]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired["PaymentMethod.CreateParamsBancontact"]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired["PaymentMethod.CreateParamsBillie"]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "PaymentMethod.CreateParamsBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired["PaymentMethod.CreateParamsBlik"]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired["PaymentMethod.CreateParamsBoleto"]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- card: NotRequired["PaymentMethod.CreateParamsCard"]
- """
- If this is a `card` PaymentMethod, this hash contains the user's card details. For backwards compatibility, you can alternatively provide a Stripe token (e.g., for Apple Pay, Amex Express Checkout, or legacy Checkout) into the card hash with format `card: {token: "tok_visa"}`. When providing a card number, you must meet the requirements for [PCI compliance](https://stripe.com/docs/security#validating-pci-compliance). We strongly recommend using Stripe.js instead of interacting with this API directly.
- """
- cashapp: NotRequired["PaymentMethod.CreateParamsCashapp"]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired["PaymentMethod.CreateParamsCrypto"]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer: NotRequired[str]
- """
- The `Customer` to whom the original PaymentMethod is attached.
- """
- customer_balance: NotRequired[
- "PaymentMethod.CreateParamsCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired["PaymentMethod.CreateParamsEps"]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- fpx: NotRequired["PaymentMethod.CreateParamsFpx"]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired["PaymentMethod.CreateParamsGiropay"]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired["PaymentMethod.CreateParamsGrabpay"]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired["PaymentMethod.CreateParamsIdeal"]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "PaymentMethod.CreateParamsInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired["PaymentMethod.CreateParamsKakaoPay"]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired["PaymentMethod.CreateParamsKlarna"]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired["PaymentMethod.CreateParamsKonbini"]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired["PaymentMethod.CreateParamsKrCard"]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired["PaymentMethod.CreateParamsLink"]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired["PaymentMethod.CreateParamsMbWay"]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired["PaymentMethod.CreateParamsMobilepay"]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired["PaymentMethod.CreateParamsMultibanco"]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired["PaymentMethod.CreateParamsNaverPay"]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired["PaymentMethod.CreateParamsNzBankAccount"]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired["PaymentMethod.CreateParamsOxxo"]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired["PaymentMethod.CreateParamsP24"]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired["PaymentMethod.CreateParamsPayByBank"]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired["PaymentMethod.CreateParamsPayco"]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- payment_method: NotRequired[str]
- """
- The PaymentMethod to share.
- """
- paynow: NotRequired["PaymentMethod.CreateParamsPaynow"]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired["PaymentMethod.CreateParamsPaypal"]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired["PaymentMethod.CreateParamsPix"]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired["PaymentMethod.CreateParamsPromptpay"]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired["PaymentMethod.CreateParamsRadarOptions"]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired["PaymentMethod.CreateParamsRevolutPay"]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired["PaymentMethod.CreateParamsSamsungPay"]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired["PaymentMethod.CreateParamsSatispay"]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired["PaymentMethod.CreateParamsSepaDebit"]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired["PaymentMethod.CreateParamsSofort"]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired["PaymentMethod.CreateParamsSwish"]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired["PaymentMethod.CreateParamsTwint"]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: NotRequired[
- Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "card",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired["PaymentMethod.CreateParamsUsBankAccount"]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired["PaymentMethod.CreateParamsWechatPay"]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired["PaymentMethod.CreateParamsZip"]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class CreateParamsAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class CreateParamsAffirm(TypedDict):
- pass
-
- class CreateParamsAfterpayClearpay(TypedDict):
- pass
-
- class CreateParamsAlipay(TypedDict):
- pass
-
- class CreateParamsAlma(TypedDict):
- pass
-
- class CreateParamsAmazonPay(TypedDict):
- pass
-
- class CreateParamsAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class CreateParamsBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class CreateParamsBancontact(TypedDict):
- pass
-
- class CreateParamsBillie(TypedDict):
- pass
-
- class CreateParamsBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|PaymentMethod.CreateParamsBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class CreateParamsBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsBlik(TypedDict):
- pass
-
- class CreateParamsBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class CreateParamsCard(TypedDict):
- cvc: NotRequired[str]
- """
- The card's CVC. It is highly recommended to always include this value.
- """
- exp_month: NotRequired[int]
- """
- Two-digit number representing the card's expiration month.
- """
- exp_year: NotRequired[int]
- """
- Four-digit number representing the card's expiration year.
- """
- networks: NotRequired["PaymentMethod.CreateParamsCardNetworks"]
- """
- Contains information about card networks used to process the payment.
- """
- number: NotRequired[str]
- """
- The card number, as a string without any separators.
- """
- token: NotRequired[str]
- """
- For backwards compatibility, you can alternatively provide a Stripe token (e.g., for Apple Pay, Amex Express Checkout, or legacy Checkout) into the card hash with format card: {token: "tok_visa"}.
- """
-
- class CreateParamsCardNetworks(TypedDict):
- preferred: NotRequired[
- Literal["cartes_bancaires", "mastercard", "visa"]
- ]
- """
- The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
- """
-
- class CreateParamsCashapp(TypedDict):
- pass
-
- class CreateParamsCrypto(TypedDict):
- pass
-
- class CreateParamsCustomerBalance(TypedDict):
- pass
-
- class CreateParamsEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsGiropay(TypedDict):
- pass
-
- class CreateParamsGrabpay(TypedDict):
- pass
-
- class CreateParamsIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class CreateParamsInteracPresent(TypedDict):
- pass
-
- class CreateParamsKakaoPay(TypedDict):
- pass
-
- class CreateParamsKlarna(TypedDict):
- dob: NotRequired["PaymentMethod.CreateParamsKlarnaDob"]
- """
- Customer's date of birth
- """
-
- class CreateParamsKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsKonbini(TypedDict):
- pass
-
- class CreateParamsKrCard(TypedDict):
- pass
-
- class CreateParamsLink(TypedDict):
- pass
-
- class CreateParamsMbWay(TypedDict):
- pass
-
- class CreateParamsMobilepay(TypedDict):
- pass
-
- class CreateParamsMultibanco(TypedDict):
- pass
-
- class CreateParamsNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class CreateParamsNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class CreateParamsOxxo(TypedDict):
- pass
-
- class CreateParamsP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPayByBank(TypedDict):
- pass
-
- class CreateParamsPayco(TypedDict):
- pass
-
- class CreateParamsPaynow(TypedDict):
- pass
-
- class CreateParamsPaypal(TypedDict):
- pass
-
- class CreateParamsPix(TypedDict):
- pass
-
- class CreateParamsPromptpay(TypedDict):
- pass
-
- class CreateParamsRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class CreateParamsRevolutPay(TypedDict):
- pass
-
- class CreateParamsSamsungPay(TypedDict):
- pass
-
- class CreateParamsSatispay(TypedDict):
- pass
-
- class CreateParamsSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class CreateParamsSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class CreateParamsSwish(TypedDict):
- pass
-
- class CreateParamsTwint(TypedDict):
- pass
-
- class CreateParamsUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class CreateParamsWechatPay(TypedDict):
- pass
-
- class CreateParamsZip(TypedDict):
- pass
-
- class DetachParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(RequestOptions):
- customer: NotRequired[str]
- """
- The ID of the customer whose PaymentMethods will be retrieved.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[
- Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "card",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- ]
- """
- An optional filter on the list, based on the object `type` field. Without the filter, the list includes all current and future payment method types. If your integration expects only one type of payment method in the response, make sure to provide a type value in the request.
- """
-
- class ModifyParams(RequestOptions):
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- billing_details: NotRequired[
- "PaymentMethod.ModifyParamsBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- card: NotRequired["PaymentMethod.ModifyParamsCard"]
- """
- If this is a `card` PaymentMethod, this hash contains the user's card details.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- us_bank_account: NotRequired["PaymentMethod.ModifyParamsUsBankAccount"]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
-
- class ModifyParamsBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|PaymentMethod.ModifyParamsBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class ModifyParamsBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ModifyParamsCard(TypedDict):
- exp_month: NotRequired[int]
- """
- Two-digit number representing the card's expiration month.
- """
- exp_year: NotRequired[int]
- """
- Four-digit number representing the card's expiration year.
- """
- networks: NotRequired["PaymentMethod.ModifyParamsCardNetworks"]
- """
- Contains information about card networks used to process the payment.
- """
-
- class ModifyParamsCardNetworks(TypedDict):
- preferred: NotRequired[
- "Literal['']|Literal['cartes_bancaires', 'mastercard', 'visa']"
- ]
- """
- The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
- """
-
- class ModifyParamsUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Bank account holder type.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Bank account type.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
acss_debit: Optional[AcssDebit]
affirm: Optional[Affirm]
afterpay_clearpay: Optional[AfterpayClearpay]
@@ -2445,9 +1499,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def _cls_attach(
- cls,
- payment_method: str,
- **params: Unpack["PaymentMethod.AttachParams"],
+ cls, payment_method: str, **params: Unpack["PaymentMethodAttachParams"]
) -> "PaymentMethod":
"""
Attaches a PaymentMethod object to a Customer.
@@ -2478,7 +1530,7 @@ def _cls_attach(
@overload
@staticmethod
def attach(
- payment_method: str, **params: Unpack["PaymentMethod.AttachParams"]
+ payment_method: str, **params: Unpack["PaymentMethodAttachParams"]
) -> "PaymentMethod":
"""
Attaches a PaymentMethod object to a Customer.
@@ -2499,7 +1551,7 @@ def attach(
@overload
def attach(
- self, **params: Unpack["PaymentMethod.AttachParams"]
+ self, **params: Unpack["PaymentMethodAttachParams"]
) -> "PaymentMethod":
"""
Attaches a PaymentMethod object to a Customer.
@@ -2520,7 +1572,7 @@ def attach(
@class_method_variant("_cls_attach")
def attach( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentMethod.AttachParams"]
+ self, **params: Unpack["PaymentMethodAttachParams"]
) -> "PaymentMethod":
"""
Attaches a PaymentMethod object to a Customer.
@@ -2550,9 +1602,7 @@ def attach( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_attach_async(
- cls,
- payment_method: str,
- **params: Unpack["PaymentMethod.AttachParams"],
+ cls, payment_method: str, **params: Unpack["PaymentMethodAttachParams"]
) -> "PaymentMethod":
"""
Attaches a PaymentMethod object to a Customer.
@@ -2583,7 +1633,7 @@ async def _cls_attach_async(
@overload
@staticmethod
async def attach_async(
- payment_method: str, **params: Unpack["PaymentMethod.AttachParams"]
+ payment_method: str, **params: Unpack["PaymentMethodAttachParams"]
) -> "PaymentMethod":
"""
Attaches a PaymentMethod object to a Customer.
@@ -2604,7 +1654,7 @@ async def attach_async(
@overload
async def attach_async(
- self, **params: Unpack["PaymentMethod.AttachParams"]
+ self, **params: Unpack["PaymentMethodAttachParams"]
) -> "PaymentMethod":
"""
Attaches a PaymentMethod object to a Customer.
@@ -2625,7 +1675,7 @@ async def attach_async(
@class_method_variant("_cls_attach_async")
async def attach_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentMethod.AttachParams"]
+ self, **params: Unpack["PaymentMethodAttachParams"]
) -> "PaymentMethod":
"""
Attaches a PaymentMethod object to a Customer.
@@ -2655,7 +1705,7 @@ async def attach_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def create(
- cls, **params: Unpack["PaymentMethod.CreateParams"]
+ cls, **params: Unpack["PaymentMethodCreateParams"]
) -> "PaymentMethod":
"""
Creates a PaymentMethod object. Read the [Stripe.js reference](https://docs.stripe.com/docs/stripe-js/reference#stripe-create-payment-method) to learn how to create PaymentMethods via Stripe.js.
@@ -2673,7 +1723,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["PaymentMethod.CreateParams"]
+ cls, **params: Unpack["PaymentMethodCreateParams"]
) -> "PaymentMethod":
"""
Creates a PaymentMethod object. Read the [Stripe.js reference](https://docs.stripe.com/docs/stripe-js/reference#stripe-create-payment-method) to learn how to create PaymentMethods via Stripe.js.
@@ -2691,9 +1741,7 @@ async def create_async(
@classmethod
def _cls_detach(
- cls,
- payment_method: str,
- **params: Unpack["PaymentMethod.DetachParams"],
+ cls, payment_method: str, **params: Unpack["PaymentMethodDetachParams"]
) -> "PaymentMethod":
"""
Detaches a PaymentMethod object from a Customer. After a PaymentMethod is detached, it can no longer be used for a payment or re-attached to a Customer.
@@ -2712,7 +1760,7 @@ def _cls_detach(
@overload
@staticmethod
def detach(
- payment_method: str, **params: Unpack["PaymentMethod.DetachParams"]
+ payment_method: str, **params: Unpack["PaymentMethodDetachParams"]
) -> "PaymentMethod":
"""
Detaches a PaymentMethod object from a Customer. After a PaymentMethod is detached, it can no longer be used for a payment or re-attached to a Customer.
@@ -2721,7 +1769,7 @@ def detach(
@overload
def detach(
- self, **params: Unpack["PaymentMethod.DetachParams"]
+ self, **params: Unpack["PaymentMethodDetachParams"]
) -> "PaymentMethod":
"""
Detaches a PaymentMethod object from a Customer. After a PaymentMethod is detached, it can no longer be used for a payment or re-attached to a Customer.
@@ -2730,7 +1778,7 @@ def detach(
@class_method_variant("_cls_detach")
def detach( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentMethod.DetachParams"]
+ self, **params: Unpack["PaymentMethodDetachParams"]
) -> "PaymentMethod":
"""
Detaches a PaymentMethod object from a Customer. After a PaymentMethod is detached, it can no longer be used for a payment or re-attached to a Customer.
@@ -2748,9 +1796,7 @@ def detach( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_detach_async(
- cls,
- payment_method: str,
- **params: Unpack["PaymentMethod.DetachParams"],
+ cls, payment_method: str, **params: Unpack["PaymentMethodDetachParams"]
) -> "PaymentMethod":
"""
Detaches a PaymentMethod object from a Customer. After a PaymentMethod is detached, it can no longer be used for a payment or re-attached to a Customer.
@@ -2769,7 +1815,7 @@ async def _cls_detach_async(
@overload
@staticmethod
async def detach_async(
- payment_method: str, **params: Unpack["PaymentMethod.DetachParams"]
+ payment_method: str, **params: Unpack["PaymentMethodDetachParams"]
) -> "PaymentMethod":
"""
Detaches a PaymentMethod object from a Customer. After a PaymentMethod is detached, it can no longer be used for a payment or re-attached to a Customer.
@@ -2778,7 +1824,7 @@ async def detach_async(
@overload
async def detach_async(
- self, **params: Unpack["PaymentMethod.DetachParams"]
+ self, **params: Unpack["PaymentMethodDetachParams"]
) -> "PaymentMethod":
"""
Detaches a PaymentMethod object from a Customer. After a PaymentMethod is detached, it can no longer be used for a payment or re-attached to a Customer.
@@ -2787,7 +1833,7 @@ async def detach_async(
@class_method_variant("_cls_detach_async")
async def detach_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentMethod.DetachParams"]
+ self, **params: Unpack["PaymentMethodDetachParams"]
) -> "PaymentMethod":
"""
Detaches a PaymentMethod object from a Customer. After a PaymentMethod is detached, it can no longer be used for a payment or re-attached to a Customer.
@@ -2805,7 +1851,7 @@ async def detach_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["PaymentMethod.ListParams"]
+ cls, **params: Unpack["PaymentMethodListParams"]
) -> ListObject["PaymentMethod"]:
"""
Returns a list of PaymentMethods for Treasury flows. If you want to list the PaymentMethods attached to a Customer for payments, you should use the [List a Customer's PaymentMethods](https://docs.stripe.com/docs/api/payment_methods/customer_list) API instead.
@@ -2825,7 +1871,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["PaymentMethod.ListParams"]
+ cls, **params: Unpack["PaymentMethodListParams"]
) -> ListObject["PaymentMethod"]:
"""
Returns a list of PaymentMethods for Treasury flows. If you want to list the PaymentMethods attached to a Customer for payments, you should use the [List a Customer's PaymentMethods](https://docs.stripe.com/docs/api/payment_methods/customer_list) API instead.
@@ -2845,7 +1891,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["PaymentMethod.ModifyParams"]
+ cls, id: str, **params: Unpack["PaymentMethodModifyParams"]
) -> "PaymentMethod":
"""
Updates a PaymentMethod object. A PaymentMethod must be attached to a customer to be updated.
@@ -2862,7 +1908,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["PaymentMethod.ModifyParams"]
+ cls, id: str, **params: Unpack["PaymentMethodModifyParams"]
) -> "PaymentMethod":
"""
Updates a PaymentMethod object. A PaymentMethod must be attached to a customer to be updated.
@@ -2879,7 +1925,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["PaymentMethod.RetrieveParams"]
+ cls, id: str, **params: Unpack["PaymentMethodRetrieveParams"]
) -> "PaymentMethod":
"""
Retrieves a PaymentMethod object attached to the StripeAccount. To retrieve a payment method attached to a Customer, you should use [Retrieve a Customer's PaymentMethods](https://docs.stripe.com/docs/api/payment_methods/customer)
@@ -2890,7 +1936,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["PaymentMethod.RetrieveParams"]
+ cls, id: str, **params: Unpack["PaymentMethodRetrieveParams"]
) -> "PaymentMethod":
"""
Retrieves a PaymentMethod object attached to the StripeAccount. To retrieve a payment method attached to a Customer, you should use [Retrieve a Customer's PaymentMethods](https://docs.stripe.com/docs/api/payment_methods/customer)
diff --git a/stripe/_payment_method_configuration.py b/stripe/_payment_method_configuration.py
index bf1aeb85d..6e9b94f23 100644
--- a/stripe/_payment_method_configuration.py
+++ b/stripe/_payment_method_configuration.py
@@ -3,12 +3,25 @@
from stripe._createable_api_resource import CreateableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import sanitize_id
-from typing import ClassVar, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing import ClassVar, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._payment_method_configuration_create_params import (
+ PaymentMethodConfigurationCreateParams,
+ )
+ from stripe.params._payment_method_configuration_list_params import (
+ PaymentMethodConfigurationListParams,
+ )
+ from stripe.params._payment_method_configuration_modify_params import (
+ PaymentMethodConfigurationModifyParams,
+ )
+ from stripe.params._payment_method_configuration_retrieve_params import (
+ PaymentMethodConfigurationRetrieveParams,
+ )
class PaymentMethodConfiguration(
@@ -1159,2070 +1172,6 @@ class DisplayPreference(StripeObject):
display_preference: DisplayPreference
_inner_class_types = {"display_preference": DisplayPreference}
- class CreateParams(RequestOptions):
- acss_debit: NotRequired[
- "PaymentMethodConfiguration.CreateParamsAcssDebit"
- ]
- """
- Canadian pre-authorized debit payments, check this [page](https://stripe.com/docs/payments/acss-debit) for more details like country availability.
- """
- affirm: NotRequired["PaymentMethodConfiguration.CreateParamsAffirm"]
- """
- [Affirm](https://www.affirm.com/) gives your customers a way to split purchases over a series of payments. Depending on the purchase, they can pay with four interest-free payments (Split Pay) or pay over a longer term (Installments), which might include interest. Check this [page](https://stripe.com/docs/payments/affirm) for more details like country availability.
- """
- afterpay_clearpay: NotRequired[
- "PaymentMethodConfiguration.CreateParamsAfterpayClearpay"
- ]
- """
- Afterpay gives your customers a way to pay for purchases in installments, check this [page](https://stripe.com/docs/payments/afterpay-clearpay) for more details like country availability. Afterpay is particularly popular among businesses selling fashion, beauty, and sports products.
- """
- alipay: NotRequired["PaymentMethodConfiguration.CreateParamsAlipay"]
- """
- Alipay is a digital wallet in China that has more than a billion active users worldwide. Alipay users can pay on the web or on a mobile device using login credentials or their Alipay app. Alipay has a low dispute rate and reduces fraud by authenticating payments using the customer's login credentials. Check this [page](https://stripe.com/docs/payments/alipay) for more details.
- """
- alma: NotRequired["PaymentMethodConfiguration.CreateParamsAlma"]
- """
- Alma is a Buy Now, Pay Later payment method that offers customers the ability to pay in 2, 3, or 4 installments.
- """
- amazon_pay: NotRequired[
- "PaymentMethodConfiguration.CreateParamsAmazonPay"
- ]
- """
- Amazon Pay is a wallet payment method that lets your customers check out the same way as on Amazon.
- """
- apple_pay: NotRequired[
- "PaymentMethodConfiguration.CreateParamsApplePay"
- ]
- """
- Stripe users can accept [Apple Pay](https://stripe.com/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. There are no additional fees to process Apple Pay payments, and the [pricing](https://stripe.com/pricing) is the same as other card transactions. Check this [page](https://stripe.com/docs/apple-pay) for more details.
- """
- apple_pay_later: NotRequired[
- "PaymentMethodConfiguration.CreateParamsApplePayLater"
- ]
- """
- Apple Pay Later, a payment method for customers to buy now and pay later, gives your customers a way to split purchases into four installments across six weeks.
- """
- au_becs_debit: NotRequired[
- "PaymentMethodConfiguration.CreateParamsAuBecsDebit"
- ]
- """
- Stripe users in Australia can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with an Australian bank account. Check this [page](https://stripe.com/docs/payments/au-becs-debit) for more details.
- """
- bacs_debit: NotRequired[
- "PaymentMethodConfiguration.CreateParamsBacsDebit"
- ]
- """
- Stripe users in the UK can accept Bacs Direct Debit payments from customers with a UK bank account, check this [page](https://stripe.com/docs/payments/payment-methods/bacs-debit) for more details.
- """
- bancontact: NotRequired[
- "PaymentMethodConfiguration.CreateParamsBancontact"
- ]
- """
- Bancontact is the most popular online payment method in Belgium, with over 15 million cards in circulation. [Customers](https://stripe.com/docs/api/customers) use a Bancontact card or mobile app linked to a Belgian bank account to make online payments that are secure, guaranteed, and confirmed immediately. Check this [page](https://stripe.com/docs/payments/bancontact) for more details.
- """
- billie: NotRequired["PaymentMethodConfiguration.CreateParamsBillie"]
- """
- Billie is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method that offers businesses Pay by Invoice where they offer payment terms ranging from 7-120 days. Customers are redirected from your website or app, authorize the payment with Billie, then return to your website or app. You get [immediate notification](https://docs.stripe.com/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
- """
- blik: NotRequired["PaymentMethodConfiguration.CreateParamsBlik"]
- """
- BLIK is a [single use](https://stripe.com/docs/payments/payment-methods#usage) payment method that requires customers to authenticate their payments. When customers want to pay online using BLIK, they request a six-digit code from their banking application and enter it into the payment collection form. Check this [page](https://stripe.com/docs/payments/blik) for more details.
- """
- boleto: NotRequired["PaymentMethodConfiguration.CreateParamsBoleto"]
- """
- Boleto is an official (regulated by the Central Bank of Brazil) payment method in Brazil. Check this [page](https://stripe.com/docs/payments/boleto) for more details.
- """
- card: NotRequired["PaymentMethodConfiguration.CreateParamsCard"]
- """
- Cards are a popular way for consumers and businesses to pay online or in person. Stripe supports global and local card networks.
- """
- cartes_bancaires: NotRequired[
- "PaymentMethodConfiguration.CreateParamsCartesBancaires"
- ]
- """
- Cartes Bancaires is France's local card network. More than 95% of these cards are co-branded with either Visa or Mastercard, meaning you can process these cards over either Cartes Bancaires or the Visa or Mastercard networks. Check this [page](https://stripe.com/docs/payments/cartes-bancaires) for more details.
- """
- cashapp: NotRequired["PaymentMethodConfiguration.CreateParamsCashapp"]
- """
- Cash App is a popular consumer app in the US that allows customers to bank, invest, send, and receive money using their digital wallet. Check this [page](https://stripe.com/docs/payments/cash-app-pay) for more details.
- """
- customer_balance: NotRequired[
- "PaymentMethodConfiguration.CreateParamsCustomerBalance"
- ]
- """
- Uses a customer's [cash balance](https://stripe.com/docs/payments/customer-balance) for the payment. The cash balance can be funded via a bank transfer. Check this [page](https://stripe.com/docs/payments/bank-transfers) for more details.
- """
- eps: NotRequired["PaymentMethodConfiguration.CreateParamsEps"]
- """
- EPS is an Austria-based payment method that allows customers to complete transactions online using their bank credentials. EPS is supported by all Austrian banks and is accepted by over 80% of Austrian online retailers. Check this [page](https://stripe.com/docs/payments/eps) for more details.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- fpx: NotRequired["PaymentMethodConfiguration.CreateParamsFpx"]
- """
- Financial Process Exchange (FPX) is a Malaysia-based payment method that allows customers to complete transactions online using their bank credentials. Bank Negara Malaysia (BNM), the Central Bank of Malaysia, and eleven other major Malaysian financial institutions are members of the PayNet Group, which owns and operates FPX. It is one of the most popular online payment methods in Malaysia, with nearly 90 million transactions in 2018 according to BNM. Check this [page](https://stripe.com/docs/payments/fpx) for more details.
- """
- fr_meal_voucher_conecs: NotRequired[
- "PaymentMethodConfiguration.CreateParamsFrMealVoucherConecs"
- ]
- """
- Meal vouchers in France, or “titres-restaurant”, is a local benefits program commonly offered by employers for their employees to purchase prepared food and beverages on working days. Check this [page](https://stripe.com/docs/payments/benefits/fr-meal-vouchers) for more details.
- """
- giropay: NotRequired["PaymentMethodConfiguration.CreateParamsGiropay"]
- """
- giropay is a German payment method based on online banking, introduced in 2006. It allows customers to complete transactions online using their online banking environment, with funds debited from their bank account. Depending on their bank, customers confirm payments on giropay using a second factor of authentication or a PIN. giropay accounts for 10% of online checkouts in Germany. Check this [page](https://stripe.com/docs/payments/giropay) for more details.
- """
- google_pay: NotRequired[
- "PaymentMethodConfiguration.CreateParamsGooglePay"
- ]
- """
- Google Pay allows customers to make payments in your app or website using any credit or debit card saved to their Google Account, including those from Google Play, YouTube, Chrome, or an Android device. Use the Google Pay API to request any credit or debit card stored in your customer's Google account. Check this [page](https://stripe.com/docs/google-pay) for more details.
- """
- grabpay: NotRequired["PaymentMethodConfiguration.CreateParamsGrabpay"]
- """
- GrabPay is a payment method developed by [Grab](https://www.grab.com/sg/consumer/finance/pay/). GrabPay is a digital wallet - customers maintain a balance in their wallets that they pay out with. Check this [page](https://stripe.com/docs/payments/grabpay) for more details.
- """
- ideal: NotRequired["PaymentMethodConfiguration.CreateParamsIdeal"]
- """
- iDEAL is a Netherlands-based payment method that allows customers to complete transactions online using their bank credentials. All major Dutch banks are members of Currence, the scheme that operates iDEAL, making it the most popular online payment method in the Netherlands with a share of online transactions close to 55%. Check this [page](https://stripe.com/docs/payments/ideal) for more details.
- """
- jcb: NotRequired["PaymentMethodConfiguration.CreateParamsJcb"]
- """
- JCB is a credit card company based in Japan. JCB is currently available in Japan to businesses approved by JCB, and available to all businesses in Australia, Canada, Hong Kong, Japan, New Zealand, Singapore, Switzerland, United Kingdom, United States, and all countries in the European Economic Area except Iceland. Check this [page](https://support.stripe.com/questions/accepting-japan-credit-bureau-%28jcb%29-payments) for more details.
- """
- kakao_pay: NotRequired[
- "PaymentMethodConfiguration.CreateParamsKakaoPay"
- ]
- """
- Kakao Pay is a popular local wallet available in South Korea.
- """
- klarna: NotRequired["PaymentMethodConfiguration.CreateParamsKlarna"]
- """
- Klarna gives customers a range of [payment options](https://stripe.com/docs/payments/klarna#payment-options) during checkout. Available payment options vary depending on the customer's billing address and the transaction amount. These payment options make it convenient for customers to purchase items in all price ranges. Check this [page](https://stripe.com/docs/payments/klarna) for more details.
- """
- konbini: NotRequired["PaymentMethodConfiguration.CreateParamsKonbini"]
- """
- Konbini allows customers in Japan to pay for bills and online purchases at convenience stores with cash. Check this [page](https://stripe.com/docs/payments/konbini) for more details.
- """
- kr_card: NotRequired["PaymentMethodConfiguration.CreateParamsKrCard"]
- """
- Korean cards let users pay using locally issued cards from South Korea.
- """
- link: NotRequired["PaymentMethodConfiguration.CreateParamsLink"]
- """
- [Link](https://stripe.com/docs/payments/link) is a payment method network. With Link, users save their payment details once, then reuse that information to pay with one click for any business on the network.
- """
- mobilepay: NotRequired[
- "PaymentMethodConfiguration.CreateParamsMobilepay"
- ]
- """
- MobilePay is a [single-use](https://stripe.com/docs/payments/payment-methods#usage) card wallet payment method used in Denmark and Finland. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the MobilePay app. Check this [page](https://stripe.com/docs/payments/mobilepay) for more details.
- """
- multibanco: NotRequired[
- "PaymentMethodConfiguration.CreateParamsMultibanco"
- ]
- """
- Stripe users in Europe and the United States can accept Multibanco payments from customers in Portugal using [Sources](https://stripe.com/docs/sources)—a single integration path for creating payments using any supported method.
- """
- name: NotRequired[str]
- """
- Configuration name.
- """
- naver_pay: NotRequired[
- "PaymentMethodConfiguration.CreateParamsNaverPay"
- ]
- """
- Naver Pay is a popular local wallet available in South Korea.
- """
- nz_bank_account: NotRequired[
- "PaymentMethodConfiguration.CreateParamsNzBankAccount"
- ]
- """
- Stripe users in New Zealand can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with a New Zeland bank account. Check this [page](https://stripe.com/docs/payments/nz-bank-account) for more details.
- """
- oxxo: NotRequired["PaymentMethodConfiguration.CreateParamsOxxo"]
- """
- OXXO is a Mexican chain of convenience stores with thousands of locations across Latin America and represents nearly 20% of online transactions in Mexico. OXXO allows customers to pay bills and online purchases in-store with cash. Check this [page](https://stripe.com/docs/payments/oxxo) for more details.
- """
- p24: NotRequired["PaymentMethodConfiguration.CreateParamsP24"]
- """
- Przelewy24 is a Poland-based payment method aggregator that allows customers to complete transactions online using bank transfers and other methods. Bank transfers account for 30% of online payments in Poland and Przelewy24 provides a way for customers to pay with over 165 banks. Check this [page](https://stripe.com/docs/payments/p24) for more details.
- """
- parent: NotRequired[str]
- """
- Configuration's parent configuration. Specify to create a child configuration.
- """
- pay_by_bank: NotRequired[
- "PaymentMethodConfiguration.CreateParamsPayByBank"
- ]
- """
- Pay by bank is a redirect payment method backed by bank transfers. A customer is redirected to their bank to authorize a bank transfer for a given amount. This removes a lot of the error risks inherent in waiting for the customer to initiate a transfer themselves, and is less expensive than card payments.
- """
- payco: NotRequired["PaymentMethodConfiguration.CreateParamsPayco"]
- """
- PAYCO is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
- """
- paynow: NotRequired["PaymentMethodConfiguration.CreateParamsPaynow"]
- """
- PayNow is a Singapore-based payment method that allows customers to make a payment using their preferred app from participating banks and participating non-bank financial institutions. Check this [page](https://stripe.com/docs/payments/paynow) for more details.
- """
- paypal: NotRequired["PaymentMethodConfiguration.CreateParamsPaypal"]
- """
- PayPal, a digital wallet popular with customers in Europe, allows your customers worldwide to pay using their PayPal account. Check this [page](https://stripe.com/docs/payments/paypal) for more details.
- """
- pix: NotRequired["PaymentMethodConfiguration.CreateParamsPix"]
- """
- Pix is a payment method popular in Brazil. When paying with Pix, customers authenticate and approve payments by scanning a QR code in their preferred banking app. Check this [page](https://docs.stripe.com/payments/pix) for more details.
- """
- promptpay: NotRequired[
- "PaymentMethodConfiguration.CreateParamsPromptpay"
- ]
- """
- PromptPay is a Thailand-based payment method that allows customers to make a payment using their preferred app from participating banks. Check this [page](https://stripe.com/docs/payments/promptpay) for more details.
- """
- revolut_pay: NotRequired[
- "PaymentMethodConfiguration.CreateParamsRevolutPay"
- ]
- """
- Revolut Pay, developed by Revolut, a global finance app, is a digital wallet payment method. Revolut Pay uses the customer's stored balance or cards to fund the payment, and offers the option for non-Revolut customers to save their details after their first purchase.
- """
- samsung_pay: NotRequired[
- "PaymentMethodConfiguration.CreateParamsSamsungPay"
- ]
- """
- Samsung Pay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
- """
- satispay: NotRequired[
- "PaymentMethodConfiguration.CreateParamsSatispay"
- ]
- """
- Satispay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method where customers are required to [authenticate](https://docs.stripe.com/payments/payment-methods#customer-actions) their payment. Customers pay by being redirected from your website or app, authorizing the payment with Satispay, then returning to your website or app. You get [immediate notification](https://docs.stripe.com/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
- """
- sepa_debit: NotRequired[
- "PaymentMethodConfiguration.CreateParamsSepaDebit"
- ]
- """
- The [Single Euro Payments Area (SEPA)](https://en.wikipedia.org/wiki/Single_Euro_Payments_Area) is an initiative of the European Union to simplify payments within and across member countries. SEPA established and enforced banking standards to allow for the direct debiting of every EUR-denominated bank account within the SEPA region, check this [page](https://stripe.com/docs/payments/sepa-debit) for more details.
- """
- sofort: NotRequired["PaymentMethodConfiguration.CreateParamsSofort"]
- """
- Stripe users in Europe and the United States can use the [Payment Intents API](https://stripe.com/docs/payments/payment-intents)—a single integration path for creating payments using any supported method—to accept [Sofort](https://www.sofort.com/) payments from customers. Check this [page](https://stripe.com/docs/payments/sofort) for more details.
- """
- swish: NotRequired["PaymentMethodConfiguration.CreateParamsSwish"]
- """
- Swish is a [real-time](https://stripe.com/docs/payments/real-time) payment method popular in Sweden. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the Swish mobile app and the Swedish BankID mobile app. Check this [page](https://stripe.com/docs/payments/swish) for more details.
- """
- twint: NotRequired["PaymentMethodConfiguration.CreateParamsTwint"]
- """
- Twint is a payment method popular in Switzerland. It allows customers to pay using their mobile phone. Check this [page](https://docs.stripe.com/payments/twint) for more details.
- """
- us_bank_account: NotRequired[
- "PaymentMethodConfiguration.CreateParamsUsBankAccount"
- ]
- """
- Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check this [page](https://stripe.com/docs/payments/ach-direct-debit) for more details.
- """
- wechat_pay: NotRequired[
- "PaymentMethodConfiguration.CreateParamsWechatPay"
- ]
- """
- WeChat, owned by Tencent, is China's leading mobile app with over 1 billion monthly active users. Chinese consumers can use WeChat Pay to pay for goods and services inside of businesses' apps and websites. WeChat Pay users buy most frequently in gaming, e-commerce, travel, online education, and food/nutrition. Check this [page](https://stripe.com/docs/payments/wechat-pay) for more details.
- """
- zip: NotRequired["PaymentMethodConfiguration.CreateParamsZip"]
- """
- Zip gives your customers a way to split purchases over a series of payments. Check this [page](https://stripe.com/docs/payments/zip) for more details like country availability.
- """
-
- class CreateParamsAcssDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsAcssDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsAcssDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsAffirm(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsAffirmDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsAffirmDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsAfterpayClearpay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsAfterpayClearpayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsAfterpayClearpayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsAlipay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsAlipayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsAlipayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsAlma(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsAlmaDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsAlmaDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsAmazonPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsAmazonPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsAmazonPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsApplePay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsApplePayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsApplePayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsApplePayLater(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsApplePayLaterDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsApplePayLaterDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsAuBecsDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsAuBecsDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsAuBecsDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsBacsDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsBacsDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsBacsDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsBancontact(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsBancontactDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsBancontactDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsBillie(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsBillieDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsBillieDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsBlik(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsBlikDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsBlikDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsBoleto(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsBoletoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsBoletoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsCard(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsCardDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsCardDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsCartesBancaires(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsCartesBancairesDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsCartesBancairesDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsCashapp(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsCashappDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsCashappDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsCustomerBalance(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsCustomerBalanceDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsCustomerBalanceDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsEps(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsEpsDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsEpsDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsFpx(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsFpxDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsFpxDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsFrMealVoucherConecs(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsFrMealVoucherConecsDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsFrMealVoucherConecsDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsGiropay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsGiropayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsGiropayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsGooglePay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsGooglePayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsGooglePayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsGrabpay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsGrabpayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsGrabpayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsIdeal(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsIdealDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsIdealDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsJcb(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsJcbDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsJcbDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsKakaoPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsKakaoPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsKakaoPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsKlarna(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsKlarnaDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsKlarnaDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsKonbini(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsKonbiniDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsKonbiniDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsKrCard(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsKrCardDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsKrCardDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsLink(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsLinkDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsLinkDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsMobilepay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsMobilepayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsMobilepayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsMultibanco(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsMultibancoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsMultibancoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsNaverPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsNaverPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsNaverPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsNzBankAccount(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsNzBankAccountDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsNzBankAccountDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsOxxo(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsOxxoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsOxxoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsP24(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsP24DisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsP24DisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsPayByBank(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsPayByBankDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsPayByBankDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsPayco(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsPaycoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsPaycoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsPaynow(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsPaynowDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsPaynowDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsPaypal(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsPaypalDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsPaypalDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsPix(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsPixDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsPixDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsPromptpay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsPromptpayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsPromptpayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsRevolutPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsRevolutPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsRevolutPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsSamsungPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsSamsungPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsSamsungPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsSatispay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsSatispayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsSatispayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsSepaDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsSepaDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsSepaDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsSofort(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsSofortDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsSofortDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsSwish(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsSwishDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsSwishDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsTwint(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsTwintDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsTwintDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsUsBankAccount(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsUsBankAccountDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsUsBankAccountDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsWechatPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsWechatPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsWechatPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsZip(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.CreateParamsZipDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsZipDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ListParams(RequestOptions):
- application: NotRequired["Literal['']|str"]
- """
- The Connect application to filter by.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ModifyParams(RequestOptions):
- acss_debit: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsAcssDebit"
- ]
- """
- Canadian pre-authorized debit payments, check this [page](https://stripe.com/docs/payments/acss-debit) for more details like country availability.
- """
- active: NotRequired[bool]
- """
- Whether the configuration can be used for new payments.
- """
- affirm: NotRequired["PaymentMethodConfiguration.ModifyParamsAffirm"]
- """
- [Affirm](https://www.affirm.com/) gives your customers a way to split purchases over a series of payments. Depending on the purchase, they can pay with four interest-free payments (Split Pay) or pay over a longer term (Installments), which might include interest. Check this [page](https://stripe.com/docs/payments/affirm) for more details like country availability.
- """
- afterpay_clearpay: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsAfterpayClearpay"
- ]
- """
- Afterpay gives your customers a way to pay for purchases in installments, check this [page](https://stripe.com/docs/payments/afterpay-clearpay) for more details like country availability. Afterpay is particularly popular among businesses selling fashion, beauty, and sports products.
- """
- alipay: NotRequired["PaymentMethodConfiguration.ModifyParamsAlipay"]
- """
- Alipay is a digital wallet in China that has more than a billion active users worldwide. Alipay users can pay on the web or on a mobile device using login credentials or their Alipay app. Alipay has a low dispute rate and reduces fraud by authenticating payments using the customer's login credentials. Check this [page](https://stripe.com/docs/payments/alipay) for more details.
- """
- alma: NotRequired["PaymentMethodConfiguration.ModifyParamsAlma"]
- """
- Alma is a Buy Now, Pay Later payment method that offers customers the ability to pay in 2, 3, or 4 installments.
- """
- amazon_pay: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsAmazonPay"
- ]
- """
- Amazon Pay is a wallet payment method that lets your customers check out the same way as on Amazon.
- """
- apple_pay: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsApplePay"
- ]
- """
- Stripe users can accept [Apple Pay](https://stripe.com/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. There are no additional fees to process Apple Pay payments, and the [pricing](https://stripe.com/pricing) is the same as other card transactions. Check this [page](https://stripe.com/docs/apple-pay) for more details.
- """
- apple_pay_later: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsApplePayLater"
- ]
- """
- Apple Pay Later, a payment method for customers to buy now and pay later, gives your customers a way to split purchases into four installments across six weeks.
- """
- au_becs_debit: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsAuBecsDebit"
- ]
- """
- Stripe users in Australia can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with an Australian bank account. Check this [page](https://stripe.com/docs/payments/au-becs-debit) for more details.
- """
- bacs_debit: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsBacsDebit"
- ]
- """
- Stripe users in the UK can accept Bacs Direct Debit payments from customers with a UK bank account, check this [page](https://stripe.com/docs/payments/payment-methods/bacs-debit) for more details.
- """
- bancontact: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsBancontact"
- ]
- """
- Bancontact is the most popular online payment method in Belgium, with over 15 million cards in circulation. [Customers](https://stripe.com/docs/api/customers) use a Bancontact card or mobile app linked to a Belgian bank account to make online payments that are secure, guaranteed, and confirmed immediately. Check this [page](https://stripe.com/docs/payments/bancontact) for more details.
- """
- billie: NotRequired["PaymentMethodConfiguration.ModifyParamsBillie"]
- """
- Billie is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method that offers businesses Pay by Invoice where they offer payment terms ranging from 7-120 days. Customers are redirected from your website or app, authorize the payment with Billie, then return to your website or app. You get [immediate notification](https://docs.stripe.com/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
- """
- blik: NotRequired["PaymentMethodConfiguration.ModifyParamsBlik"]
- """
- BLIK is a [single use](https://stripe.com/docs/payments/payment-methods#usage) payment method that requires customers to authenticate their payments. When customers want to pay online using BLIK, they request a six-digit code from their banking application and enter it into the payment collection form. Check this [page](https://stripe.com/docs/payments/blik) for more details.
- """
- boleto: NotRequired["PaymentMethodConfiguration.ModifyParamsBoleto"]
- """
- Boleto is an official (regulated by the Central Bank of Brazil) payment method in Brazil. Check this [page](https://stripe.com/docs/payments/boleto) for more details.
- """
- card: NotRequired["PaymentMethodConfiguration.ModifyParamsCard"]
- """
- Cards are a popular way for consumers and businesses to pay online or in person. Stripe supports global and local card networks.
- """
- cartes_bancaires: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsCartesBancaires"
- ]
- """
- Cartes Bancaires is France's local card network. More than 95% of these cards are co-branded with either Visa or Mastercard, meaning you can process these cards over either Cartes Bancaires or the Visa or Mastercard networks. Check this [page](https://stripe.com/docs/payments/cartes-bancaires) for more details.
- """
- cashapp: NotRequired["PaymentMethodConfiguration.ModifyParamsCashapp"]
- """
- Cash App is a popular consumer app in the US that allows customers to bank, invest, send, and receive money using their digital wallet. Check this [page](https://stripe.com/docs/payments/cash-app-pay) for more details.
- """
- customer_balance: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsCustomerBalance"
- ]
- """
- Uses a customer's [cash balance](https://stripe.com/docs/payments/customer-balance) for the payment. The cash balance can be funded via a bank transfer. Check this [page](https://stripe.com/docs/payments/bank-transfers) for more details.
- """
- eps: NotRequired["PaymentMethodConfiguration.ModifyParamsEps"]
- """
- EPS is an Austria-based payment method that allows customers to complete transactions online using their bank credentials. EPS is supported by all Austrian banks and is accepted by over 80% of Austrian online retailers. Check this [page](https://stripe.com/docs/payments/eps) for more details.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- fpx: NotRequired["PaymentMethodConfiguration.ModifyParamsFpx"]
- """
- Financial Process Exchange (FPX) is a Malaysia-based payment method that allows customers to complete transactions online using their bank credentials. Bank Negara Malaysia (BNM), the Central Bank of Malaysia, and eleven other major Malaysian financial institutions are members of the PayNet Group, which owns and operates FPX. It is one of the most popular online payment methods in Malaysia, with nearly 90 million transactions in 2018 according to BNM. Check this [page](https://stripe.com/docs/payments/fpx) for more details.
- """
- fr_meal_voucher_conecs: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsFrMealVoucherConecs"
- ]
- """
- Meal vouchers in France, or “titres-restaurant”, is a local benefits program commonly offered by employers for their employees to purchase prepared food and beverages on working days. Check this [page](https://stripe.com/docs/payments/benefits/fr-meal-vouchers) for more details.
- """
- giropay: NotRequired["PaymentMethodConfiguration.ModifyParamsGiropay"]
- """
- giropay is a German payment method based on online banking, introduced in 2006. It allows customers to complete transactions online using their online banking environment, with funds debited from their bank account. Depending on their bank, customers confirm payments on giropay using a second factor of authentication or a PIN. giropay accounts for 10% of online checkouts in Germany. Check this [page](https://stripe.com/docs/payments/giropay) for more details.
- """
- google_pay: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsGooglePay"
- ]
- """
- Google Pay allows customers to make payments in your app or website using any credit or debit card saved to their Google Account, including those from Google Play, YouTube, Chrome, or an Android device. Use the Google Pay API to request any credit or debit card stored in your customer's Google account. Check this [page](https://stripe.com/docs/google-pay) for more details.
- """
- grabpay: NotRequired["PaymentMethodConfiguration.ModifyParamsGrabpay"]
- """
- GrabPay is a payment method developed by [Grab](https://www.grab.com/sg/consumer/finance/pay/). GrabPay is a digital wallet - customers maintain a balance in their wallets that they pay out with. Check this [page](https://stripe.com/docs/payments/grabpay) for more details.
- """
- ideal: NotRequired["PaymentMethodConfiguration.ModifyParamsIdeal"]
- """
- iDEAL is a Netherlands-based payment method that allows customers to complete transactions online using their bank credentials. All major Dutch banks are members of Currence, the scheme that operates iDEAL, making it the most popular online payment method in the Netherlands with a share of online transactions close to 55%. Check this [page](https://stripe.com/docs/payments/ideal) for more details.
- """
- jcb: NotRequired["PaymentMethodConfiguration.ModifyParamsJcb"]
- """
- JCB is a credit card company based in Japan. JCB is currently available in Japan to businesses approved by JCB, and available to all businesses in Australia, Canada, Hong Kong, Japan, New Zealand, Singapore, Switzerland, United Kingdom, United States, and all countries in the European Economic Area except Iceland. Check this [page](https://support.stripe.com/questions/accepting-japan-credit-bureau-%28jcb%29-payments) for more details.
- """
- kakao_pay: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsKakaoPay"
- ]
- """
- Kakao Pay is a popular local wallet available in South Korea.
- """
- klarna: NotRequired["PaymentMethodConfiguration.ModifyParamsKlarna"]
- """
- Klarna gives customers a range of [payment options](https://stripe.com/docs/payments/klarna#payment-options) during checkout. Available payment options vary depending on the customer's billing address and the transaction amount. These payment options make it convenient for customers to purchase items in all price ranges. Check this [page](https://stripe.com/docs/payments/klarna) for more details.
- """
- konbini: NotRequired["PaymentMethodConfiguration.ModifyParamsKonbini"]
- """
- Konbini allows customers in Japan to pay for bills and online purchases at convenience stores with cash. Check this [page](https://stripe.com/docs/payments/konbini) for more details.
- """
- kr_card: NotRequired["PaymentMethodConfiguration.ModifyParamsKrCard"]
- """
- Korean cards let users pay using locally issued cards from South Korea.
- """
- link: NotRequired["PaymentMethodConfiguration.ModifyParamsLink"]
- """
- [Link](https://stripe.com/docs/payments/link) is a payment method network. With Link, users save their payment details once, then reuse that information to pay with one click for any business on the network.
- """
- mobilepay: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsMobilepay"
- ]
- """
- MobilePay is a [single-use](https://stripe.com/docs/payments/payment-methods#usage) card wallet payment method used in Denmark and Finland. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the MobilePay app. Check this [page](https://stripe.com/docs/payments/mobilepay) for more details.
- """
- multibanco: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsMultibanco"
- ]
- """
- Stripe users in Europe and the United States can accept Multibanco payments from customers in Portugal using [Sources](https://stripe.com/docs/sources)—a single integration path for creating payments using any supported method.
- """
- name: NotRequired[str]
- """
- Configuration name.
- """
- naver_pay: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsNaverPay"
- ]
- """
- Naver Pay is a popular local wallet available in South Korea.
- """
- nz_bank_account: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsNzBankAccount"
- ]
- """
- Stripe users in New Zealand can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with a New Zeland bank account. Check this [page](https://stripe.com/docs/payments/nz-bank-account) for more details.
- """
- oxxo: NotRequired["PaymentMethodConfiguration.ModifyParamsOxxo"]
- """
- OXXO is a Mexican chain of convenience stores with thousands of locations across Latin America and represents nearly 20% of online transactions in Mexico. OXXO allows customers to pay bills and online purchases in-store with cash. Check this [page](https://stripe.com/docs/payments/oxxo) for more details.
- """
- p24: NotRequired["PaymentMethodConfiguration.ModifyParamsP24"]
- """
- Przelewy24 is a Poland-based payment method aggregator that allows customers to complete transactions online using bank transfers and other methods. Bank transfers account for 30% of online payments in Poland and Przelewy24 provides a way for customers to pay with over 165 banks. Check this [page](https://stripe.com/docs/payments/p24) for more details.
- """
- pay_by_bank: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsPayByBank"
- ]
- """
- Pay by bank is a redirect payment method backed by bank transfers. A customer is redirected to their bank to authorize a bank transfer for a given amount. This removes a lot of the error risks inherent in waiting for the customer to initiate a transfer themselves, and is less expensive than card payments.
- """
- payco: NotRequired["PaymentMethodConfiguration.ModifyParamsPayco"]
- """
- PAYCO is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
- """
- paynow: NotRequired["PaymentMethodConfiguration.ModifyParamsPaynow"]
- """
- PayNow is a Singapore-based payment method that allows customers to make a payment using their preferred app from participating banks and participating non-bank financial institutions. Check this [page](https://stripe.com/docs/payments/paynow) for more details.
- """
- paypal: NotRequired["PaymentMethodConfiguration.ModifyParamsPaypal"]
- """
- PayPal, a digital wallet popular with customers in Europe, allows your customers worldwide to pay using their PayPal account. Check this [page](https://stripe.com/docs/payments/paypal) for more details.
- """
- pix: NotRequired["PaymentMethodConfiguration.ModifyParamsPix"]
- """
- Pix is a payment method popular in Brazil. When paying with Pix, customers authenticate and approve payments by scanning a QR code in their preferred banking app. Check this [page](https://docs.stripe.com/payments/pix) for more details.
- """
- promptpay: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsPromptpay"
- ]
- """
- PromptPay is a Thailand-based payment method that allows customers to make a payment using their preferred app from participating banks. Check this [page](https://stripe.com/docs/payments/promptpay) for more details.
- """
- revolut_pay: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsRevolutPay"
- ]
- """
- Revolut Pay, developed by Revolut, a global finance app, is a digital wallet payment method. Revolut Pay uses the customer's stored balance or cards to fund the payment, and offers the option for non-Revolut customers to save their details after their first purchase.
- """
- samsung_pay: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsSamsungPay"
- ]
- """
- Samsung Pay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
- """
- satispay: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsSatispay"
- ]
- """
- Satispay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method where customers are required to [authenticate](https://docs.stripe.com/payments/payment-methods#customer-actions) their payment. Customers pay by being redirected from your website or app, authorizing the payment with Satispay, then returning to your website or app. You get [immediate notification](https://docs.stripe.com/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
- """
- sepa_debit: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsSepaDebit"
- ]
- """
- The [Single Euro Payments Area (SEPA)](https://en.wikipedia.org/wiki/Single_Euro_Payments_Area) is an initiative of the European Union to simplify payments within and across member countries. SEPA established and enforced banking standards to allow for the direct debiting of every EUR-denominated bank account within the SEPA region, check this [page](https://stripe.com/docs/payments/sepa-debit) for more details.
- """
- sofort: NotRequired["PaymentMethodConfiguration.ModifyParamsSofort"]
- """
- Stripe users in Europe and the United States can use the [Payment Intents API](https://stripe.com/docs/payments/payment-intents)—a single integration path for creating payments using any supported method—to accept [Sofort](https://www.sofort.com/) payments from customers. Check this [page](https://stripe.com/docs/payments/sofort) for more details.
- """
- swish: NotRequired["PaymentMethodConfiguration.ModifyParamsSwish"]
- """
- Swish is a [real-time](https://stripe.com/docs/payments/real-time) payment method popular in Sweden. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the Swish mobile app and the Swedish BankID mobile app. Check this [page](https://stripe.com/docs/payments/swish) for more details.
- """
- twint: NotRequired["PaymentMethodConfiguration.ModifyParamsTwint"]
- """
- Twint is a payment method popular in Switzerland. It allows customers to pay using their mobile phone. Check this [page](https://docs.stripe.com/payments/twint) for more details.
- """
- us_bank_account: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsUsBankAccount"
- ]
- """
- Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check this [page](https://stripe.com/docs/payments/ach-direct-debit) for more details.
- """
- wechat_pay: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsWechatPay"
- ]
- """
- WeChat, owned by Tencent, is China's leading mobile app with over 1 billion monthly active users. Chinese consumers can use WeChat Pay to pay for goods and services inside of businesses' apps and websites. WeChat Pay users buy most frequently in gaming, e-commerce, travel, online education, and food/nutrition. Check this [page](https://stripe.com/docs/payments/wechat-pay) for more details.
- """
- zip: NotRequired["PaymentMethodConfiguration.ModifyParamsZip"]
- """
- Zip gives your customers a way to split purchases over a series of payments. Check this [page](https://stripe.com/docs/payments/zip) for more details like country availability.
- """
-
- class ModifyParamsAcssDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsAcssDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsAcssDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsAffirm(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsAffirmDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsAffirmDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsAfterpayClearpay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsAfterpayClearpayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsAfterpayClearpayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsAlipay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsAlipayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsAlipayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsAlma(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsAlmaDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsAlmaDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsAmazonPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsAmazonPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsAmazonPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsApplePay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsApplePayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsApplePayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsApplePayLater(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsApplePayLaterDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsApplePayLaterDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsAuBecsDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsAuBecsDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsAuBecsDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsBacsDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsBacsDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsBacsDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsBancontact(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsBancontactDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsBancontactDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsBillie(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsBillieDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsBillieDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsBlik(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsBlikDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsBlikDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsBoleto(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsBoletoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsBoletoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsCard(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsCardDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsCardDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsCartesBancaires(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsCartesBancairesDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsCartesBancairesDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsCashapp(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsCashappDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsCashappDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsCustomerBalance(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsCustomerBalanceDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsCustomerBalanceDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsEps(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsEpsDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsEpsDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsFpx(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsFpxDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsFpxDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsFrMealVoucherConecs(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsFrMealVoucherConecsDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsFrMealVoucherConecsDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsGiropay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsGiropayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsGiropayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsGooglePay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsGooglePayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsGooglePayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsGrabpay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsGrabpayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsGrabpayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsIdeal(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsIdealDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsIdealDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsJcb(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsJcbDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsJcbDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsKakaoPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsKakaoPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsKakaoPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsKlarna(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsKlarnaDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsKlarnaDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsKonbini(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsKonbiniDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsKonbiniDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsKrCard(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsKrCardDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsKrCardDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsLink(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsLinkDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsLinkDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsMobilepay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsMobilepayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsMobilepayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsMultibanco(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsMultibancoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsMultibancoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsNaverPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsNaverPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsNaverPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsNzBankAccount(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsNzBankAccountDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsNzBankAccountDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsOxxo(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsOxxoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsOxxoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsP24(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsP24DisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsP24DisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsPayByBank(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsPayByBankDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsPayByBankDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsPayco(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsPaycoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsPaycoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsPaynow(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsPaynowDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsPaynowDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsPaypal(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsPaypalDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsPaypalDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsPix(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsPixDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsPixDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsPromptpay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsPromptpayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsPromptpayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsRevolutPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsRevolutPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsRevolutPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsSamsungPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsSamsungPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsSamsungPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsSatispay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsSatispayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsSatispayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsSepaDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsSepaDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsSepaDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsSofort(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsSofortDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsSofortDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsSwish(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsSwishDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsSwishDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsTwint(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsTwintDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsTwintDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsUsBankAccount(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsUsBankAccountDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsUsBankAccountDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsWechatPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsWechatPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsWechatPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ModifyParamsZip(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfiguration.ModifyParamsZipDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class ModifyParamsZipDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
acss_debit: Optional[AcssDebit]
active: bool
"""
@@ -3309,7 +1258,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["PaymentMethodConfiguration.CreateParams"]
+ cls, **params: Unpack["PaymentMethodConfigurationCreateParams"]
) -> "PaymentMethodConfiguration":
"""
Creates a payment method configuration
@@ -3325,7 +1274,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["PaymentMethodConfiguration.CreateParams"]
+ cls, **params: Unpack["PaymentMethodConfigurationCreateParams"]
) -> "PaymentMethodConfiguration":
"""
Creates a payment method configuration
@@ -3341,7 +1290,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["PaymentMethodConfiguration.ListParams"]
+ cls, **params: Unpack["PaymentMethodConfigurationListParams"]
) -> ListObject["PaymentMethodConfiguration"]:
"""
List payment method configurations
@@ -3361,7 +1310,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["PaymentMethodConfiguration.ListParams"]
+ cls, **params: Unpack["PaymentMethodConfigurationListParams"]
) -> ListObject["PaymentMethodConfiguration"]:
"""
List payment method configurations
@@ -3383,7 +1332,7 @@ async def list_async(
def modify(
cls,
id: str,
- **params: Unpack["PaymentMethodConfiguration.ModifyParams"],
+ **params: Unpack["PaymentMethodConfigurationModifyParams"],
) -> "PaymentMethodConfiguration":
"""
Update payment method configuration
@@ -3402,7 +1351,7 @@ def modify(
async def modify_async(
cls,
id: str,
- **params: Unpack["PaymentMethodConfiguration.ModifyParams"],
+ **params: Unpack["PaymentMethodConfigurationModifyParams"],
) -> "PaymentMethodConfiguration":
"""
Update payment method configuration
@@ -3421,7 +1370,7 @@ async def modify_async(
def retrieve(
cls,
id: str,
- **params: Unpack["PaymentMethodConfiguration.RetrieveParams"],
+ **params: Unpack["PaymentMethodConfigurationRetrieveParams"],
) -> "PaymentMethodConfiguration":
"""
Retrieve payment method configuration
@@ -3434,7 +1383,7 @@ def retrieve(
async def retrieve_async(
cls,
id: str,
- **params: Unpack["PaymentMethodConfiguration.RetrieveParams"],
+ **params: Unpack["PaymentMethodConfigurationRetrieveParams"],
) -> "PaymentMethodConfiguration":
"""
Retrieve payment method configuration
diff --git a/stripe/_payment_method_configuration_service.py b/stripe/_payment_method_configuration_service.py
index ca35722a3..49c22e42f 100644
--- a/stripe/_payment_method_configuration_service.py
+++ b/stripe/_payment_method_configuration_service.py
@@ -5,2148 +5,28 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._payment_method_configuration_create_params import (
+ PaymentMethodConfigurationCreateParams,
+ )
+ from stripe.params._payment_method_configuration_list_params import (
+ PaymentMethodConfigurationListParams,
+ )
+ from stripe.params._payment_method_configuration_retrieve_params import (
+ PaymentMethodConfigurationRetrieveParams,
+ )
+ from stripe.params._payment_method_configuration_update_params import (
+ PaymentMethodConfigurationUpdateParams,
+ )
class PaymentMethodConfigurationService(StripeService):
- class CreateParams(TypedDict):
- acss_debit: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsAcssDebit"
- ]
- """
- Canadian pre-authorized debit payments, check this [page](https://stripe.com/docs/payments/acss-debit) for more details like country availability.
- """
- affirm: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsAffirm"
- ]
- """
- [Affirm](https://www.affirm.com/) gives your customers a way to split purchases over a series of payments. Depending on the purchase, they can pay with four interest-free payments (Split Pay) or pay over a longer term (Installments), which might include interest. Check this [page](https://stripe.com/docs/payments/affirm) for more details like country availability.
- """
- afterpay_clearpay: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsAfterpayClearpay"
- ]
- """
- Afterpay gives your customers a way to pay for purchases in installments, check this [page](https://stripe.com/docs/payments/afterpay-clearpay) for more details like country availability. Afterpay is particularly popular among businesses selling fashion, beauty, and sports products.
- """
- alipay: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsAlipay"
- ]
- """
- Alipay is a digital wallet in China that has more than a billion active users worldwide. Alipay users can pay on the web or on a mobile device using login credentials or their Alipay app. Alipay has a low dispute rate and reduces fraud by authenticating payments using the customer's login credentials. Check this [page](https://stripe.com/docs/payments/alipay) for more details.
- """
- alma: NotRequired["PaymentMethodConfigurationService.CreateParamsAlma"]
- """
- Alma is a Buy Now, Pay Later payment method that offers customers the ability to pay in 2, 3, or 4 installments.
- """
- amazon_pay: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsAmazonPay"
- ]
- """
- Amazon Pay is a wallet payment method that lets your customers check out the same way as on Amazon.
- """
- apple_pay: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsApplePay"
- ]
- """
- Stripe users can accept [Apple Pay](https://stripe.com/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. There are no additional fees to process Apple Pay payments, and the [pricing](https://stripe.com/pricing) is the same as other card transactions. Check this [page](https://stripe.com/docs/apple-pay) for more details.
- """
- apple_pay_later: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsApplePayLater"
- ]
- """
- Apple Pay Later, a payment method for customers to buy now and pay later, gives your customers a way to split purchases into four installments across six weeks.
- """
- au_becs_debit: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsAuBecsDebit"
- ]
- """
- Stripe users in Australia can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with an Australian bank account. Check this [page](https://stripe.com/docs/payments/au-becs-debit) for more details.
- """
- bacs_debit: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsBacsDebit"
- ]
- """
- Stripe users in the UK can accept Bacs Direct Debit payments from customers with a UK bank account, check this [page](https://stripe.com/docs/payments/payment-methods/bacs-debit) for more details.
- """
- bancontact: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsBancontact"
- ]
- """
- Bancontact is the most popular online payment method in Belgium, with over 15 million cards in circulation. [Customers](https://stripe.com/docs/api/customers) use a Bancontact card or mobile app linked to a Belgian bank account to make online payments that are secure, guaranteed, and confirmed immediately. Check this [page](https://stripe.com/docs/payments/bancontact) for more details.
- """
- billie: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsBillie"
- ]
- """
- Billie is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method that offers businesses Pay by Invoice where they offer payment terms ranging from 7-120 days. Customers are redirected from your website or app, authorize the payment with Billie, then return to your website or app. You get [immediate notification](https://docs.stripe.com/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
- """
- blik: NotRequired["PaymentMethodConfigurationService.CreateParamsBlik"]
- """
- BLIK is a [single use](https://stripe.com/docs/payments/payment-methods#usage) payment method that requires customers to authenticate their payments. When customers want to pay online using BLIK, they request a six-digit code from their banking application and enter it into the payment collection form. Check this [page](https://stripe.com/docs/payments/blik) for more details.
- """
- boleto: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsBoleto"
- ]
- """
- Boleto is an official (regulated by the Central Bank of Brazil) payment method in Brazil. Check this [page](https://stripe.com/docs/payments/boleto) for more details.
- """
- card: NotRequired["PaymentMethodConfigurationService.CreateParamsCard"]
- """
- Cards are a popular way for consumers and businesses to pay online or in person. Stripe supports global and local card networks.
- """
- cartes_bancaires: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsCartesBancaires"
- ]
- """
- Cartes Bancaires is France's local card network. More than 95% of these cards are co-branded with either Visa or Mastercard, meaning you can process these cards over either Cartes Bancaires or the Visa or Mastercard networks. Check this [page](https://stripe.com/docs/payments/cartes-bancaires) for more details.
- """
- cashapp: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsCashapp"
- ]
- """
- Cash App is a popular consumer app in the US that allows customers to bank, invest, send, and receive money using their digital wallet. Check this [page](https://stripe.com/docs/payments/cash-app-pay) for more details.
- """
- customer_balance: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsCustomerBalance"
- ]
- """
- Uses a customer's [cash balance](https://stripe.com/docs/payments/customer-balance) for the payment. The cash balance can be funded via a bank transfer. Check this [page](https://stripe.com/docs/payments/bank-transfers) for more details.
- """
- eps: NotRequired["PaymentMethodConfigurationService.CreateParamsEps"]
- """
- EPS is an Austria-based payment method that allows customers to complete transactions online using their bank credentials. EPS is supported by all Austrian banks and is accepted by over 80% of Austrian online retailers. Check this [page](https://stripe.com/docs/payments/eps) for more details.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- fpx: NotRequired["PaymentMethodConfigurationService.CreateParamsFpx"]
- """
- Financial Process Exchange (FPX) is a Malaysia-based payment method that allows customers to complete transactions online using their bank credentials. Bank Negara Malaysia (BNM), the Central Bank of Malaysia, and eleven other major Malaysian financial institutions are members of the PayNet Group, which owns and operates FPX. It is one of the most popular online payment methods in Malaysia, with nearly 90 million transactions in 2018 according to BNM. Check this [page](https://stripe.com/docs/payments/fpx) for more details.
- """
- fr_meal_voucher_conecs: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsFrMealVoucherConecs"
- ]
- """
- Meal vouchers in France, or “titres-restaurant”, is a local benefits program commonly offered by employers for their employees to purchase prepared food and beverages on working days. Check this [page](https://stripe.com/docs/payments/benefits/fr-meal-vouchers) for more details.
- """
- giropay: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsGiropay"
- ]
- """
- giropay is a German payment method based on online banking, introduced in 2006. It allows customers to complete transactions online using their online banking environment, with funds debited from their bank account. Depending on their bank, customers confirm payments on giropay using a second factor of authentication or a PIN. giropay accounts for 10% of online checkouts in Germany. Check this [page](https://stripe.com/docs/payments/giropay) for more details.
- """
- google_pay: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsGooglePay"
- ]
- """
- Google Pay allows customers to make payments in your app or website using any credit or debit card saved to their Google Account, including those from Google Play, YouTube, Chrome, or an Android device. Use the Google Pay API to request any credit or debit card stored in your customer's Google account. Check this [page](https://stripe.com/docs/google-pay) for more details.
- """
- grabpay: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsGrabpay"
- ]
- """
- GrabPay is a payment method developed by [Grab](https://www.grab.com/sg/consumer/finance/pay/). GrabPay is a digital wallet - customers maintain a balance in their wallets that they pay out with. Check this [page](https://stripe.com/docs/payments/grabpay) for more details.
- """
- ideal: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsIdeal"
- ]
- """
- iDEAL is a Netherlands-based payment method that allows customers to complete transactions online using their bank credentials. All major Dutch banks are members of Currence, the scheme that operates iDEAL, making it the most popular online payment method in the Netherlands with a share of online transactions close to 55%. Check this [page](https://stripe.com/docs/payments/ideal) for more details.
- """
- jcb: NotRequired["PaymentMethodConfigurationService.CreateParamsJcb"]
- """
- JCB is a credit card company based in Japan. JCB is currently available in Japan to businesses approved by JCB, and available to all businesses in Australia, Canada, Hong Kong, Japan, New Zealand, Singapore, Switzerland, United Kingdom, United States, and all countries in the European Economic Area except Iceland. Check this [page](https://support.stripe.com/questions/accepting-japan-credit-bureau-%28jcb%29-payments) for more details.
- """
- kakao_pay: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsKakaoPay"
- ]
- """
- Kakao Pay is a popular local wallet available in South Korea.
- """
- klarna: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsKlarna"
- ]
- """
- Klarna gives customers a range of [payment options](https://stripe.com/docs/payments/klarna#payment-options) during checkout. Available payment options vary depending on the customer's billing address and the transaction amount. These payment options make it convenient for customers to purchase items in all price ranges. Check this [page](https://stripe.com/docs/payments/klarna) for more details.
- """
- konbini: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsKonbini"
- ]
- """
- Konbini allows customers in Japan to pay for bills and online purchases at convenience stores with cash. Check this [page](https://stripe.com/docs/payments/konbini) for more details.
- """
- kr_card: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsKrCard"
- ]
- """
- Korean cards let users pay using locally issued cards from South Korea.
- """
- link: NotRequired["PaymentMethodConfigurationService.CreateParamsLink"]
- """
- [Link](https://stripe.com/docs/payments/link) is a payment method network. With Link, users save their payment details once, then reuse that information to pay with one click for any business on the network.
- """
- mobilepay: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsMobilepay"
- ]
- """
- MobilePay is a [single-use](https://stripe.com/docs/payments/payment-methods#usage) card wallet payment method used in Denmark and Finland. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the MobilePay app. Check this [page](https://stripe.com/docs/payments/mobilepay) for more details.
- """
- multibanco: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsMultibanco"
- ]
- """
- Stripe users in Europe and the United States can accept Multibanco payments from customers in Portugal using [Sources](https://stripe.com/docs/sources)—a single integration path for creating payments using any supported method.
- """
- name: NotRequired[str]
- """
- Configuration name.
- """
- naver_pay: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsNaverPay"
- ]
- """
- Naver Pay is a popular local wallet available in South Korea.
- """
- nz_bank_account: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsNzBankAccount"
- ]
- """
- Stripe users in New Zealand can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with a New Zeland bank account. Check this [page](https://stripe.com/docs/payments/nz-bank-account) for more details.
- """
- oxxo: NotRequired["PaymentMethodConfigurationService.CreateParamsOxxo"]
- """
- OXXO is a Mexican chain of convenience stores with thousands of locations across Latin America and represents nearly 20% of online transactions in Mexico. OXXO allows customers to pay bills and online purchases in-store with cash. Check this [page](https://stripe.com/docs/payments/oxxo) for more details.
- """
- p24: NotRequired["PaymentMethodConfigurationService.CreateParamsP24"]
- """
- Przelewy24 is a Poland-based payment method aggregator that allows customers to complete transactions online using bank transfers and other methods. Bank transfers account for 30% of online payments in Poland and Przelewy24 provides a way for customers to pay with over 165 banks. Check this [page](https://stripe.com/docs/payments/p24) for more details.
- """
- parent: NotRequired[str]
- """
- Configuration's parent configuration. Specify to create a child configuration.
- """
- pay_by_bank: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsPayByBank"
- ]
- """
- Pay by bank is a redirect payment method backed by bank transfers. A customer is redirected to their bank to authorize a bank transfer for a given amount. This removes a lot of the error risks inherent in waiting for the customer to initiate a transfer themselves, and is less expensive than card payments.
- """
- payco: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsPayco"
- ]
- """
- PAYCO is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
- """
- paynow: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsPaynow"
- ]
- """
- PayNow is a Singapore-based payment method that allows customers to make a payment using their preferred app from participating banks and participating non-bank financial institutions. Check this [page](https://stripe.com/docs/payments/paynow) for more details.
- """
- paypal: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsPaypal"
- ]
- """
- PayPal, a digital wallet popular with customers in Europe, allows your customers worldwide to pay using their PayPal account. Check this [page](https://stripe.com/docs/payments/paypal) for more details.
- """
- pix: NotRequired["PaymentMethodConfigurationService.CreateParamsPix"]
- """
- Pix is a payment method popular in Brazil. When paying with Pix, customers authenticate and approve payments by scanning a QR code in their preferred banking app. Check this [page](https://docs.stripe.com/payments/pix) for more details.
- """
- promptpay: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsPromptpay"
- ]
- """
- PromptPay is a Thailand-based payment method that allows customers to make a payment using their preferred app from participating banks. Check this [page](https://stripe.com/docs/payments/promptpay) for more details.
- """
- revolut_pay: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsRevolutPay"
- ]
- """
- Revolut Pay, developed by Revolut, a global finance app, is a digital wallet payment method. Revolut Pay uses the customer's stored balance or cards to fund the payment, and offers the option for non-Revolut customers to save their details after their first purchase.
- """
- samsung_pay: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsSamsungPay"
- ]
- """
- Samsung Pay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
- """
- satispay: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsSatispay"
- ]
- """
- Satispay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method where customers are required to [authenticate](https://docs.stripe.com/payments/payment-methods#customer-actions) their payment. Customers pay by being redirected from your website or app, authorizing the payment with Satispay, then returning to your website or app. You get [immediate notification](https://docs.stripe.com/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
- """
- sepa_debit: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsSepaDebit"
- ]
- """
- The [Single Euro Payments Area (SEPA)](https://en.wikipedia.org/wiki/Single_Euro_Payments_Area) is an initiative of the European Union to simplify payments within and across member countries. SEPA established and enforced banking standards to allow for the direct debiting of every EUR-denominated bank account within the SEPA region, check this [page](https://stripe.com/docs/payments/sepa-debit) for more details.
- """
- sofort: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsSofort"
- ]
- """
- Stripe users in Europe and the United States can use the [Payment Intents API](https://stripe.com/docs/payments/payment-intents)—a single integration path for creating payments using any supported method—to accept [Sofort](https://www.sofort.com/) payments from customers. Check this [page](https://stripe.com/docs/payments/sofort) for more details.
- """
- swish: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsSwish"
- ]
- """
- Swish is a [real-time](https://stripe.com/docs/payments/real-time) payment method popular in Sweden. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the Swish mobile app and the Swedish BankID mobile app. Check this [page](https://stripe.com/docs/payments/swish) for more details.
- """
- twint: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsTwint"
- ]
- """
- Twint is a payment method popular in Switzerland. It allows customers to pay using their mobile phone. Check this [page](https://docs.stripe.com/payments/twint) for more details.
- """
- us_bank_account: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsUsBankAccount"
- ]
- """
- Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check this [page](https://stripe.com/docs/payments/ach-direct-debit) for more details.
- """
- wechat_pay: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsWechatPay"
- ]
- """
- WeChat, owned by Tencent, is China's leading mobile app with over 1 billion monthly active users. Chinese consumers can use WeChat Pay to pay for goods and services inside of businesses' apps and websites. WeChat Pay users buy most frequently in gaming, e-commerce, travel, online education, and food/nutrition. Check this [page](https://stripe.com/docs/payments/wechat-pay) for more details.
- """
- zip: NotRequired["PaymentMethodConfigurationService.CreateParamsZip"]
- """
- Zip gives your customers a way to split purchases over a series of payments. Check this [page](https://stripe.com/docs/payments/zip) for more details like country availability.
- """
-
- class CreateParamsAcssDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsAcssDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsAcssDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsAffirm(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsAffirmDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsAffirmDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsAfterpayClearpay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsAfterpayClearpayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsAfterpayClearpayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsAlipay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsAlipayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsAlipayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsAlma(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsAlmaDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsAlmaDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsAmazonPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsAmazonPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsAmazonPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsApplePay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsApplePayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsApplePayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsApplePayLater(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsApplePayLaterDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsApplePayLaterDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsAuBecsDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsAuBecsDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsAuBecsDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsBacsDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsBacsDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsBacsDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsBancontact(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsBancontactDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsBancontactDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsBillie(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsBillieDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsBillieDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsBlik(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsBlikDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsBlikDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsBoleto(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsBoletoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsBoletoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsCard(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsCardDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsCardDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsCartesBancaires(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsCartesBancairesDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsCartesBancairesDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsCashapp(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsCashappDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsCashappDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsCustomerBalance(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsCustomerBalanceDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsCustomerBalanceDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsEps(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsEpsDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsEpsDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsFpx(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsFpxDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsFpxDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsFrMealVoucherConecs(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsFrMealVoucherConecsDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsFrMealVoucherConecsDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsGiropay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsGiropayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsGiropayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsGooglePay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsGooglePayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsGooglePayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsGrabpay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsGrabpayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsGrabpayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsIdeal(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsIdealDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsIdealDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsJcb(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsJcbDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsJcbDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsKakaoPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsKakaoPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsKakaoPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsKlarna(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsKlarnaDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsKlarnaDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsKonbini(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsKonbiniDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsKonbiniDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsKrCard(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsKrCardDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsKrCardDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsLink(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsLinkDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsLinkDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsMobilepay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsMobilepayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsMobilepayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsMultibanco(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsMultibancoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsMultibancoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsNaverPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsNaverPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsNaverPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsNzBankAccount(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsNzBankAccountDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsNzBankAccountDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsOxxo(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsOxxoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsOxxoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsP24(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsP24DisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsP24DisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsPayByBank(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsPayByBankDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsPayByBankDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsPayco(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsPaycoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsPaycoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsPaynow(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsPaynowDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsPaynowDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsPaypal(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsPaypalDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsPaypalDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsPix(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsPixDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsPixDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsPromptpay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsPromptpayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsPromptpayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsRevolutPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsRevolutPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsRevolutPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsSamsungPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsSamsungPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsSamsungPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsSatispay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsSatispayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsSatispayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsSepaDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsSepaDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsSepaDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsSofort(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsSofortDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsSofortDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsSwish(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsSwishDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsSwishDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsTwint(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsTwintDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsTwintDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsUsBankAccount(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsUsBankAccountDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsUsBankAccountDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsWechatPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsWechatPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsWechatPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class CreateParamsZip(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.CreateParamsZipDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class CreateParamsZipDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class ListParams(TypedDict):
- application: NotRequired["Literal['']|str"]
- """
- The Connect application to filter by.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- acss_debit: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsAcssDebit"
- ]
- """
- Canadian pre-authorized debit payments, check this [page](https://stripe.com/docs/payments/acss-debit) for more details like country availability.
- """
- active: NotRequired[bool]
- """
- Whether the configuration can be used for new payments.
- """
- affirm: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsAffirm"
- ]
- """
- [Affirm](https://www.affirm.com/) gives your customers a way to split purchases over a series of payments. Depending on the purchase, they can pay with four interest-free payments (Split Pay) or pay over a longer term (Installments), which might include interest. Check this [page](https://stripe.com/docs/payments/affirm) for more details like country availability.
- """
- afterpay_clearpay: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsAfterpayClearpay"
- ]
- """
- Afterpay gives your customers a way to pay for purchases in installments, check this [page](https://stripe.com/docs/payments/afterpay-clearpay) for more details like country availability. Afterpay is particularly popular among businesses selling fashion, beauty, and sports products.
- """
- alipay: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsAlipay"
- ]
- """
- Alipay is a digital wallet in China that has more than a billion active users worldwide. Alipay users can pay on the web or on a mobile device using login credentials or their Alipay app. Alipay has a low dispute rate and reduces fraud by authenticating payments using the customer's login credentials. Check this [page](https://stripe.com/docs/payments/alipay) for more details.
- """
- alma: NotRequired["PaymentMethodConfigurationService.UpdateParamsAlma"]
- """
- Alma is a Buy Now, Pay Later payment method that offers customers the ability to pay in 2, 3, or 4 installments.
- """
- amazon_pay: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsAmazonPay"
- ]
- """
- Amazon Pay is a wallet payment method that lets your customers check out the same way as on Amazon.
- """
- apple_pay: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsApplePay"
- ]
- """
- Stripe users can accept [Apple Pay](https://stripe.com/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. There are no additional fees to process Apple Pay payments, and the [pricing](https://stripe.com/pricing) is the same as other card transactions. Check this [page](https://stripe.com/docs/apple-pay) for more details.
- """
- apple_pay_later: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsApplePayLater"
- ]
- """
- Apple Pay Later, a payment method for customers to buy now and pay later, gives your customers a way to split purchases into four installments across six weeks.
- """
- au_becs_debit: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsAuBecsDebit"
- ]
- """
- Stripe users in Australia can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with an Australian bank account. Check this [page](https://stripe.com/docs/payments/au-becs-debit) for more details.
- """
- bacs_debit: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsBacsDebit"
- ]
- """
- Stripe users in the UK can accept Bacs Direct Debit payments from customers with a UK bank account, check this [page](https://stripe.com/docs/payments/payment-methods/bacs-debit) for more details.
- """
- bancontact: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsBancontact"
- ]
- """
- Bancontact is the most popular online payment method in Belgium, with over 15 million cards in circulation. [Customers](https://stripe.com/docs/api/customers) use a Bancontact card or mobile app linked to a Belgian bank account to make online payments that are secure, guaranteed, and confirmed immediately. Check this [page](https://stripe.com/docs/payments/bancontact) for more details.
- """
- billie: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsBillie"
- ]
- """
- Billie is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method that offers businesses Pay by Invoice where they offer payment terms ranging from 7-120 days. Customers are redirected from your website or app, authorize the payment with Billie, then return to your website or app. You get [immediate notification](https://docs.stripe.com/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
- """
- blik: NotRequired["PaymentMethodConfigurationService.UpdateParamsBlik"]
- """
- BLIK is a [single use](https://stripe.com/docs/payments/payment-methods#usage) payment method that requires customers to authenticate their payments. When customers want to pay online using BLIK, they request a six-digit code from their banking application and enter it into the payment collection form. Check this [page](https://stripe.com/docs/payments/blik) for more details.
- """
- boleto: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsBoleto"
- ]
- """
- Boleto is an official (regulated by the Central Bank of Brazil) payment method in Brazil. Check this [page](https://stripe.com/docs/payments/boleto) for more details.
- """
- card: NotRequired["PaymentMethodConfigurationService.UpdateParamsCard"]
- """
- Cards are a popular way for consumers and businesses to pay online or in person. Stripe supports global and local card networks.
- """
- cartes_bancaires: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsCartesBancaires"
- ]
- """
- Cartes Bancaires is France's local card network. More than 95% of these cards are co-branded with either Visa or Mastercard, meaning you can process these cards over either Cartes Bancaires or the Visa or Mastercard networks. Check this [page](https://stripe.com/docs/payments/cartes-bancaires) for more details.
- """
- cashapp: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsCashapp"
- ]
- """
- Cash App is a popular consumer app in the US that allows customers to bank, invest, send, and receive money using their digital wallet. Check this [page](https://stripe.com/docs/payments/cash-app-pay) for more details.
- """
- customer_balance: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsCustomerBalance"
- ]
- """
- Uses a customer's [cash balance](https://stripe.com/docs/payments/customer-balance) for the payment. The cash balance can be funded via a bank transfer. Check this [page](https://stripe.com/docs/payments/bank-transfers) for more details.
- """
- eps: NotRequired["PaymentMethodConfigurationService.UpdateParamsEps"]
- """
- EPS is an Austria-based payment method that allows customers to complete transactions online using their bank credentials. EPS is supported by all Austrian banks and is accepted by over 80% of Austrian online retailers. Check this [page](https://stripe.com/docs/payments/eps) for more details.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- fpx: NotRequired["PaymentMethodConfigurationService.UpdateParamsFpx"]
- """
- Financial Process Exchange (FPX) is a Malaysia-based payment method that allows customers to complete transactions online using their bank credentials. Bank Negara Malaysia (BNM), the Central Bank of Malaysia, and eleven other major Malaysian financial institutions are members of the PayNet Group, which owns and operates FPX. It is one of the most popular online payment methods in Malaysia, with nearly 90 million transactions in 2018 according to BNM. Check this [page](https://stripe.com/docs/payments/fpx) for more details.
- """
- fr_meal_voucher_conecs: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsFrMealVoucherConecs"
- ]
- """
- Meal vouchers in France, or “titres-restaurant”, is a local benefits program commonly offered by employers for their employees to purchase prepared food and beverages on working days. Check this [page](https://stripe.com/docs/payments/benefits/fr-meal-vouchers) for more details.
- """
- giropay: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsGiropay"
- ]
- """
- giropay is a German payment method based on online banking, introduced in 2006. It allows customers to complete transactions online using their online banking environment, with funds debited from their bank account. Depending on their bank, customers confirm payments on giropay using a second factor of authentication or a PIN. giropay accounts for 10% of online checkouts in Germany. Check this [page](https://stripe.com/docs/payments/giropay) for more details.
- """
- google_pay: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsGooglePay"
- ]
- """
- Google Pay allows customers to make payments in your app or website using any credit or debit card saved to their Google Account, including those from Google Play, YouTube, Chrome, or an Android device. Use the Google Pay API to request any credit or debit card stored in your customer's Google account. Check this [page](https://stripe.com/docs/google-pay) for more details.
- """
- grabpay: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsGrabpay"
- ]
- """
- GrabPay is a payment method developed by [Grab](https://www.grab.com/sg/consumer/finance/pay/). GrabPay is a digital wallet - customers maintain a balance in their wallets that they pay out with. Check this [page](https://stripe.com/docs/payments/grabpay) for more details.
- """
- ideal: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsIdeal"
- ]
- """
- iDEAL is a Netherlands-based payment method that allows customers to complete transactions online using their bank credentials. All major Dutch banks are members of Currence, the scheme that operates iDEAL, making it the most popular online payment method in the Netherlands with a share of online transactions close to 55%. Check this [page](https://stripe.com/docs/payments/ideal) for more details.
- """
- jcb: NotRequired["PaymentMethodConfigurationService.UpdateParamsJcb"]
- """
- JCB is a credit card company based in Japan. JCB is currently available in Japan to businesses approved by JCB, and available to all businesses in Australia, Canada, Hong Kong, Japan, New Zealand, Singapore, Switzerland, United Kingdom, United States, and all countries in the European Economic Area except Iceland. Check this [page](https://support.stripe.com/questions/accepting-japan-credit-bureau-%28jcb%29-payments) for more details.
- """
- kakao_pay: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsKakaoPay"
- ]
- """
- Kakao Pay is a popular local wallet available in South Korea.
- """
- klarna: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsKlarna"
- ]
- """
- Klarna gives customers a range of [payment options](https://stripe.com/docs/payments/klarna#payment-options) during checkout. Available payment options vary depending on the customer's billing address and the transaction amount. These payment options make it convenient for customers to purchase items in all price ranges. Check this [page](https://stripe.com/docs/payments/klarna) for more details.
- """
- konbini: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsKonbini"
- ]
- """
- Konbini allows customers in Japan to pay for bills and online purchases at convenience stores with cash. Check this [page](https://stripe.com/docs/payments/konbini) for more details.
- """
- kr_card: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsKrCard"
- ]
- """
- Korean cards let users pay using locally issued cards from South Korea.
- """
- link: NotRequired["PaymentMethodConfigurationService.UpdateParamsLink"]
- """
- [Link](https://stripe.com/docs/payments/link) is a payment method network. With Link, users save their payment details once, then reuse that information to pay with one click for any business on the network.
- """
- mobilepay: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsMobilepay"
- ]
- """
- MobilePay is a [single-use](https://stripe.com/docs/payments/payment-methods#usage) card wallet payment method used in Denmark and Finland. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the MobilePay app. Check this [page](https://stripe.com/docs/payments/mobilepay) for more details.
- """
- multibanco: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsMultibanco"
- ]
- """
- Stripe users in Europe and the United States can accept Multibanco payments from customers in Portugal using [Sources](https://stripe.com/docs/sources)—a single integration path for creating payments using any supported method.
- """
- name: NotRequired[str]
- """
- Configuration name.
- """
- naver_pay: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsNaverPay"
- ]
- """
- Naver Pay is a popular local wallet available in South Korea.
- """
- nz_bank_account: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsNzBankAccount"
- ]
- """
- Stripe users in New Zealand can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with a New Zeland bank account. Check this [page](https://stripe.com/docs/payments/nz-bank-account) for more details.
- """
- oxxo: NotRequired["PaymentMethodConfigurationService.UpdateParamsOxxo"]
- """
- OXXO is a Mexican chain of convenience stores with thousands of locations across Latin America and represents nearly 20% of online transactions in Mexico. OXXO allows customers to pay bills and online purchases in-store with cash. Check this [page](https://stripe.com/docs/payments/oxxo) for more details.
- """
- p24: NotRequired["PaymentMethodConfigurationService.UpdateParamsP24"]
- """
- Przelewy24 is a Poland-based payment method aggregator that allows customers to complete transactions online using bank transfers and other methods. Bank transfers account for 30% of online payments in Poland and Przelewy24 provides a way for customers to pay with over 165 banks. Check this [page](https://stripe.com/docs/payments/p24) for more details.
- """
- pay_by_bank: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsPayByBank"
- ]
- """
- Pay by bank is a redirect payment method backed by bank transfers. A customer is redirected to their bank to authorize a bank transfer for a given amount. This removes a lot of the error risks inherent in waiting for the customer to initiate a transfer themselves, and is less expensive than card payments.
- """
- payco: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsPayco"
- ]
- """
- PAYCO is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
- """
- paynow: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsPaynow"
- ]
- """
- PayNow is a Singapore-based payment method that allows customers to make a payment using their preferred app from participating banks and participating non-bank financial institutions. Check this [page](https://stripe.com/docs/payments/paynow) for more details.
- """
- paypal: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsPaypal"
- ]
- """
- PayPal, a digital wallet popular with customers in Europe, allows your customers worldwide to pay using their PayPal account. Check this [page](https://stripe.com/docs/payments/paypal) for more details.
- """
- pix: NotRequired["PaymentMethodConfigurationService.UpdateParamsPix"]
- """
- Pix is a payment method popular in Brazil. When paying with Pix, customers authenticate and approve payments by scanning a QR code in their preferred banking app. Check this [page](https://docs.stripe.com/payments/pix) for more details.
- """
- promptpay: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsPromptpay"
- ]
- """
- PromptPay is a Thailand-based payment method that allows customers to make a payment using their preferred app from participating banks. Check this [page](https://stripe.com/docs/payments/promptpay) for more details.
- """
- revolut_pay: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsRevolutPay"
- ]
- """
- Revolut Pay, developed by Revolut, a global finance app, is a digital wallet payment method. Revolut Pay uses the customer's stored balance or cards to fund the payment, and offers the option for non-Revolut customers to save their details after their first purchase.
- """
- samsung_pay: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsSamsungPay"
- ]
- """
- Samsung Pay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
- """
- satispay: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsSatispay"
- ]
- """
- Satispay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method where customers are required to [authenticate](https://docs.stripe.com/payments/payment-methods#customer-actions) their payment. Customers pay by being redirected from your website or app, authorizing the payment with Satispay, then returning to your website or app. You get [immediate notification](https://docs.stripe.com/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
- """
- sepa_debit: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsSepaDebit"
- ]
- """
- The [Single Euro Payments Area (SEPA)](https://en.wikipedia.org/wiki/Single_Euro_Payments_Area) is an initiative of the European Union to simplify payments within and across member countries. SEPA established and enforced banking standards to allow for the direct debiting of every EUR-denominated bank account within the SEPA region, check this [page](https://stripe.com/docs/payments/sepa-debit) for more details.
- """
- sofort: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsSofort"
- ]
- """
- Stripe users in Europe and the United States can use the [Payment Intents API](https://stripe.com/docs/payments/payment-intents)—a single integration path for creating payments using any supported method—to accept [Sofort](https://www.sofort.com/) payments from customers. Check this [page](https://stripe.com/docs/payments/sofort) for more details.
- """
- swish: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsSwish"
- ]
- """
- Swish is a [real-time](https://stripe.com/docs/payments/real-time) payment method popular in Sweden. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the Swish mobile app and the Swedish BankID mobile app. Check this [page](https://stripe.com/docs/payments/swish) for more details.
- """
- twint: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsTwint"
- ]
- """
- Twint is a payment method popular in Switzerland. It allows customers to pay using their mobile phone. Check this [page](https://docs.stripe.com/payments/twint) for more details.
- """
- us_bank_account: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsUsBankAccount"
- ]
- """
- Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check this [page](https://stripe.com/docs/payments/ach-direct-debit) for more details.
- """
- wechat_pay: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsWechatPay"
- ]
- """
- WeChat, owned by Tencent, is China's leading mobile app with over 1 billion monthly active users. Chinese consumers can use WeChat Pay to pay for goods and services inside of businesses' apps and websites. WeChat Pay users buy most frequently in gaming, e-commerce, travel, online education, and food/nutrition. Check this [page](https://stripe.com/docs/payments/wechat-pay) for more details.
- """
- zip: NotRequired["PaymentMethodConfigurationService.UpdateParamsZip"]
- """
- Zip gives your customers a way to split purchases over a series of payments. Check this [page](https://stripe.com/docs/payments/zip) for more details like country availability.
- """
-
- class UpdateParamsAcssDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsAcssDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsAcssDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsAffirm(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsAffirmDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsAffirmDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsAfterpayClearpay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsAfterpayClearpayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsAfterpayClearpayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsAlipay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsAlipayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsAlipayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsAlma(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsAlmaDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsAlmaDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsAmazonPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsAmazonPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsAmazonPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsApplePay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsApplePayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsApplePayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsApplePayLater(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsApplePayLaterDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsApplePayLaterDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsAuBecsDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsAuBecsDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsAuBecsDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsBacsDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsBacsDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsBacsDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsBancontact(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsBancontactDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsBancontactDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsBillie(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsBillieDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsBillieDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsBlik(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsBlikDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsBlikDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsBoleto(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsBoletoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsBoletoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsCard(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsCardDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsCardDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsCartesBancaires(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsCartesBancairesDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsCartesBancairesDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsCashapp(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsCashappDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsCashappDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsCustomerBalance(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsCustomerBalanceDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsCustomerBalanceDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsEps(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsEpsDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsEpsDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsFpx(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsFpxDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsFpxDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsFrMealVoucherConecs(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsFrMealVoucherConecsDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsFrMealVoucherConecsDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsGiropay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsGiropayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsGiropayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsGooglePay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsGooglePayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsGooglePayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsGrabpay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsGrabpayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsGrabpayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsIdeal(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsIdealDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsIdealDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsJcb(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsJcbDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsJcbDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsKakaoPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsKakaoPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsKakaoPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsKlarna(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsKlarnaDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsKlarnaDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsKonbini(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsKonbiniDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsKonbiniDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsKrCard(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsKrCardDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsKrCardDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsLink(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsLinkDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsLinkDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsMobilepay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsMobilepayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsMobilepayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsMultibanco(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsMultibancoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsMultibancoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsNaverPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsNaverPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsNaverPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsNzBankAccount(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsNzBankAccountDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsNzBankAccountDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsOxxo(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsOxxoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsOxxoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsP24(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsP24DisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsP24DisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsPayByBank(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsPayByBankDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsPayByBankDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsPayco(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsPaycoDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsPaycoDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsPaynow(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsPaynowDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsPaynowDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsPaypal(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsPaypalDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsPaypalDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsPix(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsPixDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsPixDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsPromptpay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsPromptpayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsPromptpayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsRevolutPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsRevolutPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsRevolutPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsSamsungPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsSamsungPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsSamsungPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsSatispay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsSatispayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsSatispayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsSepaDebit(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsSepaDebitDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsSepaDebitDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsSofort(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsSofortDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsSofortDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsSwish(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsSwishDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsSwishDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsTwint(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsTwintDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsTwintDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsUsBankAccount(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsUsBankAccountDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsUsBankAccountDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsWechatPay(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsWechatPayDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsWechatPayDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
- class UpdateParamsZip(TypedDict):
- display_preference: NotRequired[
- "PaymentMethodConfigurationService.UpdateParamsZipDisplayPreference"
- ]
- """
- Whether or not the payment method should be displayed.
- """
-
- class UpdateParamsZipDisplayPreference(TypedDict):
- preference: NotRequired[Literal["none", "off", "on"]]
- """
- The account's preference for whether or not to display this payment method.
- """
-
def list(
self,
- params: Optional[
- "PaymentMethodConfigurationService.ListParams"
- ] = None,
+ params: Optional["PaymentMethodConfigurationListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PaymentMethodConfiguration]:
"""
@@ -2165,9 +45,7 @@ def list(
async def list_async(
self,
- params: Optional[
- "PaymentMethodConfigurationService.ListParams"
- ] = None,
+ params: Optional["PaymentMethodConfigurationListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PaymentMethodConfiguration]:
"""
@@ -2186,9 +64,7 @@ async def list_async(
def create(
self,
- params: Optional[
- "PaymentMethodConfigurationService.CreateParams"
- ] = None,
+ params: Optional["PaymentMethodConfigurationCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethodConfiguration:
"""
@@ -2207,9 +83,7 @@ def create(
async def create_async(
self,
- params: Optional[
- "PaymentMethodConfigurationService.CreateParams"
- ] = None,
+ params: Optional["PaymentMethodConfigurationCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethodConfiguration:
"""
@@ -2229,9 +103,7 @@ async def create_async(
def retrieve(
self,
configuration: str,
- params: Optional[
- "PaymentMethodConfigurationService.RetrieveParams"
- ] = None,
+ params: Optional["PaymentMethodConfigurationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethodConfiguration:
"""
@@ -2253,9 +125,7 @@ def retrieve(
async def retrieve_async(
self,
configuration: str,
- params: Optional[
- "PaymentMethodConfigurationService.RetrieveParams"
- ] = None,
+ params: Optional["PaymentMethodConfigurationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethodConfiguration:
"""
@@ -2277,9 +147,7 @@ async def retrieve_async(
def update(
self,
configuration: str,
- params: Optional[
- "PaymentMethodConfigurationService.UpdateParams"
- ] = None,
+ params: Optional["PaymentMethodConfigurationUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethodConfiguration:
"""
@@ -2301,9 +169,7 @@ def update(
async def update_async(
self,
configuration: str,
- params: Optional[
- "PaymentMethodConfigurationService.UpdateParams"
- ] = None,
+ params: Optional["PaymentMethodConfigurationUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethodConfiguration:
"""
diff --git a/stripe/_payment_method_domain.py b/stripe/_payment_method_domain.py
index 78f636b50..bf61a3fc9 100644
--- a/stripe/_payment_method_domain.py
+++ b/stripe/_payment_method_domain.py
@@ -3,12 +3,28 @@
from stripe._createable_api_resource import CreateableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, List, Optional, cast, overload
-from typing_extensions import Literal, NotRequired, Unpack
+from typing import ClassVar, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._payment_method_domain_create_params import (
+ PaymentMethodDomainCreateParams,
+ )
+ from stripe.params._payment_method_domain_list_params import (
+ PaymentMethodDomainListParams,
+ )
+ from stripe.params._payment_method_domain_modify_params import (
+ PaymentMethodDomainModifyParams,
+ )
+ from stripe.params._payment_method_domain_retrieve_params import (
+ PaymentMethodDomainRetrieveParams,
+ )
+ from stripe.params._payment_method_domain_validate_params import (
+ PaymentMethodDomainValidateParams,
+ )
class PaymentMethodDomain(
@@ -129,68 +145,6 @@ class StatusDetails(StripeObject):
"""
_inner_class_types = {"status_details": StatusDetails}
- class CreateParams(RequestOptions):
- domain_name: str
- """
- The domain name that this payment method domain object represents.
- """
- enabled: NotRequired[bool]
- """
- Whether this payment method domain is enabled. If the domain is not enabled, payment methods that require a payment method domain will not appear in Elements or Embedded Checkout.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(RequestOptions):
- domain_name: NotRequired[str]
- """
- The domain name that this payment method domain object represents.
- """
- enabled: NotRequired[bool]
- """
- Whether this payment method domain is enabled. If the domain is not enabled, payment methods will not appear in Elements or Embedded Checkout
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ModifyParams(RequestOptions):
- enabled: NotRequired[bool]
- """
- Whether this payment method domain is enabled. If the domain is not enabled, payment methods that require a payment method domain will not appear in Elements or Embedded Checkout.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ValidateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amazon_pay: AmazonPay
"""
Indicates the status of a specific payment method on a payment method domain.
@@ -242,7 +196,7 @@ class ValidateParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["PaymentMethodDomain.CreateParams"]
+ cls, **params: Unpack["PaymentMethodDomainCreateParams"]
) -> "PaymentMethodDomain":
"""
Creates a payment method domain.
@@ -258,7 +212,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["PaymentMethodDomain.CreateParams"]
+ cls, **params: Unpack["PaymentMethodDomainCreateParams"]
) -> "PaymentMethodDomain":
"""
Creates a payment method domain.
@@ -274,7 +228,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["PaymentMethodDomain.ListParams"]
+ cls, **params: Unpack["PaymentMethodDomainListParams"]
) -> ListObject["PaymentMethodDomain"]:
"""
Lists the details of existing payment method domains.
@@ -294,7 +248,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["PaymentMethodDomain.ListParams"]
+ cls, **params: Unpack["PaymentMethodDomainListParams"]
) -> ListObject["PaymentMethodDomain"]:
"""
Lists the details of existing payment method domains.
@@ -314,7 +268,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["PaymentMethodDomain.ModifyParams"]
+ cls, id: str, **params: Unpack["PaymentMethodDomainModifyParams"]
) -> "PaymentMethodDomain":
"""
Updates an existing payment method domain.
@@ -331,7 +285,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["PaymentMethodDomain.ModifyParams"]
+ cls, id: str, **params: Unpack["PaymentMethodDomainModifyParams"]
) -> "PaymentMethodDomain":
"""
Updates an existing payment method domain.
@@ -348,7 +302,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["PaymentMethodDomain.RetrieveParams"]
+ cls, id: str, **params: Unpack["PaymentMethodDomainRetrieveParams"]
) -> "PaymentMethodDomain":
"""
Retrieves the details of an existing payment method domain.
@@ -359,7 +313,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["PaymentMethodDomain.RetrieveParams"]
+ cls, id: str, **params: Unpack["PaymentMethodDomainRetrieveParams"]
) -> "PaymentMethodDomain":
"""
Retrieves the details of an existing payment method domain.
@@ -372,7 +326,7 @@ async def retrieve_async(
def _cls_validate(
cls,
payment_method_domain: str,
- **params: Unpack["PaymentMethodDomain.ValidateParams"],
+ **params: Unpack["PaymentMethodDomainValidateParams"],
) -> "PaymentMethodDomain":
"""
Some payment methods might require additional steps to register a domain. If the requirements weren't satisfied when the domain was created, the payment method will be inactive on the domain.
@@ -397,7 +351,7 @@ def _cls_validate(
@staticmethod
def validate(
payment_method_domain: str,
- **params: Unpack["PaymentMethodDomain.ValidateParams"],
+ **params: Unpack["PaymentMethodDomainValidateParams"],
) -> "PaymentMethodDomain":
"""
Some payment methods might require additional steps to register a domain. If the requirements weren't satisfied when the domain was created, the payment method will be inactive on the domain.
@@ -411,7 +365,7 @@ def validate(
@overload
def validate(
- self, **params: Unpack["PaymentMethodDomain.ValidateParams"]
+ self, **params: Unpack["PaymentMethodDomainValidateParams"]
) -> "PaymentMethodDomain":
"""
Some payment methods might require additional steps to register a domain. If the requirements weren't satisfied when the domain was created, the payment method will be inactive on the domain.
@@ -425,7 +379,7 @@ def validate(
@class_method_variant("_cls_validate")
def validate( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentMethodDomain.ValidateParams"]
+ self, **params: Unpack["PaymentMethodDomainValidateParams"]
) -> "PaymentMethodDomain":
"""
Some payment methods might require additional steps to register a domain. If the requirements weren't satisfied when the domain was created, the payment method will be inactive on the domain.
@@ -450,7 +404,7 @@ def validate( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_validate_async(
cls,
payment_method_domain: str,
- **params: Unpack["PaymentMethodDomain.ValidateParams"],
+ **params: Unpack["PaymentMethodDomainValidateParams"],
) -> "PaymentMethodDomain":
"""
Some payment methods might require additional steps to register a domain. If the requirements weren't satisfied when the domain was created, the payment method will be inactive on the domain.
@@ -475,7 +429,7 @@ async def _cls_validate_async(
@staticmethod
async def validate_async(
payment_method_domain: str,
- **params: Unpack["PaymentMethodDomain.ValidateParams"],
+ **params: Unpack["PaymentMethodDomainValidateParams"],
) -> "PaymentMethodDomain":
"""
Some payment methods might require additional steps to register a domain. If the requirements weren't satisfied when the domain was created, the payment method will be inactive on the domain.
@@ -489,7 +443,7 @@ async def validate_async(
@overload
async def validate_async(
- self, **params: Unpack["PaymentMethodDomain.ValidateParams"]
+ self, **params: Unpack["PaymentMethodDomainValidateParams"]
) -> "PaymentMethodDomain":
"""
Some payment methods might require additional steps to register a domain. If the requirements weren't satisfied when the domain was created, the payment method will be inactive on the domain.
@@ -503,7 +457,7 @@ async def validate_async(
@class_method_variant("_cls_validate_async")
async def validate_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PaymentMethodDomain.ValidateParams"]
+ self, **params: Unpack["PaymentMethodDomainValidateParams"]
) -> "PaymentMethodDomain":
"""
Some payment methods might require additional steps to register a domain. If the requirements weren't satisfied when the domain was created, the payment method will be inactive on the domain.
diff --git a/stripe/_payment_method_domain_service.py b/stripe/_payment_method_domain_service.py
index 4e0948cd2..a45a74502 100644
--- a/stripe/_payment_method_domain_service.py
+++ b/stripe/_payment_method_domain_service.py
@@ -5,76 +5,31 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._payment_method_domain_create_params import (
+ PaymentMethodDomainCreateParams,
+ )
+ from stripe.params._payment_method_domain_list_params import (
+ PaymentMethodDomainListParams,
+ )
+ from stripe.params._payment_method_domain_retrieve_params import (
+ PaymentMethodDomainRetrieveParams,
+ )
+ from stripe.params._payment_method_domain_update_params import (
+ PaymentMethodDomainUpdateParams,
+ )
+ from stripe.params._payment_method_domain_validate_params import (
+ PaymentMethodDomainValidateParams,
+ )
class PaymentMethodDomainService(StripeService):
- class CreateParams(TypedDict):
- domain_name: str
- """
- The domain name that this payment method domain object represents.
- """
- enabled: NotRequired[bool]
- """
- Whether this payment method domain is enabled. If the domain is not enabled, payment methods that require a payment method domain will not appear in Elements or Embedded Checkout.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(TypedDict):
- domain_name: NotRequired[str]
- """
- The domain name that this payment method domain object represents.
- """
- enabled: NotRequired[bool]
- """
- Whether this payment method domain is enabled. If the domain is not enabled, payment methods will not appear in Elements or Embedded Checkout
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- enabled: NotRequired[bool]
- """
- Whether this payment method domain is enabled. If the domain is not enabled, payment methods that require a payment method domain will not appear in Elements or Embedded Checkout.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ValidateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
def list(
self,
- params: Optional["PaymentMethodDomainService.ListParams"] = None,
+ params: Optional["PaymentMethodDomainListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PaymentMethodDomain]:
"""
@@ -93,7 +48,7 @@ def list(
async def list_async(
self,
- params: Optional["PaymentMethodDomainService.ListParams"] = None,
+ params: Optional["PaymentMethodDomainListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PaymentMethodDomain]:
"""
@@ -112,7 +67,7 @@ async def list_async(
def create(
self,
- params: "PaymentMethodDomainService.CreateParams",
+ params: "PaymentMethodDomainCreateParams",
options: Optional[RequestOptions] = None,
) -> PaymentMethodDomain:
"""
@@ -131,7 +86,7 @@ def create(
async def create_async(
self,
- params: "PaymentMethodDomainService.CreateParams",
+ params: "PaymentMethodDomainCreateParams",
options: Optional[RequestOptions] = None,
) -> PaymentMethodDomain:
"""
@@ -151,7 +106,7 @@ async def create_async(
def retrieve(
self,
payment_method_domain: str,
- params: Optional["PaymentMethodDomainService.RetrieveParams"] = None,
+ params: Optional["PaymentMethodDomainRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethodDomain:
"""
@@ -173,7 +128,7 @@ def retrieve(
async def retrieve_async(
self,
payment_method_domain: str,
- params: Optional["PaymentMethodDomainService.RetrieveParams"] = None,
+ params: Optional["PaymentMethodDomainRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethodDomain:
"""
@@ -195,7 +150,7 @@ async def retrieve_async(
def update(
self,
payment_method_domain: str,
- params: Optional["PaymentMethodDomainService.UpdateParams"] = None,
+ params: Optional["PaymentMethodDomainUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethodDomain:
"""
@@ -217,7 +172,7 @@ def update(
async def update_async(
self,
payment_method_domain: str,
- params: Optional["PaymentMethodDomainService.UpdateParams"] = None,
+ params: Optional["PaymentMethodDomainUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethodDomain:
"""
@@ -239,7 +194,7 @@ async def update_async(
def validate(
self,
payment_method_domain: str,
- params: Optional["PaymentMethodDomainService.ValidateParams"] = None,
+ params: Optional["PaymentMethodDomainValidateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethodDomain:
"""
@@ -266,7 +221,7 @@ def validate(
async def validate_async(
self,
payment_method_domain: str,
- params: Optional["PaymentMethodDomainService.ValidateParams"] = None,
+ params: Optional["PaymentMethodDomainValidateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethodDomain:
"""
diff --git a/stripe/_payment_method_service.py b/stripe/_payment_method_service.py
index 42aa9a38e..816036ce3 100644
--- a/stripe/_payment_method_service.py
+++ b/stripe/_payment_method_service.py
@@ -5,981 +5,34 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._payment_method_attach_params import (
+ PaymentMethodAttachParams,
+ )
+ from stripe.params._payment_method_create_params import (
+ PaymentMethodCreateParams,
+ )
+ from stripe.params._payment_method_detach_params import (
+ PaymentMethodDetachParams,
+ )
+ from stripe.params._payment_method_list_params import (
+ PaymentMethodListParams,
+ )
+ from stripe.params._payment_method_retrieve_params import (
+ PaymentMethodRetrieveParams,
+ )
+ from stripe.params._payment_method_update_params import (
+ PaymentMethodUpdateParams,
+ )
class PaymentMethodService(StripeService):
- class AttachParams(TypedDict):
- customer: str
- """
- The ID of the customer to which to attach the PaymentMethod.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(TypedDict):
- acss_debit: NotRequired["PaymentMethodService.CreateParamsAcssDebit"]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired["PaymentMethodService.CreateParamsAffirm"]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "PaymentMethodService.CreateParamsAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired["PaymentMethodService.CreateParamsAlipay"]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired["PaymentMethodService.CreateParamsAlma"]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired["PaymentMethodService.CreateParamsAmazonPay"]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired[
- "PaymentMethodService.CreateParamsAuBecsDebit"
- ]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired["PaymentMethodService.CreateParamsBacsDebit"]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired["PaymentMethodService.CreateParamsBancontact"]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired["PaymentMethodService.CreateParamsBillie"]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "PaymentMethodService.CreateParamsBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired["PaymentMethodService.CreateParamsBlik"]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired["PaymentMethodService.CreateParamsBoleto"]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- card: NotRequired["PaymentMethodService.CreateParamsCard"]
- """
- If this is a `card` PaymentMethod, this hash contains the user's card details. For backwards compatibility, you can alternatively provide a Stripe token (e.g., for Apple Pay, Amex Express Checkout, or legacy Checkout) into the card hash with format `card: {token: "tok_visa"}`. When providing a card number, you must meet the requirements for [PCI compliance](https://stripe.com/docs/security#validating-pci-compliance). We strongly recommend using Stripe.js instead of interacting with this API directly.
- """
- cashapp: NotRequired["PaymentMethodService.CreateParamsCashapp"]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired["PaymentMethodService.CreateParamsCrypto"]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer: NotRequired[str]
- """
- The `Customer` to whom the original PaymentMethod is attached.
- """
- customer_balance: NotRequired[
- "PaymentMethodService.CreateParamsCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired["PaymentMethodService.CreateParamsEps"]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- fpx: NotRequired["PaymentMethodService.CreateParamsFpx"]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired["PaymentMethodService.CreateParamsGiropay"]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired["PaymentMethodService.CreateParamsGrabpay"]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired["PaymentMethodService.CreateParamsIdeal"]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "PaymentMethodService.CreateParamsInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired["PaymentMethodService.CreateParamsKakaoPay"]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired["PaymentMethodService.CreateParamsKlarna"]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired["PaymentMethodService.CreateParamsKonbini"]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired["PaymentMethodService.CreateParamsKrCard"]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired["PaymentMethodService.CreateParamsLink"]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired["PaymentMethodService.CreateParamsMbWay"]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired["PaymentMethodService.CreateParamsMobilepay"]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired["PaymentMethodService.CreateParamsMultibanco"]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired["PaymentMethodService.CreateParamsNaverPay"]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired[
- "PaymentMethodService.CreateParamsNzBankAccount"
- ]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired["PaymentMethodService.CreateParamsOxxo"]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired["PaymentMethodService.CreateParamsP24"]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired["PaymentMethodService.CreateParamsPayByBank"]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired["PaymentMethodService.CreateParamsPayco"]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- payment_method: NotRequired[str]
- """
- The PaymentMethod to share.
- """
- paynow: NotRequired["PaymentMethodService.CreateParamsPaynow"]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired["PaymentMethodService.CreateParamsPaypal"]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired["PaymentMethodService.CreateParamsPix"]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired["PaymentMethodService.CreateParamsPromptpay"]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired[
- "PaymentMethodService.CreateParamsRadarOptions"
- ]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired["PaymentMethodService.CreateParamsRevolutPay"]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired["PaymentMethodService.CreateParamsSamsungPay"]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired["PaymentMethodService.CreateParamsSatispay"]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired["PaymentMethodService.CreateParamsSepaDebit"]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired["PaymentMethodService.CreateParamsSofort"]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired["PaymentMethodService.CreateParamsSwish"]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired["PaymentMethodService.CreateParamsTwint"]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: NotRequired[
- Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "card",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "PaymentMethodService.CreateParamsUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired["PaymentMethodService.CreateParamsWechatPay"]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired["PaymentMethodService.CreateParamsZip"]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class CreateParamsAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class CreateParamsAffirm(TypedDict):
- pass
-
- class CreateParamsAfterpayClearpay(TypedDict):
- pass
-
- class CreateParamsAlipay(TypedDict):
- pass
-
- class CreateParamsAlma(TypedDict):
- pass
-
- class CreateParamsAmazonPay(TypedDict):
- pass
-
- class CreateParamsAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class CreateParamsBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class CreateParamsBancontact(TypedDict):
- pass
-
- class CreateParamsBillie(TypedDict):
- pass
-
- class CreateParamsBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|PaymentMethodService.CreateParamsBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class CreateParamsBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsBlik(TypedDict):
- pass
-
- class CreateParamsBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class CreateParamsCard(TypedDict):
- cvc: NotRequired[str]
- """
- The card's CVC. It is highly recommended to always include this value.
- """
- exp_month: NotRequired[int]
- """
- Two-digit number representing the card's expiration month.
- """
- exp_year: NotRequired[int]
- """
- Four-digit number representing the card's expiration year.
- """
- networks: NotRequired["PaymentMethodService.CreateParamsCardNetworks"]
- """
- Contains information about card networks used to process the payment.
- """
- number: NotRequired[str]
- """
- The card number, as a string without any separators.
- """
- token: NotRequired[str]
- """
- For backwards compatibility, you can alternatively provide a Stripe token (e.g., for Apple Pay, Amex Express Checkout, or legacy Checkout) into the card hash with format card: {token: "tok_visa"}.
- """
-
- class CreateParamsCardNetworks(TypedDict):
- preferred: NotRequired[
- Literal["cartes_bancaires", "mastercard", "visa"]
- ]
- """
- The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
- """
-
- class CreateParamsCashapp(TypedDict):
- pass
-
- class CreateParamsCrypto(TypedDict):
- pass
-
- class CreateParamsCustomerBalance(TypedDict):
- pass
-
- class CreateParamsEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsGiropay(TypedDict):
- pass
-
- class CreateParamsGrabpay(TypedDict):
- pass
-
- class CreateParamsIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class CreateParamsInteracPresent(TypedDict):
- pass
-
- class CreateParamsKakaoPay(TypedDict):
- pass
-
- class CreateParamsKlarna(TypedDict):
- dob: NotRequired["PaymentMethodService.CreateParamsKlarnaDob"]
- """
- Customer's date of birth
- """
-
- class CreateParamsKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsKonbini(TypedDict):
- pass
-
- class CreateParamsKrCard(TypedDict):
- pass
-
- class CreateParamsLink(TypedDict):
- pass
-
- class CreateParamsMbWay(TypedDict):
- pass
-
- class CreateParamsMobilepay(TypedDict):
- pass
-
- class CreateParamsMultibanco(TypedDict):
- pass
-
- class CreateParamsNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class CreateParamsNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class CreateParamsOxxo(TypedDict):
- pass
-
- class CreateParamsP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPayByBank(TypedDict):
- pass
-
- class CreateParamsPayco(TypedDict):
- pass
-
- class CreateParamsPaynow(TypedDict):
- pass
-
- class CreateParamsPaypal(TypedDict):
- pass
-
- class CreateParamsPix(TypedDict):
- pass
-
- class CreateParamsPromptpay(TypedDict):
- pass
-
- class CreateParamsRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class CreateParamsRevolutPay(TypedDict):
- pass
-
- class CreateParamsSamsungPay(TypedDict):
- pass
-
- class CreateParamsSatispay(TypedDict):
- pass
-
- class CreateParamsSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class CreateParamsSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class CreateParamsSwish(TypedDict):
- pass
-
- class CreateParamsTwint(TypedDict):
- pass
-
- class CreateParamsUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class CreateParamsWechatPay(TypedDict):
- pass
-
- class CreateParamsZip(TypedDict):
- pass
-
- class DetachParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(TypedDict):
- customer: NotRequired[str]
- """
- The ID of the customer whose PaymentMethods will be retrieved.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[
- Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "card",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- ]
- """
- An optional filter on the list, based on the object `type` field. Without the filter, the list includes all current and future payment method types. If your integration expects only one type of payment method in the response, make sure to provide a type value in the request.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- billing_details: NotRequired[
- "PaymentMethodService.UpdateParamsBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- card: NotRequired["PaymentMethodService.UpdateParamsCard"]
- """
- If this is a `card` PaymentMethod, this hash contains the user's card details.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- us_bank_account: NotRequired[
- "PaymentMethodService.UpdateParamsUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
-
- class UpdateParamsBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|PaymentMethodService.UpdateParamsBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class UpdateParamsBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsCard(TypedDict):
- exp_month: NotRequired[int]
- """
- Two-digit number representing the card's expiration month.
- """
- exp_year: NotRequired[int]
- """
- Four-digit number representing the card's expiration year.
- """
- networks: NotRequired["PaymentMethodService.UpdateParamsCardNetworks"]
- """
- Contains information about card networks used to process the payment.
- """
-
- class UpdateParamsCardNetworks(TypedDict):
- preferred: NotRequired[
- "Literal['']|Literal['cartes_bancaires', 'mastercard', 'visa']"
- ]
- """
- The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
- """
-
- class UpdateParamsUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Bank account holder type.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Bank account type.
- """
-
def list(
self,
- params: Optional["PaymentMethodService.ListParams"] = None,
+ params: Optional["PaymentMethodListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PaymentMethod]:
"""
@@ -998,7 +51,7 @@ def list(
async def list_async(
self,
- params: Optional["PaymentMethodService.ListParams"] = None,
+ params: Optional["PaymentMethodListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PaymentMethod]:
"""
@@ -1017,7 +70,7 @@ async def list_async(
def create(
self,
- params: Optional["PaymentMethodService.CreateParams"] = None,
+ params: Optional["PaymentMethodCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethod:
"""
@@ -1038,7 +91,7 @@ def create(
async def create_async(
self,
- params: Optional["PaymentMethodService.CreateParams"] = None,
+ params: Optional["PaymentMethodCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethod:
"""
@@ -1060,7 +113,7 @@ async def create_async(
def retrieve(
self,
payment_method: str,
- params: Optional["PaymentMethodService.RetrieveParams"] = None,
+ params: Optional["PaymentMethodRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethod:
"""
@@ -1082,7 +135,7 @@ def retrieve(
async def retrieve_async(
self,
payment_method: str,
- params: Optional["PaymentMethodService.RetrieveParams"] = None,
+ params: Optional["PaymentMethodRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethod:
"""
@@ -1104,7 +157,7 @@ async def retrieve_async(
def update(
self,
payment_method: str,
- params: Optional["PaymentMethodService.UpdateParams"] = None,
+ params: Optional["PaymentMethodUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethod:
"""
@@ -1126,7 +179,7 @@ def update(
async def update_async(
self,
payment_method: str,
- params: Optional["PaymentMethodService.UpdateParams"] = None,
+ params: Optional["PaymentMethodUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethod:
"""
@@ -1148,7 +201,7 @@ async def update_async(
def attach(
self,
payment_method: str,
- params: "PaymentMethodService.AttachParams",
+ params: "PaymentMethodAttachParams",
options: Optional[RequestOptions] = None,
) -> PaymentMethod:
"""
@@ -1182,7 +235,7 @@ def attach(
async def attach_async(
self,
payment_method: str,
- params: "PaymentMethodService.AttachParams",
+ params: "PaymentMethodAttachParams",
options: Optional[RequestOptions] = None,
) -> PaymentMethod:
"""
@@ -1216,7 +269,7 @@ async def attach_async(
def detach(
self,
payment_method: str,
- params: Optional["PaymentMethodService.DetachParams"] = None,
+ params: Optional["PaymentMethodDetachParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethod:
"""
@@ -1238,7 +291,7 @@ def detach(
async def detach_async(
self,
payment_method: str,
- params: Optional["PaymentMethodService.DetachParams"] = None,
+ params: Optional["PaymentMethodDetachParams"] = None,
options: Optional[RequestOptions] = None,
) -> PaymentMethod:
"""
diff --git a/stripe/_payout.py b/stripe/_payout.py
index d000d8181..3f7d7f9ab 100644
--- a/stripe/_payout.py
+++ b/stripe/_payout.py
@@ -4,24 +4,23 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, Dict, List, Optional, Union, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Dict, Optional, Union, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._application_fee import ApplicationFee
from stripe._balance_transaction import BalanceTransaction
from stripe._bank_account import BankAccount
from stripe._card import Card
+ from stripe.params._payout_cancel_params import PayoutCancelParams
+ from stripe.params._payout_create_params import PayoutCreateParams
+ from stripe.params._payout_list_params import PayoutListParams
+ from stripe.params._payout_modify_params import PayoutModifyParams
+ from stripe.params._payout_retrieve_params import PayoutRetrieveParams
+ from stripe.params._payout_reverse_params import PayoutReverseParams
class Payout(
@@ -52,150 +51,6 @@ class TraceId(StripeObject):
The trace ID value if `trace_id.status` is `supported`, otherwise `nil`.
"""
- class CancelParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(RequestOptions):
- amount: int
- """
- A positive integer in cents representing how much to payout.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- destination: NotRequired[str]
- """
- The ID of a bank account or a card to send the payout to. If you don't provide a destination, we use the default external account for the specified currency.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- method: NotRequired[Literal["instant", "standard"]]
- """
- The method used to send this payout, which is `standard` or `instant`. We support `instant` for payouts to debit cards and bank accounts in certain countries. Learn more about [bank support for Instant Payouts](https://stripe.com/docs/payouts/instant-payouts-banks).
- """
- payout_method: NotRequired[str]
- """
- The ID of a v2 FinancialAccount to send funds to.
- """
- source_type: NotRequired[Literal["bank_account", "card", "fpx"]]
- """
- The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the Balances API. One of `bank_account`, `card`, or `fpx`.
- """
- statement_descriptor: NotRequired[str]
- """
- A string that displays on the recipient's bank or card statement (up to 22 characters). A `statement_descriptor` that's longer than 22 characters return an error. Most banks truncate this information and display it inconsistently. Some banks might not display it at all.
- """
-
- class ListParams(RequestOptions):
- arrival_date: NotRequired["Payout.ListParamsArrivalDate|int"]
- """
- Only return payouts that are expected to arrive during the given date interval.
- """
- created: NotRequired["Payout.ListParamsCreated|int"]
- """
- Only return payouts that were created during the given date interval.
- """
- destination: NotRequired[str]
- """
- The ID of an external account - only return payouts sent to this external account.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[str]
- """
- Only return payouts that have the given status: `pending`, `paid`, `failed`, or `canceled`.
- """
-
- class ListParamsArrivalDate(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ReverseParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
amount: int
"""
The amount (in cents (or local equivalent)) that transfers to your bank account or debit card.
@@ -311,7 +166,7 @@ class ReverseParams(RequestOptions):
@classmethod
def _cls_cancel(
- cls, payout: str, **params: Unpack["Payout.CancelParams"]
+ 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.
@@ -330,7 +185,7 @@ def _cls_cancel(
@overload
@staticmethod
def cancel(
- payout: str, **params: Unpack["Payout.CancelParams"]
+ 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.
@@ -338,7 +193,7 @@ def cancel(
...
@overload
- def cancel(self, **params: Unpack["Payout.CancelParams"]) -> "Payout":
+ def cancel(self, **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.
"""
@@ -346,7 +201,7 @@ def cancel(self, **params: Unpack["Payout.CancelParams"]) -> "Payout":
@class_method_variant("_cls_cancel")
def cancel( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Payout.CancelParams"]
+ self, **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.
@@ -364,7 +219,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_cancel_async(
- cls, payout: str, **params: Unpack["Payout.CancelParams"]
+ 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.
@@ -383,7 +238,7 @@ async def _cls_cancel_async(
@overload
@staticmethod
async def cancel_async(
- payout: str, **params: Unpack["Payout.CancelParams"]
+ 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.
@@ -392,7 +247,7 @@ async def cancel_async(
@overload
async def cancel_async(
- self, **params: Unpack["Payout.CancelParams"]
+ self, **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.
@@ -401,7 +256,7 @@ async def cancel_async(
@class_method_variant("_cls_cancel_async")
async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Payout.CancelParams"]
+ self, **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.
@@ -418,7 +273,7 @@ async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
)
@classmethod
- def create(cls, **params: Unpack["Payout.CreateParams"]) -> "Payout":
+ def create(cls, **params: Unpack["PayoutCreateParams"]) -> "Payout":
"""
To send funds to your own bank account, create a new payout object. Your [Stripe balance](https://docs.stripe.com/api#balance) must cover the payout amount. If it doesn't, you receive an “Insufficient Funds” error.
@@ -437,7 +292,7 @@ def create(cls, **params: Unpack["Payout.CreateParams"]) -> "Payout":
@classmethod
async def create_async(
- cls, **params: Unpack["Payout.CreateParams"]
+ cls, **params: Unpack["PayoutCreateParams"]
) -> "Payout":
"""
To send funds to your own bank account, create a new payout object. Your [Stripe balance](https://docs.stripe.com/api#balance) must cover the payout amount. If it doesn't, you receive an “Insufficient Funds” error.
@@ -457,7 +312,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["Payout.ListParams"]
+ cls, **params: Unpack["PayoutListParams"]
) -> ListObject["Payout"]:
"""
Returns a list of existing payouts sent to third-party bank accounts or payouts that Stripe sent to you. The payouts return in sorted order, with the most recently created payouts appearing first.
@@ -477,7 +332,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Payout.ListParams"]
+ cls, **params: Unpack["PayoutListParams"]
) -> ListObject["Payout"]:
"""
Returns a list of existing payouts sent to third-party bank accounts or payouts that Stripe sent to you. The payouts return in sorted order, with the most recently created payouts appearing first.
@@ -497,7 +352,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Payout.ModifyParams"]
+ cls, id: str, **params: Unpack["PayoutModifyParams"]
) -> "Payout":
"""
Updates the specified payout by setting the values of the parameters you pass. We don't change parameters that you don't provide. This request only accepts the metadata as arguments.
@@ -514,7 +369,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Payout.ModifyParams"]
+ cls, id: str, **params: Unpack["PayoutModifyParams"]
) -> "Payout":
"""
Updates the specified payout by setting the values of the parameters you pass. We don't change parameters that you don't provide. This request only accepts the metadata as arguments.
@@ -531,7 +386,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Payout.RetrieveParams"]
+ cls, id: str, **params: Unpack["PayoutRetrieveParams"]
) -> "Payout":
"""
Retrieves the details of an existing payout. Supply the unique payout ID from either a payout creation request or the payout list. Stripe returns the corresponding payout information.
@@ -542,7 +397,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Payout.RetrieveParams"]
+ cls, id: str, **params: Unpack["PayoutRetrieveParams"]
) -> "Payout":
"""
Retrieves the details of an existing payout. Supply the unique payout ID from either a payout creation request or the payout list. Stripe returns the corresponding payout information.
@@ -553,7 +408,7 @@ async def retrieve_async(
@classmethod
def _cls_reverse(
- cls, payout: str, **params: Unpack["Payout.ReverseParams"]
+ 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 bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead.
@@ -574,7 +429,7 @@ def _cls_reverse(
@overload
@staticmethod
def reverse(
- payout: str, **params: Unpack["Payout.ReverseParams"]
+ 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 bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead.
@@ -584,7 +439,7 @@ def reverse(
...
@overload
- def reverse(self, **params: Unpack["Payout.ReverseParams"]) -> "Payout":
+ def reverse(self, **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 bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead.
@@ -594,7 +449,7 @@ def reverse(self, **params: Unpack["Payout.ReverseParams"]) -> "Payout":
@class_method_variant("_cls_reverse")
def reverse( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Payout.ReverseParams"]
+ self, **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 bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead.
@@ -614,7 +469,7 @@ def reverse( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_reverse_async(
- cls, payout: str, **params: Unpack["Payout.ReverseParams"]
+ 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 bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead.
@@ -635,7 +490,7 @@ async def _cls_reverse_async(
@overload
@staticmethod
async def reverse_async(
- payout: str, **params: Unpack["Payout.ReverseParams"]
+ 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 bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead.
@@ -646,7 +501,7 @@ async def reverse_async(
@overload
async def reverse_async(
- self, **params: Unpack["Payout.ReverseParams"]
+ self, **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 bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead.
@@ -657,7 +512,7 @@ async def reverse_async(
@class_method_variant("_cls_reverse_async")
async def reverse_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Payout.ReverseParams"]
+ self, **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 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 ebec17306..31dbed352 100644
--- a/stripe/_payout_service.py
+++ b/stripe/_payout_service.py
@@ -5,158 +5,22 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._payout_cancel_params import PayoutCancelParams
+ from stripe.params._payout_create_params import PayoutCreateParams
+ from stripe.params._payout_list_params import PayoutListParams
+ from stripe.params._payout_retrieve_params import PayoutRetrieveParams
+ from stripe.params._payout_reverse_params import PayoutReverseParams
+ from stripe.params._payout_update_params import PayoutUpdateParams
-class PayoutService(StripeService):
- class CancelParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(TypedDict):
- amount: int
- """
- A positive integer in cents representing how much to payout.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- destination: NotRequired[str]
- """
- The ID of a bank account or a card to send the payout to. If you don't provide a destination, we use the default external account for the specified currency.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- method: NotRequired[Literal["instant", "standard"]]
- """
- The method used to send this payout, which is `standard` or `instant`. We support `instant` for payouts to debit cards and bank accounts in certain countries. Learn more about [bank support for Instant Payouts](https://stripe.com/docs/payouts/instant-payouts-banks).
- """
- payout_method: NotRequired[str]
- """
- The ID of a v2 FinancialAccount to send funds to.
- """
- source_type: NotRequired[Literal["bank_account", "card", "fpx"]]
- """
- The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the Balances API. One of `bank_account`, `card`, or `fpx`.
- """
- statement_descriptor: NotRequired[str]
- """
- A string that displays on the recipient's bank or card statement (up to 22 characters). A `statement_descriptor` that's longer than 22 characters return an error. Most banks truncate this information and display it inconsistently. Some banks might not display it at all.
- """
-
- class ListParams(TypedDict):
- arrival_date: NotRequired["PayoutService.ListParamsArrivalDate|int"]
- """
- Only return payouts that are expected to arrive during the given date interval.
- """
- created: NotRequired["PayoutService.ListParamsCreated|int"]
- """
- Only return payouts that were created during the given date interval.
- """
- destination: NotRequired[str]
- """
- The ID of an external account - only return payouts sent to this external account.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[str]
- """
- Only return payouts that have the given status: `pending`, `paid`, `failed`, or `canceled`.
- """
-
- class ListParamsArrivalDate(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ReverseParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
+class PayoutService(StripeService):
def list(
self,
- params: Optional["PayoutService.ListParams"] = None,
+ params: Optional["PayoutListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Payout]:
"""
@@ -175,7 +39,7 @@ def list(
async def list_async(
self,
- params: Optional["PayoutService.ListParams"] = None,
+ params: Optional["PayoutListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Payout]:
"""
@@ -194,7 +58,7 @@ async def list_async(
def create(
self,
- params: "PayoutService.CreateParams",
+ params: "PayoutCreateParams",
options: Optional[RequestOptions] = None,
) -> Payout:
"""
@@ -217,7 +81,7 @@ def create(
async def create_async(
self,
- params: "PayoutService.CreateParams",
+ params: "PayoutCreateParams",
options: Optional[RequestOptions] = None,
) -> Payout:
"""
@@ -241,7 +105,7 @@ async def create_async(
def retrieve(
self,
payout: str,
- params: Optional["PayoutService.RetrieveParams"] = None,
+ params: Optional["PayoutRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Payout:
"""
@@ -261,7 +125,7 @@ def retrieve(
async def retrieve_async(
self,
payout: str,
- params: Optional["PayoutService.RetrieveParams"] = None,
+ params: Optional["PayoutRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Payout:
"""
@@ -281,7 +145,7 @@ async def retrieve_async(
def update(
self,
payout: str,
- params: Optional["PayoutService.UpdateParams"] = None,
+ params: Optional["PayoutUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Payout:
"""
@@ -301,7 +165,7 @@ def update(
async def update_async(
self,
payout: str,
- params: Optional["PayoutService.UpdateParams"] = None,
+ params: Optional["PayoutUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Payout:
"""
@@ -321,7 +185,7 @@ async def update_async(
def cancel(
self,
payout: str,
- params: Optional["PayoutService.CancelParams"] = None,
+ params: Optional["PayoutCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> Payout:
"""
@@ -343,7 +207,7 @@ def cancel(
async def cancel_async(
self,
payout: str,
- params: Optional["PayoutService.CancelParams"] = None,
+ params: Optional["PayoutCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> Payout:
"""
@@ -365,7 +229,7 @@ async def cancel_async(
def reverse(
self,
payout: str,
- params: Optional["PayoutService.ReverseParams"] = None,
+ params: Optional["PayoutReverseParams"] = None,
options: Optional[RequestOptions] = None,
) -> Payout:
"""
@@ -389,7 +253,7 @@ def reverse(
async def reverse_async(
self,
payout: str,
- params: Optional["PayoutService.ReverseParams"] = None,
+ params: Optional["PayoutReverseParams"] = None,
options: Optional[RequestOptions] = None,
) -> Payout:
"""
diff --git a/stripe/_plan.py b/stripe/_plan.py
index 6a66982df..644a58386 100644
--- a/stripe/_plan.py
+++ b/stripe/_plan.py
@@ -5,21 +5,19 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, Dict, List, Optional, Union, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Dict, List, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._product import Product
+ from stripe.params._plan_create_params import PlanCreateParams
+ from stripe.params._plan_delete_params import PlanDeleteParams
+ from stripe.params._plan_list_params import PlanListParams
+ from stripe.params._plan_modify_params import PlanModifyParams
+ from stripe.params._plan_retrieve_params import PlanRetrieveParams
class Plan(
@@ -73,224 +71,6 @@ class TransformUsage(StripeObject):
After division, either round the result `up` or `down`.
"""
- class CreateParams(RequestOptions):
- active: NotRequired[bool]
- """
- Whether the plan is currently available for new subscriptions. Defaults to `true`.
- """
- amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free plan) representing how much to charge on a recurring basis.
- """
- amount_decimal: NotRequired[str]
- """
- Same as `amount`, but accepts a decimal value with at most 12 decimal places. Only one of `amount` and `amount_decimal` can be set.
- """
- billing_scheme: NotRequired[Literal["per_unit", "tiered"]]
- """
- Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- id: NotRequired[str]
- """
- An identifier randomly generated by Stripe. Used to identify this plan when subscribing a customer. You can optionally override this ID, but the ID must be unique across all plans in your Stripe account. You can, however, use the same plan ID in both live and test modes.
- """
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- meter: NotRequired[str]
- """
- The meter tracking the usage of a metered price
- """
- nickname: NotRequired[str]
- """
- A brief description of the plan, hidden from customers.
- """
- product: NotRequired["Plan.CreateParamsProduct|str"]
- tiers: NotRequired[List["Plan.CreateParamsTier"]]
- """
- Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
- """
- tiers_mode: NotRequired[Literal["graduated", "volume"]]
- """
- Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows.
- """
- transform_usage: NotRequired["Plan.CreateParamsTransformUsage"]
- """
- Apply a transformation to the reported usage or set quantity before computing the billed price. Cannot be combined with `tiers`.
- """
- trial_period_days: NotRequired[int]
- """
- Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
- """
- usage_type: NotRequired[Literal["licensed", "metered"]]
- """
- Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.
- """
-
- class CreateParamsProduct(TypedDict):
- active: NotRequired[bool]
- """
- Whether the product is currently available for purchase. Defaults to `true`.
- """
- id: NotRequired[str]
- """
- The identifier for the product. Must be unique. If not provided, an identifier will be randomly generated.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The product's name, meant to be displayable to the customer.
- """
- statement_descriptor: NotRequired[str]
- """
- An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
-
- This may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- unit_label: NotRequired[str]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
- """
-
- class CreateParamsTier(TypedDict):
- flat_amount: NotRequired[int]
- """
- The flat billing amount for an entire tier, regardless of the number of units in the tier.
- """
- flat_amount_decimal: NotRequired[str]
- """
- Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
- """
- unit_amount: NotRequired[int]
- """
- The per unit billing amount for each individual unit for which this tier applies.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
- up_to: Union[Literal["inf"], int]
- """
- Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
- """
-
- class CreateParamsTransformUsage(TypedDict):
- divide_by: int
- """
- Divide usage by this number.
- """
- round: Literal["down", "up"]
- """
- After division, either round the result `up` or `down`.
- """
-
- class DeleteParams(RequestOptions):
- pass
-
- class ListParams(RequestOptions):
- active: NotRequired[bool]
- """
- Only return plans that are active or inactive (e.g., pass `false` to list all inactive plans).
- """
- created: NotRequired["Plan.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- product: NotRequired[str]
- """
- Only return plans for the given product.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- active: NotRequired[bool]
- """
- Whether the plan is currently available for new subscriptions.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nickname: NotRequired[str]
- """
- A brief description of the plan, hidden from customers.
- """
- product: NotRequired[str]
- """
- The product the plan belongs to. This cannot be changed once it has been used in a subscription or subscription schedule.
- """
- trial_period_days: NotRequired[int]
- """
- Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
active: bool
"""
Whether the plan can be used for new purchases.
@@ -377,7 +157,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["Plan.CreateParams"]) -> "Plan":
+ def create(cls, **params: Unpack["PlanCreateParams"]) -> "Plan":
"""
You can now model subscriptions more flexibly using the [Prices API](https://docs.stripe.com/api#prices). It replaces the Plans API and is backwards compatible to simplify your migration.
"""
@@ -392,7 +172,7 @@ def create(cls, **params: Unpack["Plan.CreateParams"]) -> "Plan":
@classmethod
async def create_async(
- cls, **params: Unpack["Plan.CreateParams"]
+ cls, **params: Unpack["PlanCreateParams"]
) -> "Plan":
"""
You can now model subscriptions more flexibly using the [Prices API](https://docs.stripe.com/api#prices). It replaces the Plans API and is backwards compatible to simplify your migration.
@@ -408,7 +188,7 @@ async def create_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["Plan.DeleteParams"]
+ cls, sid: str, **params: Unpack["PlanDeleteParams"]
) -> "Plan":
"""
Deleting plans means new subscribers can't be added. Existing subscribers aren't affected.
@@ -425,14 +205,14 @@ def _cls_delete(
@overload
@staticmethod
- def delete(sid: str, **params: Unpack["Plan.DeleteParams"]) -> "Plan":
+ def delete(sid: str, **params: Unpack["PlanDeleteParams"]) -> "Plan":
"""
Deleting plans means new subscribers can't be added. Existing subscribers aren't affected.
"""
...
@overload
- def delete(self, **params: Unpack["Plan.DeleteParams"]) -> "Plan":
+ def delete(self, **params: Unpack["PlanDeleteParams"]) -> "Plan":
"""
Deleting plans means new subscribers can't be added. Existing subscribers aren't affected.
"""
@@ -440,7 +220,7 @@ def delete(self, **params: Unpack["Plan.DeleteParams"]) -> "Plan":
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Plan.DeleteParams"]
+ self, **params: Unpack["PlanDeleteParams"]
) -> "Plan":
"""
Deleting plans means new subscribers can't be added. Existing subscribers aren't affected.
@@ -453,7 +233,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["Plan.DeleteParams"]
+ cls, sid: str, **params: Unpack["PlanDeleteParams"]
) -> "Plan":
"""
Deleting plans means new subscribers can't be added. Existing subscribers aren't affected.
@@ -471,7 +251,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["Plan.DeleteParams"]
+ sid: str, **params: Unpack["PlanDeleteParams"]
) -> "Plan":
"""
Deleting plans means new subscribers can't be added. Existing subscribers aren't affected.
@@ -480,7 +260,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["Plan.DeleteParams"]
+ self, **params: Unpack["PlanDeleteParams"]
) -> "Plan":
"""
Deleting plans means new subscribers can't be added. Existing subscribers aren't affected.
@@ -489,7 +269,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Plan.DeleteParams"]
+ self, **params: Unpack["PlanDeleteParams"]
) -> "Plan":
"""
Deleting plans means new subscribers can't be added. Existing subscribers aren't affected.
@@ -501,7 +281,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
)
@classmethod
- def list(cls, **params: Unpack["Plan.ListParams"]) -> ListObject["Plan"]:
+ def list(cls, **params: Unpack["PlanListParams"]) -> ListObject["Plan"]:
"""
Returns a list of your plans.
"""
@@ -520,7 +300,7 @@ def list(cls, **params: Unpack["Plan.ListParams"]) -> ListObject["Plan"]:
@classmethod
async def list_async(
- cls, **params: Unpack["Plan.ListParams"]
+ cls, **params: Unpack["PlanListParams"]
) -> ListObject["Plan"]:
"""
Returns a list of your plans.
@@ -539,7 +319,7 @@ async def list_async(
return result
@classmethod
- def modify(cls, id: str, **params: Unpack["Plan.ModifyParams"]) -> "Plan":
+ def modify(cls, id: str, **params: Unpack["PlanModifyParams"]) -> "Plan":
"""
Updates the specified plan by setting the values of the parameters passed. Any parameters not provided are left unchanged. By design, you cannot change a plan's ID, amount, currency, or billing cycle.
"""
@@ -555,7 +335,7 @@ def modify(cls, id: str, **params: Unpack["Plan.ModifyParams"]) -> "Plan":
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Plan.ModifyParams"]
+ cls, id: str, **params: Unpack["PlanModifyParams"]
) -> "Plan":
"""
Updates the specified plan by setting the values of the parameters passed. Any parameters not provided are left unchanged. By design, you cannot change a plan's ID, amount, currency, or billing cycle.
@@ -572,7 +352,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Plan.RetrieveParams"]
+ cls, id: str, **params: Unpack["PlanRetrieveParams"]
) -> "Plan":
"""
Retrieves the plan with the given ID.
@@ -583,7 +363,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Plan.RetrieveParams"]
+ cls, id: str, **params: Unpack["PlanRetrieveParams"]
) -> "Plan":
"""
Retrieves the plan with the given ID.
diff --git a/stripe/_plan_service.py b/stripe/_plan_service.py
index 30e129018..6050e2c2a 100644
--- a/stripe/_plan_service.py
+++ b/stripe/_plan_service.py
@@ -5,233 +5,22 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, Union, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._plan_create_params import PlanCreateParams
+ from stripe.params._plan_delete_params import PlanDeleteParams
+ from stripe.params._plan_list_params import PlanListParams
+ from stripe.params._plan_retrieve_params import PlanRetrieveParams
+ from stripe.params._plan_update_params import PlanUpdateParams
-class PlanService(StripeService):
- class CreateParams(TypedDict):
- active: NotRequired[bool]
- """
- Whether the plan is currently available for new subscriptions. Defaults to `true`.
- """
- amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free plan) representing how much to charge on a recurring basis.
- """
- amount_decimal: NotRequired[str]
- """
- Same as `amount`, but accepts a decimal value with at most 12 decimal places. Only one of `amount` and `amount_decimal` can be set.
- """
- billing_scheme: NotRequired[Literal["per_unit", "tiered"]]
- """
- Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- id: NotRequired[str]
- """
- An identifier randomly generated by Stripe. Used to identify this plan when subscribing a customer. You can optionally override this ID, but the ID must be unique across all plans in your Stripe account. You can, however, use the same plan ID in both live and test modes.
- """
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- meter: NotRequired[str]
- """
- The meter tracking the usage of a metered price
- """
- nickname: NotRequired[str]
- """
- A brief description of the plan, hidden from customers.
- """
- product: NotRequired["PlanService.CreateParamsProduct|str"]
- tiers: NotRequired[List["PlanService.CreateParamsTier"]]
- """
- Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
- """
- tiers_mode: NotRequired[Literal["graduated", "volume"]]
- """
- Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows.
- """
- transform_usage: NotRequired["PlanService.CreateParamsTransformUsage"]
- """
- Apply a transformation to the reported usage or set quantity before computing the billed price. Cannot be combined with `tiers`.
- """
- trial_period_days: NotRequired[int]
- """
- Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
- """
- usage_type: NotRequired[Literal["licensed", "metered"]]
- """
- Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.
- """
-
- class CreateParamsProduct(TypedDict):
- active: NotRequired[bool]
- """
- Whether the product is currently available for purchase. Defaults to `true`.
- """
- id: NotRequired[str]
- """
- The identifier for the product. Must be unique. If not provided, an identifier will be randomly generated.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The product's name, meant to be displayable to the customer.
- """
- statement_descriptor: NotRequired[str]
- """
- An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
-
- This may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- unit_label: NotRequired[str]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
- """
-
- class CreateParamsTier(TypedDict):
- flat_amount: NotRequired[int]
- """
- The flat billing amount for an entire tier, regardless of the number of units in the tier.
- """
- flat_amount_decimal: NotRequired[str]
- """
- Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
- """
- unit_amount: NotRequired[int]
- """
- The per unit billing amount for each individual unit for which this tier applies.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
- up_to: Union[Literal["inf"], int]
- """
- Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
- """
-
- class CreateParamsTransformUsage(TypedDict):
- divide_by: int
- """
- Divide usage by this number.
- """
- round: Literal["down", "up"]
- """
- After division, either round the result `up` or `down`.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- active: NotRequired[bool]
- """
- Only return plans that are active or inactive (e.g., pass `false` to list all inactive plans).
- """
- created: NotRequired["PlanService.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- product: NotRequired[str]
- """
- Only return plans for the given product.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- active: NotRequired[bool]
- """
- Whether the plan is currently available for new subscriptions.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nickname: NotRequired[str]
- """
- A brief description of the plan, hidden from customers.
- """
- product: NotRequired[str]
- """
- The product the plan belongs to. This cannot be changed once it has been used in a subscription or subscription schedule.
- """
- trial_period_days: NotRequired[int]
- """
- Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
- """
+class PlanService(StripeService):
def delete(
self,
plan: str,
- params: Optional["PlanService.DeleteParams"] = None,
+ params: Optional["PlanDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Plan:
"""
@@ -251,7 +40,7 @@ def delete(
async def delete_async(
self,
plan: str,
- params: Optional["PlanService.DeleteParams"] = None,
+ params: Optional["PlanDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Plan:
"""
@@ -271,7 +60,7 @@ async def delete_async(
def retrieve(
self,
plan: str,
- params: Optional["PlanService.RetrieveParams"] = None,
+ params: Optional["PlanRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Plan:
"""
@@ -291,7 +80,7 @@ def retrieve(
async def retrieve_async(
self,
plan: str,
- params: Optional["PlanService.RetrieveParams"] = None,
+ params: Optional["PlanRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Plan:
"""
@@ -311,7 +100,7 @@ async def retrieve_async(
def update(
self,
plan: str,
- params: Optional["PlanService.UpdateParams"] = None,
+ params: Optional["PlanUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Plan:
"""
@@ -331,7 +120,7 @@ def update(
async def update_async(
self,
plan: str,
- params: Optional["PlanService.UpdateParams"] = None,
+ params: Optional["PlanUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Plan:
"""
@@ -350,7 +139,7 @@ async def update_async(
def list(
self,
- params: Optional["PlanService.ListParams"] = None,
+ params: Optional["PlanListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Plan]:
"""
@@ -369,7 +158,7 @@ def list(
async def list_async(
self,
- params: Optional["PlanService.ListParams"] = None,
+ params: Optional["PlanListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Plan]:
"""
@@ -388,7 +177,7 @@ async def list_async(
def create(
self,
- params: "PlanService.CreateParams",
+ params: "PlanCreateParams",
options: Optional[RequestOptions] = None,
) -> Plan:
"""
@@ -407,7 +196,7 @@ def create(
async def create_async(
self,
- params: "PlanService.CreateParams",
+ params: "PlanCreateParams",
options: Optional[RequestOptions] = None,
) -> Plan:
"""
diff --git a/stripe/_price.py b/stripe/_price.py
index f3f4edaa6..5ba57213c 100644
--- a/stripe/_price.py
+++ b/stripe/_price.py
@@ -4,7 +4,6 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._search_result_object import SearchResultObject
from stripe._searchable_api_resource import SearchableAPIResource
from stripe._stripe_object import StripeObject
@@ -17,19 +16,17 @@
Iterator,
List,
Optional,
- Union,
cast,
)
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._product import Product
+ from stripe.params._price_create_params import PriceCreateParams
+ from stripe.params._price_list_params import PriceListParams
+ from stripe.params._price_modify_params import PriceModifyParams
+ from stripe.params._price_retrieve_params import PriceRetrieveParams
+ from stripe.params._price_search_params import PriceSearchParams
class Price(
@@ -181,464 +178,6 @@ class TransformQuantity(StripeObject):
After division, either round the result `up` or `down`.
"""
- class CreateParams(RequestOptions):
- active: NotRequired[bool]
- """
- Whether the price can be used for new purchases. Defaults to `true`.
- """
- billing_scheme: NotRequired[Literal["per_unit", "tiered"]]
- """
- Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `unit_amount` or `unit_amount_decimal`) will be charged per unit in `quantity` (for prices with `usage_type=licensed`), or per unit of total usage (for prices with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- currency_options: NotRequired[
- Dict[str, "Price.CreateParamsCurrencyOptions"]
- ]
- """
- Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
- custom_unit_amount: NotRequired["Price.CreateParamsCustomUnitAmount"]
- """
- When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- lookup_key: NotRequired[str]
- """
- A lookup key used to retrieve prices dynamically from a static string. This may be up to 200 characters.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nickname: NotRequired[str]
- """
- A brief description of the price, hidden from customers.
- """
- product: NotRequired[str]
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- product_data: NotRequired["Price.CreateParamsProductData"]
- """
- These fields can be used to create a new product that this price will belong to.
- """
- recurring: NotRequired["Price.CreateParamsRecurring"]
- """
- The recurring components of a price such as `interval` and `usage_type`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- tiers: NotRequired[List["Price.CreateParamsTier"]]
- """
- Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
- """
- tiers_mode: NotRequired[Literal["graduated", "volume"]]
- """
- Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows.
- """
- transfer_lookup_key: NotRequired[bool]
- """
- If set to true, will atomically remove the lookup key from the existing price, and assign it to this price.
- """
- transform_quantity: NotRequired["Price.CreateParamsTransformQuantity"]
- """
- Apply a transformation to the reported usage or set quantity before computing the billed price. Cannot be combined with `tiers`.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge. One of `unit_amount`, `unit_amount_decimal`, or `custom_unit_amount` is required, unless `billing_scheme=tiered`.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsCurrencyOptions(TypedDict):
- custom_unit_amount: NotRequired[
- "Price.CreateParamsCurrencyOptionsCustomUnitAmount"
- ]
- """
- When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- tiers: NotRequired[List["Price.CreateParamsCurrencyOptionsTier"]]
- """
- Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsCurrencyOptionsCustomUnitAmount(TypedDict):
- enabled: bool
- """
- Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
- """
- maximum: NotRequired[int]
- """
- The maximum unit amount the customer can specify for this item.
- """
- minimum: NotRequired[int]
- """
- The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
- """
- preset: NotRequired[int]
- """
- The starting unit amount which can be updated by the customer.
- """
-
- class CreateParamsCurrencyOptionsTier(TypedDict):
- flat_amount: NotRequired[int]
- """
- The flat billing amount for an entire tier, regardless of the number of units in the tier.
- """
- flat_amount_decimal: NotRequired[str]
- """
- Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
- """
- unit_amount: NotRequired[int]
- """
- The per unit billing amount for each individual unit for which this tier applies.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
- up_to: Union[Literal["inf"], int]
- """
- Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
- """
-
- class CreateParamsCustomUnitAmount(TypedDict):
- enabled: bool
- """
- Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
- """
- maximum: NotRequired[int]
- """
- The maximum unit amount the customer can specify for this item.
- """
- minimum: NotRequired[int]
- """
- The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
- """
- preset: NotRequired[int]
- """
- The starting unit amount which can be updated by the customer.
- """
-
- class CreateParamsProductData(TypedDict):
- active: NotRequired[bool]
- """
- Whether the product is currently available for purchase. Defaults to `true`.
- """
- id: NotRequired[str]
- """
- The identifier for the product. Must be unique. If not provided, an identifier will be randomly generated.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The product's name, meant to be displayable to the customer.
- """
- statement_descriptor: NotRequired[str]
- """
- An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
-
- This may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- unit_label: NotRequired[str]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
- """
-
- class CreateParamsRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
- meter: NotRequired[str]
- """
- The meter tracking the usage of a metered price
- """
- trial_period_days: NotRequired[int]
- """
- Default number of trial days when subscribing a customer to this price using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
- """
- usage_type: NotRequired[Literal["licensed", "metered"]]
- """
- Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.
- """
-
- class CreateParamsTier(TypedDict):
- flat_amount: NotRequired[int]
- """
- The flat billing amount for an entire tier, regardless of the number of units in the tier.
- """
- flat_amount_decimal: NotRequired[str]
- """
- Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
- """
- unit_amount: NotRequired[int]
- """
- The per unit billing amount for each individual unit for which this tier applies.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
- up_to: Union[Literal["inf"], int]
- """
- Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
- """
-
- class CreateParamsTransformQuantity(TypedDict):
- divide_by: int
- """
- Divide usage by this number.
- """
- round: Literal["down", "up"]
- """
- After division, either round the result `up` or `down`.
- """
-
- class ListParams(RequestOptions):
- active: NotRequired[bool]
- """
- Only return prices that are active or inactive (e.g., pass `false` to list all inactive prices).
- """
- created: NotRequired["Price.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
- """
- currency: NotRequired[str]
- """
- Only return prices for the given currency.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- lookup_keys: NotRequired[List[str]]
- """
- Only return the price with these lookup_keys, if any exist. You can specify up to 10 lookup_keys.
- """
- product: NotRequired[str]
- """
- Only return prices for the given product.
- """
- recurring: NotRequired["Price.ListParamsRecurring"]
- """
- Only return prices with these recurring fields.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[Literal["one_time", "recurring"]]
- """
- Only return prices of type `recurring` or `one_time`.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsRecurring(TypedDict):
- interval: NotRequired[Literal["day", "month", "week", "year"]]
- """
- Filter by billing frequency. Either `day`, `week`, `month` or `year`.
- """
- meter: NotRequired[str]
- """
- Filter by the price's meter.
- """
- usage_type: NotRequired[Literal["licensed", "metered"]]
- """
- Filter by the usage type for this price. Can be either `metered` or `licensed`.
- """
-
- class ModifyParams(RequestOptions):
- active: NotRequired[bool]
- """
- Whether the price can be used for new purchases. Defaults to `true`.
- """
- currency_options: NotRequired[
- "Literal['']|Dict[str, Price.ModifyParamsCurrencyOptions]"
- ]
- """
- Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- lookup_key: NotRequired[str]
- """
- A lookup key used to retrieve prices dynamically from a static string. This may be up to 200 characters.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nickname: NotRequired[str]
- """
- A brief description of the price, hidden from customers.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- transfer_lookup_key: NotRequired[bool]
- """
- If set to true, will atomically remove the lookup key from the existing price, and assign it to this price.
- """
-
- class ModifyParamsCurrencyOptions(TypedDict):
- custom_unit_amount: NotRequired[
- "Price.ModifyParamsCurrencyOptionsCustomUnitAmount"
- ]
- """
- When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- tiers: NotRequired[List["Price.ModifyParamsCurrencyOptionsTier"]]
- """
- Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class ModifyParamsCurrencyOptionsCustomUnitAmount(TypedDict):
- enabled: bool
- """
- Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
- """
- maximum: NotRequired[int]
- """
- The maximum unit amount the customer can specify for this item.
- """
- minimum: NotRequired[int]
- """
- The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
- """
- preset: NotRequired[int]
- """
- The starting unit amount which can be updated by the customer.
- """
-
- class ModifyParamsCurrencyOptionsTier(TypedDict):
- flat_amount: NotRequired[int]
- """
- The flat billing amount for an entire tier, regardless of the number of units in the tier.
- """
- flat_amount_decimal: NotRequired[str]
- """
- Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
- """
- unit_amount: NotRequired[int]
- """
- The per unit billing amount for each individual unit for which this tier applies.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
- up_to: Union[Literal["inf"], int]
- """
- Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SearchParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- page: NotRequired[str]
- """
- A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
- """
- query: str
- """
- The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for prices](https://stripe.com/docs/search#query-fields-for-prices).
- """
-
active: bool
"""
Whether the price can be used for new purchases.
@@ -729,7 +268,7 @@ class SearchParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["Price.CreateParams"]) -> "Price":
+ def create(cls, **params: Unpack["PriceCreateParams"]) -> "Price":
"""
Creates a new [Price for an existing Product](https://docs.stripe.com/api/prices). The Price can be recurring or one-time.
"""
@@ -744,7 +283,7 @@ def create(cls, **params: Unpack["Price.CreateParams"]) -> "Price":
@classmethod
async def create_async(
- cls, **params: Unpack["Price.CreateParams"]
+ cls, **params: Unpack["PriceCreateParams"]
) -> "Price":
"""
Creates a new [Price for an existing Product](https://docs.stripe.com/api/prices). The Price can be recurring or one-time.
@@ -759,7 +298,7 @@ async def create_async(
)
@classmethod
- def list(cls, **params: Unpack["Price.ListParams"]) -> ListObject["Price"]:
+ def list(cls, **params: Unpack["PriceListParams"]) -> ListObject["Price"]:
"""
Returns a list of your active prices, excluding [inline prices](https://docs.stripe.com/docs/products-prices/pricing-models#inline-pricing). For the list of inactive prices, set active to false.
"""
@@ -778,7 +317,7 @@ def list(cls, **params: Unpack["Price.ListParams"]) -> ListObject["Price"]:
@classmethod
async def list_async(
- cls, **params: Unpack["Price.ListParams"]
+ cls, **params: Unpack["PriceListParams"]
) -> ListObject["Price"]:
"""
Returns a list of your active prices, excluding [inline prices](https://docs.stripe.com/docs/products-prices/pricing-models#inline-pricing). For the list of inactive prices, set active to false.
@@ -797,9 +336,7 @@ async def list_async(
return result
@classmethod
- def modify(
- cls, id: str, **params: Unpack["Price.ModifyParams"]
- ) -> "Price":
+ def modify(cls, id: str, **params: Unpack["PriceModifyParams"]) -> "Price":
"""
Updates the specified price by setting the values of the parameters passed. Any parameters not provided are left unchanged.
"""
@@ -815,7 +352,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Price.ModifyParams"]
+ cls, id: str, **params: Unpack["PriceModifyParams"]
) -> "Price":
"""
Updates the specified price by setting the values of the parameters passed. Any parameters not provided are left unchanged.
@@ -832,7 +369,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Price.RetrieveParams"]
+ cls, id: str, **params: Unpack["PriceRetrieveParams"]
) -> "Price":
"""
Retrieves the price with the given ID.
@@ -843,7 +380,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Price.RetrieveParams"]
+ cls, id: str, **params: Unpack["PriceRetrieveParams"]
) -> "Price":
"""
Retrieves the price with the given ID.
@@ -854,7 +391,7 @@ async def retrieve_async(
@classmethod
def search(
- cls, *args, **kwargs: Unpack["Price.SearchParams"]
+ cls, *args, **kwargs: Unpack["PriceSearchParams"]
) -> SearchResultObject["Price"]:
"""
Search for prices you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
@@ -866,7 +403,7 @@ def search(
@classmethod
async def search_async(
- cls, *args, **kwargs: Unpack["Price.SearchParams"]
+ cls, *args, **kwargs: Unpack["PriceSearchParams"]
) -> SearchResultObject["Price"]:
"""
Search for prices you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
@@ -880,13 +417,13 @@ async def search_async(
@classmethod
def search_auto_paging_iter(
- cls, *args, **kwargs: Unpack["Price.SearchParams"]
+ cls, *args, **kwargs: Unpack["PriceSearchParams"]
) -> Iterator["Price"]:
return cls.search(*args, **kwargs).auto_paging_iter()
@classmethod
async def search_auto_paging_iter_async(
- cls, *args, **kwargs: Unpack["Price.SearchParams"]
+ cls, *args, **kwargs: Unpack["PriceSearchParams"]
) -> AsyncIterator["Price"]:
return (await cls.search_async(*args, **kwargs)).auto_paging_iter()
diff --git a/stripe/_price_service.py b/stripe/_price_service.py
index a7837ecc8..48753de6d 100644
--- a/stripe/_price_service.py
+++ b/stripe/_price_service.py
@@ -6,480 +6,21 @@
from stripe._search_result_object import SearchResultObject
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, Union, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._price_create_params import PriceCreateParams
+ from stripe.params._price_list_params import PriceListParams
+ from stripe.params._price_retrieve_params import PriceRetrieveParams
+ from stripe.params._price_search_params import PriceSearchParams
+ from stripe.params._price_update_params import PriceUpdateParams
-class PriceService(StripeService):
- class CreateParams(TypedDict):
- active: NotRequired[bool]
- """
- Whether the price can be used for new purchases. Defaults to `true`.
- """
- billing_scheme: NotRequired[Literal["per_unit", "tiered"]]
- """
- Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `unit_amount` or `unit_amount_decimal`) will be charged per unit in `quantity` (for prices with `usage_type=licensed`), or per unit of total usage (for prices with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- currency_options: NotRequired[
- Dict[str, "PriceService.CreateParamsCurrencyOptions"]
- ]
- """
- Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
- custom_unit_amount: NotRequired[
- "PriceService.CreateParamsCustomUnitAmount"
- ]
- """
- When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- lookup_key: NotRequired[str]
- """
- A lookup key used to retrieve prices dynamically from a static string. This may be up to 200 characters.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nickname: NotRequired[str]
- """
- A brief description of the price, hidden from customers.
- """
- product: NotRequired[str]
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- product_data: NotRequired["PriceService.CreateParamsProductData"]
- """
- These fields can be used to create a new product that this price will belong to.
- """
- recurring: NotRequired["PriceService.CreateParamsRecurring"]
- """
- The recurring components of a price such as `interval` and `usage_type`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- tiers: NotRequired[List["PriceService.CreateParamsTier"]]
- """
- Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
- """
- tiers_mode: NotRequired[Literal["graduated", "volume"]]
- """
- Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows.
- """
- transfer_lookup_key: NotRequired[bool]
- """
- If set to true, will atomically remove the lookup key from the existing price, and assign it to this price.
- """
- transform_quantity: NotRequired[
- "PriceService.CreateParamsTransformQuantity"
- ]
- """
- Apply a transformation to the reported usage or set quantity before computing the billed price. Cannot be combined with `tiers`.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge. One of `unit_amount`, `unit_amount_decimal`, or `custom_unit_amount` is required, unless `billing_scheme=tiered`.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsCurrencyOptions(TypedDict):
- custom_unit_amount: NotRequired[
- "PriceService.CreateParamsCurrencyOptionsCustomUnitAmount"
- ]
- """
- When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- tiers: NotRequired[
- List["PriceService.CreateParamsCurrencyOptionsTier"]
- ]
- """
- Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsCurrencyOptionsCustomUnitAmount(TypedDict):
- enabled: bool
- """
- Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
- """
- maximum: NotRequired[int]
- """
- The maximum unit amount the customer can specify for this item.
- """
- minimum: NotRequired[int]
- """
- The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
- """
- preset: NotRequired[int]
- """
- The starting unit amount which can be updated by the customer.
- """
-
- class CreateParamsCurrencyOptionsTier(TypedDict):
- flat_amount: NotRequired[int]
- """
- The flat billing amount for an entire tier, regardless of the number of units in the tier.
- """
- flat_amount_decimal: NotRequired[str]
- """
- Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
- """
- unit_amount: NotRequired[int]
- """
- The per unit billing amount for each individual unit for which this tier applies.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
- up_to: Union[Literal["inf"], int]
- """
- Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
- """
-
- class CreateParamsCustomUnitAmount(TypedDict):
- enabled: bool
- """
- Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
- """
- maximum: NotRequired[int]
- """
- The maximum unit amount the customer can specify for this item.
- """
- minimum: NotRequired[int]
- """
- The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
- """
- preset: NotRequired[int]
- """
- The starting unit amount which can be updated by the customer.
- """
-
- class CreateParamsProductData(TypedDict):
- active: NotRequired[bool]
- """
- Whether the product is currently available for purchase. Defaults to `true`.
- """
- id: NotRequired[str]
- """
- The identifier for the product. Must be unique. If not provided, an identifier will be randomly generated.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The product's name, meant to be displayable to the customer.
- """
- statement_descriptor: NotRequired[str]
- """
- An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
-
- This may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- unit_label: NotRequired[str]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
- """
-
- class CreateParamsRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
- meter: NotRequired[str]
- """
- The meter tracking the usage of a metered price
- """
- trial_period_days: NotRequired[int]
- """
- Default number of trial days when subscribing a customer to this price using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
- """
- usage_type: NotRequired[Literal["licensed", "metered"]]
- """
- Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.
- """
-
- class CreateParamsTier(TypedDict):
- flat_amount: NotRequired[int]
- """
- The flat billing amount for an entire tier, regardless of the number of units in the tier.
- """
- flat_amount_decimal: NotRequired[str]
- """
- Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
- """
- unit_amount: NotRequired[int]
- """
- The per unit billing amount for each individual unit for which this tier applies.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
- up_to: Union[Literal["inf"], int]
- """
- Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
- """
-
- class CreateParamsTransformQuantity(TypedDict):
- divide_by: int
- """
- Divide usage by this number.
- """
- round: Literal["down", "up"]
- """
- After division, either round the result `up` or `down`.
- """
-
- class ListParams(TypedDict):
- active: NotRequired[bool]
- """
- Only return prices that are active or inactive (e.g., pass `false` to list all inactive prices).
- """
- created: NotRequired["PriceService.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
- """
- currency: NotRequired[str]
- """
- Only return prices for the given currency.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- lookup_keys: NotRequired[List[str]]
- """
- Only return the price with these lookup_keys, if any exist. You can specify up to 10 lookup_keys.
- """
- product: NotRequired[str]
- """
- Only return prices for the given product.
- """
- recurring: NotRequired["PriceService.ListParamsRecurring"]
- """
- Only return prices with these recurring fields.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[Literal["one_time", "recurring"]]
- """
- Only return prices of type `recurring` or `one_time`.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsRecurring(TypedDict):
- interval: NotRequired[Literal["day", "month", "week", "year"]]
- """
- Filter by billing frequency. Either `day`, `week`, `month` or `year`.
- """
- meter: NotRequired[str]
- """
- Filter by the price's meter.
- """
- usage_type: NotRequired[Literal["licensed", "metered"]]
- """
- Filter by the usage type for this price. Can be either `metered` or `licensed`.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SearchParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- page: NotRequired[str]
- """
- A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
- """
- query: str
- """
- The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for prices](https://stripe.com/docs/search#query-fields-for-prices).
- """
-
- class UpdateParams(TypedDict):
- active: NotRequired[bool]
- """
- Whether the price can be used for new purchases. Defaults to `true`.
- """
- currency_options: NotRequired[
- "Literal['']|Dict[str, PriceService.UpdateParamsCurrencyOptions]"
- ]
- """
- Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- lookup_key: NotRequired[str]
- """
- A lookup key used to retrieve prices dynamically from a static string. This may be up to 200 characters.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nickname: NotRequired[str]
- """
- A brief description of the price, hidden from customers.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- transfer_lookup_key: NotRequired[bool]
- """
- If set to true, will atomically remove the lookup key from the existing price, and assign it to this price.
- """
-
- class UpdateParamsCurrencyOptions(TypedDict):
- custom_unit_amount: NotRequired[
- "PriceService.UpdateParamsCurrencyOptionsCustomUnitAmount"
- ]
- """
- When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- tiers: NotRequired[
- List["PriceService.UpdateParamsCurrencyOptionsTier"]
- ]
- """
- Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class UpdateParamsCurrencyOptionsCustomUnitAmount(TypedDict):
- enabled: bool
- """
- Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
- """
- maximum: NotRequired[int]
- """
- The maximum unit amount the customer can specify for this item.
- """
- minimum: NotRequired[int]
- """
- The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
- """
- preset: NotRequired[int]
- """
- The starting unit amount which can be updated by the customer.
- """
-
- class UpdateParamsCurrencyOptionsTier(TypedDict):
- flat_amount: NotRequired[int]
- """
- The flat billing amount for an entire tier, regardless of the number of units in the tier.
- """
- flat_amount_decimal: NotRequired[str]
- """
- Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
- """
- unit_amount: NotRequired[int]
- """
- The per unit billing amount for each individual unit for which this tier applies.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
- up_to: Union[Literal["inf"], int]
- """
- Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
- """
+class PriceService(StripeService):
def list(
self,
- params: Optional["PriceService.ListParams"] = None,
+ params: Optional["PriceListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Price]:
"""
@@ -498,7 +39,7 @@ def list(
async def list_async(
self,
- params: Optional["PriceService.ListParams"] = None,
+ params: Optional["PriceListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Price]:
"""
@@ -517,7 +58,7 @@ async def list_async(
def create(
self,
- params: "PriceService.CreateParams",
+ params: "PriceCreateParams",
options: Optional[RequestOptions] = None,
) -> Price:
"""
@@ -536,7 +77,7 @@ def create(
async def create_async(
self,
- params: "PriceService.CreateParams",
+ params: "PriceCreateParams",
options: Optional[RequestOptions] = None,
) -> Price:
"""
@@ -556,7 +97,7 @@ async def create_async(
def retrieve(
self,
price: str,
- params: Optional["PriceService.RetrieveParams"] = None,
+ params: Optional["PriceRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Price:
"""
@@ -576,7 +117,7 @@ def retrieve(
async def retrieve_async(
self,
price: str,
- params: Optional["PriceService.RetrieveParams"] = None,
+ params: Optional["PriceRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Price:
"""
@@ -596,7 +137,7 @@ async def retrieve_async(
def update(
self,
price: str,
- params: Optional["PriceService.UpdateParams"] = None,
+ params: Optional["PriceUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Price:
"""
@@ -616,7 +157,7 @@ def update(
async def update_async(
self,
price: str,
- params: Optional["PriceService.UpdateParams"] = None,
+ params: Optional["PriceUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Price:
"""
@@ -635,7 +176,7 @@ async def update_async(
def search(
self,
- params: "PriceService.SearchParams",
+ params: "PriceSearchParams",
options: Optional[RequestOptions] = None,
) -> SearchResultObject[Price]:
"""
@@ -657,7 +198,7 @@ def search(
async def search_async(
self,
- params: "PriceService.SearchParams",
+ params: "PriceSearchParams",
options: Optional[RequestOptions] = None,
) -> SearchResultObject[Price]:
"""
diff --git a/stripe/_product.py b/stripe/_product.py
index 3ee2a67cd..aa29a9eae 100644
--- a/stripe/_product.py
+++ b/stripe/_product.py
@@ -6,7 +6,6 @@
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
from stripe._nested_resource_class_methods import nested_resource_class_methods
-from stripe._request_options import RequestOptions
from stripe._search_result_object import SearchResultObject
from stripe._searchable_api_resource import SearchableAPIResource
from stripe._stripe_object import StripeObject
@@ -19,22 +18,33 @@
Iterator,
List,
Optional,
- Union,
cast,
overload,
)
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._price import Price
from stripe._product_feature import ProductFeature
from stripe._tax_code import TaxCode
+ from stripe.params._product_create_feature_params import (
+ ProductCreateFeatureParams,
+ )
+ from stripe.params._product_create_params import ProductCreateParams
+ from stripe.params._product_delete_feature_params import (
+ ProductDeleteFeatureParams,
+ )
+ from stripe.params._product_delete_params import ProductDeleteParams
+ from stripe.params._product_list_features_params import (
+ ProductListFeaturesParams,
+ )
+ from stripe.params._product_list_params import ProductListParams
+ from stripe.params._product_modify_params import ProductModifyParams
+ from stripe.params._product_retrieve_feature_params import (
+ ProductRetrieveFeatureParams,
+ )
+ from stripe.params._product_retrieve_params import ProductRetrieveParams
+ from stripe.params._product_search_params import ProductSearchParams
@nested_resource_class_methods("feature")
@@ -82,454 +92,6 @@ class PackageDimensions(StripeObject):
Width, in inches.
"""
- class CreateFeatureParams(RequestOptions):
- entitlement_feature: str
- """
- The ID of the [Feature](https://stripe.com/docs/api/entitlements/feature) object attached to this product.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(RequestOptions):
- active: NotRequired[bool]
- """
- Whether the product is currently available for purchase. Defaults to `true`.
- """
- default_price_data: NotRequired["Product.CreateParamsDefaultPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object. This Price will be set as the default price for this product.
- """
- description: NotRequired[str]
- """
- The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- id: NotRequired[str]
- """
- An identifier will be randomly generated by Stripe. You can optionally override this ID, but the ID must be unique across all products in your Stripe account.
- """
- images: NotRequired[List[str]]
- """
- A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
- """
- marketing_features: NotRequired[
- List["Product.CreateParamsMarketingFeature"]
- ]
- """
- A list of up to 15 marketing features for this product. These are displayed in [pricing tables](https://stripe.com/docs/payments/checkout/pricing-table).
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The product's name, meant to be displayable to the customer.
- """
- package_dimensions: NotRequired[
- "Product.CreateParamsPackageDimensions"
- ]
- """
- The dimensions of this product for shipping purposes.
- """
- shippable: NotRequired[bool]
- """
- Whether this product is shipped (i.e., physical goods).
- """
- statement_descriptor: NotRequired[str]
- """
- An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
-
- This may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
- It must contain at least one letter. Only used for subscription payments.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- type: NotRequired[Literal["good", "service"]]
- """
- The type of the product. Defaults to `service` if not explicitly specified, enabling use of this product with Subscriptions and Plans. Set this parameter to `good` to use this product with Orders and SKUs. On API versions before `2018-02-05`, this field defaults to `good` for compatibility reasons.
- """
- unit_label: NotRequired[str]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
- """
- url: NotRequired[str]
- """
- A URL of a publicly-accessible webpage for this product.
- """
-
- class CreateParamsDefaultPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- currency_options: NotRequired[
- Dict[str, "Product.CreateParamsDefaultPriceDataCurrencyOptions"]
- ]
- """
- Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
- custom_unit_amount: NotRequired[
- "Product.CreateParamsDefaultPriceDataCustomUnitAmount"
- ]
- """
- When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- recurring: NotRequired["Product.CreateParamsDefaultPriceDataRecurring"]
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge. One of `unit_amount`, `unit_amount_decimal`, or `custom_unit_amount` is required.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsDefaultPriceDataCurrencyOptions(TypedDict):
- custom_unit_amount: NotRequired[
- "Product.CreateParamsDefaultPriceDataCurrencyOptionsCustomUnitAmount"
- ]
- """
- When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- tiers: NotRequired[
- List["Product.CreateParamsDefaultPriceDataCurrencyOptionsTier"]
- ]
- """
- Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsDefaultPriceDataCurrencyOptionsCustomUnitAmount(
- TypedDict,
- ):
- enabled: bool
- """
- Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
- """
- maximum: NotRequired[int]
- """
- The maximum unit amount the customer can specify for this item.
- """
- minimum: NotRequired[int]
- """
- The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
- """
- preset: NotRequired[int]
- """
- The starting unit amount which can be updated by the customer.
- """
-
- class CreateParamsDefaultPriceDataCurrencyOptionsTier(TypedDict):
- flat_amount: NotRequired[int]
- """
- The flat billing amount for an entire tier, regardless of the number of units in the tier.
- """
- flat_amount_decimal: NotRequired[str]
- """
- Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
- """
- unit_amount: NotRequired[int]
- """
- The per unit billing amount for each individual unit for which this tier applies.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
- up_to: Union[Literal["inf"], int]
- """
- Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
- """
-
- class CreateParamsDefaultPriceDataCustomUnitAmount(TypedDict):
- enabled: bool
- """
- Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
- """
- maximum: NotRequired[int]
- """
- The maximum unit amount the customer can specify for this item.
- """
- minimum: NotRequired[int]
- """
- The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
- """
- preset: NotRequired[int]
- """
- The starting unit amount which can be updated by the customer.
- """
-
- class CreateParamsDefaultPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class CreateParamsMarketingFeature(TypedDict):
- name: str
- """
- The marketing feature name. Up to 80 characters long.
- """
-
- class CreateParamsPackageDimensions(TypedDict):
- height: float
- """
- Height, in inches. Maximum precision is 2 decimal places.
- """
- length: float
- """
- Length, in inches. Maximum precision is 2 decimal places.
- """
- weight: float
- """
- Weight, in ounces. Maximum precision is 2 decimal places.
- """
- width: float
- """
- Width, in inches. Maximum precision is 2 decimal places.
- """
-
- class DeleteFeatureParams(RequestOptions):
- pass
-
- class DeleteParams(RequestOptions):
- pass
-
- class ListFeaturesParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParams(RequestOptions):
- active: NotRequired[bool]
- """
- Only return products that are active or inactive (e.g., pass `false` to list all inactive products).
- """
- created: NotRequired["Product.ListParamsCreated|int"]
- """
- Only return products that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- ids: NotRequired[List[str]]
- """
- Only return products with the given IDs. Cannot be used with [starting_after](https://stripe.com/docs/api#list_products-starting_after) or [ending_before](https://stripe.com/docs/api#list_products-ending_before).
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- shippable: NotRequired[bool]
- """
- Only return products that can be shipped (i.e., physical, not digital products).
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[Literal["good", "service"]]
- """
- Only return products of this type.
- """
- url: NotRequired[str]
- """
- Only return products with the given url.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- active: NotRequired[bool]
- """
- Whether the product is available for purchase.
- """
- default_price: NotRequired[str]
- """
- The ID of the [Price](https://stripe.com/docs/api/prices) object that is the default price for this product.
- """
- description: NotRequired["Literal['']|str"]
- """
- The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- images: NotRequired["Literal['']|List[str]"]
- """
- A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
- """
- marketing_features: NotRequired[
- "Literal['']|List[Product.ModifyParamsMarketingFeature]"
- ]
- """
- A list of up to 15 marketing features for this product. These are displayed in [pricing tables](https://stripe.com/docs/payments/checkout/pricing-table).
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- The product's name, meant to be displayable to the customer.
- """
- package_dimensions: NotRequired[
- "Literal['']|Product.ModifyParamsPackageDimensions"
- ]
- """
- The dimensions of this product for shipping purposes.
- """
- shippable: NotRequired[bool]
- """
- Whether this product is shipped (i.e., physical goods).
- """
- statement_descriptor: NotRequired[str]
- """
- An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
-
- This may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
- It must contain at least one letter. May only be set if `type=service`. Only used for subscription payments.
- """
- tax_code: NotRequired["Literal['']|str"]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- unit_label: NotRequired["Literal['']|str"]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal. May only be set if `type=service`.
- """
- url: NotRequired["Literal['']|str"]
- """
- A URL of a publicly-accessible webpage for this product.
- """
-
- class ModifyParamsMarketingFeature(TypedDict):
- name: str
- """
- The marketing feature name. Up to 80 characters long.
- """
-
- class ModifyParamsPackageDimensions(TypedDict):
- height: float
- """
- Height, in inches. Maximum precision is 2 decimal places.
- """
- length: float
- """
- Length, in inches. Maximum precision is 2 decimal places.
- """
- weight: float
- """
- Weight, in ounces. Maximum precision is 2 decimal places.
- """
- width: float
- """
- Width, in inches. Maximum precision is 2 decimal places.
- """
-
- class RetrieveFeatureParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SearchParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- page: NotRequired[str]
- """
- A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
- """
- query: str
- """
- The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for products](https://stripe.com/docs/search#query-fields-for-products).
- """
-
active: bool
"""
Whether the product is currently available for purchase.
@@ -612,7 +174,7 @@ class SearchParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["Product.CreateParams"]) -> "Product":
+ def create(cls, **params: Unpack["ProductCreateParams"]) -> "Product":
"""
Creates a new product object.
"""
@@ -627,7 +189,7 @@ def create(cls, **params: Unpack["Product.CreateParams"]) -> "Product":
@classmethod
async def create_async(
- cls, **params: Unpack["Product.CreateParams"]
+ cls, **params: Unpack["ProductCreateParams"]
) -> "Product":
"""
Creates a new product object.
@@ -643,7 +205,7 @@ async def create_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["Product.DeleteParams"]
+ cls, sid: str, **params: Unpack["ProductDeleteParams"]
) -> "Product":
"""
Delete a product. Deleting a product is only possible if it has no prices associated with it. Additionally, deleting a product with type=good is only possible if it has no SKUs associated with it.
@@ -660,16 +222,14 @@ def _cls_delete(
@overload
@staticmethod
- def delete(
- sid: str, **params: Unpack["Product.DeleteParams"]
- ) -> "Product":
+ def delete(sid: str, **params: Unpack["ProductDeleteParams"]) -> "Product":
"""
Delete a product. Deleting a product is only possible if it has no prices associated with it. Additionally, deleting a product with type=good is only possible if it has no SKUs associated with it.
"""
...
@overload
- def delete(self, **params: Unpack["Product.DeleteParams"]) -> "Product":
+ def delete(self, **params: Unpack["ProductDeleteParams"]) -> "Product":
"""
Delete a product. Deleting a product is only possible if it has no prices associated with it. Additionally, deleting a product with type=good is only possible if it has no SKUs associated with it.
"""
@@ -677,7 +237,7 @@ def delete(self, **params: Unpack["Product.DeleteParams"]) -> "Product":
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Product.DeleteParams"]
+ self, **params: Unpack["ProductDeleteParams"]
) -> "Product":
"""
Delete a product. Deleting a product is only possible if it has no prices associated with it. Additionally, deleting a product with type=good is only possible if it has no SKUs associated with it.
@@ -690,7 +250,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["Product.DeleteParams"]
+ cls, sid: str, **params: Unpack["ProductDeleteParams"]
) -> "Product":
"""
Delete a product. Deleting a product is only possible if it has no prices associated with it. Additionally, deleting a product with type=good is only possible if it has no SKUs associated with it.
@@ -708,7 +268,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["Product.DeleteParams"]
+ sid: str, **params: Unpack["ProductDeleteParams"]
) -> "Product":
"""
Delete a product. Deleting a product is only possible if it has no prices associated with it. Additionally, deleting a product with type=good is only possible if it has no SKUs associated with it.
@@ -717,7 +277,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["Product.DeleteParams"]
+ self, **params: Unpack["ProductDeleteParams"]
) -> "Product":
"""
Delete a product. Deleting a product is only possible if it has no prices associated with it. Additionally, deleting a product with type=good is only possible if it has no SKUs associated with it.
@@ -726,7 +286,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Product.DeleteParams"]
+ self, **params: Unpack["ProductDeleteParams"]
) -> "Product":
"""
Delete a product. Deleting a product is only possible if it has no prices associated with it. Additionally, deleting a product with type=good is only possible if it has no SKUs associated with it.
@@ -739,7 +299,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["Product.ListParams"]
+ cls, **params: Unpack["ProductListParams"]
) -> ListObject["Product"]:
"""
Returns a list of your products. The products are returned sorted by creation date, with the most recently created products appearing first.
@@ -759,7 +319,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Product.ListParams"]
+ cls, **params: Unpack["ProductListParams"]
) -> ListObject["Product"]:
"""
Returns a list of your products. The products are returned sorted by creation date, with the most recently created products appearing first.
@@ -779,7 +339,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Product.ModifyParams"]
+ cls, id: str, **params: Unpack["ProductModifyParams"]
) -> "Product":
"""
Updates the specific product by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -796,7 +356,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Product.ModifyParams"]
+ cls, id: str, **params: Unpack["ProductModifyParams"]
) -> "Product":
"""
Updates the specific product by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -813,7 +373,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Product.RetrieveParams"]
+ cls, id: str, **params: Unpack["ProductRetrieveParams"]
) -> "Product":
"""
Retrieves the details of an existing product. Supply the unique product ID from either a product creation request or the product list, and Stripe will return the corresponding product information.
@@ -824,7 +384,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Product.RetrieveParams"]
+ cls, id: str, **params: Unpack["ProductRetrieveParams"]
) -> "Product":
"""
Retrieves the details of an existing product. Supply the unique product ID from either a product creation request or the product list, and Stripe will return the corresponding product information.
@@ -835,7 +395,7 @@ async def retrieve_async(
@classmethod
def search(
- cls, *args, **kwargs: Unpack["Product.SearchParams"]
+ cls, *args, **kwargs: Unpack["ProductSearchParams"]
) -> SearchResultObject["Product"]:
"""
Search for products you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
@@ -847,7 +407,7 @@ def search(
@classmethod
async def search_async(
- cls, *args, **kwargs: Unpack["Product.SearchParams"]
+ cls, *args, **kwargs: Unpack["ProductSearchParams"]
) -> SearchResultObject["Product"]:
"""
Search for products you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
@@ -861,13 +421,13 @@ async def search_async(
@classmethod
def search_auto_paging_iter(
- cls, *args, **kwargs: Unpack["Product.SearchParams"]
+ cls, *args, **kwargs: Unpack["ProductSearchParams"]
) -> Iterator["Product"]:
return cls.search(*args, **kwargs).auto_paging_iter()
@classmethod
async def search_auto_paging_iter_async(
- cls, *args, **kwargs: Unpack["Product.SearchParams"]
+ cls, *args, **kwargs: Unpack["ProductSearchParams"]
) -> AsyncIterator["Product"]:
return (await cls.search_async(*args, **kwargs)).auto_paging_iter()
@@ -876,7 +436,7 @@ def delete_feature(
cls,
product: str,
id: str,
- **params: Unpack["Product.DeleteFeatureParams"],
+ **params: Unpack["ProductDeleteFeatureParams"],
) -> "ProductFeature":
"""
Deletes the feature attachment to a product
@@ -897,7 +457,7 @@ async def delete_feature_async(
cls,
product: str,
id: str,
- **params: Unpack["Product.DeleteFeatureParams"],
+ **params: Unpack["ProductDeleteFeatureParams"],
) -> "ProductFeature":
"""
Deletes the feature attachment to a product
@@ -918,7 +478,7 @@ def retrieve_feature(
cls,
product: str,
id: str,
- **params: Unpack["Product.RetrieveFeatureParams"],
+ **params: Unpack["ProductRetrieveFeatureParams"],
) -> "ProductFeature":
"""
Retrieves a product_feature, which represents a feature attachment to a product
@@ -939,7 +499,7 @@ async def retrieve_feature_async(
cls,
product: str,
id: str,
- **params: Unpack["Product.RetrieveFeatureParams"],
+ **params: Unpack["ProductRetrieveFeatureParams"],
) -> "ProductFeature":
"""
Retrieves a product_feature, which represents a feature attachment to a product
@@ -957,7 +517,7 @@ async def retrieve_feature_async(
@classmethod
def list_features(
- cls, product: str, **params: Unpack["Product.ListFeaturesParams"]
+ cls, product: str, **params: Unpack["ProductListFeaturesParams"]
) -> ListObject["ProductFeature"]:
"""
Retrieve a list of features for a product
@@ -975,7 +535,7 @@ def list_features(
@classmethod
async def list_features_async(
- cls, product: str, **params: Unpack["Product.ListFeaturesParams"]
+ cls, product: str, **params: Unpack["ProductListFeaturesParams"]
) -> ListObject["ProductFeature"]:
"""
Retrieve a list of features for a product
@@ -993,7 +553,7 @@ async def list_features_async(
@classmethod
def create_feature(
- cls, product: str, **params: Unpack["Product.CreateFeatureParams"]
+ cls, product: str, **params: Unpack["ProductCreateFeatureParams"]
) -> "ProductFeature":
"""
Creates a product_feature, which represents a feature attachment to a product
@@ -1011,7 +571,7 @@ def create_feature(
@classmethod
async def create_feature_async(
- cls, product: str, **params: Unpack["Product.CreateFeatureParams"]
+ 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 cb3c5bb42..6b51bf496 100644
--- a/stripe/_product_feature_service.py
+++ b/stripe/_product_feature_service.py
@@ -5,53 +5,30 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._product_feature_create_params import (
+ ProductFeatureCreateParams,
+ )
+ from stripe.params._product_feature_delete_params import (
+ ProductFeatureDeleteParams,
+ )
+ from stripe.params._product_feature_list_params import (
+ ProductFeatureListParams,
+ )
+ from stripe.params._product_feature_retrieve_params import (
+ ProductFeatureRetrieveParams,
+ )
-class ProductFeatureService(StripeService):
- class CreateParams(TypedDict):
- entitlement_feature: str
- """
- The ID of the [Feature](https://stripe.com/docs/api/entitlements/feature) object attached to this product.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class ProductFeatureService(StripeService):
def delete(
self,
product: str,
id: str,
- params: Optional["ProductFeatureService.DeleteParams"] = None,
+ params: Optional["ProductFeatureDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> ProductFeature:
"""
@@ -75,7 +52,7 @@ async def delete_async(
self,
product: str,
id: str,
- params: Optional["ProductFeatureService.DeleteParams"] = None,
+ params: Optional["ProductFeatureDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> ProductFeature:
"""
@@ -99,7 +76,7 @@ def retrieve(
self,
product: str,
id: str,
- params: Optional["ProductFeatureService.RetrieveParams"] = None,
+ params: Optional["ProductFeatureRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ProductFeature:
"""
@@ -123,7 +100,7 @@ async def retrieve_async(
self,
product: str,
id: str,
- params: Optional["ProductFeatureService.RetrieveParams"] = None,
+ params: Optional["ProductFeatureRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ProductFeature:
"""
@@ -146,7 +123,7 @@ async def retrieve_async(
def list(
self,
product: str,
- params: Optional["ProductFeatureService.ListParams"] = None,
+ params: Optional["ProductFeatureListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ProductFeature]:
"""
@@ -168,7 +145,7 @@ def list(
async def list_async(
self,
product: str,
- params: Optional["ProductFeatureService.ListParams"] = None,
+ params: Optional["ProductFeatureListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ProductFeature]:
"""
@@ -190,7 +167,7 @@ async def list_async(
def create(
self,
product: str,
- params: "ProductFeatureService.CreateParams",
+ params: "ProductFeatureCreateParams",
options: Optional[RequestOptions] = None,
) -> ProductFeature:
"""
@@ -212,7 +189,7 @@ def create(
async def create_async(
self,
product: str,
- params: "ProductFeatureService.CreateParams",
+ params: "ProductFeatureCreateParams",
options: Optional[RequestOptions] = None,
) -> ProductFeature:
"""
diff --git a/stripe/_product_service.py b/stripe/_product_service.py
index e2d532098..31c85f4af 100644
--- a/stripe/_product_service.py
+++ b/stripe/_product_service.py
@@ -7,8 +7,16 @@
from stripe._search_result_object import SearchResultObject
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, Union, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._product_create_params import ProductCreateParams
+ from stripe.params._product_delete_params import ProductDeleteParams
+ from stripe.params._product_list_params import ProductListParams
+ from stripe.params._product_retrieve_params import ProductRetrieveParams
+ from stripe.params._product_search_params import ProductSearchParams
+ from stripe.params._product_update_params import ProductUpdateParams
class ProductService(StripeService):
@@ -16,430 +24,10 @@ def __init__(self, requestor):
super().__init__(requestor)
self.features = ProductFeatureService(self._requestor)
- class CreateParams(TypedDict):
- active: NotRequired[bool]
- """
- Whether the product is currently available for purchase. Defaults to `true`.
- """
- default_price_data: NotRequired[
- "ProductService.CreateParamsDefaultPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object. This Price will be set as the default price for this product.
- """
- description: NotRequired[str]
- """
- The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- id: NotRequired[str]
- """
- An identifier will be randomly generated by Stripe. You can optionally override this ID, but the ID must be unique across all products in your Stripe account.
- """
- images: NotRequired[List[str]]
- """
- A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
- """
- marketing_features: NotRequired[
- List["ProductService.CreateParamsMarketingFeature"]
- ]
- """
- A list of up to 15 marketing features for this product. These are displayed in [pricing tables](https://stripe.com/docs/payments/checkout/pricing-table).
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The product's name, meant to be displayable to the customer.
- """
- package_dimensions: NotRequired[
- "ProductService.CreateParamsPackageDimensions"
- ]
- """
- The dimensions of this product for shipping purposes.
- """
- shippable: NotRequired[bool]
- """
- Whether this product is shipped (i.e., physical goods).
- """
- statement_descriptor: NotRequired[str]
- """
- An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
-
- This may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
- It must contain at least one letter. Only used for subscription payments.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- type: NotRequired[Literal["good", "service"]]
- """
- The type of the product. Defaults to `service` if not explicitly specified, enabling use of this product with Subscriptions and Plans. Set this parameter to `good` to use this product with Orders and SKUs. On API versions before `2018-02-05`, this field defaults to `good` for compatibility reasons.
- """
- unit_label: NotRequired[str]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
- """
- url: NotRequired[str]
- """
- A URL of a publicly-accessible webpage for this product.
- """
-
- class CreateParamsDefaultPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- currency_options: NotRequired[
- Dict[
- str,
- "ProductService.CreateParamsDefaultPriceDataCurrencyOptions",
- ]
- ]
- """
- Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
- custom_unit_amount: NotRequired[
- "ProductService.CreateParamsDefaultPriceDataCustomUnitAmount"
- ]
- """
- When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- recurring: NotRequired[
- "ProductService.CreateParamsDefaultPriceDataRecurring"
- ]
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge. One of `unit_amount`, `unit_amount_decimal`, or `custom_unit_amount` is required.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsDefaultPriceDataCurrencyOptions(TypedDict):
- custom_unit_amount: NotRequired[
- "ProductService.CreateParamsDefaultPriceDataCurrencyOptionsCustomUnitAmount"
- ]
- """
- When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- tiers: NotRequired[
- List[
- "ProductService.CreateParamsDefaultPriceDataCurrencyOptionsTier"
- ]
- ]
- """
- Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsDefaultPriceDataCurrencyOptionsCustomUnitAmount(
- TypedDict,
- ):
- enabled: bool
- """
- Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
- """
- maximum: NotRequired[int]
- """
- The maximum unit amount the customer can specify for this item.
- """
- minimum: NotRequired[int]
- """
- The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
- """
- preset: NotRequired[int]
- """
- The starting unit amount which can be updated by the customer.
- """
-
- class CreateParamsDefaultPriceDataCurrencyOptionsTier(TypedDict):
- flat_amount: NotRequired[int]
- """
- The flat billing amount for an entire tier, regardless of the number of units in the tier.
- """
- flat_amount_decimal: NotRequired[str]
- """
- Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
- """
- unit_amount: NotRequired[int]
- """
- The per unit billing amount for each individual unit for which this tier applies.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
- up_to: Union[Literal["inf"], int]
- """
- Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
- """
-
- class CreateParamsDefaultPriceDataCustomUnitAmount(TypedDict):
- enabled: bool
- """
- Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
- """
- maximum: NotRequired[int]
- """
- The maximum unit amount the customer can specify for this item.
- """
- minimum: NotRequired[int]
- """
- The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
- """
- preset: NotRequired[int]
- """
- The starting unit amount which can be updated by the customer.
- """
-
- class CreateParamsDefaultPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class CreateParamsMarketingFeature(TypedDict):
- name: str
- """
- The marketing feature name. Up to 80 characters long.
- """
-
- class CreateParamsPackageDimensions(TypedDict):
- height: float
- """
- Height, in inches. Maximum precision is 2 decimal places.
- """
- length: float
- """
- Length, in inches. Maximum precision is 2 decimal places.
- """
- weight: float
- """
- Weight, in ounces. Maximum precision is 2 decimal places.
- """
- width: float
- """
- Width, in inches. Maximum precision is 2 decimal places.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- active: NotRequired[bool]
- """
- Only return products that are active or inactive (e.g., pass `false` to list all inactive products).
- """
- created: NotRequired["ProductService.ListParamsCreated|int"]
- """
- Only return products that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- ids: NotRequired[List[str]]
- """
- Only return products with the given IDs. Cannot be used with [starting_after](https://stripe.com/docs/api#list_products-starting_after) or [ending_before](https://stripe.com/docs/api#list_products-ending_before).
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- shippable: NotRequired[bool]
- """
- Only return products that can be shipped (i.e., physical, not digital products).
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[Literal["good", "service"]]
- """
- Only return products of this type.
- """
- url: NotRequired[str]
- """
- Only return products with the given url.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SearchParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- page: NotRequired[str]
- """
- A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
- """
- query: str
- """
- The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for products](https://stripe.com/docs/search#query-fields-for-products).
- """
-
- class UpdateParams(TypedDict):
- active: NotRequired[bool]
- """
- Whether the product is available for purchase.
- """
- default_price: NotRequired[str]
- """
- The ID of the [Price](https://stripe.com/docs/api/prices) object that is the default price for this product.
- """
- description: NotRequired["Literal['']|str"]
- """
- The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- images: NotRequired["Literal['']|List[str]"]
- """
- A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
- """
- marketing_features: NotRequired[
- "Literal['']|List[ProductService.UpdateParamsMarketingFeature]"
- ]
- """
- A list of up to 15 marketing features for this product. These are displayed in [pricing tables](https://stripe.com/docs/payments/checkout/pricing-table).
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- The product's name, meant to be displayable to the customer.
- """
- package_dimensions: NotRequired[
- "Literal['']|ProductService.UpdateParamsPackageDimensions"
- ]
- """
- The dimensions of this product for shipping purposes.
- """
- shippable: NotRequired[bool]
- """
- Whether this product is shipped (i.e., physical goods).
- """
- statement_descriptor: NotRequired[str]
- """
- An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
-
- This may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
- It must contain at least one letter. May only be set if `type=service`. Only used for subscription payments.
- """
- tax_code: NotRequired["Literal['']|str"]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- unit_label: NotRequired["Literal['']|str"]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal. May only be set if `type=service`.
- """
- url: NotRequired["Literal['']|str"]
- """
- A URL of a publicly-accessible webpage for this product.
- """
-
- class UpdateParamsMarketingFeature(TypedDict):
- name: str
- """
- The marketing feature name. Up to 80 characters long.
- """
-
- class UpdateParamsPackageDimensions(TypedDict):
- height: float
- """
- Height, in inches. Maximum precision is 2 decimal places.
- """
- length: float
- """
- Length, in inches. Maximum precision is 2 decimal places.
- """
- weight: float
- """
- Weight, in ounces. Maximum precision is 2 decimal places.
- """
- width: float
- """
- Width, in inches. Maximum precision is 2 decimal places.
- """
-
def delete(
self,
id: str,
- params: Optional["ProductService.DeleteParams"] = None,
+ params: Optional["ProductDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Product:
"""
@@ -459,7 +47,7 @@ def delete(
async def delete_async(
self,
id: str,
- params: Optional["ProductService.DeleteParams"] = None,
+ params: Optional["ProductDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Product:
"""
@@ -479,7 +67,7 @@ async def delete_async(
def retrieve(
self,
id: str,
- params: Optional["ProductService.RetrieveParams"] = None,
+ params: Optional["ProductRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Product:
"""
@@ -499,7 +87,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["ProductService.RetrieveParams"] = None,
+ params: Optional["ProductRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Product:
"""
@@ -519,7 +107,7 @@ async def retrieve_async(
def update(
self,
id: str,
- params: Optional["ProductService.UpdateParams"] = None,
+ params: Optional["ProductUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Product:
"""
@@ -539,7 +127,7 @@ def update(
async def update_async(
self,
id: str,
- params: Optional["ProductService.UpdateParams"] = None,
+ params: Optional["ProductUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Product:
"""
@@ -558,7 +146,7 @@ async def update_async(
def list(
self,
- params: Optional["ProductService.ListParams"] = None,
+ params: Optional["ProductListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Product]:
"""
@@ -577,7 +165,7 @@ def list(
async def list_async(
self,
- params: Optional["ProductService.ListParams"] = None,
+ params: Optional["ProductListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Product]:
"""
@@ -596,7 +184,7 @@ async def list_async(
def create(
self,
- params: "ProductService.CreateParams",
+ params: "ProductCreateParams",
options: Optional[RequestOptions] = None,
) -> Product:
"""
@@ -615,7 +203,7 @@ def create(
async def create_async(
self,
- params: "ProductService.CreateParams",
+ params: "ProductCreateParams",
options: Optional[RequestOptions] = None,
) -> Product:
"""
@@ -634,7 +222,7 @@ async def create_async(
def search(
self,
- params: "ProductService.SearchParams",
+ params: "ProductSearchParams",
options: Optional[RequestOptions] = None,
) -> SearchResultObject[Product]:
"""
@@ -656,7 +244,7 @@ def search(
async def search_async(
self,
- params: "ProductService.SearchParams",
+ params: "ProductSearchParams",
options: Optional[RequestOptions] = None,
) -> SearchResultObject[Product]:
"""
diff --git a/stripe/_promotion_code.py b/stripe/_promotion_code.py
index 2b2c6630e..d97e75dea 100644
--- a/stripe/_promotion_code.py
+++ b/stripe/_promotion_code.py
@@ -4,22 +4,27 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import sanitize_id
-from typing import ClassVar, Dict, List, Optional, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Dict, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._coupon import Coupon
from stripe._customer import Customer
+ from stripe.params._promotion_code_create_params import (
+ PromotionCodeCreateParams,
+ )
+ from stripe.params._promotion_code_list_params import (
+ PromotionCodeListParams,
+ )
+ from stripe.params._promotion_code_modify_params import (
+ PromotionCodeModifyParams,
+ )
+ from stripe.params._promotion_code_retrieve_params import (
+ PromotionCodeRetrieveParams,
+ )
class PromotionCode(
@@ -73,176 +78,6 @@ class CurrencyOptions(StripeObject):
_inner_class_types = {"currency_options": CurrencyOptions}
_inner_class_dicts = ["currency_options"]
- class CreateParams(RequestOptions):
- active: NotRequired[bool]
- """
- Whether the promotion code is currently active.
- """
- code: NotRequired[str]
- """
- The customer-facing code. Regardless of case, this code must be unique across all active promotion codes for a specific customer. Valid characters are lower case letters (a-z), upper case letters (A-Z), and digits (0-9).
-
- If left blank, we will generate one automatically.
- """
- customer: NotRequired[str]
- """
- The customer that this promotion code can be used by. If not set, the promotion code can be used by all customers.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- The timestamp at which this promotion code will expire. If the coupon has specified a `redeems_by`, then this value cannot be after the coupon's `redeems_by`.
- """
- max_redemptions: NotRequired[int]
- """
- A positive integer specifying the number of times the promotion code can be redeemed. If the coupon has specified a `max_redemptions`, then this value cannot be greater than the coupon's `max_redemptions`.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- promotion: "PromotionCode.CreateParamsPromotion"
- """
- The promotion referenced by this promotion code.
- """
- restrictions: NotRequired["PromotionCode.CreateParamsRestrictions"]
- """
- Settings that restrict the redemption of the promotion code.
- """
-
- class CreateParamsPromotion(TypedDict):
- coupon: NotRequired[str]
- """
- If promotion `type` is `coupon`, the coupon for this promotion code.
- """
- type: Literal["coupon"]
- """
- Specifies the type of promotion.
- """
-
- class CreateParamsRestrictions(TypedDict):
- currency_options: NotRequired[
- Dict[str, "PromotionCode.CreateParamsRestrictionsCurrencyOptions"]
- ]
- """
- Promotion codes defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
- first_time_transaction: NotRequired[bool]
- """
- A Boolean indicating if the Promotion Code should only be redeemed for Customers without any successful payments or invoices
- """
- minimum_amount: NotRequired[int]
- """
- Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
- """
- minimum_amount_currency: NotRequired[str]
- """
- Three-letter [ISO code](https://stripe.com/docs/currencies) for minimum_amount
- """
-
- class CreateParamsRestrictionsCurrencyOptions(TypedDict):
- minimum_amount: NotRequired[int]
- """
- Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
- """
-
- class ListParams(RequestOptions):
- active: NotRequired[bool]
- """
- Filter promotion codes by whether they are active.
- """
- code: NotRequired[str]
- """
- Only return promotion codes that have this case-insensitive code.
- """
- coupon: NotRequired[str]
- """
- Only return promotion codes for this coupon.
- """
- created: NotRequired["PromotionCode.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
- """
- customer: NotRequired[str]
- """
- Only return promotion codes that are restricted to this customer.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- active: NotRequired[bool]
- """
- Whether the promotion code is currently active. A promotion code can only be reactivated when the coupon is still valid and the promotion code is otherwise redeemable.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- restrictions: NotRequired["PromotionCode.ModifyParamsRestrictions"]
- """
- Settings that restrict the redemption of the promotion code.
- """
-
- class ModifyParamsRestrictions(TypedDict):
- currency_options: NotRequired[
- Dict[str, "PromotionCode.ModifyParamsRestrictionsCurrencyOptions"]
- ]
- """
- Promotion codes defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class ModifyParamsRestrictionsCurrencyOptions(TypedDict):
- minimum_amount: NotRequired[int]
- """
- Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
active: bool
"""
Whether the promotion code is currently active. A promotion code is only active if the coupon is also valid.
@@ -292,7 +127,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["PromotionCode.CreateParams"]
+ cls, **params: Unpack["PromotionCodeCreateParams"]
) -> "PromotionCode":
"""
A promotion code points to an underlying promotion. You can optionally restrict the code to a specific customer, redemption limit, and expiration date.
@@ -308,7 +143,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["PromotionCode.CreateParams"]
+ cls, **params: Unpack["PromotionCodeCreateParams"]
) -> "PromotionCode":
"""
A promotion code points to an underlying promotion. You can optionally restrict the code to a specific customer, redemption limit, and expiration date.
@@ -324,7 +159,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["PromotionCode.ListParams"]
+ cls, **params: Unpack["PromotionCodeListParams"]
) -> ListObject["PromotionCode"]:
"""
Returns a list of your promotion codes.
@@ -344,7 +179,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["PromotionCode.ListParams"]
+ cls, **params: Unpack["PromotionCodeListParams"]
) -> ListObject["PromotionCode"]:
"""
Returns a list of your promotion codes.
@@ -364,7 +199,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["PromotionCode.ModifyParams"]
+ cls, id: str, **params: Unpack["PromotionCodeModifyParams"]
) -> "PromotionCode":
"""
Updates the specified promotion code by setting the values of the parameters passed. Most fields are, by design, not editable.
@@ -381,7 +216,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["PromotionCode.ModifyParams"]
+ cls, id: str, **params: Unpack["PromotionCodeModifyParams"]
) -> "PromotionCode":
"""
Updates the specified promotion code by setting the values of the parameters passed. Most fields are, by design, not editable.
@@ -398,7 +233,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["PromotionCode.RetrieveParams"]
+ cls, id: str, **params: Unpack["PromotionCodeRetrieveParams"]
) -> "PromotionCode":
"""
Retrieves the promotion code with the given ID. In order to retrieve a promotion code by the customer-facing code use [list](https://docs.stripe.com/docs/api/promotion_codes/list) with the desired code.
@@ -409,7 +244,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["PromotionCode.RetrieveParams"]
+ cls, id: str, **params: Unpack["PromotionCodeRetrieveParams"]
) -> "PromotionCode":
"""
Retrieves the promotion code with the given ID. In order to retrieve a promotion code by the customer-facing code use [list](https://docs.stripe.com/docs/api/promotion_codes/list) with the desired code.
diff --git a/stripe/_promotion_code_service.py b/stripe/_promotion_code_service.py
index f735b2463..7c93faa8c 100644
--- a/stripe/_promotion_code_service.py
+++ b/stripe/_promotion_code_service.py
@@ -5,194 +5,28 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._promotion_code_create_params import (
+ PromotionCodeCreateParams,
+ )
+ from stripe.params._promotion_code_list_params import (
+ PromotionCodeListParams,
+ )
+ from stripe.params._promotion_code_retrieve_params import (
+ PromotionCodeRetrieveParams,
+ )
+ from stripe.params._promotion_code_update_params import (
+ PromotionCodeUpdateParams,
+ )
class PromotionCodeService(StripeService):
- class CreateParams(TypedDict):
- active: NotRequired[bool]
- """
- Whether the promotion code is currently active.
- """
- code: NotRequired[str]
- """
- The customer-facing code. Regardless of case, this code must be unique across all active promotion codes for a specific customer. Valid characters are lower case letters (a-z), upper case letters (A-Z), and digits (0-9).
-
- If left blank, we will generate one automatically.
- """
- customer: NotRequired[str]
- """
- The customer that this promotion code can be used by. If not set, the promotion code can be used by all customers.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- The timestamp at which this promotion code will expire. If the coupon has specified a `redeems_by`, then this value cannot be after the coupon's `redeems_by`.
- """
- max_redemptions: NotRequired[int]
- """
- A positive integer specifying the number of times the promotion code can be redeemed. If the coupon has specified a `max_redemptions`, then this value cannot be greater than the coupon's `max_redemptions`.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- promotion: "PromotionCodeService.CreateParamsPromotion"
- """
- The promotion referenced by this promotion code.
- """
- restrictions: NotRequired[
- "PromotionCodeService.CreateParamsRestrictions"
- ]
- """
- Settings that restrict the redemption of the promotion code.
- """
-
- class CreateParamsPromotion(TypedDict):
- coupon: NotRequired[str]
- """
- If promotion `type` is `coupon`, the coupon for this promotion code.
- """
- type: Literal["coupon"]
- """
- Specifies the type of promotion.
- """
-
- class CreateParamsRestrictions(TypedDict):
- currency_options: NotRequired[
- Dict[
- str,
- "PromotionCodeService.CreateParamsRestrictionsCurrencyOptions",
- ]
- ]
- """
- Promotion codes defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
- first_time_transaction: NotRequired[bool]
- """
- A Boolean indicating if the Promotion Code should only be redeemed for Customers without any successful payments or invoices
- """
- minimum_amount: NotRequired[int]
- """
- Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
- """
- minimum_amount_currency: NotRequired[str]
- """
- Three-letter [ISO code](https://stripe.com/docs/currencies) for minimum_amount
- """
-
- class CreateParamsRestrictionsCurrencyOptions(TypedDict):
- minimum_amount: NotRequired[int]
- """
- Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
- """
-
- class ListParams(TypedDict):
- active: NotRequired[bool]
- """
- Filter promotion codes by whether they are active.
- """
- code: NotRequired[str]
- """
- Only return promotion codes that have this case-insensitive code.
- """
- coupon: NotRequired[str]
- """
- Only return promotion codes for this coupon.
- """
- created: NotRequired["PromotionCodeService.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
- """
- customer: NotRequired[str]
- """
- Only return promotion codes that are restricted to this customer.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- active: NotRequired[bool]
- """
- Whether the promotion code is currently active. A promotion code can only be reactivated when the coupon is still valid and the promotion code is otherwise redeemable.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- restrictions: NotRequired[
- "PromotionCodeService.UpdateParamsRestrictions"
- ]
- """
- Settings that restrict the redemption of the promotion code.
- """
-
- class UpdateParamsRestrictions(TypedDict):
- currency_options: NotRequired[
- Dict[
- str,
- "PromotionCodeService.UpdateParamsRestrictionsCurrencyOptions",
- ]
- ]
- """
- Promotion codes defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class UpdateParamsRestrictionsCurrencyOptions(TypedDict):
- minimum_amount: NotRequired[int]
- """
- Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
- """
-
def list(
self,
- params: Optional["PromotionCodeService.ListParams"] = None,
+ params: Optional["PromotionCodeListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PromotionCode]:
"""
@@ -211,7 +45,7 @@ def list(
async def list_async(
self,
- params: Optional["PromotionCodeService.ListParams"] = None,
+ params: Optional["PromotionCodeListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PromotionCode]:
"""
@@ -230,7 +64,7 @@ async def list_async(
def create(
self,
- params: "PromotionCodeService.CreateParams",
+ params: "PromotionCodeCreateParams",
options: Optional[RequestOptions] = None,
) -> PromotionCode:
"""
@@ -249,7 +83,7 @@ def create(
async def create_async(
self,
- params: "PromotionCodeService.CreateParams",
+ params: "PromotionCodeCreateParams",
options: Optional[RequestOptions] = None,
) -> PromotionCode:
"""
@@ -269,7 +103,7 @@ async def create_async(
def retrieve(
self,
promotion_code: str,
- params: Optional["PromotionCodeService.RetrieveParams"] = None,
+ params: Optional["PromotionCodeRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PromotionCode:
"""
@@ -291,7 +125,7 @@ def retrieve(
async def retrieve_async(
self,
promotion_code: str,
- params: Optional["PromotionCodeService.RetrieveParams"] = None,
+ params: Optional["PromotionCodeRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PromotionCode:
"""
@@ -313,7 +147,7 @@ async def retrieve_async(
def update(
self,
promotion_code: str,
- params: Optional["PromotionCodeService.UpdateParams"] = None,
+ params: Optional["PromotionCodeUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PromotionCode:
"""
@@ -335,7 +169,7 @@ def update(
async def update_async(
self,
promotion_code: str,
- params: Optional["PromotionCodeService.UpdateParams"] = None,
+ params: Optional["PromotionCodeUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PromotionCode:
"""
diff --git a/stripe/_quote.py b/stripe/_quote.py
index b6e4041f7..7319501a1 100644
--- a/stripe/_quote.py
+++ b/stripe/_quote.py
@@ -4,18 +4,11 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import Any, ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account
@@ -27,6 +20,22 @@
from stripe._subscription import Subscription
from stripe._subscription_schedule import SubscriptionSchedule
from stripe._tax_rate import TaxRate
+ from stripe.params._quote_accept_params import QuoteAcceptParams
+ from stripe.params._quote_cancel_params import QuoteCancelParams
+ from stripe.params._quote_create_params import QuoteCreateParams
+ from stripe.params._quote_finalize_quote_params import (
+ QuoteFinalizeQuoteParams,
+ )
+ from stripe.params._quote_list_computed_upfront_line_items_params import (
+ QuoteListComputedUpfrontLineItemsParams,
+ )
+ from stripe.params._quote_list_line_items_params import (
+ QuoteListLineItemsParams,
+ )
+ from stripe.params._quote_list_params import QuoteListParams
+ from stripe.params._quote_modify_params import QuoteModifyParams
+ from stripe.params._quote_pdf_params import QuotePdfParams
+ from stripe.params._quote_retrieve_params import QuoteRetrieveParams
from stripe.test_helpers._test_clock import TestClock
@@ -444,636 +453,6 @@ class TransferData(StripeObject):
The account where funds from the payment will be transferred to upon payment success.
"""
- class AcceptParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CancelParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(RequestOptions):
- application_fee_amount: NotRequired["Literal['']|int"]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field.
- """
- application_fee_percent: NotRequired["Literal['']|float"]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
- """
- automatic_tax: NotRequired["Quote.CreateParamsAutomaticTax"]
- """
- Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
- """
- customer: NotRequired[str]
- """
- The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates that will apply to any line item that does not have `tax_rates` set.
- """
- description: NotRequired["Literal['']|str"]
- """
- A description that will be displayed on the quote PDF. If no value is passed, the default description configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
- """
- discounts: NotRequired["Literal['']|List[Quote.CreateParamsDiscount]"]
- """
- The discounts applied to the quote.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch. If no value is passed, the default expiration date configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
- """
- footer: NotRequired["Literal['']|str"]
- """
- A footer that will be displayed on the quote PDF. If no value is passed, the default footer configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
- """
- from_quote: NotRequired["Quote.CreateParamsFromQuote"]
- """
- Clone an existing quote. The new quote will be created in `status=draft`. When using this parameter, you cannot specify any other parameters except for `expires_at`.
- """
- header: NotRequired["Literal['']|str"]
- """
- A header that will be displayed on the quote PDF. If no value is passed, the default header configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
- """
- invoice_settings: NotRequired["Quote.CreateParamsInvoiceSettings"]
- """
- All invoices will be billed using the specified settings.
- """
- line_items: NotRequired[List["Quote.CreateParamsLineItem"]]
- """
- A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account on behalf of which to charge.
- """
- subscription_data: NotRequired["Quote.CreateParamsSubscriptionData"]
- """
- When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if `subscription_data[effective_date]` is present and in the future, otherwise a subscription is created.
- """
- test_clock: NotRequired[str]
- """
- ID of the test clock to attach to the quote.
- """
- transfer_data: NotRequired[
- "Literal['']|Quote.CreateParamsTransferData"
- ]
- """
- The data with which to automatically create a Transfer for each of the invoices.
- """
-
- class CreateParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Controls whether Stripe will automatically compute tax on the resulting invoices or subscriptions as well as the quote itself.
- """
- liability: NotRequired["Quote.CreateParamsAutomaticTaxLiability"]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreateParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsFromQuote(TypedDict):
- is_revision: NotRequired[bool]
- """
- Whether this quote is a revision of the previous quote.
- """
- quote: str
- """
- The `id` of the quote that will be cloned.
- """
-
- class CreateParamsInvoiceSettings(TypedDict):
- days_until_due: NotRequired[int]
- """
- Number of days within which a customer must pay the invoice generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
- """
- issuer: NotRequired["Quote.CreateParamsInvoiceSettingsIssuer"]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class CreateParamsInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsLineItem(TypedDict):
- discounts: NotRequired[
- "Literal['']|List[Quote.CreateParamsLineItemDiscount]"
- ]
- """
- The discounts applied to this line item.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired["Quote.CreateParamsLineItemPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- The quantity of the line item.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the line item. When set, the `default_tax_rates` on the quote do not apply to this line item.
- """
-
- class CreateParamsLineItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsLineItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: NotRequired["Quote.CreateParamsLineItemPriceDataRecurring"]
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsLineItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class CreateParamsSubscriptionData(TypedDict):
- billing_mode: NotRequired[
- "Quote.CreateParamsSubscriptionDataBillingMode"
- ]
- """
- Controls how prorations and invoices for subscriptions are calculated and orchestrated.
- """
- description: NotRequired[str]
- """
- The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- effective_date: NotRequired[
- "Literal['']|Literal['current_period_end']|int"
- ]
- """
- When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. The `effective_date` is ignored if it is in the past when the quote is accepted.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
- """
- trial_period_days: NotRequired["Literal['']|int"]
- """
- Integer representing the number of trial period days before the customer is charged for the first time.
- """
-
- class CreateParamsSubscriptionDataBillingMode(TypedDict):
- flexible: NotRequired[
- "Quote.CreateParamsSubscriptionDataBillingModeFlexible"
- ]
- """
- Configure behavior for flexible billing mode.
- """
- type: Literal["classic", "flexible"]
- """
- Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
- """
-
- class CreateParamsSubscriptionDataBillingModeFlexible(TypedDict):
- proration_discounts: NotRequired[Literal["included", "itemized"]]
- """
- Controls how invoices and invoice items display proration amounts and discount amounts.
- """
-
- class CreateParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
- """
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination. There must be at least 1 line item with a recurring price to use this field.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class FinalizeQuoteParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.
- """
-
- class ListComputedUpfrontLineItemsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListLineItemsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParams(RequestOptions):
- customer: NotRequired[str]
- """
- The ID of the customer whose quotes will be retrieved.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["accepted", "canceled", "draft", "open"]]
- """
- The status of the quote.
- """
- test_clock: NotRequired[str]
- """
- Provides a list of quotes that are associated with the specified test clock. The response will not include quotes with test clocks if this and the customer parameter is not set.
- """
-
- class ModifyParams(RequestOptions):
- application_fee_amount: NotRequired["Literal['']|int"]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field.
- """
- application_fee_percent: NotRequired["Literal['']|float"]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
- """
- automatic_tax: NotRequired["Quote.ModifyParamsAutomaticTax"]
- """
- Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
- """
- customer: NotRequired[str]
- """
- The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates that will apply to any line item that does not have `tax_rates` set.
- """
- description: NotRequired["Literal['']|str"]
- """
- A description that will be displayed on the quote PDF.
- """
- discounts: NotRequired["Literal['']|List[Quote.ModifyParamsDiscount]"]
- """
- The discounts applied to the quote.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.
- """
- footer: NotRequired["Literal['']|str"]
- """
- A footer that will be displayed on the quote PDF.
- """
- header: NotRequired["Literal['']|str"]
- """
- A header that will be displayed on the quote PDF.
- """
- invoice_settings: NotRequired["Quote.ModifyParamsInvoiceSettings"]
- """
- All invoices will be billed using the specified settings.
- """
- line_items: NotRequired[List["Quote.ModifyParamsLineItem"]]
- """
- A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account on behalf of which to charge.
- """
- subscription_data: NotRequired["Quote.ModifyParamsSubscriptionData"]
- """
- When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if `subscription_data[effective_date]` is present and in the future, otherwise a subscription is created.
- """
- transfer_data: NotRequired[
- "Literal['']|Quote.ModifyParamsTransferData"
- ]
- """
- The data with which to automatically create a Transfer for each of the invoices.
- """
-
- class ModifyParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Controls whether Stripe will automatically compute tax on the resulting invoices or subscriptions as well as the quote itself.
- """
- liability: NotRequired["Quote.ModifyParamsAutomaticTaxLiability"]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class ModifyParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class ModifyParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class ModifyParamsInvoiceSettings(TypedDict):
- days_until_due: NotRequired[int]
- """
- Number of days within which a customer must pay the invoice generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
- """
- issuer: NotRequired["Quote.ModifyParamsInvoiceSettingsIssuer"]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class ModifyParamsInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class ModifyParamsLineItem(TypedDict):
- discounts: NotRequired[
- "Literal['']|List[Quote.ModifyParamsLineItemDiscount]"
- ]
- """
- The discounts applied to this line item.
- """
- id: NotRequired[str]
- """
- The ID of an existing line item on the quote.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired["Quote.ModifyParamsLineItemPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- The quantity of the line item.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the line item. When set, the `default_tax_rates` on the quote do not apply to this line item.
- """
-
- class ModifyParamsLineItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class ModifyParamsLineItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: NotRequired["Quote.ModifyParamsLineItemPriceDataRecurring"]
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class ModifyParamsLineItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class ModifyParamsSubscriptionData(TypedDict):
- description: NotRequired["Literal['']|str"]
- """
- The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- effective_date: NotRequired[
- "Literal['']|Literal['current_period_end']|int"
- ]
- """
- When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. The `effective_date` is ignored if it is in the past when the quote is accepted.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
- """
- trial_period_days: NotRequired["Literal['']|int"]
- """
- Integer representing the number of trial period days before the customer is charged for the first time.
- """
-
- class ModifyParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
- """
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination. There must be at least 1 line item with a recurring price to use this field.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class PdfParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount_subtotal: int
"""
Total before any discounts or taxes are applied.
@@ -1199,7 +578,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def _cls_accept(
- cls, quote: str, **params: Unpack["Quote.AcceptParams"]
+ cls, quote: str, **params: Unpack["QuoteAcceptParams"]
) -> "Quote":
"""
Accepts the specified quote.
@@ -1215,14 +594,14 @@ def _cls_accept(
@overload
@staticmethod
- def accept(quote: str, **params: Unpack["Quote.AcceptParams"]) -> "Quote":
+ def accept(quote: str, **params: Unpack["QuoteAcceptParams"]) -> "Quote":
"""
Accepts the specified quote.
"""
...
@overload
- def accept(self, **params: Unpack["Quote.AcceptParams"]) -> "Quote":
+ def accept(self, **params: Unpack["QuoteAcceptParams"]) -> "Quote":
"""
Accepts the specified quote.
"""
@@ -1230,7 +609,7 @@ def accept(self, **params: Unpack["Quote.AcceptParams"]) -> "Quote":
@class_method_variant("_cls_accept")
def accept( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Quote.AcceptParams"]
+ self, **params: Unpack["QuoteAcceptParams"]
) -> "Quote":
"""
Accepts the specified quote.
@@ -1248,7 +627,7 @@ def accept( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_accept_async(
- cls, quote: str, **params: Unpack["Quote.AcceptParams"]
+ cls, quote: str, **params: Unpack["QuoteAcceptParams"]
) -> "Quote":
"""
Accepts the specified quote.
@@ -1265,7 +644,7 @@ async def _cls_accept_async(
@overload
@staticmethod
async def accept_async(
- quote: str, **params: Unpack["Quote.AcceptParams"]
+ quote: str, **params: Unpack["QuoteAcceptParams"]
) -> "Quote":
"""
Accepts the specified quote.
@@ -1274,7 +653,7 @@ async def accept_async(
@overload
async def accept_async(
- self, **params: Unpack["Quote.AcceptParams"]
+ self, **params: Unpack["QuoteAcceptParams"]
) -> "Quote":
"""
Accepts the specified quote.
@@ -1283,7 +662,7 @@ async def accept_async(
@class_method_variant("_cls_accept_async")
async def accept_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Quote.AcceptParams"]
+ self, **params: Unpack["QuoteAcceptParams"]
) -> "Quote":
"""
Accepts the specified quote.
@@ -1301,7 +680,7 @@ async def accept_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_cancel(
- cls, quote: str, **params: Unpack["Quote.CancelParams"]
+ cls, quote: str, **params: Unpack["QuoteCancelParams"]
) -> "Quote":
"""
Cancels the quote.
@@ -1317,14 +696,14 @@ def _cls_cancel(
@overload
@staticmethod
- def cancel(quote: str, **params: Unpack["Quote.CancelParams"]) -> "Quote":
+ def cancel(quote: str, **params: Unpack["QuoteCancelParams"]) -> "Quote":
"""
Cancels the quote.
"""
...
@overload
- def cancel(self, **params: Unpack["Quote.CancelParams"]) -> "Quote":
+ def cancel(self, **params: Unpack["QuoteCancelParams"]) -> "Quote":
"""
Cancels the quote.
"""
@@ -1332,7 +711,7 @@ def cancel(self, **params: Unpack["Quote.CancelParams"]) -> "Quote":
@class_method_variant("_cls_cancel")
def cancel( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Quote.CancelParams"]
+ self, **params: Unpack["QuoteCancelParams"]
) -> "Quote":
"""
Cancels the quote.
@@ -1350,7 +729,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_cancel_async(
- cls, quote: str, **params: Unpack["Quote.CancelParams"]
+ cls, quote: str, **params: Unpack["QuoteCancelParams"]
) -> "Quote":
"""
Cancels the quote.
@@ -1367,7 +746,7 @@ async def _cls_cancel_async(
@overload
@staticmethod
async def cancel_async(
- quote: str, **params: Unpack["Quote.CancelParams"]
+ quote: str, **params: Unpack["QuoteCancelParams"]
) -> "Quote":
"""
Cancels the quote.
@@ -1376,7 +755,7 @@ async def cancel_async(
@overload
async def cancel_async(
- self, **params: Unpack["Quote.CancelParams"]
+ self, **params: Unpack["QuoteCancelParams"]
) -> "Quote":
"""
Cancels the quote.
@@ -1385,7 +764,7 @@ async def cancel_async(
@class_method_variant("_cls_cancel_async")
async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Quote.CancelParams"]
+ self, **params: Unpack["QuoteCancelParams"]
) -> "Quote":
"""
Cancels the quote.
@@ -1402,7 +781,7 @@ async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
)
@classmethod
- def create(cls, **params: Unpack["Quote.CreateParams"]) -> "Quote":
+ def create(cls, **params: Unpack["QuoteCreateParams"]) -> "Quote":
"""
A quote models prices and services for a customer. Default options for header, description, footer, and expires_at can be set in the dashboard via the [quote template](https://dashboard.stripe.com/settings/billing/quote).
"""
@@ -1417,7 +796,7 @@ def create(cls, **params: Unpack["Quote.CreateParams"]) -> "Quote":
@classmethod
async def create_async(
- cls, **params: Unpack["Quote.CreateParams"]
+ cls, **params: Unpack["QuoteCreateParams"]
) -> "Quote":
"""
A quote models prices and services for a customer. Default options for header, description, footer, and expires_at can be set in the dashboard via the [quote template](https://dashboard.stripe.com/settings/billing/quote).
@@ -1433,7 +812,7 @@ async def create_async(
@classmethod
def _cls_finalize_quote(
- cls, quote: str, **params: Unpack["Quote.FinalizeQuoteParams"]
+ cls, quote: str, **params: Unpack["QuoteFinalizeQuoteParams"]
) -> "Quote":
"""
Finalizes the quote.
@@ -1450,7 +829,7 @@ def _cls_finalize_quote(
@overload
@staticmethod
def finalize_quote(
- quote: str, **params: Unpack["Quote.FinalizeQuoteParams"]
+ quote: str, **params: Unpack["QuoteFinalizeQuoteParams"]
) -> "Quote":
"""
Finalizes the quote.
@@ -1459,7 +838,7 @@ def finalize_quote(
@overload
def finalize_quote(
- self, **params: Unpack["Quote.FinalizeQuoteParams"]
+ self, **params: Unpack["QuoteFinalizeQuoteParams"]
) -> "Quote":
"""
Finalizes the quote.
@@ -1468,7 +847,7 @@ def finalize_quote(
@class_method_variant("_cls_finalize_quote")
def finalize_quote( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Quote.FinalizeQuoteParams"]
+ self, **params: Unpack["QuoteFinalizeQuoteParams"]
) -> "Quote":
"""
Finalizes the quote.
@@ -1486,7 +865,7 @@ def finalize_quote( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_finalize_quote_async(
- cls, quote: str, **params: Unpack["Quote.FinalizeQuoteParams"]
+ cls, quote: str, **params: Unpack["QuoteFinalizeQuoteParams"]
) -> "Quote":
"""
Finalizes the quote.
@@ -1503,7 +882,7 @@ async def _cls_finalize_quote_async(
@overload
@staticmethod
async def finalize_quote_async(
- quote: str, **params: Unpack["Quote.FinalizeQuoteParams"]
+ quote: str, **params: Unpack["QuoteFinalizeQuoteParams"]
) -> "Quote":
"""
Finalizes the quote.
@@ -1512,7 +891,7 @@ async def finalize_quote_async(
@overload
async def finalize_quote_async(
- self, **params: Unpack["Quote.FinalizeQuoteParams"]
+ self, **params: Unpack["QuoteFinalizeQuoteParams"]
) -> "Quote":
"""
Finalizes the quote.
@@ -1521,7 +900,7 @@ async def finalize_quote_async(
@class_method_variant("_cls_finalize_quote_async")
async def finalize_quote_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Quote.FinalizeQuoteParams"]
+ self, **params: Unpack["QuoteFinalizeQuoteParams"]
) -> "Quote":
"""
Finalizes the quote.
@@ -1538,7 +917,7 @@ async def finalize_quote_async( # pyright: ignore[reportGeneralTypeIssues]
)
@classmethod
- def list(cls, **params: Unpack["Quote.ListParams"]) -> ListObject["Quote"]:
+ def list(cls, **params: Unpack["QuoteListParams"]) -> ListObject["Quote"]:
"""
Returns a list of your quotes.
"""
@@ -1557,7 +936,7 @@ def list(cls, **params: Unpack["Quote.ListParams"]) -> ListObject["Quote"]:
@classmethod
async def list_async(
- cls, **params: Unpack["Quote.ListParams"]
+ cls, **params: Unpack["QuoteListParams"]
) -> ListObject["Quote"]:
"""
Returns a list of your quotes.
@@ -1579,7 +958,7 @@ async def list_async(
def _cls_list_computed_upfront_line_items(
cls,
quote: str,
- **params: Unpack["Quote.ListComputedUpfrontLineItemsParams"],
+ **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.
@@ -1598,8 +977,7 @@ def _cls_list_computed_upfront_line_items(
@overload
@staticmethod
def list_computed_upfront_line_items(
- quote: str,
- **params: Unpack["Quote.ListComputedUpfrontLineItemsParams"],
+ 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.
@@ -1608,7 +986,7 @@ def list_computed_upfront_line_items(
@overload
def list_computed_upfront_line_items(
- self, **params: Unpack["Quote.ListComputedUpfrontLineItemsParams"]
+ self, **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.
@@ -1617,7 +995,7 @@ def list_computed_upfront_line_items(
@class_method_variant("_cls_list_computed_upfront_line_items")
def list_computed_upfront_line_items( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Quote.ListComputedUpfrontLineItemsParams"]
+ self, **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.
@@ -1637,7 +1015,7 @@ def list_computed_upfront_line_items( # pyright: ignore[reportGeneralTypeIssues
async def _cls_list_computed_upfront_line_items_async(
cls,
quote: str,
- **params: Unpack["Quote.ListComputedUpfrontLineItemsParams"],
+ **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.
@@ -1656,8 +1034,7 @@ async def _cls_list_computed_upfront_line_items_async(
@overload
@staticmethod
async def list_computed_upfront_line_items_async(
- quote: str,
- **params: Unpack["Quote.ListComputedUpfrontLineItemsParams"],
+ 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.
@@ -1666,7 +1043,7 @@ async def list_computed_upfront_line_items_async(
@overload
async def list_computed_upfront_line_items_async(
- self, **params: Unpack["Quote.ListComputedUpfrontLineItemsParams"]
+ self, **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.
@@ -1675,7 +1052,7 @@ async def list_computed_upfront_line_items_async(
@class_method_variant("_cls_list_computed_upfront_line_items_async")
async def list_computed_upfront_line_items_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Quote.ListComputedUpfrontLineItemsParams"]
+ self, **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.
@@ -1693,7 +1070,7 @@ async def list_computed_upfront_line_items_async( # pyright: ignore[reportGener
@classmethod
def _cls_list_line_items(
- cls, quote: str, **params: Unpack["Quote.ListLineItemsParams"]
+ 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.
@@ -1712,7 +1089,7 @@ def _cls_list_line_items(
@overload
@staticmethod
def list_line_items(
- quote: str, **params: Unpack["Quote.ListLineItemsParams"]
+ 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.
@@ -1721,7 +1098,7 @@ def list_line_items(
@overload
def list_line_items(
- self, **params: Unpack["Quote.ListLineItemsParams"]
+ self, **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.
@@ -1730,7 +1107,7 @@ def list_line_items(
@class_method_variant("_cls_list_line_items")
def list_line_items( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Quote.ListLineItemsParams"]
+ self, **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.
@@ -1748,7 +1125,7 @@ def list_line_items( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_list_line_items_async(
- cls, quote: str, **params: Unpack["Quote.ListLineItemsParams"]
+ 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.
@@ -1767,7 +1144,7 @@ async def _cls_list_line_items_async(
@overload
@staticmethod
async def list_line_items_async(
- quote: str, **params: Unpack["Quote.ListLineItemsParams"]
+ 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.
@@ -1776,7 +1153,7 @@ async def list_line_items_async(
@overload
async def list_line_items_async(
- self, **params: Unpack["Quote.ListLineItemsParams"]
+ self, **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.
@@ -1785,7 +1162,7 @@ async def list_line_items_async(
@class_method_variant("_cls_list_line_items_async")
async def list_line_items_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Quote.ListLineItemsParams"]
+ self, **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.
@@ -1802,9 +1179,7 @@ async def list_line_items_async( # pyright: ignore[reportGeneralTypeIssues]
)
@classmethod
- def modify(
- cls, id: str, **params: Unpack["Quote.ModifyParams"]
- ) -> "Quote":
+ def modify(cls, id: str, **params: Unpack["QuoteModifyParams"]) -> "Quote":
"""
A quote models prices and services for a customer.
"""
@@ -1820,7 +1195,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Quote.ModifyParams"]
+ cls, id: str, **params: Unpack["QuoteModifyParams"]
) -> "Quote":
"""
A quote models prices and services for a customer.
@@ -1836,7 +1211,7 @@ async def modify_async(
)
@classmethod
- def _cls_pdf(cls, quote: str, **params: Unpack["Quote.PdfParams"]) -> 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)
"""
@@ -1852,14 +1227,14 @@ def _cls_pdf(cls, quote: str, **params: Unpack["Quote.PdfParams"]) -> Any:
@overload
@staticmethod
- def pdf(quote: str, **params: Unpack["Quote.PdfParams"]) -> 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)
"""
...
@overload
- def pdf(self, **params: Unpack["Quote.PdfParams"]) -> Any:
+ def pdf(self, **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)
"""
@@ -1867,7 +1242,7 @@ def pdf(self, **params: Unpack["Quote.PdfParams"]) -> Any:
@class_method_variant("_cls_pdf")
def pdf( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Quote.PdfParams"]
+ self, **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)
@@ -1886,7 +1261,7 @@ def pdf( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_pdf_async(
- cls, quote: str, **params: Unpack["Quote.PdfParams"]
+ 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)
@@ -1903,16 +1278,14 @@ async def _cls_pdf_async(
@overload
@staticmethod
- async def pdf_async(
- quote: str, **params: Unpack["Quote.PdfParams"]
- ) -> 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)
"""
...
@overload
- async def pdf_async(self, **params: Unpack["Quote.PdfParams"]) -> Any:
+ async def pdf_async(self, **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)
"""
@@ -1920,7 +1293,7 @@ async def pdf_async(self, **params: Unpack["Quote.PdfParams"]) -> Any:
@class_method_variant("_cls_pdf_async")
async def pdf_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Quote.PdfParams"]
+ self, **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)
@@ -1939,7 +1312,7 @@ async def pdf_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Quote.RetrieveParams"]
+ cls, id: str, **params: Unpack["QuoteRetrieveParams"]
) -> "Quote":
"""
Retrieves the quote with the given ID.
@@ -1950,7 +1323,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Quote.RetrieveParams"]
+ cls, id: str, **params: Unpack["QuoteRetrieveParams"]
) -> "Quote":
"""
Retrieves the quote with the given ID.
diff --git a/stripe/_quote_computed_upfront_line_items_service.py b/stripe/_quote_computed_upfront_line_items_service.py
index 87aea0365..927f91d10 100644
--- a/stripe/_quote_computed_upfront_line_items_service.py
+++ b/stripe/_quote_computed_upfront_line_items_service.py
@@ -5,35 +5,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._quote_computed_upfront_line_items_list_params import (
+ QuoteComputedUpfrontLineItemsListParams,
+ )
-class QuoteComputedUpfrontLineItemsService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
+class QuoteComputedUpfrontLineItemsService(StripeService):
def list(
self,
quote: str,
- params: Optional[
- "QuoteComputedUpfrontLineItemsService.ListParams"
- ] = None,
+ params: Optional["QuoteComputedUpfrontLineItemsListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[LineItem]:
"""
@@ -55,9 +40,7 @@ def list(
async def list_async(
self,
quote: str,
- params: Optional[
- "QuoteComputedUpfrontLineItemsService.ListParams"
- ] = None,
+ 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 1c574a4ba..dbb28fa9a 100644
--- a/stripe/_quote_line_item_service.py
+++ b/stripe/_quote_line_item_service.py
@@ -5,33 +5,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._quote_line_item_list_params import (
+ QuoteLineItemListParams,
+ )
-class QuoteLineItemService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
+class QuoteLineItemService(StripeService):
def list(
self,
quote: str,
- params: Optional["QuoteLineItemService.ListParams"] = None,
+ params: Optional["QuoteLineItemListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[LineItem]:
"""
@@ -53,7 +40,7 @@ def list(
async def list_async(
self,
quote: str,
- params: Optional["QuoteLineItemService.ListParams"] = None,
+ params: Optional["QuoteLineItemListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[LineItem]:
"""
diff --git a/stripe/_quote_service.py b/stripe/_quote_service.py
index 00d4232f3..6eb65270e 100644
--- a/stripe/_quote_service.py
+++ b/stripe/_quote_service.py
@@ -9,8 +9,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Any, Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Any, Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._quote_accept_params import QuoteAcceptParams
+ from stripe.params._quote_cancel_params import QuoteCancelParams
+ from stripe.params._quote_create_params import QuoteCreateParams
+ from stripe.params._quote_finalize_quote_params import (
+ QuoteFinalizeQuoteParams,
+ )
+ from stripe.params._quote_list_params import QuoteListParams
+ from stripe.params._quote_pdf_params import QuotePdfParams
+ from stripe.params._quote_retrieve_params import QuoteRetrieveParams
+ from stripe.params._quote_update_params import QuoteUpdateParams
class QuoteService(StripeService):
@@ -23,623 +35,9 @@ def __init__(self, requestor):
)
self.line_items = QuoteLineItemService(self._requestor)
- class AcceptParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CancelParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(TypedDict):
- application_fee_amount: NotRequired["Literal['']|int"]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field.
- """
- application_fee_percent: NotRequired["Literal['']|float"]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
- """
- automatic_tax: NotRequired["QuoteService.CreateParamsAutomaticTax"]
- """
- Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
- """
- customer: NotRequired[str]
- """
- The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates that will apply to any line item that does not have `tax_rates` set.
- """
- description: NotRequired["Literal['']|str"]
- """
- A description that will be displayed on the quote PDF. If no value is passed, the default description configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
- """
- discounts: NotRequired[
- "Literal['']|List[QuoteService.CreateParamsDiscount]"
- ]
- """
- The discounts applied to the quote.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch. If no value is passed, the default expiration date configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
- """
- footer: NotRequired["Literal['']|str"]
- """
- A footer that will be displayed on the quote PDF. If no value is passed, the default footer configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
- """
- from_quote: NotRequired["QuoteService.CreateParamsFromQuote"]
- """
- Clone an existing quote. The new quote will be created in `status=draft`. When using this parameter, you cannot specify any other parameters except for `expires_at`.
- """
- header: NotRequired["Literal['']|str"]
- """
- A header that will be displayed on the quote PDF. If no value is passed, the default header configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
- """
- invoice_settings: NotRequired[
- "QuoteService.CreateParamsInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- line_items: NotRequired[List["QuoteService.CreateParamsLineItem"]]
- """
- A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account on behalf of which to charge.
- """
- subscription_data: NotRequired[
- "QuoteService.CreateParamsSubscriptionData"
- ]
- """
- When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if `subscription_data[effective_date]` is present and in the future, otherwise a subscription is created.
- """
- test_clock: NotRequired[str]
- """
- ID of the test clock to attach to the quote.
- """
- transfer_data: NotRequired[
- "Literal['']|QuoteService.CreateParamsTransferData"
- ]
- """
- The data with which to automatically create a Transfer for each of the invoices.
- """
-
- class CreateParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Controls whether Stripe will automatically compute tax on the resulting invoices or subscriptions as well as the quote itself.
- """
- liability: NotRequired[
- "QuoteService.CreateParamsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreateParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsFromQuote(TypedDict):
- is_revision: NotRequired[bool]
- """
- Whether this quote is a revision of the previous quote.
- """
- quote: str
- """
- The `id` of the quote that will be cloned.
- """
-
- class CreateParamsInvoiceSettings(TypedDict):
- days_until_due: NotRequired[int]
- """
- Number of days within which a customer must pay the invoice generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
- """
- issuer: NotRequired["QuoteService.CreateParamsInvoiceSettingsIssuer"]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class CreateParamsInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsLineItem(TypedDict):
- discounts: NotRequired[
- "Literal['']|List[QuoteService.CreateParamsLineItemDiscount]"
- ]
- """
- The discounts applied to this line item.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired["QuoteService.CreateParamsLineItemPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- The quantity of the line item.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the line item. When set, the `default_tax_rates` on the quote do not apply to this line item.
- """
-
- class CreateParamsLineItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsLineItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: NotRequired[
- "QuoteService.CreateParamsLineItemPriceDataRecurring"
- ]
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsLineItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class CreateParamsSubscriptionData(TypedDict):
- billing_mode: NotRequired[
- "QuoteService.CreateParamsSubscriptionDataBillingMode"
- ]
- """
- Controls how prorations and invoices for subscriptions are calculated and orchestrated.
- """
- description: NotRequired[str]
- """
- The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- effective_date: NotRequired[
- "Literal['']|Literal['current_period_end']|int"
- ]
- """
- When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. The `effective_date` is ignored if it is in the past when the quote is accepted.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
- """
- trial_period_days: NotRequired["Literal['']|int"]
- """
- Integer representing the number of trial period days before the customer is charged for the first time.
- """
-
- class CreateParamsSubscriptionDataBillingMode(TypedDict):
- flexible: NotRequired[
- "QuoteService.CreateParamsSubscriptionDataBillingModeFlexible"
- ]
- """
- Configure behavior for flexible billing mode.
- """
- type: Literal["classic", "flexible"]
- """
- Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
- """
-
- class CreateParamsSubscriptionDataBillingModeFlexible(TypedDict):
- proration_discounts: NotRequired[Literal["included", "itemized"]]
- """
- Controls how invoices and invoice items display proration amounts and discount amounts.
- """
-
- class CreateParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
- """
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination. There must be at least 1 line item with a recurring price to use this field.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class FinalizeQuoteParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.
- """
-
- class ListParams(TypedDict):
- customer: NotRequired[str]
- """
- The ID of the customer whose quotes will be retrieved.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["accepted", "canceled", "draft", "open"]]
- """
- The status of the quote.
- """
- test_clock: NotRequired[str]
- """
- Provides a list of quotes that are associated with the specified test clock. The response will not include quotes with test clocks if this and the customer parameter is not set.
- """
-
- class PdfParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- application_fee_amount: NotRequired["Literal['']|int"]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field.
- """
- application_fee_percent: NotRequired["Literal['']|float"]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
- """
- automatic_tax: NotRequired["QuoteService.UpdateParamsAutomaticTax"]
- """
- Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
- """
- customer: NotRequired[str]
- """
- The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates that will apply to any line item that does not have `tax_rates` set.
- """
- description: NotRequired["Literal['']|str"]
- """
- A description that will be displayed on the quote PDF.
- """
- discounts: NotRequired[
- "Literal['']|List[QuoteService.UpdateParamsDiscount]"
- ]
- """
- The discounts applied to the quote.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.
- """
- footer: NotRequired["Literal['']|str"]
- """
- A footer that will be displayed on the quote PDF.
- """
- header: NotRequired["Literal['']|str"]
- """
- A header that will be displayed on the quote PDF.
- """
- invoice_settings: NotRequired[
- "QuoteService.UpdateParamsInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- line_items: NotRequired[List["QuoteService.UpdateParamsLineItem"]]
- """
- A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account on behalf of which to charge.
- """
- subscription_data: NotRequired[
- "QuoteService.UpdateParamsSubscriptionData"
- ]
- """
- When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if `subscription_data[effective_date]` is present and in the future, otherwise a subscription is created.
- """
- transfer_data: NotRequired[
- "Literal['']|QuoteService.UpdateParamsTransferData"
- ]
- """
- The data with which to automatically create a Transfer for each of the invoices.
- """
-
- class UpdateParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Controls whether Stripe will automatically compute tax on the resulting invoices or subscriptions as well as the quote itself.
- """
- liability: NotRequired[
- "QuoteService.UpdateParamsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class UpdateParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class UpdateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class UpdateParamsInvoiceSettings(TypedDict):
- days_until_due: NotRequired[int]
- """
- Number of days within which a customer must pay the invoice generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
- """
- issuer: NotRequired["QuoteService.UpdateParamsInvoiceSettingsIssuer"]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class UpdateParamsInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class UpdateParamsLineItem(TypedDict):
- discounts: NotRequired[
- "Literal['']|List[QuoteService.UpdateParamsLineItemDiscount]"
- ]
- """
- The discounts applied to this line item.
- """
- id: NotRequired[str]
- """
- The ID of an existing line item on the quote.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired["QuoteService.UpdateParamsLineItemPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- The quantity of the line item.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the line item. When set, the `default_tax_rates` on the quote do not apply to this line item.
- """
-
- class UpdateParamsLineItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class UpdateParamsLineItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: NotRequired[
- "QuoteService.UpdateParamsLineItemPriceDataRecurring"
- ]
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class UpdateParamsLineItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class UpdateParamsSubscriptionData(TypedDict):
- description: NotRequired["Literal['']|str"]
- """
- The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- effective_date: NotRequired[
- "Literal['']|Literal['current_period_end']|int"
- ]
- """
- When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. The `effective_date` is ignored if it is in the past when the quote is accepted.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
- """
- trial_period_days: NotRequired["Literal['']|int"]
- """
- Integer representing the number of trial period days before the customer is charged for the first time.
- """
-
- class UpdateParamsTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
- """
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination. There must be at least 1 line item with a recurring price to use this field.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
def list(
self,
- params: Optional["QuoteService.ListParams"] = None,
+ params: Optional["QuoteListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Quote]:
"""
@@ -658,7 +56,7 @@ def list(
async def list_async(
self,
- params: Optional["QuoteService.ListParams"] = None,
+ params: Optional["QuoteListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Quote]:
"""
@@ -677,7 +75,7 @@ async def list_async(
def create(
self,
- params: Optional["QuoteService.CreateParams"] = None,
+ params: Optional["QuoteCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Quote:
"""
@@ -696,7 +94,7 @@ def create(
async def create_async(
self,
- params: Optional["QuoteService.CreateParams"] = None,
+ params: Optional["QuoteCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Quote:
"""
@@ -716,7 +114,7 @@ async def create_async(
def retrieve(
self,
quote: str,
- params: Optional["QuoteService.RetrieveParams"] = None,
+ params: Optional["QuoteRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Quote:
"""
@@ -736,7 +134,7 @@ def retrieve(
async def retrieve_async(
self,
quote: str,
- params: Optional["QuoteService.RetrieveParams"] = None,
+ params: Optional["QuoteRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Quote:
"""
@@ -756,7 +154,7 @@ async def retrieve_async(
def update(
self,
quote: str,
- params: Optional["QuoteService.UpdateParams"] = None,
+ params: Optional["QuoteUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Quote:
"""
@@ -776,7 +174,7 @@ def update(
async def update_async(
self,
quote: str,
- params: Optional["QuoteService.UpdateParams"] = None,
+ params: Optional["QuoteUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Quote:
"""
@@ -796,7 +194,7 @@ async def update_async(
def accept(
self,
quote: str,
- params: Optional["QuoteService.AcceptParams"] = None,
+ params: Optional["QuoteAcceptParams"] = None,
options: Optional[RequestOptions] = None,
) -> Quote:
"""
@@ -816,7 +214,7 @@ def accept(
async def accept_async(
self,
quote: str,
- params: Optional["QuoteService.AcceptParams"] = None,
+ params: Optional["QuoteAcceptParams"] = None,
options: Optional[RequestOptions] = None,
) -> Quote:
"""
@@ -836,7 +234,7 @@ async def accept_async(
def cancel(
self,
quote: str,
- params: Optional["QuoteService.CancelParams"] = None,
+ params: Optional["QuoteCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> Quote:
"""
@@ -856,7 +254,7 @@ def cancel(
async def cancel_async(
self,
quote: str,
- params: Optional["QuoteService.CancelParams"] = None,
+ params: Optional["QuoteCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> Quote:
"""
@@ -876,7 +274,7 @@ async def cancel_async(
def finalize_quote(
self,
quote: str,
- params: Optional["QuoteService.FinalizeQuoteParams"] = None,
+ params: Optional["QuoteFinalizeQuoteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Quote:
"""
@@ -896,7 +294,7 @@ def finalize_quote(
async def finalize_quote_async(
self,
quote: str,
- params: Optional["QuoteService.FinalizeQuoteParams"] = None,
+ params: Optional["QuoteFinalizeQuoteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Quote:
"""
@@ -916,7 +314,7 @@ async def finalize_quote_async(
def pdf(
self,
quote: str,
- params: Optional["QuoteService.PdfParams"] = None,
+ params: Optional["QuotePdfParams"] = None,
options: Optional[RequestOptions] = None,
) -> Any:
"""
@@ -936,7 +334,7 @@ def pdf(
async def pdf_async(
self,
quote: str,
- params: Optional["QuoteService.PdfParams"] = None,
+ params: Optional["QuotePdfParams"] = None,
options: Optional[RequestOptions] = None,
) -> Any:
"""
diff --git a/stripe/_refund.py b/stripe/_refund.py
index 5d48f86be..e46b0329c 100644
--- a/stripe/_refund.py
+++ b/stripe/_refund.py
@@ -4,26 +4,24 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._test_helpers import APIResourceTestHelpers
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- Type,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Dict, Optional, cast, overload
+from typing_extensions import Literal, Type, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._balance_transaction import BalanceTransaction
from stripe._charge import Charge
from stripe._payment_intent import PaymentIntent
from stripe._reversal import Reversal
+ from stripe.params._refund_cancel_params import RefundCancelParams
+ from stripe.params._refund_create_params import RefundCreateParams
+ from stripe.params._refund_expire_params import RefundExpireParams
+ from stripe.params._refund_list_params import RefundListParams
+ from stripe.params._refund_modify_params import RefundModifyParams
+ from stripe.params._refund_retrieve_params import RefundRetrieveParams
class Refund(
@@ -348,133 +346,6 @@ class PresentmentDetails(StripeObject):
Currency presented to the customer during payment.
"""
- class CancelParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(RequestOptions):
- amount: NotRequired[int]
- charge: NotRequired[str]
- """
- The identifier of the charge to refund.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: NotRequired[str]
- """
- Customer whose customer balance to refund from.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- instructions_email: NotRequired[str]
- """
- For payment methods without native refund support (e.g., Konbini, PromptPay), use this email from the customer to receive refund instructions.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- origin: NotRequired[Literal["customer_balance"]]
- """
- Origin of the refund
- """
- payment_intent: NotRequired[str]
- """
- The identifier of the PaymentIntent to refund.
- """
- reason: NotRequired[
- Literal["duplicate", "fraudulent", "requested_by_customer"]
- ]
- """
- String indicating the reason for the refund. If set, possible values are `duplicate`, `fraudulent`, and `requested_by_customer`. If you believe the charge to be fraudulent, specifying `fraudulent` as the reason will add the associated card and email to your [block lists](https://stripe.com/docs/radar/lists), and will also help us improve our fraud detection algorithms.
- """
- refund_application_fee: NotRequired[bool]
- """
- Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.
- """
- reverse_transfer: NotRequired[bool]
- """
- Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount).
-
- A transfer can be reversed only by the application that created the charge.
- """
-
- class ExpireParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(RequestOptions):
- charge: NotRequired[str]
- """
- Only return refunds for the charge specified by this charge ID.
- """
- created: NotRequired["Refund.ListParamsCreated|int"]
- """
- Only return refunds that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payment_intent: NotRequired[str]
- """
- Only return refunds for the PaymentIntent specified by this ID.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount: int
"""
Amount, in cents (or local equivalent).
@@ -568,7 +439,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def _cls_cancel(
- cls, refund: str, **params: Unpack["Refund.CancelParams"]
+ cls, refund: str, **params: Unpack["RefundCancelParams"]
) -> "Refund":
"""
Cancels a refund with a status of requires_action.
@@ -589,7 +460,7 @@ def _cls_cancel(
@overload
@staticmethod
def cancel(
- refund: str, **params: Unpack["Refund.CancelParams"]
+ refund: str, **params: Unpack["RefundCancelParams"]
) -> "Refund":
"""
Cancels a refund with a status of requires_action.
@@ -599,7 +470,7 @@ def cancel(
...
@overload
- def cancel(self, **params: Unpack["Refund.CancelParams"]) -> "Refund":
+ def cancel(self, **params: Unpack["RefundCancelParams"]) -> "Refund":
"""
Cancels a refund with a status of requires_action.
@@ -609,7 +480,7 @@ def cancel(self, **params: Unpack["Refund.CancelParams"]) -> "Refund":
@class_method_variant("_cls_cancel")
def cancel( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Refund.CancelParams"]
+ self, **params: Unpack["RefundCancelParams"]
) -> "Refund":
"""
Cancels a refund with a status of requires_action.
@@ -629,7 +500,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_cancel_async(
- cls, refund: str, **params: Unpack["Refund.CancelParams"]
+ cls, refund: str, **params: Unpack["RefundCancelParams"]
) -> "Refund":
"""
Cancels a refund with a status of requires_action.
@@ -650,7 +521,7 @@ async def _cls_cancel_async(
@overload
@staticmethod
async def cancel_async(
- refund: str, **params: Unpack["Refund.CancelParams"]
+ refund: str, **params: Unpack["RefundCancelParams"]
) -> "Refund":
"""
Cancels a refund with a status of requires_action.
@@ -661,7 +532,7 @@ async def cancel_async(
@overload
async def cancel_async(
- self, **params: Unpack["Refund.CancelParams"]
+ self, **params: Unpack["RefundCancelParams"]
) -> "Refund":
"""
Cancels a refund with a status of requires_action.
@@ -672,7 +543,7 @@ async def cancel_async(
@class_method_variant("_cls_cancel_async")
async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Refund.CancelParams"]
+ self, **params: Unpack["RefundCancelParams"]
) -> "Refund":
"""
Cancels a refund with a status of requires_action.
@@ -691,7 +562,7 @@ async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
)
@classmethod
- def create(cls, **params: Unpack["Refund.CreateParams"]) -> "Refund":
+ def create(cls, **params: Unpack["RefundCreateParams"]) -> "Refund":
"""
When you create a new refund, you must specify a Charge or a PaymentIntent object on which to create it.
@@ -716,7 +587,7 @@ def create(cls, **params: Unpack["Refund.CreateParams"]) -> "Refund":
@classmethod
async def create_async(
- cls, **params: Unpack["Refund.CreateParams"]
+ cls, **params: Unpack["RefundCreateParams"]
) -> "Refund":
"""
When you create a new refund, you must specify a Charge or a PaymentIntent object on which to create it.
@@ -742,7 +613,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["Refund.ListParams"]
+ cls, **params: Unpack["RefundListParams"]
) -> ListObject["Refund"]:
"""
Returns a list of all refunds you created. We return the refunds in sorted order, with the most recent refunds appearing first. The 10 most recent refunds are always available by default on the Charge object.
@@ -762,7 +633,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Refund.ListParams"]
+ cls, **params: Unpack["RefundListParams"]
) -> ListObject["Refund"]:
"""
Returns a list of all refunds you created. We return the refunds in sorted order, with the most recent refunds appearing first. The 10 most recent refunds are always available by default on the Charge object.
@@ -782,7 +653,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Refund.ModifyParams"]
+ cls, id: str, **params: Unpack["RefundModifyParams"]
) -> "Refund":
"""
Updates the refund that you specify by setting the values of the passed parameters. Any parameters that you don't provide remain unchanged.
@@ -801,7 +672,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Refund.ModifyParams"]
+ cls, id: str, **params: Unpack["RefundModifyParams"]
) -> "Refund":
"""
Updates the refund that you specify by setting the values of the passed parameters. Any parameters that you don't provide remain unchanged.
@@ -820,7 +691,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Refund.RetrieveParams"]
+ cls, id: str, **params: Unpack["RefundRetrieveParams"]
) -> "Refund":
"""
Retrieves the details of an existing refund.
@@ -831,7 +702,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Refund.RetrieveParams"]
+ cls, id: str, **params: Unpack["RefundRetrieveParams"]
) -> "Refund":
"""
Retrieves the details of an existing refund.
@@ -845,7 +716,7 @@ class TestHelpers(APIResourceTestHelpers["Refund"]):
@classmethod
def _cls_expire(
- cls, refund: str, **params: Unpack["Refund.ExpireParams"]
+ cls, refund: str, **params: Unpack["RefundExpireParams"]
) -> "Refund":
"""
Expire a refund with a status of requires_action.
@@ -864,7 +735,7 @@ def _cls_expire(
@overload
@staticmethod
def expire(
- refund: str, **params: Unpack["Refund.ExpireParams"]
+ refund: str, **params: Unpack["RefundExpireParams"]
) -> "Refund":
"""
Expire a refund with a status of requires_action.
@@ -872,7 +743,7 @@ def expire(
...
@overload
- def expire(self, **params: Unpack["Refund.ExpireParams"]) -> "Refund":
+ def expire(self, **params: Unpack["RefundExpireParams"]) -> "Refund":
"""
Expire a refund with a status of requires_action.
"""
@@ -880,7 +751,7 @@ def expire(self, **params: Unpack["Refund.ExpireParams"]) -> "Refund":
@class_method_variant("_cls_expire")
def expire( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Refund.ExpireParams"]
+ self, **params: Unpack["RefundExpireParams"]
) -> "Refund":
"""
Expire a refund with a status of requires_action.
@@ -898,7 +769,7 @@ def expire( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_expire_async(
- cls, refund: str, **params: Unpack["Refund.ExpireParams"]
+ cls, refund: str, **params: Unpack["RefundExpireParams"]
) -> "Refund":
"""
Expire a refund with a status of requires_action.
@@ -917,7 +788,7 @@ async def _cls_expire_async(
@overload
@staticmethod
async def expire_async(
- refund: str, **params: Unpack["Refund.ExpireParams"]
+ refund: str, **params: Unpack["RefundExpireParams"]
) -> "Refund":
"""
Expire a refund with a status of requires_action.
@@ -926,7 +797,7 @@ async def expire_async(
@overload
async def expire_async(
- self, **params: Unpack["Refund.ExpireParams"]
+ self, **params: Unpack["RefundExpireParams"]
) -> "Refund":
"""
Expire a refund with a status of requires_action.
@@ -935,7 +806,7 @@ async def expire_async(
@class_method_variant("_cls_expire_async")
async def expire_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Refund.ExpireParams"]
+ self, **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 6a8c35794..a9319e0bc 100644
--- a/stripe/_refund_service.py
+++ b/stripe/_refund_service.py
@@ -5,135 +5,21 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._refund_cancel_params import RefundCancelParams
+ from stripe.params._refund_create_params import RefundCreateParams
+ from stripe.params._refund_list_params import RefundListParams
+ from stripe.params._refund_retrieve_params import RefundRetrieveParams
+ from stripe.params._refund_update_params import RefundUpdateParams
-class RefundService(StripeService):
- class CancelParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(TypedDict):
- amount: NotRequired[int]
- charge: NotRequired[str]
- """
- The identifier of the charge to refund.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: NotRequired[str]
- """
- Customer whose customer balance to refund from.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- instructions_email: NotRequired[str]
- """
- For payment methods without native refund support (e.g., Konbini, PromptPay), use this email from the customer to receive refund instructions.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- origin: NotRequired[Literal["customer_balance"]]
- """
- Origin of the refund
- """
- payment_intent: NotRequired[str]
- """
- The identifier of the PaymentIntent to refund.
- """
- reason: NotRequired[
- Literal["duplicate", "fraudulent", "requested_by_customer"]
- ]
- """
- String indicating the reason for the refund. If set, possible values are `duplicate`, `fraudulent`, and `requested_by_customer`. If you believe the charge to be fraudulent, specifying `fraudulent` as the reason will add the associated card and email to your [block lists](https://stripe.com/docs/radar/lists), and will also help us improve our fraud detection algorithms.
- """
- refund_application_fee: NotRequired[bool]
- """
- Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.
- """
- reverse_transfer: NotRequired[bool]
- """
- Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount).
-
- A transfer can be reversed only by the application that created the charge.
- """
-
- class ListParams(TypedDict):
- charge: NotRequired[str]
- """
- Only return refunds for the charge specified by this charge ID.
- """
- created: NotRequired["RefundService.ListParamsCreated|int"]
- """
- Only return refunds that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payment_intent: NotRequired[str]
- """
- Only return refunds for the PaymentIntent specified by this ID.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
+class RefundService(StripeService):
def list(
self,
- params: Optional["RefundService.ListParams"] = None,
+ params: Optional["RefundListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Refund]:
"""
@@ -152,7 +38,7 @@ def list(
async def list_async(
self,
- params: Optional["RefundService.ListParams"] = None,
+ params: Optional["RefundListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Refund]:
"""
@@ -171,7 +57,7 @@ async def list_async(
def create(
self,
- params: Optional["RefundService.CreateParams"] = None,
+ params: Optional["RefundCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Refund:
"""
@@ -200,7 +86,7 @@ def create(
async def create_async(
self,
- params: Optional["RefundService.CreateParams"] = None,
+ params: Optional["RefundCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Refund:
"""
@@ -230,7 +116,7 @@ async def create_async(
def retrieve(
self,
refund: str,
- params: Optional["RefundService.RetrieveParams"] = None,
+ params: Optional["RefundRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Refund:
"""
@@ -250,7 +136,7 @@ def retrieve(
async def retrieve_async(
self,
refund: str,
- params: Optional["RefundService.RetrieveParams"] = None,
+ params: Optional["RefundRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Refund:
"""
@@ -270,7 +156,7 @@ async def retrieve_async(
def update(
self,
refund: str,
- params: Optional["RefundService.UpdateParams"] = None,
+ params: Optional["RefundUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Refund:
"""
@@ -292,7 +178,7 @@ def update(
async def update_async(
self,
refund: str,
- params: Optional["RefundService.UpdateParams"] = None,
+ params: Optional["RefundUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Refund:
"""
@@ -314,7 +200,7 @@ async def update_async(
def cancel(
self,
refund: str,
- params: Optional["RefundService.CancelParams"] = None,
+ params: Optional["RefundCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> Refund:
"""
@@ -338,7 +224,7 @@ def cancel(
async def cancel_async(
self,
refund: str,
- params: Optional["RefundService.CancelParams"] = None,
+ params: Optional["RefundCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> Refund:
"""
diff --git a/stripe/_review.py b/stripe/_review.py
index cbe4c0386..d03e8462f 100644
--- a/stripe/_review.py
+++ b/stripe/_review.py
@@ -3,21 +3,17 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._charge import Charge
from stripe._payment_intent import PaymentIntent
+ from stripe.params._review_approve_params import ReviewApproveParams
+ from stripe.params._review_list_params import ReviewListParams
+ from stripe.params._review_retrieve_params import ReviewRetrieveParams
class Review(ListableAPIResource["Review"]):
@@ -70,58 +66,6 @@ class Session(StripeObject):
The version for the browser session (e.g., `61.0.3163.100`).
"""
- class ApproveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["Review.ListParamsCreated|int"]
- """
- Only return reviews that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
billing_zip: Optional[str]
"""
The ZIP or postal code of the card used, if applicable.
@@ -192,7 +136,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def _cls_approve(
- cls, review: str, **params: Unpack["Review.ApproveParams"]
+ cls, review: str, **params: Unpack["ReviewApproveParams"]
) -> "Review":
"""
Approves a Review object, closing it and removing it from the list of reviews.
@@ -211,7 +155,7 @@ def _cls_approve(
@overload
@staticmethod
def approve(
- review: str, **params: Unpack["Review.ApproveParams"]
+ review: str, **params: Unpack["ReviewApproveParams"]
) -> "Review":
"""
Approves a Review object, closing it and removing it from the list of reviews.
@@ -219,7 +163,7 @@ def approve(
...
@overload
- def approve(self, **params: Unpack["Review.ApproveParams"]) -> "Review":
+ def approve(self, **params: Unpack["ReviewApproveParams"]) -> "Review":
"""
Approves a Review object, closing it and removing it from the list of reviews.
"""
@@ -227,7 +171,7 @@ def approve(self, **params: Unpack["Review.ApproveParams"]) -> "Review":
@class_method_variant("_cls_approve")
def approve( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Review.ApproveParams"]
+ self, **params: Unpack["ReviewApproveParams"]
) -> "Review":
"""
Approves a Review object, closing it and removing it from the list of reviews.
@@ -245,7 +189,7 @@ def approve( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_approve_async(
- cls, review: str, **params: Unpack["Review.ApproveParams"]
+ cls, review: str, **params: Unpack["ReviewApproveParams"]
) -> "Review":
"""
Approves a Review object, closing it and removing it from the list of reviews.
@@ -264,7 +208,7 @@ async def _cls_approve_async(
@overload
@staticmethod
async def approve_async(
- review: str, **params: Unpack["Review.ApproveParams"]
+ review: str, **params: Unpack["ReviewApproveParams"]
) -> "Review":
"""
Approves a Review object, closing it and removing it from the list of reviews.
@@ -273,7 +217,7 @@ async def approve_async(
@overload
async def approve_async(
- self, **params: Unpack["Review.ApproveParams"]
+ self, **params: Unpack["ReviewApproveParams"]
) -> "Review":
"""
Approves a Review object, closing it and removing it from the list of reviews.
@@ -282,7 +226,7 @@ async def approve_async(
@class_method_variant("_cls_approve_async")
async def approve_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Review.ApproveParams"]
+ self, **params: Unpack["ReviewApproveParams"]
) -> "Review":
"""
Approves a Review object, closing it and removing it from the list of reviews.
@@ -300,7 +244,7 @@ async def approve_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["Review.ListParams"]
+ cls, **params: Unpack["ReviewListParams"]
) -> ListObject["Review"]:
"""
Returns a list of Review objects that have open set to true. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -320,7 +264,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Review.ListParams"]
+ cls, **params: Unpack["ReviewListParams"]
) -> ListObject["Review"]:
"""
Returns a list of Review objects that have open set to true. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -340,7 +284,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Review.RetrieveParams"]
+ cls, id: str, **params: Unpack["ReviewRetrieveParams"]
) -> "Review":
"""
Retrieves a Review object.
@@ -351,7 +295,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Review.RetrieveParams"]
+ cls, id: str, **params: Unpack["ReviewRetrieveParams"]
) -> "Review":
"""
Retrieves a Review object.
diff --git a/stripe/_review_service.py b/stripe/_review_service.py
index 14aea532b..ddae806a2 100644
--- a/stripe/_review_service.py
+++ b/stripe/_review_service.py
@@ -5,66 +5,19 @@
from stripe._review import Review
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._review_approve_params import ReviewApproveParams
+ from stripe.params._review_list_params import ReviewListParams
+ from stripe.params._review_retrieve_params import ReviewRetrieveParams
-class ReviewService(StripeService):
- class ApproveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(TypedDict):
- created: NotRequired["ReviewService.ListParamsCreated|int"]
- """
- Only return reviews that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class ReviewService(StripeService):
def list(
self,
- params: Optional["ReviewService.ListParams"] = None,
+ params: Optional["ReviewListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Review]:
"""
@@ -83,7 +36,7 @@ def list(
async def list_async(
self,
- params: Optional["ReviewService.ListParams"] = None,
+ params: Optional["ReviewListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Review]:
"""
@@ -103,7 +56,7 @@ async def list_async(
def retrieve(
self,
review: str,
- params: Optional["ReviewService.RetrieveParams"] = None,
+ params: Optional["ReviewRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Review:
"""
@@ -123,7 +76,7 @@ def retrieve(
async def retrieve_async(
self,
review: str,
- params: Optional["ReviewService.RetrieveParams"] = None,
+ params: Optional["ReviewRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Review:
"""
@@ -143,7 +96,7 @@ async def retrieve_async(
def approve(
self,
review: str,
- params: Optional["ReviewService.ApproveParams"] = None,
+ params: Optional["ReviewApproveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Review:
"""
@@ -165,7 +118,7 @@ def approve(
async def approve_async(
self,
review: str,
- params: Optional["ReviewService.ApproveParams"] = None,
+ params: Optional["ReviewApproveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Review:
"""
diff --git a/stripe/_setup_attempt.py b/stripe/_setup_attempt.py
index 17d411835..c3f801bea 100644
--- a/stripe/_setup_attempt.py
+++ b/stripe/_setup_attempt.py
@@ -3,16 +3,9 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from typing import ClassVar, List, Optional, Union
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account
@@ -25,6 +18,7 @@
from stripe._payment_method import PaymentMethod
from stripe._setup_intent import SetupIntent
from stripe._source import Source
+ from stripe.params._setup_attempt_list_params import SetupAttemptListParams
class SetupAttempt(ListableAPIResource["SetupAttempt"]):
@@ -736,53 +730,6 @@ class SetupError(StripeObject):
The type of error returned. One of `api_error`, `card_error`, `idempotency_error`, or `invalid_request_error`
"""
- class ListParams(RequestOptions):
- created: NotRequired["SetupAttempt.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value
- can be a string with an integer Unix timestamp or a
- dictionary with a number of different query options.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- setup_intent: str
- """
- Only return SetupAttempts created by the SetupIntent specified by
- this ID.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
application: Optional[ExpandableField["Application"]]
"""
The value of [application](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-application) on the SetupIntent at the time of this confirmation.
@@ -847,7 +794,7 @@ class ListParamsCreated(TypedDict):
@classmethod
def list(
- cls, **params: Unpack["SetupAttempt.ListParams"]
+ cls, **params: Unpack["SetupAttemptListParams"]
) -> ListObject["SetupAttempt"]:
"""
Returns a list of SetupAttempts that associate with a provided SetupIntent.
@@ -867,7 +814,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["SetupAttempt.ListParams"]
+ cls, **params: Unpack["SetupAttemptListParams"]
) -> ListObject["SetupAttempt"]:
"""
Returns a list of SetupAttempts that associate with a provided SetupIntent.
diff --git a/stripe/_setup_attempt_service.py b/stripe/_setup_attempt_service.py
index 1b8aa0154..328957a4b 100644
--- a/stripe/_setup_attempt_service.py
+++ b/stripe/_setup_attempt_service.py
@@ -4,61 +4,17 @@
from stripe._request_options import RequestOptions
from stripe._setup_attempt import SetupAttempt
from stripe._stripe_service import StripeService
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._setup_attempt_list_params import SetupAttemptListParams
-class SetupAttemptService(StripeService):
- class ListParams(TypedDict):
- created: NotRequired["SetupAttemptService.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value
- can be a string with an integer Unix timestamp or a
- dictionary with a number of different query options.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- setup_intent: str
- """
- Only return SetupAttempts created by the SetupIntent specified by
- this ID.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
+class SetupAttemptService(StripeService):
def list(
self,
- params: "SetupAttemptService.ListParams",
+ params: "SetupAttemptListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[SetupAttempt]:
"""
@@ -77,7 +33,7 @@ def list(
async def list_async(
self,
- params: "SetupAttemptService.ListParams",
+ params: "SetupAttemptListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[SetupAttempt]:
"""
diff --git a/stripe/_setup_intent.py b/stripe/_setup_intent.py
index 7ccbd159b..21121b537 100644
--- a/stripe/_setup_intent.py
+++ b/stripe/_setup_intent.py
@@ -4,18 +4,11 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import Any, ClassVar, Dict, List, Optional, Union, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account
@@ -28,6 +21,25 @@
from stripe._payment_method import PaymentMethod
from stripe._setup_attempt import SetupAttempt
from stripe._source import Source
+ from stripe.params._setup_intent_cancel_params import (
+ SetupIntentCancelParams,
+ )
+ from stripe.params._setup_intent_confirm_params import (
+ SetupIntentConfirmParams,
+ )
+ from stripe.params._setup_intent_create_params import (
+ SetupIntentCreateParams,
+ )
+ from stripe.params._setup_intent_list_params import SetupIntentListParams
+ from stripe.params._setup_intent_modify_params import (
+ SetupIntentModifyParams,
+ )
+ from stripe.params._setup_intent_retrieve_params import (
+ SetupIntentRetrieveParams,
+ )
+ from stripe.params._setup_intent_verify_microdeposits_params import (
+ SetupIntentVerifyMicrodepositsParams,
+ )
class SetupIntent(
@@ -680,4180 +692,6 @@ class MandateOptions(StripeObject):
"us_bank_account": UsBankAccount,
}
- class CancelParams(RequestOptions):
- cancellation_reason: NotRequired[
- Literal["abandoned", "duplicate", "requested_by_customer"]
- ]
- """
- Reason for canceling this SetupIntent. Possible values are: `abandoned`, `requested_by_customer`, or `duplicate`
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ConfirmParams(RequestOptions):
- confirmation_token: NotRequired[str]
- """
- ID of the ConfirmationToken used to confirm this SetupIntent.
-
- If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- mandate_data: NotRequired[
- "Literal['']|SetupIntent.ConfirmParamsMandateData"
- ]
- payment_method: NotRequired[str]
- """
- ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.
- """
- payment_method_data: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodData"
- ]
- """
- When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
- value in the SetupIntent.
- """
- payment_method_options: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptions"
- ]
- """
- Payment method-specific configuration for this SetupIntent.
- """
- return_url: NotRequired[str]
- """
- The URL to redirect your customer back to after they authenticate on the payment method's app or site.
- If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
- This parameter is only used for cards and other redirect-based payment methods.
- """
- use_stripe_sdk: NotRequired[bool]
- """
- Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
- """
-
- class ConfirmParamsMandateData(TypedDict):
- customer_acceptance: NotRequired[
- "SetupIntent.ConfirmParamsMandateDataCustomerAcceptance"
- ]
- """
- This hash contains details about the customer acceptance of the Mandate.
- """
-
- class ConfirmParamsMandateDataCustomerAcceptance(TypedDict):
- accepted_at: NotRequired[int]
- """
- The time at which the customer accepted the Mandate.
- """
- offline: NotRequired[
- "SetupIntent.ConfirmParamsMandateDataCustomerAcceptanceOffline"
- ]
- """
- If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
- """
- online: NotRequired[
- "SetupIntent.ConfirmParamsMandateDataCustomerAcceptanceOnline"
- ]
- """
- If this is a Mandate accepted online, this hash contains details about the online acceptance.
- """
- type: Literal["offline", "online"]
- """
- The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
- """
-
- class ConfirmParamsMandateDataCustomerAcceptanceOffline(TypedDict):
- pass
-
- class ConfirmParamsMandateDataCustomerAcceptanceOnline(TypedDict):
- ip_address: NotRequired[str]
- """
- The IP address from which the Mandate was accepted by the customer.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the Mandate was accepted by the customer.
- """
-
- class ConfirmParamsPaymentMethodData(TypedDict):
- acss_debit: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataAcssDebit"
- ]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataAffirm"]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataAlipay"]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataAlma"]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataAmazonPay"
- ]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataAuBecsDebit"
- ]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataBillie"]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataBlik"]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataBoleto"]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- cashapp: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataCrypto"]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer_balance: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataEps"]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- fpx: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataFpx"]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataIdeal"]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataKlarna"]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataLink"]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataMbWay"]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataMobilepay"
- ]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataNzBankAccount"
- ]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataOxxo"]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataP24"]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataPayco"]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- paynow: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataPaynow"]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataPaypal"]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataPix"]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataRadarOptions"
- ]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataSofort"]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataSwish"]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataTwint"]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodDataWechatPay"
- ]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataZip"]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class ConfirmParamsPaymentMethodDataAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataAffirm(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAfterpayClearpay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAlipay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAlma(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAmazonPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class ConfirmParamsPaymentMethodDataBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class ConfirmParamsPaymentMethodDataBancontact(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataBillie(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|SetupIntent.ConfirmParamsPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class ConfirmParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ConfirmParamsPaymentMethodDataBlik(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class ConfirmParamsPaymentMethodDataCashapp(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataCrypto(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataCustomerBalance(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataGiropay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataGrabpay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class ConfirmParamsPaymentMethodDataInteracPresent(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataKakaoPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataKlarna(TypedDict):
- dob: NotRequired["SetupIntent.ConfirmParamsPaymentMethodDataKlarnaDob"]
- """
- Customer's date of birth
- """
-
- class ConfirmParamsPaymentMethodDataKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class ConfirmParamsPaymentMethodDataKonbini(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataKrCard(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataLink(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataMbWay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataMobilepay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataMultibanco(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class ConfirmParamsPaymentMethodDataNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class ConfirmParamsPaymentMethodDataOxxo(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataPayByBank(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPayco(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPaynow(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPaypal(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPix(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPromptpay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class ConfirmParamsPaymentMethodDataRevolutPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataSamsungPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataSatispay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class ConfirmParamsPaymentMethodDataSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class ConfirmParamsPaymentMethodDataSwish(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataTwint(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class ConfirmParamsPaymentMethodDataWechatPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataZip(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsAcssDebit"
- ]
- """
- If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
- """
- amazon_pay: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsAmazonPay"
- ]
- """
- If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
- """
- bacs_debit: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsBacsDebit"
- ]
- """
- If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
- """
- card: NotRequired["SetupIntent.ConfirmParamsPaymentMethodOptionsCard"]
- """
- Configuration for any card setup attempted on this SetupIntent.
- """
- card_present: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsCardPresent"
- ]
- """
- If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
- """
- klarna: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method options.
- """
- link: NotRequired["SetupIntent.ConfirmParamsPaymentMethodOptionsLink"]
- """
- If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
- """
- paypal: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
- """
- sepa_debit: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsSepaDebit"
- ]
- """
- If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
- """
- us_bank_account: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
- """
-
- class ConfirmParamsPaymentMethodOptionsAcssDebit(TypedDict):
- currency: NotRequired[Literal["cad", "usd"]]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- mandate_options: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class ConfirmParamsPaymentMethodOptionsAcssDebitMandateOptions(TypedDict):
- custom_mandate_url: NotRequired["Literal['']|str"]
- """
- A URL for custom mandate text to render during confirmation step.
- The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
- or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
- """
- default_for: NotRequired[List[Literal["invoice", "subscription"]]]
- """
- List of Stripe products where this mandate can be selected automatically.
- """
- interval_description: NotRequired[str]
- """
- Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
- """
- payment_schedule: NotRequired[
- Literal["combined", "interval", "sporadic"]
- ]
- """
- Payment schedule for the mandate.
- """
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class ConfirmParamsPaymentMethodOptionsAmazonPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodOptionsBacsDebit(TypedDict):
- mandate_options: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsBacsDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
-
- class ConfirmParamsPaymentMethodOptionsBacsDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
- """
-
- class ConfirmParamsPaymentMethodOptionsCard(TypedDict):
- mandate_options: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- moto: NotRequired[bool]
- """
- When specified, this parameter signals that a card has been collected
- as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
- parameter can only be provided during confirmation.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
- three_d_secure: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsCardThreeDSecure"
- ]
- """
- If 3D Secure authentication was performed with a third-party provider,
- the authentication details to use for this setup.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardMandateOptions(TypedDict):
- amount: int
- """
- Amount to be charged for future payments.
- """
- amount_type: Literal["fixed", "maximum"]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- currency: str
- """
- Currency in which future payments will be charged. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
- end_date: NotRequired[int]
- """
- End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
- """
- interval: Literal["day", "month", "sporadic", "week", "year"]
- """
- Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
- """
- reference: str
- """
- Unique identifier for the mandate or subscription.
- """
- start_date: int
- """
- Start date of the mandate or subscription. Start date should not be lesser than yesterday.
- """
- supported_types: NotRequired[List[Literal["india"]]]
- """
- Specifies the type of mandates supported. Possible values are `india`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardPresent(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
- ares_trans_status: NotRequired[
- Literal["A", "C", "I", "N", "R", "U", "Y"]
- ]
- """
- The `transStatus` returned from the card Issuer's ACS in the ARes.
- """
- cryptogram: NotRequired[str]
- """
- The cryptogram, also known as the "authentication value" (AAV, CAVV or
- AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
- (Most 3D Secure providers will return the base64-encoded version, which
- is what you should specify here.)
- """
- electronic_commerce_indicator: NotRequired[
- Literal["01", "02", "05", "06", "07"]
- ]
- """
- The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
- provider and indicates what degree of authentication was performed.
- """
- network_options: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
- ]
- """
- Network specific 3DS fields. Network specific arguments require an
- explicit card brand choice. The parameter `payment_method_options.card.network``
- must be populated accordingly
- """
- requestor_challenge_indicator: NotRequired[str]
- """
- The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
- AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
- """
- transaction_id: NotRequired[str]
- """
- For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
- Transaction ID (dsTransID).
- """
- version: NotRequired[Literal["1.0.2", "2.1.0", "2.2.0"]]
- """
- The version of 3D Secure that was performed.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
- TypedDict,
- ):
- cartes_bancaires: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
- ]
- """
- Cartes Bancaires-specific 3DS fields.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
- TypedDict,
- ):
- cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
- """
- The cryptogram calculation algorithm used by the card Issuer's ACS
- to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
- messageExtension: CB-AVALGO
- """
- cb_exemption: NotRequired[str]
- """
- The exemption indicator returned from Cartes Bancaires in the ARes.
- message extension: CB-EXEMPTION; string (4 characters)
- This is a 3 byte bitmap (low significant byte first and most significant
- bit first) that has been Base64 encoded
- """
- cb_score: NotRequired[int]
- """
- The risk score returned from Cartes Bancaires in the ARes.
- message extension: CB-SCORE; numeric value 0-99
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarna(TypedDict):
- currency: NotRequired[str]
- """
- The currency of the SetupIntent. Three letter ISO currency code.
- """
- on_demand: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsKlarnaOnDemand"
- ]
- """
- On-demand details if setting up a payment method for on-demand payments.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-CH",
- "de-DE",
- "el-GR",
- "en-AT",
- "en-AU",
- "en-BE",
- "en-CA",
- "en-CH",
- "en-CZ",
- "en-DE",
- "en-DK",
- "en-ES",
- "en-FI",
- "en-FR",
- "en-GB",
- "en-GR",
- "en-IE",
- "en-IT",
- "en-NL",
- "en-NO",
- "en-NZ",
- "en-PL",
- "en-PT",
- "en-RO",
- "en-SE",
- "en-US",
- "es-ES",
- "es-US",
- "fi-FI",
- "fr-BE",
- "fr-CA",
- "fr-CH",
- "fr-FR",
- "it-CH",
- "it-IT",
- "nb-NO",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "ro-RO",
- "sv-FI",
- "sv-SE",
- ]
- ]
- """
- Preferred language of the Klarna authorization page that the customer is redirected to
- """
- subscriptions: NotRequired[
- "Literal['']|List[SetupIntent.ConfirmParamsPaymentMethodOptionsKlarnaSubscription]"
- ]
- """
- Subscription details if setting up or charging a subscription
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
- average_amount: NotRequired[int]
- """
- Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- maximum_amount: NotRequired[int]
- """
- The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- minimum_amount: NotRequired[int]
- """
- The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
- """
- Interval at which the customer is making purchases
- """
- purchase_interval_count: NotRequired[int]
- """
- The number of `purchase_interval` between charges
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Unit of time between subscription charges.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
- """
- name: NotRequired[str]
- """
- Name for subscription.
- """
- next_billing: "SetupIntent.ConfirmParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
- """
- Describes the upcoming charge for this subscription.
- """
- reference: str
- """
- A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
- TypedDict,
- ):
- amount: int
- """
- The amount of the next charge for the subscription.
- """
- date: str
- """
- The date of the next charge for the subscription in YYYY-MM-DD format.
- """
-
- class ConfirmParamsPaymentMethodOptionsLink(TypedDict):
- persistent_token: NotRequired[str]
- """
- [Deprecated] This is a legacy parameter that no longer has any function.
- """
-
- class ConfirmParamsPaymentMethodOptionsPaypal(TypedDict):
- billing_agreement_id: NotRequired[str]
- """
- The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
- """
-
- class ConfirmParamsPaymentMethodOptionsSepaDebit(TypedDict):
- mandate_options: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsSepaDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
-
- class ConfirmParamsPaymentMethodOptionsSepaDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccount(TypedDict):
- financial_connections: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- mandate_options: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsUsBankAccountMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- networks: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsUsBankAccountNetworks"
- ]
- """
- Additional fields for network related functions
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "SetupIntent.ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
- return_url: NotRequired[str]
- """
- For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountMandateOptions(
- TypedDict,
- ):
- collection_method: NotRequired["Literal['']|Literal['paper']"]
- """
- The method used to collect offline mandate customer acceptance.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountNetworks(TypedDict):
- requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
- """
- Triggers validations to run across the selected networks
- """
-
- class CreateParams(RequestOptions):
- attach_to_self: NotRequired[bool]
- """
- If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
-
- It can only be used for this Stripe Account's own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
- """
- automatic_payment_methods: NotRequired[
- "SetupIntent.CreateParamsAutomaticPaymentMethods"
- ]
- """
- When you enable this parameter, this SetupIntent accepts payment methods that you enable in the Dashboard and that are compatible with its other parameters.
- """
- confirm: NotRequired[bool]
- """
- Set to `true` to attempt to confirm this SetupIntent immediately. This parameter defaults to `false`. If a card is the attached payment method, you can provide a `return_url` in case further authentication is necessary.
- """
- confirmation_token: NotRequired[str]
- """
- ID of the ConfirmationToken used to confirm this SetupIntent.
-
- If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
- """
- customer: NotRequired[str]
- """
- ID of the Customer this SetupIntent belongs to, if one exists.
-
- If present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- flow_directions: NotRequired[List[Literal["inbound", "outbound"]]]
- """
- Indicates the directions of money movement for which this payment method is intended to be used.
-
- Include `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.
- """
- mandate_data: NotRequired[
- "Literal['']|SetupIntent.CreateParamsMandateData"
- ]
- """
- This hash contains details about the mandate to create. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/setup_intents/create#create_setup_intent-confirm).
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The Stripe account ID created for this SetupIntent.
- """
- payment_method: NotRequired[str]
- """
- ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.
- """
- payment_method_configuration: NotRequired[str]
- """
- The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this SetupIntent.
- """
- payment_method_data: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodData"
- ]
- """
- When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
- value in the SetupIntent.
- """
- payment_method_options: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptions"
- ]
- """
- Payment method-specific configuration for this SetupIntent.
- """
- payment_method_types: NotRequired[List[str]]
- """
- The list of payment method types (for example, card) that this SetupIntent can use. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
- """
- return_url: NotRequired[str]
- """
- The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. To redirect to a mobile application, you can alternatively supply an application URI scheme. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/setup_intents/create#create_setup_intent-confirm).
- """
- single_use: NotRequired["SetupIntent.CreateParamsSingleUse"]
- """
- If you populate this hash, this SetupIntent generates a `single_use` mandate after successful completion.
-
- Single-use mandates are only valid for the following payment methods: `acss_debit`, `alipay`, `au_becs_debit`, `bacs_debit`, `bancontact`, `boleto`, `ideal`, `link`, `sepa_debit`, and `us_bank_account`.
- """
- usage: NotRequired[Literal["off_session", "on_session"]]
- """
- Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`.
- """
- use_stripe_sdk: NotRequired[bool]
- """
- Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
- """
-
- class CreateParamsAutomaticPaymentMethods(TypedDict):
- allow_redirects: NotRequired[Literal["always", "never"]]
- """
- Controls whether this SetupIntent will accept redirect-based payment methods.
-
- Redirect-based payment methods may require your customer to be redirected to a payment method's app or site for authentication or additional steps. To [confirm](https://stripe.com/docs/api/setup_intents/confirm) this SetupIntent, you may be required to provide a `return_url` to redirect customers back to your site after they authenticate or complete the setup.
- """
- enabled: bool
- """
- Whether this feature is enabled.
- """
-
- class CreateParamsMandateData(TypedDict):
- customer_acceptance: (
- "SetupIntent.CreateParamsMandateDataCustomerAcceptance"
- )
- """
- This hash contains details about the customer acceptance of the Mandate.
- """
-
- class CreateParamsMandateDataCustomerAcceptance(TypedDict):
- accepted_at: NotRequired[int]
- """
- The time at which the customer accepted the Mandate.
- """
- offline: NotRequired[
- "SetupIntent.CreateParamsMandateDataCustomerAcceptanceOffline"
- ]
- """
- If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
- """
- online: NotRequired[
- "SetupIntent.CreateParamsMandateDataCustomerAcceptanceOnline"
- ]
- """
- If this is a Mandate accepted online, this hash contains details about the online acceptance.
- """
- type: Literal["offline", "online"]
- """
- The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
- """
-
- class CreateParamsMandateDataCustomerAcceptanceOffline(TypedDict):
- pass
-
- class CreateParamsMandateDataCustomerAcceptanceOnline(TypedDict):
- ip_address: str
- """
- The IP address from which the Mandate was accepted by the customer.
- """
- user_agent: str
- """
- The user agent of the browser from which the Mandate was accepted by the customer.
- """
-
- class CreateParamsPaymentMethodData(TypedDict):
- acss_debit: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataAcssDebit"
- ]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired["SetupIntent.CreateParamsPaymentMethodDataAffirm"]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired["SetupIntent.CreateParamsPaymentMethodDataAlipay"]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired["SetupIntent.CreateParamsPaymentMethodDataAlma"]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataAmazonPay"
- ]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataAuBecsDebit"
- ]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired["SetupIntent.CreateParamsPaymentMethodDataBillie"]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired["SetupIntent.CreateParamsPaymentMethodDataBlik"]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired["SetupIntent.CreateParamsPaymentMethodDataBoleto"]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- cashapp: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired["SetupIntent.CreateParamsPaymentMethodDataCrypto"]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer_balance: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired["SetupIntent.CreateParamsPaymentMethodDataEps"]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- fpx: NotRequired["SetupIntent.CreateParamsPaymentMethodDataFpx"]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired["SetupIntent.CreateParamsPaymentMethodDataIdeal"]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired["SetupIntent.CreateParamsPaymentMethodDataKlarna"]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired["SetupIntent.CreateParamsPaymentMethodDataKrCard"]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired["SetupIntent.CreateParamsPaymentMethodDataLink"]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired["SetupIntent.CreateParamsPaymentMethodDataMbWay"]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataMobilepay"
- ]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataNzBankAccount"
- ]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired["SetupIntent.CreateParamsPaymentMethodDataOxxo"]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired["SetupIntent.CreateParamsPaymentMethodDataP24"]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired["SetupIntent.CreateParamsPaymentMethodDataPayco"]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- paynow: NotRequired["SetupIntent.CreateParamsPaymentMethodDataPaynow"]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired["SetupIntent.CreateParamsPaymentMethodDataPaypal"]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired["SetupIntent.CreateParamsPaymentMethodDataPix"]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataRadarOptions"
- ]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired["SetupIntent.CreateParamsPaymentMethodDataSofort"]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired["SetupIntent.CreateParamsPaymentMethodDataSwish"]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired["SetupIntent.CreateParamsPaymentMethodDataTwint"]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodDataWechatPay"
- ]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired["SetupIntent.CreateParamsPaymentMethodDataZip"]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class CreateParamsPaymentMethodDataAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class CreateParamsPaymentMethodDataAffirm(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAfterpayClearpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAlipay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAlma(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAmazonPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class CreateParamsPaymentMethodDataBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class CreateParamsPaymentMethodDataBancontact(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBillie(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|SetupIntent.CreateParamsPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class CreateParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsPaymentMethodDataBlik(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class CreateParamsPaymentMethodDataCashapp(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataCrypto(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataCustomerBalance(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataGiropay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataGrabpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class CreateParamsPaymentMethodDataInteracPresent(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKakaoPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKlarna(TypedDict):
- dob: NotRequired["SetupIntent.CreateParamsPaymentMethodDataKlarnaDob"]
- """
- Customer's date of birth
- """
-
- class CreateParamsPaymentMethodDataKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsPaymentMethodDataKonbini(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKrCard(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataLink(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMbWay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMobilepay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMultibanco(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class CreateParamsPaymentMethodDataNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class CreateParamsPaymentMethodDataOxxo(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataPayByBank(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPayco(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPaynow(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPaypal(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPix(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPromptpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class CreateParamsPaymentMethodDataRevolutPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSamsungPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSatispay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class CreateParamsPaymentMethodDataSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class CreateParamsPaymentMethodDataSwish(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataTwint(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class CreateParamsPaymentMethodDataWechatPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataZip(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsAcssDebit"
- ]
- """
- If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
- """
- amazon_pay: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsAmazonPay"
- ]
- """
- If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
- """
- bacs_debit: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsBacsDebit"
- ]
- """
- If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
- """
- card: NotRequired["SetupIntent.CreateParamsPaymentMethodOptionsCard"]
- """
- Configuration for any card setup attempted on this SetupIntent.
- """
- card_present: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsCardPresent"
- ]
- """
- If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
- """
- klarna: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method options.
- """
- link: NotRequired["SetupIntent.CreateParamsPaymentMethodOptionsLink"]
- """
- If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
- """
- paypal: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
- """
- sepa_debit: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsSepaDebit"
- ]
- """
- If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
- """
- us_bank_account: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
- """
-
- class CreateParamsPaymentMethodOptionsAcssDebit(TypedDict):
- currency: NotRequired[Literal["cad", "usd"]]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- mandate_options: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class CreateParamsPaymentMethodOptionsAcssDebitMandateOptions(TypedDict):
- custom_mandate_url: NotRequired["Literal['']|str"]
- """
- A URL for custom mandate text to render during confirmation step.
- The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
- or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
- """
- default_for: NotRequired[List[Literal["invoice", "subscription"]]]
- """
- List of Stripe products where this mandate can be selected automatically.
- """
- interval_description: NotRequired[str]
- """
- Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
- """
- payment_schedule: NotRequired[
- Literal["combined", "interval", "sporadic"]
- ]
- """
- Payment schedule for the mandate.
- """
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class CreateParamsPaymentMethodOptionsAmazonPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptionsBacsDebit(TypedDict):
- mandate_options: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsBacsDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
-
- class CreateParamsPaymentMethodOptionsBacsDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
- """
-
- class CreateParamsPaymentMethodOptionsCard(TypedDict):
- mandate_options: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- moto: NotRequired[bool]
- """
- When specified, this parameter signals that a card has been collected
- as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
- parameter can only be provided during confirmation.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
- three_d_secure: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsCardThreeDSecure"
- ]
- """
- If 3D Secure authentication was performed with a third-party provider,
- the authentication details to use for this setup.
- """
-
- class CreateParamsPaymentMethodOptionsCardMandateOptions(TypedDict):
- amount: int
- """
- Amount to be charged for future payments.
- """
- amount_type: Literal["fixed", "maximum"]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- currency: str
- """
- Currency in which future payments will be charged. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
- end_date: NotRequired[int]
- """
- End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
- """
- interval: Literal["day", "month", "sporadic", "week", "year"]
- """
- Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
- """
- reference: str
- """
- Unique identifier for the mandate or subscription.
- """
- start_date: int
- """
- Start date of the mandate or subscription. Start date should not be lesser than yesterday.
- """
- supported_types: NotRequired[List[Literal["india"]]]
- """
- Specifies the type of mandates supported. Possible values are `india`.
- """
-
- class CreateParamsPaymentMethodOptionsCardPresent(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
- ares_trans_status: NotRequired[
- Literal["A", "C", "I", "N", "R", "U", "Y"]
- ]
- """
- The `transStatus` returned from the card Issuer's ACS in the ARes.
- """
- cryptogram: NotRequired[str]
- """
- The cryptogram, also known as the "authentication value" (AAV, CAVV or
- AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
- (Most 3D Secure providers will return the base64-encoded version, which
- is what you should specify here.)
- """
- electronic_commerce_indicator: NotRequired[
- Literal["01", "02", "05", "06", "07"]
- ]
- """
- The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
- provider and indicates what degree of authentication was performed.
- """
- network_options: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
- ]
- """
- Network specific 3DS fields. Network specific arguments require an
- explicit card brand choice. The parameter `payment_method_options.card.network``
- must be populated accordingly
- """
- requestor_challenge_indicator: NotRequired[str]
- """
- The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
- AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
- """
- transaction_id: NotRequired[str]
- """
- For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
- Transaction ID (dsTransID).
- """
- version: NotRequired[Literal["1.0.2", "2.1.0", "2.2.0"]]
- """
- The version of 3D Secure that was performed.
- """
-
- class CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
- TypedDict,
- ):
- cartes_bancaires: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
- ]
- """
- Cartes Bancaires-specific 3DS fields.
- """
-
- class CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
- TypedDict,
- ):
- cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
- """
- The cryptogram calculation algorithm used by the card Issuer's ACS
- to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
- messageExtension: CB-AVALGO
- """
- cb_exemption: NotRequired[str]
- """
- The exemption indicator returned from Cartes Bancaires in the ARes.
- message extension: CB-EXEMPTION; string (4 characters)
- This is a 3 byte bitmap (low significant byte first and most significant
- bit first) that has been Base64 encoded
- """
- cb_score: NotRequired[int]
- """
- The risk score returned from Cartes Bancaires in the ARes.
- message extension: CB-SCORE; numeric value 0-99
- """
-
- class CreateParamsPaymentMethodOptionsKlarna(TypedDict):
- currency: NotRequired[str]
- """
- The currency of the SetupIntent. Three letter ISO currency code.
- """
- on_demand: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsKlarnaOnDemand"
- ]
- """
- On-demand details if setting up a payment method for on-demand payments.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-CH",
- "de-DE",
- "el-GR",
- "en-AT",
- "en-AU",
- "en-BE",
- "en-CA",
- "en-CH",
- "en-CZ",
- "en-DE",
- "en-DK",
- "en-ES",
- "en-FI",
- "en-FR",
- "en-GB",
- "en-GR",
- "en-IE",
- "en-IT",
- "en-NL",
- "en-NO",
- "en-NZ",
- "en-PL",
- "en-PT",
- "en-RO",
- "en-SE",
- "en-US",
- "es-ES",
- "es-US",
- "fi-FI",
- "fr-BE",
- "fr-CA",
- "fr-CH",
- "fr-FR",
- "it-CH",
- "it-IT",
- "nb-NO",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "ro-RO",
- "sv-FI",
- "sv-SE",
- ]
- ]
- """
- Preferred language of the Klarna authorization page that the customer is redirected to
- """
- subscriptions: NotRequired[
- "Literal['']|List[SetupIntent.CreateParamsPaymentMethodOptionsKlarnaSubscription]"
- ]
- """
- Subscription details if setting up or charging a subscription
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
- average_amount: NotRequired[int]
- """
- Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- maximum_amount: NotRequired[int]
- """
- The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- minimum_amount: NotRequired[int]
- """
- The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
- """
- Interval at which the customer is making purchases
- """
- purchase_interval_count: NotRequired[int]
- """
- The number of `purchase_interval` between charges
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Unit of time between subscription charges.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
- """
- name: NotRequired[str]
- """
- Name for subscription.
- """
- next_billing: "SetupIntent.CreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
- """
- Describes the upcoming charge for this subscription.
- """
- reference: str
- """
- A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
- TypedDict,
- ):
- amount: int
- """
- The amount of the next charge for the subscription.
- """
- date: str
- """
- The date of the next charge for the subscription in YYYY-MM-DD format.
- """
-
- class CreateParamsPaymentMethodOptionsLink(TypedDict):
- persistent_token: NotRequired[str]
- """
- [Deprecated] This is a legacy parameter that no longer has any function.
- """
-
- class CreateParamsPaymentMethodOptionsPaypal(TypedDict):
- billing_agreement_id: NotRequired[str]
- """
- The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
- """
-
- class CreateParamsPaymentMethodOptionsSepaDebit(TypedDict):
- mandate_options: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsSepaDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
-
- class CreateParamsPaymentMethodOptionsSepaDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccount(TypedDict):
- financial_connections: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- mandate_options: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsUsBankAccountMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- networks: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsUsBankAccountNetworks"
- ]
- """
- Additional fields for network related functions
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "SetupIntent.CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
- return_url: NotRequired[str]
- """
- For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountMandateOptions(
- TypedDict,
- ):
- collection_method: NotRequired["Literal['']|Literal['paper']"]
- """
- The method used to collect offline mandate customer acceptance.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountNetworks(TypedDict):
- requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
- """
- Triggers validations to run across the selected networks
- """
-
- class CreateParamsSingleUse(TypedDict):
- amount: int
- """
- Amount the customer is granting permission to collect later. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class ListParams(RequestOptions):
- attach_to_self: NotRequired[bool]
- """
- If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
-
- It can only be used for this Stripe Account's own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
- """
- created: NotRequired["SetupIntent.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
- """
- customer: NotRequired[str]
- """
- Only return SetupIntents for the customer specified by this customer ID.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payment_method: NotRequired[str]
- """
- Only return SetupIntents that associate with the specified payment method.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- attach_to_self: NotRequired[bool]
- """
- If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
-
- It can only be used for this Stripe Account's own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
- """
- customer: NotRequired[str]
- """
- ID of the Customer this SetupIntent belongs to, if one exists.
-
- If present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- flow_directions: NotRequired[List[Literal["inbound", "outbound"]]]
- """
- Indicates the directions of money movement for which this payment method is intended to be used.
-
- Include `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- payment_method: NotRequired[str]
- """
- ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent. To unset this field to null, pass in an empty string.
- """
- payment_method_configuration: NotRequired[str]
- """
- The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this SetupIntent.
- """
- payment_method_data: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodData"
- ]
- """
- When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
- value in the SetupIntent.
- """
- payment_method_options: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptions"
- ]
- """
- Payment method-specific configuration for this SetupIntent.
- """
- payment_method_types: NotRequired[List[str]]
- """
- The list of payment method types (for example, card) that this SetupIntent can set up. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
- """
-
- class ModifyParamsPaymentMethodData(TypedDict):
- acss_debit: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataAcssDebit"
- ]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataAffirm"]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataAlipay"]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataAlma"]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataAmazonPay"
- ]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataAuBecsDebit"
- ]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataBillie"]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataBlik"]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataBoleto"]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- cashapp: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataCrypto"]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer_balance: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataEps"]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- fpx: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataFpx"]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataIdeal"]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataKlarna"]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataKrCard"]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataLink"]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataMbWay"]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataMobilepay"
- ]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataNzBankAccount"
- ]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataOxxo"]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataP24"]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataPayco"]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- paynow: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataPaynow"]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataPaypal"]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataPix"]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataRadarOptions"
- ]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataSofort"]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataSwish"]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataTwint"]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodDataWechatPay"
- ]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataZip"]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class ModifyParamsPaymentMethodDataAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class ModifyParamsPaymentMethodDataAffirm(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataAfterpayClearpay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataAlipay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataAlma(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataAmazonPay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class ModifyParamsPaymentMethodDataBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class ModifyParamsPaymentMethodDataBancontact(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataBillie(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|SetupIntent.ModifyParamsPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class ModifyParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ModifyParamsPaymentMethodDataBlik(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class ModifyParamsPaymentMethodDataCashapp(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataCrypto(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataCustomerBalance(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class ModifyParamsPaymentMethodDataFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class ModifyParamsPaymentMethodDataGiropay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataGrabpay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class ModifyParamsPaymentMethodDataInteracPresent(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataKakaoPay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataKlarna(TypedDict):
- dob: NotRequired["SetupIntent.ModifyParamsPaymentMethodDataKlarnaDob"]
- """
- Customer's date of birth
- """
-
- class ModifyParamsPaymentMethodDataKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class ModifyParamsPaymentMethodDataKonbini(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataKrCard(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataLink(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataMbWay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataMobilepay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataMultibanco(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class ModifyParamsPaymentMethodDataNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class ModifyParamsPaymentMethodDataOxxo(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class ModifyParamsPaymentMethodDataPayByBank(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataPayco(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataPaynow(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataPaypal(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataPix(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataPromptpay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class ModifyParamsPaymentMethodDataRevolutPay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataSamsungPay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataSatispay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class ModifyParamsPaymentMethodDataSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class ModifyParamsPaymentMethodDataSwish(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataTwint(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class ModifyParamsPaymentMethodDataWechatPay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodDataZip(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsAcssDebit"
- ]
- """
- If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
- """
- amazon_pay: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsAmazonPay"
- ]
- """
- If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
- """
- bacs_debit: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsBacsDebit"
- ]
- """
- If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
- """
- card: NotRequired["SetupIntent.ModifyParamsPaymentMethodOptionsCard"]
- """
- Configuration for any card setup attempted on this SetupIntent.
- """
- card_present: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsCardPresent"
- ]
- """
- If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
- """
- klarna: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method options.
- """
- link: NotRequired["SetupIntent.ModifyParamsPaymentMethodOptionsLink"]
- """
- If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
- """
- paypal: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
- """
- sepa_debit: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsSepaDebit"
- ]
- """
- If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
- """
- us_bank_account: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
- """
-
- class ModifyParamsPaymentMethodOptionsAcssDebit(TypedDict):
- currency: NotRequired[Literal["cad", "usd"]]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- mandate_options: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class ModifyParamsPaymentMethodOptionsAcssDebitMandateOptions(TypedDict):
- custom_mandate_url: NotRequired["Literal['']|str"]
- """
- A URL for custom mandate text to render during confirmation step.
- The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
- or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
- """
- default_for: NotRequired[List[Literal["invoice", "subscription"]]]
- """
- List of Stripe products where this mandate can be selected automatically.
- """
- interval_description: NotRequired[str]
- """
- Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
- """
- payment_schedule: NotRequired[
- Literal["combined", "interval", "sporadic"]
- ]
- """
- Payment schedule for the mandate.
- """
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class ModifyParamsPaymentMethodOptionsAmazonPay(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodOptionsBacsDebit(TypedDict):
- mandate_options: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsBacsDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
-
- class ModifyParamsPaymentMethodOptionsBacsDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
- """
-
- class ModifyParamsPaymentMethodOptionsCard(TypedDict):
- mandate_options: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- moto: NotRequired[bool]
- """
- When specified, this parameter signals that a card has been collected
- as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
- parameter can only be provided during confirmation.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
- three_d_secure: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsCardThreeDSecure"
- ]
- """
- If 3D Secure authentication was performed with a third-party provider,
- the authentication details to use for this setup.
- """
-
- class ModifyParamsPaymentMethodOptionsCardMandateOptions(TypedDict):
- amount: int
- """
- Amount to be charged for future payments.
- """
- amount_type: Literal["fixed", "maximum"]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- currency: str
- """
- Currency in which future payments will be charged. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
- end_date: NotRequired[int]
- """
- End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
- """
- interval: Literal["day", "month", "sporadic", "week", "year"]
- """
- Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
- """
- reference: str
- """
- Unique identifier for the mandate or subscription.
- """
- start_date: int
- """
- Start date of the mandate or subscription. Start date should not be lesser than yesterday.
- """
- supported_types: NotRequired[List[Literal["india"]]]
- """
- Specifies the type of mandates supported. Possible values are `india`.
- """
-
- class ModifyParamsPaymentMethodOptionsCardPresent(TypedDict):
- pass
-
- class ModifyParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
- ares_trans_status: NotRequired[
- Literal["A", "C", "I", "N", "R", "U", "Y"]
- ]
- """
- The `transStatus` returned from the card Issuer's ACS in the ARes.
- """
- cryptogram: NotRequired[str]
- """
- The cryptogram, also known as the "authentication value" (AAV, CAVV or
- AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
- (Most 3D Secure providers will return the base64-encoded version, which
- is what you should specify here.)
- """
- electronic_commerce_indicator: NotRequired[
- Literal["01", "02", "05", "06", "07"]
- ]
- """
- The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
- provider and indicates what degree of authentication was performed.
- """
- network_options: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
- ]
- """
- Network specific 3DS fields. Network specific arguments require an
- explicit card brand choice. The parameter `payment_method_options.card.network``
- must be populated accordingly
- """
- requestor_challenge_indicator: NotRequired[str]
- """
- The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
- AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
- """
- transaction_id: NotRequired[str]
- """
- For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
- Transaction ID (dsTransID).
- """
- version: NotRequired[Literal["1.0.2", "2.1.0", "2.2.0"]]
- """
- The version of 3D Secure that was performed.
- """
-
- class ModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
- TypedDict,
- ):
- cartes_bancaires: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
- ]
- """
- Cartes Bancaires-specific 3DS fields.
- """
-
- class ModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
- TypedDict,
- ):
- cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
- """
- The cryptogram calculation algorithm used by the card Issuer's ACS
- to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
- messageExtension: CB-AVALGO
- """
- cb_exemption: NotRequired[str]
- """
- The exemption indicator returned from Cartes Bancaires in the ARes.
- message extension: CB-EXEMPTION; string (4 characters)
- This is a 3 byte bitmap (low significant byte first and most significant
- bit first) that has been Base64 encoded
- """
- cb_score: NotRequired[int]
- """
- The risk score returned from Cartes Bancaires in the ARes.
- message extension: CB-SCORE; numeric value 0-99
- """
-
- class ModifyParamsPaymentMethodOptionsKlarna(TypedDict):
- currency: NotRequired[str]
- """
- The currency of the SetupIntent. Three letter ISO currency code.
- """
- on_demand: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsKlarnaOnDemand"
- ]
- """
- On-demand details if setting up a payment method for on-demand payments.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-CH",
- "de-DE",
- "el-GR",
- "en-AT",
- "en-AU",
- "en-BE",
- "en-CA",
- "en-CH",
- "en-CZ",
- "en-DE",
- "en-DK",
- "en-ES",
- "en-FI",
- "en-FR",
- "en-GB",
- "en-GR",
- "en-IE",
- "en-IT",
- "en-NL",
- "en-NO",
- "en-NZ",
- "en-PL",
- "en-PT",
- "en-RO",
- "en-SE",
- "en-US",
- "es-ES",
- "es-US",
- "fi-FI",
- "fr-BE",
- "fr-CA",
- "fr-CH",
- "fr-FR",
- "it-CH",
- "it-IT",
- "nb-NO",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "ro-RO",
- "sv-FI",
- "sv-SE",
- ]
- ]
- """
- Preferred language of the Klarna authorization page that the customer is redirected to
- """
- subscriptions: NotRequired[
- "Literal['']|List[SetupIntent.ModifyParamsPaymentMethodOptionsKlarnaSubscription]"
- ]
- """
- Subscription details if setting up or charging a subscription
- """
-
- class ModifyParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
- average_amount: NotRequired[int]
- """
- Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- maximum_amount: NotRequired[int]
- """
- The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- minimum_amount: NotRequired[int]
- """
- The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
- """
- Interval at which the customer is making purchases
- """
- purchase_interval_count: NotRequired[int]
- """
- The number of `purchase_interval` between charges
- """
-
- class ModifyParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Unit of time between subscription charges.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
- """
- name: NotRequired[str]
- """
- Name for subscription.
- """
- next_billing: "SetupIntent.ModifyParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
- """
- Describes the upcoming charge for this subscription.
- """
- reference: str
- """
- A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
- """
-
- class ModifyParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
- TypedDict,
- ):
- amount: int
- """
- The amount of the next charge for the subscription.
- """
- date: str
- """
- The date of the next charge for the subscription in YYYY-MM-DD format.
- """
-
- class ModifyParamsPaymentMethodOptionsLink(TypedDict):
- persistent_token: NotRequired[str]
- """
- [Deprecated] This is a legacy parameter that no longer has any function.
- """
-
- class ModifyParamsPaymentMethodOptionsPaypal(TypedDict):
- billing_agreement_id: NotRequired[str]
- """
- The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
- """
-
- class ModifyParamsPaymentMethodOptionsSepaDebit(TypedDict):
- mandate_options: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsSepaDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
-
- class ModifyParamsPaymentMethodOptionsSepaDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
- """
-
- class ModifyParamsPaymentMethodOptionsUsBankAccount(TypedDict):
- financial_connections: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- mandate_options: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsUsBankAccountMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- networks: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsUsBankAccountNetworks"
- ]
- """
- Additional fields for network related functions
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class ModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "SetupIntent.ModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
- return_url: NotRequired[str]
- """
- For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
- """
-
- class ModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class ModifyParamsPaymentMethodOptionsUsBankAccountMandateOptions(
- TypedDict,
- ):
- collection_method: NotRequired["Literal['']|Literal['paper']"]
- """
- The method used to collect offline mandate customer acceptance.
- """
-
- class ModifyParamsPaymentMethodOptionsUsBankAccountNetworks(TypedDict):
- requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
- """
- Triggers validations to run across the selected networks
- """
-
- class RetrieveParams(RequestOptions):
- client_secret: NotRequired[str]
- """
- The client secret of the SetupIntent. We require this string if you use a publishable key to retrieve the SetupIntent.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class VerifyMicrodepositsParams(RequestOptions):
- amounts: NotRequired[List[int]]
- """
- Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.
- """
- descriptor_code: NotRequired[str]
- """
- A six-character code starting with SM present in the microdeposit sent to the bank account.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
application: Optional[ExpandableField["Application"]]
"""
ID of the Connect application that created the SetupIntent.
@@ -4978,7 +816,7 @@ class VerifyMicrodepositsParams(RequestOptions):
@classmethod
def _cls_cancel(
- cls, intent: str, **params: Unpack["SetupIntent.CancelParams"]
+ 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.
@@ -4999,7 +837,7 @@ def _cls_cancel(
@overload
@staticmethod
def cancel(
- intent: str, **params: Unpack["SetupIntent.CancelParams"]
+ 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.
@@ -5010,7 +848,7 @@ def cancel(
@overload
def cancel(
- self, **params: Unpack["SetupIntent.CancelParams"]
+ self, **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.
@@ -5021,7 +859,7 @@ def cancel(
@class_method_variant("_cls_cancel")
def cancel( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["SetupIntent.CancelParams"]
+ self, **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.
@@ -5041,7 +879,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_cancel_async(
- cls, intent: str, **params: Unpack["SetupIntent.CancelParams"]
+ 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.
@@ -5062,7 +900,7 @@ async def _cls_cancel_async(
@overload
@staticmethod
async def cancel_async(
- intent: str, **params: Unpack["SetupIntent.CancelParams"]
+ 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.
@@ -5073,7 +911,7 @@ async def cancel_async(
@overload
async def cancel_async(
- self, **params: Unpack["SetupIntent.CancelParams"]
+ self, **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.
@@ -5084,7 +922,7 @@ async def cancel_async(
@class_method_variant("_cls_cancel_async")
async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["SetupIntent.CancelParams"]
+ self, **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.
@@ -5104,7 +942,7 @@ async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_confirm(
- cls, intent: str, **params: Unpack["SetupIntent.ConfirmParams"]
+ cls, intent: str, **params: Unpack["SetupIntentConfirmParams"]
) -> "SetupIntent":
"""
Confirm that your customer intends to set up the current or
@@ -5136,7 +974,7 @@ def _cls_confirm(
@overload
@staticmethod
def confirm(
- intent: str, **params: Unpack["SetupIntent.ConfirmParams"]
+ intent: str, **params: Unpack["SetupIntentConfirmParams"]
) -> "SetupIntent":
"""
Confirm that your customer intends to set up the current or
@@ -5158,7 +996,7 @@ def confirm(
@overload
def confirm(
- self, **params: Unpack["SetupIntent.ConfirmParams"]
+ self, **params: Unpack["SetupIntentConfirmParams"]
) -> "SetupIntent":
"""
Confirm that your customer intends to set up the current or
@@ -5180,7 +1018,7 @@ def confirm(
@class_method_variant("_cls_confirm")
def confirm( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["SetupIntent.ConfirmParams"]
+ self, **params: Unpack["SetupIntentConfirmParams"]
) -> "SetupIntent":
"""
Confirm that your customer intends to set up the current or
@@ -5211,7 +1049,7 @@ def confirm( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_confirm_async(
- cls, intent: str, **params: Unpack["SetupIntent.ConfirmParams"]
+ cls, intent: str, **params: Unpack["SetupIntentConfirmParams"]
) -> "SetupIntent":
"""
Confirm that your customer intends to set up the current or
@@ -5243,7 +1081,7 @@ async def _cls_confirm_async(
@overload
@staticmethod
async def confirm_async(
- intent: str, **params: Unpack["SetupIntent.ConfirmParams"]
+ intent: str, **params: Unpack["SetupIntentConfirmParams"]
) -> "SetupIntent":
"""
Confirm that your customer intends to set up the current or
@@ -5265,7 +1103,7 @@ async def confirm_async(
@overload
async def confirm_async(
- self, **params: Unpack["SetupIntent.ConfirmParams"]
+ self, **params: Unpack["SetupIntentConfirmParams"]
) -> "SetupIntent":
"""
Confirm that your customer intends to set up the current or
@@ -5287,7 +1125,7 @@ async def confirm_async(
@class_method_variant("_cls_confirm_async")
async def confirm_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["SetupIntent.ConfirmParams"]
+ self, **params: Unpack["SetupIntentConfirmParams"]
) -> "SetupIntent":
"""
Confirm that your customer intends to set up the current or
@@ -5318,7 +1156,7 @@ async def confirm_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def create(
- cls, **params: Unpack["SetupIntent.CreateParams"]
+ cls, **params: Unpack["SetupIntentCreateParams"]
) -> "SetupIntent":
"""
Creates a SetupIntent object.
@@ -5337,7 +1175,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["SetupIntent.CreateParams"]
+ cls, **params: Unpack["SetupIntentCreateParams"]
) -> "SetupIntent":
"""
Creates a SetupIntent object.
@@ -5356,7 +1194,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["SetupIntent.ListParams"]
+ cls, **params: Unpack["SetupIntentListParams"]
) -> ListObject["SetupIntent"]:
"""
Returns a list of SetupIntents.
@@ -5376,7 +1214,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["SetupIntent.ListParams"]
+ cls, **params: Unpack["SetupIntentListParams"]
) -> ListObject["SetupIntent"]:
"""
Returns a list of SetupIntents.
@@ -5396,7 +1234,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["SetupIntent.ModifyParams"]
+ cls, id: str, **params: Unpack["SetupIntentModifyParams"]
) -> "SetupIntent":
"""
Updates a SetupIntent object.
@@ -5413,7 +1251,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["SetupIntent.ModifyParams"]
+ cls, id: str, **params: Unpack["SetupIntentModifyParams"]
) -> "SetupIntent":
"""
Updates a SetupIntent object.
@@ -5430,7 +1268,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["SetupIntent.RetrieveParams"]
+ cls, id: str, **params: Unpack["SetupIntentRetrieveParams"]
) -> "SetupIntent":
"""
Retrieves the details of a SetupIntent that has previously been created.
@@ -5445,7 +1283,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["SetupIntent.RetrieveParams"]
+ cls, id: str, **params: Unpack["SetupIntentRetrieveParams"]
) -> "SetupIntent":
"""
Retrieves the details of a SetupIntent that has previously been created.
@@ -5462,7 +1300,7 @@ async def retrieve_async(
def _cls_verify_microdeposits(
cls,
intent: str,
- **params: Unpack["SetupIntent.VerifyMicrodepositsParams"],
+ **params: Unpack["SetupIntentVerifyMicrodepositsParams"],
) -> "SetupIntent":
"""
Verifies microdeposits on a SetupIntent object.
@@ -5481,7 +1319,7 @@ def _cls_verify_microdeposits(
@overload
@staticmethod
def verify_microdeposits(
- intent: str, **params: Unpack["SetupIntent.VerifyMicrodepositsParams"]
+ intent: str, **params: Unpack["SetupIntentVerifyMicrodepositsParams"]
) -> "SetupIntent":
"""
Verifies microdeposits on a SetupIntent object.
@@ -5490,7 +1328,7 @@ def verify_microdeposits(
@overload
def verify_microdeposits(
- self, **params: Unpack["SetupIntent.VerifyMicrodepositsParams"]
+ self, **params: Unpack["SetupIntentVerifyMicrodepositsParams"]
) -> "SetupIntent":
"""
Verifies microdeposits on a SetupIntent object.
@@ -5499,7 +1337,7 @@ def verify_microdeposits(
@class_method_variant("_cls_verify_microdeposits")
def verify_microdeposits( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["SetupIntent.VerifyMicrodepositsParams"]
+ self, **params: Unpack["SetupIntentVerifyMicrodepositsParams"]
) -> "SetupIntent":
"""
Verifies microdeposits on a SetupIntent object.
@@ -5519,7 +1357,7 @@ def verify_microdeposits( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_verify_microdeposits_async(
cls,
intent: str,
- **params: Unpack["SetupIntent.VerifyMicrodepositsParams"],
+ **params: Unpack["SetupIntentVerifyMicrodepositsParams"],
) -> "SetupIntent":
"""
Verifies microdeposits on a SetupIntent object.
@@ -5538,7 +1376,7 @@ async def _cls_verify_microdeposits_async(
@overload
@staticmethod
async def verify_microdeposits_async(
- intent: str, **params: Unpack["SetupIntent.VerifyMicrodepositsParams"]
+ intent: str, **params: Unpack["SetupIntentVerifyMicrodepositsParams"]
) -> "SetupIntent":
"""
Verifies microdeposits on a SetupIntent object.
@@ -5547,7 +1385,7 @@ async def verify_microdeposits_async(
@overload
async def verify_microdeposits_async(
- self, **params: Unpack["SetupIntent.VerifyMicrodepositsParams"]
+ self, **params: Unpack["SetupIntentVerifyMicrodepositsParams"]
) -> "SetupIntent":
"""
Verifies microdeposits on a SetupIntent object.
@@ -5556,7 +1394,7 @@ async def verify_microdeposits_async(
@class_method_variant("_cls_verify_microdeposits_async")
async def verify_microdeposits_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["SetupIntent.VerifyMicrodepositsParams"]
+ self, **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 be557d25a..ed7492301 100644
--- a/stripe/_setup_intent_service.py
+++ b/stripe/_setup_intent_service.py
@@ -5,4328 +5,35 @@
from stripe._setup_intent import SetupIntent
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._setup_intent_cancel_params import (
+ SetupIntentCancelParams,
+ )
+ from stripe.params._setup_intent_confirm_params import (
+ SetupIntentConfirmParams,
+ )
+ from stripe.params._setup_intent_create_params import (
+ SetupIntentCreateParams,
+ )
+ from stripe.params._setup_intent_list_params import SetupIntentListParams
+ from stripe.params._setup_intent_retrieve_params import (
+ SetupIntentRetrieveParams,
+ )
+ from stripe.params._setup_intent_update_params import (
+ SetupIntentUpdateParams,
+ )
+ from stripe.params._setup_intent_verify_microdeposits_params import (
+ SetupIntentVerifyMicrodepositsParams,
+ )
class SetupIntentService(StripeService):
- class CancelParams(TypedDict):
- cancellation_reason: NotRequired[
- Literal["abandoned", "duplicate", "requested_by_customer"]
- ]
- """
- Reason for canceling this SetupIntent. Possible values are: `abandoned`, `requested_by_customer`, or `duplicate`
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ConfirmParams(TypedDict):
- confirmation_token: NotRequired[str]
- """
- ID of the ConfirmationToken used to confirm this SetupIntent.
-
- If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- mandate_data: NotRequired[
- "Literal['']|SetupIntentService.ConfirmParamsMandateData"
- ]
- payment_method: NotRequired[str]
- """
- ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.
- """
- payment_method_data: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodData"
- ]
- """
- When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
- value in the SetupIntent.
- """
- payment_method_options: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptions"
- ]
- """
- Payment method-specific configuration for this SetupIntent.
- """
- return_url: NotRequired[str]
- """
- The URL to redirect your customer back to after they authenticate on the payment method's app or site.
- If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
- This parameter is only used for cards and other redirect-based payment methods.
- """
- use_stripe_sdk: NotRequired[bool]
- """
- Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
- """
-
- class ConfirmParamsMandateData(TypedDict):
- customer_acceptance: NotRequired[
- "SetupIntentService.ConfirmParamsMandateDataCustomerAcceptance"
- ]
- """
- This hash contains details about the customer acceptance of the Mandate.
- """
-
- class ConfirmParamsMandateDataCustomerAcceptance(TypedDict):
- accepted_at: NotRequired[int]
- """
- The time at which the customer accepted the Mandate.
- """
- offline: NotRequired[
- "SetupIntentService.ConfirmParamsMandateDataCustomerAcceptanceOffline"
- ]
- """
- If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
- """
- online: NotRequired[
- "SetupIntentService.ConfirmParamsMandateDataCustomerAcceptanceOnline"
- ]
- """
- If this is a Mandate accepted online, this hash contains details about the online acceptance.
- """
- type: Literal["offline", "online"]
- """
- The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
- """
-
- class ConfirmParamsMandateDataCustomerAcceptanceOffline(TypedDict):
- pass
-
- class ConfirmParamsMandateDataCustomerAcceptanceOnline(TypedDict):
- ip_address: NotRequired[str]
- """
- The IP address from which the Mandate was accepted by the customer.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the Mandate was accepted by the customer.
- """
-
- class ConfirmParamsPaymentMethodData(TypedDict):
- acss_debit: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataAcssDebit"
- ]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataAlipay"
- ]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataAlma"
- ]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataAmazonPay"
- ]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataAuBecsDebit"
- ]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataBlik"
- ]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- cashapp: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataCrypto"
- ]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer_balance: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataEps"
- ]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- fpx: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataFpx"
- ]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataIdeal"
- ]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataLink"
- ]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataMbWay"
- ]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataMobilepay"
- ]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataNzBankAccount"
- ]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataOxxo"
- ]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataP24"
- ]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataPayco"
- ]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- paynow: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataPix"
- ]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataRadarOptions"
- ]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataSwish"
- ]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataTwint"
- ]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataWechatPay"
- ]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataZip"
- ]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class ConfirmParamsPaymentMethodDataAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataAffirm(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAfterpayClearpay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAlipay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAlma(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAmazonPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class ConfirmParamsPaymentMethodDataBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class ConfirmParamsPaymentMethodDataBancontact(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataBillie(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|SetupIntentService.ConfirmParamsPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class ConfirmParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ConfirmParamsPaymentMethodDataBlik(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class ConfirmParamsPaymentMethodDataCashapp(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataCrypto(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataCustomerBalance(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataGiropay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataGrabpay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class ConfirmParamsPaymentMethodDataInteracPresent(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataKakaoPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataKlarna(TypedDict):
- dob: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodDataKlarnaDob"
- ]
- """
- Customer's date of birth
- """
-
- class ConfirmParamsPaymentMethodDataKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class ConfirmParamsPaymentMethodDataKonbini(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataKrCard(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataLink(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataMbWay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataMobilepay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataMultibanco(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class ConfirmParamsPaymentMethodDataNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class ConfirmParamsPaymentMethodDataOxxo(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class ConfirmParamsPaymentMethodDataPayByBank(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPayco(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPaynow(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPaypal(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPix(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataPromptpay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class ConfirmParamsPaymentMethodDataRevolutPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataSamsungPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataSatispay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class ConfirmParamsPaymentMethodDataSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class ConfirmParamsPaymentMethodDataSwish(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataTwint(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class ConfirmParamsPaymentMethodDataWechatPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodDataZip(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsAcssDebit"
- ]
- """
- If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
- """
- amazon_pay: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsAmazonPay"
- ]
- """
- If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
- """
- bacs_debit: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsBacsDebit"
- ]
- """
- If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
- """
- card: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsCard"
- ]
- """
- Configuration for any card setup attempted on this SetupIntent.
- """
- card_present: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsCardPresent"
- ]
- """
- If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
- """
- klarna: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method options.
- """
- link: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsLink"
- ]
- """
- If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
- """
- paypal: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
- """
- sepa_debit: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsSepaDebit"
- ]
- """
- If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
- """
- us_bank_account: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
- """
-
- class ConfirmParamsPaymentMethodOptionsAcssDebit(TypedDict):
- currency: NotRequired[Literal["cad", "usd"]]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- mandate_options: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class ConfirmParamsPaymentMethodOptionsAcssDebitMandateOptions(TypedDict):
- custom_mandate_url: NotRequired["Literal['']|str"]
- """
- A URL for custom mandate text to render during confirmation step.
- The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
- or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
- """
- default_for: NotRequired[List[Literal["invoice", "subscription"]]]
- """
- List of Stripe products where this mandate can be selected automatically.
- """
- interval_description: NotRequired[str]
- """
- Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
- """
- payment_schedule: NotRequired[
- Literal["combined", "interval", "sporadic"]
- ]
- """
- Payment schedule for the mandate.
- """
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class ConfirmParamsPaymentMethodOptionsAmazonPay(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodOptionsBacsDebit(TypedDict):
- mandate_options: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsBacsDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
-
- class ConfirmParamsPaymentMethodOptionsBacsDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
- """
-
- class ConfirmParamsPaymentMethodOptionsCard(TypedDict):
- mandate_options: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- moto: NotRequired[bool]
- """
- When specified, this parameter signals that a card has been collected
- as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
- parameter can only be provided during confirmation.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
- three_d_secure: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsCardThreeDSecure"
- ]
- """
- If 3D Secure authentication was performed with a third-party provider,
- the authentication details to use for this setup.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardMandateOptions(TypedDict):
- amount: int
- """
- Amount to be charged for future payments.
- """
- amount_type: Literal["fixed", "maximum"]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- currency: str
- """
- Currency in which future payments will be charged. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
- end_date: NotRequired[int]
- """
- End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
- """
- interval: Literal["day", "month", "sporadic", "week", "year"]
- """
- Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
- """
- reference: str
- """
- Unique identifier for the mandate or subscription.
- """
- start_date: int
- """
- Start date of the mandate or subscription. Start date should not be lesser than yesterday.
- """
- supported_types: NotRequired[List[Literal["india"]]]
- """
- Specifies the type of mandates supported. Possible values are `india`.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardPresent(TypedDict):
- pass
-
- class ConfirmParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
- ares_trans_status: NotRequired[
- Literal["A", "C", "I", "N", "R", "U", "Y"]
- ]
- """
- The `transStatus` returned from the card Issuer's ACS in the ARes.
- """
- cryptogram: NotRequired[str]
- """
- The cryptogram, also known as the "authentication value" (AAV, CAVV or
- AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
- (Most 3D Secure providers will return the base64-encoded version, which
- is what you should specify here.)
- """
- electronic_commerce_indicator: NotRequired[
- Literal["01", "02", "05", "06", "07"]
- ]
- """
- The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
- provider and indicates what degree of authentication was performed.
- """
- network_options: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
- ]
- """
- Network specific 3DS fields. Network specific arguments require an
- explicit card brand choice. The parameter `payment_method_options.card.network``
- must be populated accordingly
- """
- requestor_challenge_indicator: NotRequired[str]
- """
- The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
- AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
- """
- transaction_id: NotRequired[str]
- """
- For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
- Transaction ID (dsTransID).
- """
- version: NotRequired[Literal["1.0.2", "2.1.0", "2.2.0"]]
- """
- The version of 3D Secure that was performed.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
- TypedDict,
- ):
- cartes_bancaires: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
- ]
- """
- Cartes Bancaires-specific 3DS fields.
- """
-
- class ConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
- TypedDict,
- ):
- cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
- """
- The cryptogram calculation algorithm used by the card Issuer's ACS
- to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
- messageExtension: CB-AVALGO
- """
- cb_exemption: NotRequired[str]
- """
- The exemption indicator returned from Cartes Bancaires in the ARes.
- message extension: CB-EXEMPTION; string (4 characters)
- This is a 3 byte bitmap (low significant byte first and most significant
- bit first) that has been Base64 encoded
- """
- cb_score: NotRequired[int]
- """
- The risk score returned from Cartes Bancaires in the ARes.
- message extension: CB-SCORE; numeric value 0-99
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarna(TypedDict):
- currency: NotRequired[str]
- """
- The currency of the SetupIntent. Three letter ISO currency code.
- """
- on_demand: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsKlarnaOnDemand"
- ]
- """
- On-demand details if setting up a payment method for on-demand payments.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-CH",
- "de-DE",
- "el-GR",
- "en-AT",
- "en-AU",
- "en-BE",
- "en-CA",
- "en-CH",
- "en-CZ",
- "en-DE",
- "en-DK",
- "en-ES",
- "en-FI",
- "en-FR",
- "en-GB",
- "en-GR",
- "en-IE",
- "en-IT",
- "en-NL",
- "en-NO",
- "en-NZ",
- "en-PL",
- "en-PT",
- "en-RO",
- "en-SE",
- "en-US",
- "es-ES",
- "es-US",
- "fi-FI",
- "fr-BE",
- "fr-CA",
- "fr-CH",
- "fr-FR",
- "it-CH",
- "it-IT",
- "nb-NO",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "ro-RO",
- "sv-FI",
- "sv-SE",
- ]
- ]
- """
- Preferred language of the Klarna authorization page that the customer is redirected to
- """
- subscriptions: NotRequired[
- "Literal['']|List[SetupIntentService.ConfirmParamsPaymentMethodOptionsKlarnaSubscription]"
- ]
- """
- Subscription details if setting up or charging a subscription
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
- average_amount: NotRequired[int]
- """
- Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- maximum_amount: NotRequired[int]
- """
- The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- minimum_amount: NotRequired[int]
- """
- The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
- """
- Interval at which the customer is making purchases
- """
- purchase_interval_count: NotRequired[int]
- """
- The number of `purchase_interval` between charges
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Unit of time between subscription charges.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
- """
- name: NotRequired[str]
- """
- Name for subscription.
- """
- next_billing: "SetupIntentService.ConfirmParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
- """
- Describes the upcoming charge for this subscription.
- """
- reference: str
- """
- A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
- """
-
- class ConfirmParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
- TypedDict,
- ):
- amount: int
- """
- The amount of the next charge for the subscription.
- """
- date: str
- """
- The date of the next charge for the subscription in YYYY-MM-DD format.
- """
-
- class ConfirmParamsPaymentMethodOptionsLink(TypedDict):
- persistent_token: NotRequired[str]
- """
- [Deprecated] This is a legacy parameter that no longer has any function.
- """
-
- class ConfirmParamsPaymentMethodOptionsPaypal(TypedDict):
- billing_agreement_id: NotRequired[str]
- """
- The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
- """
-
- class ConfirmParamsPaymentMethodOptionsSepaDebit(TypedDict):
- mandate_options: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsSepaDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
-
- class ConfirmParamsPaymentMethodOptionsSepaDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccount(TypedDict):
- financial_connections: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- mandate_options: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsUsBankAccountMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- networks: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsUsBankAccountNetworks"
- ]
- """
- Additional fields for network related functions
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "SetupIntentService.ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
- return_url: NotRequired[str]
- """
- For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountMandateOptions(
- TypedDict,
- ):
- collection_method: NotRequired["Literal['']|Literal['paper']"]
- """
- The method used to collect offline mandate customer acceptance.
- """
-
- class ConfirmParamsPaymentMethodOptionsUsBankAccountNetworks(TypedDict):
- requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
- """
- Triggers validations to run across the selected networks
- """
-
- class CreateParams(TypedDict):
- attach_to_self: NotRequired[bool]
- """
- If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
-
- It can only be used for this Stripe Account's own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
- """
- automatic_payment_methods: NotRequired[
- "SetupIntentService.CreateParamsAutomaticPaymentMethods"
- ]
- """
- When you enable this parameter, this SetupIntent accepts payment methods that you enable in the Dashboard and that are compatible with its other parameters.
- """
- confirm: NotRequired[bool]
- """
- Set to `true` to attempt to confirm this SetupIntent immediately. This parameter defaults to `false`. If a card is the attached payment method, you can provide a `return_url` in case further authentication is necessary.
- """
- confirmation_token: NotRequired[str]
- """
- ID of the ConfirmationToken used to confirm this SetupIntent.
-
- If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
- """
- customer: NotRequired[str]
- """
- ID of the Customer this SetupIntent belongs to, if one exists.
-
- If present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- flow_directions: NotRequired[List[Literal["inbound", "outbound"]]]
- """
- Indicates the directions of money movement for which this payment method is intended to be used.
-
- Include `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.
- """
- mandate_data: NotRequired[
- "Literal['']|SetupIntentService.CreateParamsMandateData"
- ]
- """
- This hash contains details about the mandate to create. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/setup_intents/create#create_setup_intent-confirm).
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The Stripe account ID created for this SetupIntent.
- """
- payment_method: NotRequired[str]
- """
- ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.
- """
- payment_method_configuration: NotRequired[str]
- """
- The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this SetupIntent.
- """
- payment_method_data: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodData"
- ]
- """
- When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
- value in the SetupIntent.
- """
- payment_method_options: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptions"
- ]
- """
- Payment method-specific configuration for this SetupIntent.
- """
- payment_method_types: NotRequired[List[str]]
- """
- The list of payment method types (for example, card) that this SetupIntent can use. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
- """
- return_url: NotRequired[str]
- """
- The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. To redirect to a mobile application, you can alternatively supply an application URI scheme. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/setup_intents/create#create_setup_intent-confirm).
- """
- single_use: NotRequired["SetupIntentService.CreateParamsSingleUse"]
- """
- If you populate this hash, this SetupIntent generates a `single_use` mandate after successful completion.
-
- Single-use mandates are only valid for the following payment methods: `acss_debit`, `alipay`, `au_becs_debit`, `bacs_debit`, `bancontact`, `boleto`, `ideal`, `link`, `sepa_debit`, and `us_bank_account`.
- """
- usage: NotRequired[Literal["off_session", "on_session"]]
- """
- Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`.
- """
- use_stripe_sdk: NotRequired[bool]
- """
- Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
- """
-
- class CreateParamsAutomaticPaymentMethods(TypedDict):
- allow_redirects: NotRequired[Literal["always", "never"]]
- """
- Controls whether this SetupIntent will accept redirect-based payment methods.
-
- Redirect-based payment methods may require your customer to be redirected to a payment method's app or site for authentication or additional steps. To [confirm](https://stripe.com/docs/api/setup_intents/confirm) this SetupIntent, you may be required to provide a `return_url` to redirect customers back to your site after they authenticate or complete the setup.
- """
- enabled: bool
- """
- Whether this feature is enabled.
- """
-
- class CreateParamsMandateData(TypedDict):
- customer_acceptance: (
- "SetupIntentService.CreateParamsMandateDataCustomerAcceptance"
- )
- """
- This hash contains details about the customer acceptance of the Mandate.
- """
-
- class CreateParamsMandateDataCustomerAcceptance(TypedDict):
- accepted_at: NotRequired[int]
- """
- The time at which the customer accepted the Mandate.
- """
- offline: NotRequired[
- "SetupIntentService.CreateParamsMandateDataCustomerAcceptanceOffline"
- ]
- """
- If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
- """
- online: NotRequired[
- "SetupIntentService.CreateParamsMandateDataCustomerAcceptanceOnline"
- ]
- """
- If this is a Mandate accepted online, this hash contains details about the online acceptance.
- """
- type: Literal["offline", "online"]
- """
- The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
- """
-
- class CreateParamsMandateDataCustomerAcceptanceOffline(TypedDict):
- pass
-
- class CreateParamsMandateDataCustomerAcceptanceOnline(TypedDict):
- ip_address: str
- """
- The IP address from which the Mandate was accepted by the customer.
- """
- user_agent: str
- """
- The user agent of the browser from which the Mandate was accepted by the customer.
- """
-
- class CreateParamsPaymentMethodData(TypedDict):
- acss_debit: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataAcssDebit"
- ]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataAlipay"
- ]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataAlma"
- ]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataAmazonPay"
- ]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataAuBecsDebit"
- ]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataBlik"
- ]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- cashapp: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataCrypto"
- ]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer_balance: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired["SetupIntentService.CreateParamsPaymentMethodDataEps"]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- fpx: NotRequired["SetupIntentService.CreateParamsPaymentMethodDataFpx"]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataIdeal"
- ]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataLink"
- ]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataMbWay"
- ]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataMobilepay"
- ]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataNzBankAccount"
- ]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataOxxo"
- ]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired["SetupIntentService.CreateParamsPaymentMethodDataP24"]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataPayco"
- ]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- paynow: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired["SetupIntentService.CreateParamsPaymentMethodDataPix"]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataRadarOptions"
- ]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataSwish"
- ]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataTwint"
- ]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataWechatPay"
- ]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired["SetupIntentService.CreateParamsPaymentMethodDataZip"]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class CreateParamsPaymentMethodDataAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class CreateParamsPaymentMethodDataAffirm(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAfterpayClearpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAlipay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAlma(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAmazonPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class CreateParamsPaymentMethodDataBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class CreateParamsPaymentMethodDataBancontact(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBillie(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|SetupIntentService.CreateParamsPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class CreateParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsPaymentMethodDataBlik(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class CreateParamsPaymentMethodDataCashapp(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataCrypto(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataCustomerBalance(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataGiropay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataGrabpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class CreateParamsPaymentMethodDataInteracPresent(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKakaoPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKlarna(TypedDict):
- dob: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodDataKlarnaDob"
- ]
- """
- Customer's date of birth
- """
-
- class CreateParamsPaymentMethodDataKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsPaymentMethodDataKonbini(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKrCard(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataLink(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMbWay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMobilepay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMultibanco(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class CreateParamsPaymentMethodDataNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class CreateParamsPaymentMethodDataOxxo(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataPayByBank(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPayco(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPaynow(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPaypal(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPix(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPromptpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class CreateParamsPaymentMethodDataRevolutPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSamsungPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSatispay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class CreateParamsPaymentMethodDataSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class CreateParamsPaymentMethodDataSwish(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataTwint(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class CreateParamsPaymentMethodDataWechatPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataZip(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsAcssDebit"
- ]
- """
- If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
- """
- amazon_pay: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsAmazonPay"
- ]
- """
- If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
- """
- bacs_debit: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsBacsDebit"
- ]
- """
- If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
- """
- card: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsCard"
- ]
- """
- Configuration for any card setup attempted on this SetupIntent.
- """
- card_present: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsCardPresent"
- ]
- """
- If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
- """
- klarna: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method options.
- """
- link: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsLink"
- ]
- """
- If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
- """
- paypal: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
- """
- sepa_debit: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsSepaDebit"
- ]
- """
- If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
- """
- us_bank_account: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
- """
-
- class CreateParamsPaymentMethodOptionsAcssDebit(TypedDict):
- currency: NotRequired[Literal["cad", "usd"]]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- mandate_options: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class CreateParamsPaymentMethodOptionsAcssDebitMandateOptions(TypedDict):
- custom_mandate_url: NotRequired["Literal['']|str"]
- """
- A URL for custom mandate text to render during confirmation step.
- The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
- or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
- """
- default_for: NotRequired[List[Literal["invoice", "subscription"]]]
- """
- List of Stripe products where this mandate can be selected automatically.
- """
- interval_description: NotRequired[str]
- """
- Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
- """
- payment_schedule: NotRequired[
- Literal["combined", "interval", "sporadic"]
- ]
- """
- Payment schedule for the mandate.
- """
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class CreateParamsPaymentMethodOptionsAmazonPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptionsBacsDebit(TypedDict):
- mandate_options: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsBacsDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
-
- class CreateParamsPaymentMethodOptionsBacsDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
- """
-
- class CreateParamsPaymentMethodOptionsCard(TypedDict):
- mandate_options: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- moto: NotRequired[bool]
- """
- When specified, this parameter signals that a card has been collected
- as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
- parameter can only be provided during confirmation.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
- three_d_secure: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsCardThreeDSecure"
- ]
- """
- If 3D Secure authentication was performed with a third-party provider,
- the authentication details to use for this setup.
- """
-
- class CreateParamsPaymentMethodOptionsCardMandateOptions(TypedDict):
- amount: int
- """
- Amount to be charged for future payments.
- """
- amount_type: Literal["fixed", "maximum"]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- currency: str
- """
- Currency in which future payments will be charged. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
- end_date: NotRequired[int]
- """
- End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
- """
- interval: Literal["day", "month", "sporadic", "week", "year"]
- """
- Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
- """
- reference: str
- """
- Unique identifier for the mandate or subscription.
- """
- start_date: int
- """
- Start date of the mandate or subscription. Start date should not be lesser than yesterday.
- """
- supported_types: NotRequired[List[Literal["india"]]]
- """
- Specifies the type of mandates supported. Possible values are `india`.
- """
-
- class CreateParamsPaymentMethodOptionsCardPresent(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
- ares_trans_status: NotRequired[
- Literal["A", "C", "I", "N", "R", "U", "Y"]
- ]
- """
- The `transStatus` returned from the card Issuer's ACS in the ARes.
- """
- cryptogram: NotRequired[str]
- """
- The cryptogram, also known as the "authentication value" (AAV, CAVV or
- AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
- (Most 3D Secure providers will return the base64-encoded version, which
- is what you should specify here.)
- """
- electronic_commerce_indicator: NotRequired[
- Literal["01", "02", "05", "06", "07"]
- ]
- """
- The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
- provider and indicates what degree of authentication was performed.
- """
- network_options: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
- ]
- """
- Network specific 3DS fields. Network specific arguments require an
- explicit card brand choice. The parameter `payment_method_options.card.network``
- must be populated accordingly
- """
- requestor_challenge_indicator: NotRequired[str]
- """
- The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
- AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
- """
- transaction_id: NotRequired[str]
- """
- For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
- Transaction ID (dsTransID).
- """
- version: NotRequired[Literal["1.0.2", "2.1.0", "2.2.0"]]
- """
- The version of 3D Secure that was performed.
- """
-
- class CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
- TypedDict,
- ):
- cartes_bancaires: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
- ]
- """
- Cartes Bancaires-specific 3DS fields.
- """
-
- class CreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
- TypedDict,
- ):
- cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
- """
- The cryptogram calculation algorithm used by the card Issuer's ACS
- to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
- messageExtension: CB-AVALGO
- """
- cb_exemption: NotRequired[str]
- """
- The exemption indicator returned from Cartes Bancaires in the ARes.
- message extension: CB-EXEMPTION; string (4 characters)
- This is a 3 byte bitmap (low significant byte first and most significant
- bit first) that has been Base64 encoded
- """
- cb_score: NotRequired[int]
- """
- The risk score returned from Cartes Bancaires in the ARes.
- message extension: CB-SCORE; numeric value 0-99
- """
-
- class CreateParamsPaymentMethodOptionsKlarna(TypedDict):
- currency: NotRequired[str]
- """
- The currency of the SetupIntent. Three letter ISO currency code.
- """
- on_demand: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsKlarnaOnDemand"
- ]
- """
- On-demand details if setting up a payment method for on-demand payments.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-CH",
- "de-DE",
- "el-GR",
- "en-AT",
- "en-AU",
- "en-BE",
- "en-CA",
- "en-CH",
- "en-CZ",
- "en-DE",
- "en-DK",
- "en-ES",
- "en-FI",
- "en-FR",
- "en-GB",
- "en-GR",
- "en-IE",
- "en-IT",
- "en-NL",
- "en-NO",
- "en-NZ",
- "en-PL",
- "en-PT",
- "en-RO",
- "en-SE",
- "en-US",
- "es-ES",
- "es-US",
- "fi-FI",
- "fr-BE",
- "fr-CA",
- "fr-CH",
- "fr-FR",
- "it-CH",
- "it-IT",
- "nb-NO",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "ro-RO",
- "sv-FI",
- "sv-SE",
- ]
- ]
- """
- Preferred language of the Klarna authorization page that the customer is redirected to
- """
- subscriptions: NotRequired[
- "Literal['']|List[SetupIntentService.CreateParamsPaymentMethodOptionsKlarnaSubscription]"
- ]
- """
- Subscription details if setting up or charging a subscription
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
- average_amount: NotRequired[int]
- """
- Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- maximum_amount: NotRequired[int]
- """
- The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- minimum_amount: NotRequired[int]
- """
- The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
- """
- Interval at which the customer is making purchases
- """
- purchase_interval_count: NotRequired[int]
- """
- The number of `purchase_interval` between charges
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Unit of time between subscription charges.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
- """
- name: NotRequired[str]
- """
- Name for subscription.
- """
- next_billing: "SetupIntentService.CreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
- """
- Describes the upcoming charge for this subscription.
- """
- reference: str
- """
- A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
- TypedDict,
- ):
- amount: int
- """
- The amount of the next charge for the subscription.
- """
- date: str
- """
- The date of the next charge for the subscription in YYYY-MM-DD format.
- """
-
- class CreateParamsPaymentMethodOptionsLink(TypedDict):
- persistent_token: NotRequired[str]
- """
- [Deprecated] This is a legacy parameter that no longer has any function.
- """
-
- class CreateParamsPaymentMethodOptionsPaypal(TypedDict):
- billing_agreement_id: NotRequired[str]
- """
- The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
- """
-
- class CreateParamsPaymentMethodOptionsSepaDebit(TypedDict):
- mandate_options: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsSepaDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
-
- class CreateParamsPaymentMethodOptionsSepaDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccount(TypedDict):
- financial_connections: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- mandate_options: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsUsBankAccountMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- networks: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsUsBankAccountNetworks"
- ]
- """
- Additional fields for network related functions
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "SetupIntentService.CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
- return_url: NotRequired[str]
- """
- For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountMandateOptions(
- TypedDict,
- ):
- collection_method: NotRequired["Literal['']|Literal['paper']"]
- """
- The method used to collect offline mandate customer acceptance.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountNetworks(TypedDict):
- requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
- """
- Triggers validations to run across the selected networks
- """
-
- class CreateParamsSingleUse(TypedDict):
- amount: int
- """
- Amount the customer is granting permission to collect later. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class ListParams(TypedDict):
- attach_to_self: NotRequired[bool]
- """
- If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
-
- It can only be used for this Stripe Account's own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
- """
- created: NotRequired["SetupIntentService.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
- """
- customer: NotRequired[str]
- """
- Only return SetupIntents for the customer specified by this customer ID.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payment_method: NotRequired[str]
- """
- Only return SetupIntents that associate with the specified payment method.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- client_secret: NotRequired[str]
- """
- The client secret of the SetupIntent. We require this string if you use a publishable key to retrieve the SetupIntent.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- attach_to_self: NotRequired[bool]
- """
- If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
-
- It can only be used for this Stripe Account's own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
- """
- customer: NotRequired[str]
- """
- ID of the Customer this SetupIntent belongs to, if one exists.
-
- If present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- flow_directions: NotRequired[List[Literal["inbound", "outbound"]]]
- """
- Indicates the directions of money movement for which this payment method is intended to be used.
-
- Include `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- payment_method: NotRequired[str]
- """
- ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent. To unset this field to null, pass in an empty string.
- """
- payment_method_configuration: NotRequired[str]
- """
- The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this SetupIntent.
- """
- payment_method_data: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodData"
- ]
- """
- When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
- value in the SetupIntent.
- """
- payment_method_options: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptions"
- ]
- """
- Payment method-specific configuration for this SetupIntent.
- """
- payment_method_types: NotRequired[List[str]]
- """
- The list of payment method types (for example, card) that this SetupIntent can set up. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
- """
-
- class UpdateParamsPaymentMethodData(TypedDict):
- acss_debit: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataAcssDebit"
- ]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataAlipay"
- ]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataAlma"
- ]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataAmazonPay"
- ]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataAuBecsDebit"
- ]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataBlik"
- ]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- cashapp: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataCrypto"
- ]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer_balance: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired["SetupIntentService.UpdateParamsPaymentMethodDataEps"]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- fpx: NotRequired["SetupIntentService.UpdateParamsPaymentMethodDataFpx"]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataIdeal"
- ]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataLink"
- ]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataMbWay"
- ]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataMobilepay"
- ]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataNzBankAccount"
- ]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataOxxo"
- ]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired["SetupIntentService.UpdateParamsPaymentMethodDataP24"]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataPayco"
- ]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- paynow: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired["SetupIntentService.UpdateParamsPaymentMethodDataPix"]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataRadarOptions"
- ]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataSwish"
- ]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataTwint"
- ]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataWechatPay"
- ]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired["SetupIntentService.UpdateParamsPaymentMethodDataZip"]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class UpdateParamsPaymentMethodDataAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class UpdateParamsPaymentMethodDataAffirm(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataAfterpayClearpay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataAlipay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataAlma(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataAmazonPay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class UpdateParamsPaymentMethodDataBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class UpdateParamsPaymentMethodDataBancontact(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataBillie(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|SetupIntentService.UpdateParamsPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class UpdateParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsPaymentMethodDataBlik(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class UpdateParamsPaymentMethodDataCashapp(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataCrypto(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataCustomerBalance(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class UpdateParamsPaymentMethodDataFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class UpdateParamsPaymentMethodDataGiropay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataGrabpay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class UpdateParamsPaymentMethodDataInteracPresent(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataKakaoPay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataKlarna(TypedDict):
- dob: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodDataKlarnaDob"
- ]
- """
- Customer's date of birth
- """
-
- class UpdateParamsPaymentMethodDataKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class UpdateParamsPaymentMethodDataKonbini(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataKrCard(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataLink(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataMbWay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataMobilepay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataMultibanco(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class UpdateParamsPaymentMethodDataNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class UpdateParamsPaymentMethodDataOxxo(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class UpdateParamsPaymentMethodDataPayByBank(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataPayco(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataPaynow(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataPaypal(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataPix(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataPromptpay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class UpdateParamsPaymentMethodDataRevolutPay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataSamsungPay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataSatispay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class UpdateParamsPaymentMethodDataSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class UpdateParamsPaymentMethodDataSwish(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataTwint(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class UpdateParamsPaymentMethodDataWechatPay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodDataZip(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsAcssDebit"
- ]
- """
- If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
- """
- amazon_pay: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsAmazonPay"
- ]
- """
- If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
- """
- bacs_debit: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsBacsDebit"
- ]
- """
- If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
- """
- card: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsCard"
- ]
- """
- Configuration for any card setup attempted on this SetupIntent.
- """
- card_present: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsCardPresent"
- ]
- """
- If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
- """
- klarna: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method options.
- """
- link: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsLink"
- ]
- """
- If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
- """
- paypal: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
- """
- sepa_debit: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsSepaDebit"
- ]
- """
- If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
- """
- us_bank_account: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsUsBankAccount"
- ]
- """
- If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
- """
-
- class UpdateParamsPaymentMethodOptionsAcssDebit(TypedDict):
- currency: NotRequired[Literal["cad", "usd"]]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- mandate_options: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class UpdateParamsPaymentMethodOptionsAcssDebitMandateOptions(TypedDict):
- custom_mandate_url: NotRequired["Literal['']|str"]
- """
- A URL for custom mandate text to render during confirmation step.
- The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
- or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
- """
- default_for: NotRequired[List[Literal["invoice", "subscription"]]]
- """
- List of Stripe products where this mandate can be selected automatically.
- """
- interval_description: NotRequired[str]
- """
- Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
- """
- payment_schedule: NotRequired[
- Literal["combined", "interval", "sporadic"]
- ]
- """
- Payment schedule for the mandate.
- """
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class UpdateParamsPaymentMethodOptionsAmazonPay(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodOptionsBacsDebit(TypedDict):
- mandate_options: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsBacsDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
-
- class UpdateParamsPaymentMethodOptionsBacsDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
- """
-
- class UpdateParamsPaymentMethodOptionsCard(TypedDict):
- mandate_options: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- moto: NotRequired[bool]
- """
- When specified, this parameter signals that a card has been collected
- as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
- parameter can only be provided during confirmation.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
- three_d_secure: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsCardThreeDSecure"
- ]
- """
- If 3D Secure authentication was performed with a third-party provider,
- the authentication details to use for this setup.
- """
-
- class UpdateParamsPaymentMethodOptionsCardMandateOptions(TypedDict):
- amount: int
- """
- Amount to be charged for future payments.
- """
- amount_type: Literal["fixed", "maximum"]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- currency: str
- """
- Currency in which future payments will be charged. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
- end_date: NotRequired[int]
- """
- End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
- """
- interval: Literal["day", "month", "sporadic", "week", "year"]
- """
- Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
- """
- reference: str
- """
- Unique identifier for the mandate or subscription.
- """
- start_date: int
- """
- Start date of the mandate or subscription. Start date should not be lesser than yesterday.
- """
- supported_types: NotRequired[List[Literal["india"]]]
- """
- Specifies the type of mandates supported. Possible values are `india`.
- """
-
- class UpdateParamsPaymentMethodOptionsCardPresent(TypedDict):
- pass
-
- class UpdateParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
- ares_trans_status: NotRequired[
- Literal["A", "C", "I", "N", "R", "U", "Y"]
- ]
- """
- The `transStatus` returned from the card Issuer's ACS in the ARes.
- """
- cryptogram: NotRequired[str]
- """
- The cryptogram, also known as the "authentication value" (AAV, CAVV or
- AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
- (Most 3D Secure providers will return the base64-encoded version, which
- is what you should specify here.)
- """
- electronic_commerce_indicator: NotRequired[
- Literal["01", "02", "05", "06", "07"]
- ]
- """
- The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
- provider and indicates what degree of authentication was performed.
- """
- network_options: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
- ]
- """
- Network specific 3DS fields. Network specific arguments require an
- explicit card brand choice. The parameter `payment_method_options.card.network``
- must be populated accordingly
- """
- requestor_challenge_indicator: NotRequired[str]
- """
- The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
- AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
- """
- transaction_id: NotRequired[str]
- """
- For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
- Transaction ID (dsTransID).
- """
- version: NotRequired[Literal["1.0.2", "2.1.0", "2.2.0"]]
- """
- The version of 3D Secure that was performed.
- """
-
- class UpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
- TypedDict,
- ):
- cartes_bancaires: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
- ]
- """
- Cartes Bancaires-specific 3DS fields.
- """
-
- class UpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
- TypedDict,
- ):
- cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
- """
- The cryptogram calculation algorithm used by the card Issuer's ACS
- to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
- messageExtension: CB-AVALGO
- """
- cb_exemption: NotRequired[str]
- """
- The exemption indicator returned from Cartes Bancaires in the ARes.
- message extension: CB-EXEMPTION; string (4 characters)
- This is a 3 byte bitmap (low significant byte first and most significant
- bit first) that has been Base64 encoded
- """
- cb_score: NotRequired[int]
- """
- The risk score returned from Cartes Bancaires in the ARes.
- message extension: CB-SCORE; numeric value 0-99
- """
-
- class UpdateParamsPaymentMethodOptionsKlarna(TypedDict):
- currency: NotRequired[str]
- """
- The currency of the SetupIntent. Three letter ISO currency code.
- """
- on_demand: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsKlarnaOnDemand"
- ]
- """
- On-demand details if setting up a payment method for on-demand payments.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-CH",
- "de-DE",
- "el-GR",
- "en-AT",
- "en-AU",
- "en-BE",
- "en-CA",
- "en-CH",
- "en-CZ",
- "en-DE",
- "en-DK",
- "en-ES",
- "en-FI",
- "en-FR",
- "en-GB",
- "en-GR",
- "en-IE",
- "en-IT",
- "en-NL",
- "en-NO",
- "en-NZ",
- "en-PL",
- "en-PT",
- "en-RO",
- "en-SE",
- "en-US",
- "es-ES",
- "es-US",
- "fi-FI",
- "fr-BE",
- "fr-CA",
- "fr-CH",
- "fr-FR",
- "it-CH",
- "it-IT",
- "nb-NO",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "ro-RO",
- "sv-FI",
- "sv-SE",
- ]
- ]
- """
- Preferred language of the Klarna authorization page that the customer is redirected to
- """
- subscriptions: NotRequired[
- "Literal['']|List[SetupIntentService.UpdateParamsPaymentMethodOptionsKlarnaSubscription]"
- ]
- """
- Subscription details if setting up or charging a subscription
- """
-
- class UpdateParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
- average_amount: NotRequired[int]
- """
- Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- maximum_amount: NotRequired[int]
- """
- The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- minimum_amount: NotRequired[int]
- """
- The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
- """
- purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
- """
- Interval at which the customer is making purchases
- """
- purchase_interval_count: NotRequired[int]
- """
- The number of `purchase_interval` between charges
- """
-
- class UpdateParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Unit of time between subscription charges.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
- """
- name: NotRequired[str]
- """
- Name for subscription.
- """
- next_billing: "SetupIntentService.UpdateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
- """
- Describes the upcoming charge for this subscription.
- """
- reference: str
- """
- A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
- """
-
- class UpdateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
- TypedDict,
- ):
- amount: int
- """
- The amount of the next charge for the subscription.
- """
- date: str
- """
- The date of the next charge for the subscription in YYYY-MM-DD format.
- """
-
- class UpdateParamsPaymentMethodOptionsLink(TypedDict):
- persistent_token: NotRequired[str]
- """
- [Deprecated] This is a legacy parameter that no longer has any function.
- """
-
- class UpdateParamsPaymentMethodOptionsPaypal(TypedDict):
- billing_agreement_id: NotRequired[str]
- """
- The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
- """
-
- class UpdateParamsPaymentMethodOptionsSepaDebit(TypedDict):
- mandate_options: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsSepaDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
-
- class UpdateParamsPaymentMethodOptionsSepaDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
- """
-
- class UpdateParamsPaymentMethodOptionsUsBankAccount(TypedDict):
- financial_connections: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- mandate_options: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsUsBankAccountMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- networks: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsUsBankAccountNetworks"
- ]
- """
- Additional fields for network related functions
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Bank account verification method.
- """
-
- class UpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "SetupIntentService.UpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
- return_url: NotRequired[str]
- """
- For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
- """
-
- class UpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class UpdateParamsPaymentMethodOptionsUsBankAccountMandateOptions(
- TypedDict,
- ):
- collection_method: NotRequired["Literal['']|Literal['paper']"]
- """
- The method used to collect offline mandate customer acceptance.
- """
-
- class UpdateParamsPaymentMethodOptionsUsBankAccountNetworks(TypedDict):
- requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
- """
- Triggers validations to run across the selected networks
- """
-
- class VerifyMicrodepositsParams(TypedDict):
- amounts: NotRequired[List[int]]
- """
- Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.
- """
- descriptor_code: NotRequired[str]
- """
- A six-character code starting with SM present in the microdeposit sent to the bank account.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
def list(
self,
- params: Optional["SetupIntentService.ListParams"] = None,
+ params: Optional["SetupIntentListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[SetupIntent]:
"""
@@ -4345,7 +52,7 @@ def list(
async def list_async(
self,
- params: Optional["SetupIntentService.ListParams"] = None,
+ params: Optional["SetupIntentListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[SetupIntent]:
"""
@@ -4364,7 +71,7 @@ async def list_async(
def create(
self,
- params: Optional["SetupIntentService.CreateParams"] = None,
+ params: Optional["SetupIntentCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> SetupIntent:
"""
@@ -4386,7 +93,7 @@ def create(
async def create_async(
self,
- params: Optional["SetupIntentService.CreateParams"] = None,
+ params: Optional["SetupIntentCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> SetupIntent:
"""
@@ -4409,7 +116,7 @@ async def create_async(
def retrieve(
self,
intent: str,
- params: Optional["SetupIntentService.RetrieveParams"] = None,
+ params: Optional["SetupIntentRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> SetupIntent:
"""
@@ -4435,7 +142,7 @@ def retrieve(
async def retrieve_async(
self,
intent: str,
- params: Optional["SetupIntentService.RetrieveParams"] = None,
+ params: Optional["SetupIntentRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> SetupIntent:
"""
@@ -4461,7 +168,7 @@ async def retrieve_async(
def update(
self,
intent: str,
- params: Optional["SetupIntentService.UpdateParams"] = None,
+ params: Optional["SetupIntentUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> SetupIntent:
"""
@@ -4483,7 +190,7 @@ def update(
async def update_async(
self,
intent: str,
- params: Optional["SetupIntentService.UpdateParams"] = None,
+ params: Optional["SetupIntentUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> SetupIntent:
"""
@@ -4505,7 +212,7 @@ async def update_async(
def cancel(
self,
intent: str,
- params: Optional["SetupIntentService.CancelParams"] = None,
+ params: Optional["SetupIntentCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> SetupIntent:
"""
@@ -4529,7 +236,7 @@ def cancel(
async def cancel_async(
self,
intent: str,
- params: Optional["SetupIntentService.CancelParams"] = None,
+ params: Optional["SetupIntentCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> SetupIntent:
"""
@@ -4553,7 +260,7 @@ async def cancel_async(
def confirm(
self,
intent: str,
- params: Optional["SetupIntentService.ConfirmParams"] = None,
+ params: Optional["SetupIntentConfirmParams"] = None,
options: Optional[RequestOptions] = None,
) -> SetupIntent:
"""
@@ -4588,7 +295,7 @@ def confirm(
async def confirm_async(
self,
intent: str,
- params: Optional["SetupIntentService.ConfirmParams"] = None,
+ params: Optional["SetupIntentConfirmParams"] = None,
options: Optional[RequestOptions] = None,
) -> SetupIntent:
"""
@@ -4623,9 +330,7 @@ async def confirm_async(
def verify_microdeposits(
self,
intent: str,
- params: Optional[
- "SetupIntentService.VerifyMicrodepositsParams"
- ] = None,
+ params: Optional["SetupIntentVerifyMicrodepositsParams"] = None,
options: Optional[RequestOptions] = None,
) -> SetupIntent:
"""
@@ -4647,9 +352,7 @@ def verify_microdeposits(
async def verify_microdeposits_async(
self,
intent: str,
- params: Optional[
- "SetupIntentService.VerifyMicrodepositsParams"
- ] = None,
+ params: Optional["SetupIntentVerifyMicrodepositsParams"] = None,
options: Optional[RequestOptions] = None,
) -> SetupIntent:
"""
diff --git a/stripe/_shipping_rate.py b/stripe/_shipping_rate.py
index 4373b7f00..1389c7506 100644
--- a/stripe/_shipping_rate.py
+++ b/stripe/_shipping_rate.py
@@ -4,21 +4,24 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import sanitize_id
-from typing import ClassVar, Dict, List, Optional, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Dict, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._tax_code import TaxCode
+ from stripe.params._shipping_rate_create_params import (
+ ShippingRateCreateParams,
+ )
+ from stripe.params._shipping_rate_list_params import ShippingRateListParams
+ from stripe.params._shipping_rate_modify_params import (
+ ShippingRateModifyParams,
+ )
+ from stripe.params._shipping_rate_retrieve_params import (
+ ShippingRateRetrieveParams,
+ )
class ShippingRate(
@@ -90,204 +93,6 @@ class CurrencyOptions(StripeObject):
_inner_class_types = {"currency_options": CurrencyOptions}
_inner_class_dicts = ["currency_options"]
- class CreateParams(RequestOptions):
- delivery_estimate: NotRequired[
- "ShippingRate.CreateParamsDeliveryEstimate"
- ]
- """
- The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- display_name: str
- """
- The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- fixed_amount: NotRequired["ShippingRate.CreateParamsFixedAmount"]
- """
- Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
- """
- type: NotRequired[Literal["fixed_amount"]]
- """
- The type of calculation to use on the shipping rate.
- """
-
- class CreateParamsDeliveryEstimate(TypedDict):
- maximum: NotRequired[
- "ShippingRate.CreateParamsDeliveryEstimateMaximum"
- ]
- """
- The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
- """
- minimum: NotRequired[
- "ShippingRate.CreateParamsDeliveryEstimateMinimum"
- ]
- """
- The lower bound of the estimated range. If empty, represents no lower bound.
- """
-
- class CreateParamsDeliveryEstimateMaximum(TypedDict):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class CreateParamsDeliveryEstimateMinimum(TypedDict):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class CreateParamsFixedAmount(TypedDict):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- currency_options: NotRequired[
- Dict[str, "ShippingRate.CreateParamsFixedAmountCurrencyOptions"]
- ]
- """
- Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class CreateParamsFixedAmountCurrencyOptions(TypedDict):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
-
- class ListParams(RequestOptions):
- active: NotRequired[bool]
- """
- Only return shipping rates that are active or inactive.
- """
- created: NotRequired["ShippingRate.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
- """
- currency: NotRequired[str]
- """
- Only return shipping rates for the given currency.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- active: NotRequired[bool]
- """
- Whether the shipping rate can be used for new purchases. Defaults to `true`.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- fixed_amount: NotRequired["ShippingRate.ModifyParamsFixedAmount"]
- """
- Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
-
- class ModifyParamsFixedAmount(TypedDict):
- currency_options: NotRequired[
- Dict[str, "ShippingRate.ModifyParamsFixedAmountCurrencyOptions"]
- ]
- """
- Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class ModifyParamsFixedAmountCurrencyOptions(TypedDict):
- amount: NotRequired[int]
- """
- A non-negative integer in cents representing how much to charge.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
active: bool
"""
Whether the shipping rate can be used for new purchases. Defaults to `true`.
@@ -336,7 +141,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["ShippingRate.CreateParams"]
+ cls, **params: Unpack["ShippingRateCreateParams"]
) -> "ShippingRate":
"""
Creates a new shipping rate object.
@@ -352,7 +157,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["ShippingRate.CreateParams"]
+ cls, **params: Unpack["ShippingRateCreateParams"]
) -> "ShippingRate":
"""
Creates a new shipping rate object.
@@ -368,7 +173,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["ShippingRate.ListParams"]
+ cls, **params: Unpack["ShippingRateListParams"]
) -> ListObject["ShippingRate"]:
"""
Returns a list of your shipping rates.
@@ -388,7 +193,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["ShippingRate.ListParams"]
+ cls, **params: Unpack["ShippingRateListParams"]
) -> ListObject["ShippingRate"]:
"""
Returns a list of your shipping rates.
@@ -408,7 +213,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["ShippingRate.ModifyParams"]
+ cls, id: str, **params: Unpack["ShippingRateModifyParams"]
) -> "ShippingRate":
"""
Updates an existing shipping rate object.
@@ -425,7 +230,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["ShippingRate.ModifyParams"]
+ cls, id: str, **params: Unpack["ShippingRateModifyParams"]
) -> "ShippingRate":
"""
Updates an existing shipping rate object.
@@ -442,7 +247,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["ShippingRate.RetrieveParams"]
+ cls, id: str, **params: Unpack["ShippingRateRetrieveParams"]
) -> "ShippingRate":
"""
Returns the shipping rate object with the given ID.
@@ -453,7 +258,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["ShippingRate.RetrieveParams"]
+ cls, id: str, **params: Unpack["ShippingRateRetrieveParams"]
) -> "ShippingRate":
"""
Returns the shipping rate object with the given ID.
diff --git a/stripe/_shipping_rate_service.py b/stripe/_shipping_rate_service.py
index 5fc70569e..2cd493c1b 100644
--- a/stripe/_shipping_rate_service.py
+++ b/stripe/_shipping_rate_service.py
@@ -5,222 +5,26 @@
from stripe._shipping_rate import ShippingRate
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._shipping_rate_create_params import (
+ ShippingRateCreateParams,
+ )
+ from stripe.params._shipping_rate_list_params import ShippingRateListParams
+ from stripe.params._shipping_rate_retrieve_params import (
+ ShippingRateRetrieveParams,
+ )
+ from stripe.params._shipping_rate_update_params import (
+ ShippingRateUpdateParams,
+ )
class ShippingRateService(StripeService):
- class CreateParams(TypedDict):
- delivery_estimate: NotRequired[
- "ShippingRateService.CreateParamsDeliveryEstimate"
- ]
- """
- The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- display_name: str
- """
- The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- fixed_amount: NotRequired[
- "ShippingRateService.CreateParamsFixedAmount"
- ]
- """
- Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
- """
- type: NotRequired[Literal["fixed_amount"]]
- """
- The type of calculation to use on the shipping rate.
- """
-
- class CreateParamsDeliveryEstimate(TypedDict):
- maximum: NotRequired[
- "ShippingRateService.CreateParamsDeliveryEstimateMaximum"
- ]
- """
- The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
- """
- minimum: NotRequired[
- "ShippingRateService.CreateParamsDeliveryEstimateMinimum"
- ]
- """
- The lower bound of the estimated range. If empty, represents no lower bound.
- """
-
- class CreateParamsDeliveryEstimateMaximum(TypedDict):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class CreateParamsDeliveryEstimateMinimum(TypedDict):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class CreateParamsFixedAmount(TypedDict):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- currency_options: NotRequired[
- Dict[
- str,
- "ShippingRateService.CreateParamsFixedAmountCurrencyOptions",
- ]
- ]
- """
- Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class CreateParamsFixedAmountCurrencyOptions(TypedDict):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
-
- class ListParams(TypedDict):
- active: NotRequired[bool]
- """
- Only return shipping rates that are active or inactive.
- """
- created: NotRequired["ShippingRateService.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
- """
- currency: NotRequired[str]
- """
- Only return shipping rates for the given currency.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- active: NotRequired[bool]
- """
- Whether the shipping rate can be used for new purchases. Defaults to `true`.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- fixed_amount: NotRequired[
- "ShippingRateService.UpdateParamsFixedAmount"
- ]
- """
- Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
-
- class UpdateParamsFixedAmount(TypedDict):
- currency_options: NotRequired[
- Dict[
- str,
- "ShippingRateService.UpdateParamsFixedAmountCurrencyOptions",
- ]
- ]
- """
- Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class UpdateParamsFixedAmountCurrencyOptions(TypedDict):
- amount: NotRequired[int]
- """
- A non-negative integer in cents representing how much to charge.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
-
def list(
self,
- params: Optional["ShippingRateService.ListParams"] = None,
+ params: Optional["ShippingRateListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ShippingRate]:
"""
@@ -239,7 +43,7 @@ def list(
async def list_async(
self,
- params: Optional["ShippingRateService.ListParams"] = None,
+ params: Optional["ShippingRateListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ShippingRate]:
"""
@@ -258,7 +62,7 @@ async def list_async(
def create(
self,
- params: "ShippingRateService.CreateParams",
+ params: "ShippingRateCreateParams",
options: Optional[RequestOptions] = None,
) -> ShippingRate:
"""
@@ -277,7 +81,7 @@ def create(
async def create_async(
self,
- params: "ShippingRateService.CreateParams",
+ params: "ShippingRateCreateParams",
options: Optional[RequestOptions] = None,
) -> ShippingRate:
"""
@@ -297,7 +101,7 @@ async def create_async(
def retrieve(
self,
shipping_rate_token: str,
- params: Optional["ShippingRateService.RetrieveParams"] = None,
+ params: Optional["ShippingRateRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ShippingRate:
"""
@@ -319,7 +123,7 @@ def retrieve(
async def retrieve_async(
self,
shipping_rate_token: str,
- params: Optional["ShippingRateService.RetrieveParams"] = None,
+ params: Optional["ShippingRateRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ShippingRate:
"""
@@ -341,7 +145,7 @@ async def retrieve_async(
def update(
self,
shipping_rate_token: str,
- params: Optional["ShippingRateService.UpdateParams"] = None,
+ params: Optional["ShippingRateUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> ShippingRate:
"""
@@ -363,7 +167,7 @@ def update(
async def update_async(
self,
shipping_rate_token: str,
- params: Optional["ShippingRateService.UpdateParams"] = None,
+ params: Optional["ShippingRateUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> ShippingRate:
"""
diff --git a/stripe/_source.py b/stripe/_source.py
index 0c36e83e7..c7f66c53a 100644
--- a/stripe/_source.py
+++ b/stripe/_source.py
@@ -4,21 +4,21 @@
from stripe._customer import Customer
from stripe._error import InvalidRequestError
from stripe._list_object import ListObject
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._source_transaction import SourceTransaction
+ from stripe.params._source_create_params import SourceCreateParams
+ from stripe.params._source_list_source_transactions_params import (
+ SourceListSourceTransactionsParams,
+ )
+ from stripe.params._source_modify_params import SourceModifyParams
+ from stripe.params._source_retrieve_params import SourceRetrieveParams
+ from stripe.params._source_verify_params import SourceVerifyParams
class Source(CreateableAPIResource["Source"], UpdateableAPIResource["Source"]):
@@ -485,530 +485,6 @@ class Wechat(StripeObject):
qr_code_url: Optional[str]
statement_descriptor: Optional[str]
- class CreateParams(RequestOptions):
- amount: NotRequired[int]
- """
- Amount associated with the source. This is the amount for which the source will be chargeable once ready. Required for `single_use` sources. Not supported for `receiver` type sources, where charge amount may not be specified until funds land.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) associated with the source. This is the currency for which the source will be chargeable once ready.
- """
- customer: NotRequired[str]
- """
- The `Customer` to whom the original source is attached to. Must be set when the original source is not a `Source` (e.g., `Card`).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- flow: NotRequired[
- Literal["code_verification", "none", "receiver", "redirect"]
- ]
- """
- The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows.
- """
- mandate: NotRequired["Source.CreateParamsMandate"]
- """
- Information about a mandate possibility attached to a source object (generally for bank debits) as well as its acceptance status.
- """
- metadata: NotRequired[Dict[str, str]]
- original_source: NotRequired[str]
- """
- The source to share.
- """
- owner: NotRequired["Source.CreateParamsOwner"]
- """
- Information about the owner of the payment instrument that may be used or required by particular source types.
- """
- receiver: NotRequired["Source.CreateParamsReceiver"]
- """
- Optional parameters for the receiver flow. Can be set only if the source is a receiver (`flow` is `receiver`).
- """
- redirect: NotRequired["Source.CreateParamsRedirect"]
- """
- Parameters required for the redirect flow. Required if the source is authenticated by a redirect (`flow` is `redirect`).
- """
- source_order: NotRequired["Source.CreateParamsSourceOrder"]
- """
- Information about the items and shipping associated with the source. Required for transactional credit (for example Klarna) sources before you can charge it.
- """
- statement_descriptor: NotRequired[str]
- """
- An arbitrary string to be displayed on your customer's statement. As an example, if your website is `RunClub` and the item you're charging for is a race ticket, you may want to specify a `statement_descriptor` of `RunClub 5K race ticket.` While many payment types will display this information, some may not display it at all.
- """
- token: NotRequired[str]
- """
- An optional token used to create the source. When passed, token properties will override source parameters.
- """
- type: NotRequired[str]
- """
- The `type` of the source to create. Required unless `customer` and `original_source` are specified (see the [Cloning card Sources](https://stripe.com/docs/sources/connect#cloning-card-sources) guide)
- """
- usage: NotRequired[Literal["reusable", "single_use"]]
-
- class CreateParamsMandate(TypedDict):
- acceptance: NotRequired["Source.CreateParamsMandateAcceptance"]
- """
- The parameters required to notify Stripe of a mandate acceptance or refusal by the customer.
- """
- amount: NotRequired["Literal['']|int"]
- """
- The amount specified by the mandate. (Leave null for a mandate covering all amounts)
- """
- currency: NotRequired[str]
- """
- The currency specified by the mandate. (Must match `currency` of the source)
- """
- interval: NotRequired[Literal["one_time", "scheduled", "variable"]]
- """
- The interval of debits permitted by the mandate. Either `one_time` (just permitting a single debit), `scheduled` (with debits on an agreed schedule or for clearly-defined events), or `variable`(for debits with any frequency)
- """
- notification_method: NotRequired[
- Literal[
- "deprecated_none", "email", "manual", "none", "stripe_email"
- ]
- ]
- """
- The method Stripe should use to notify the customer of upcoming debit instructions and/or mandate confirmation as required by the underlying debit network. Either `email` (an email is sent directly to the customer), `manual` (a `source.mandate_notification` event is sent to your webhooks endpoint and you should handle the notification) or `none` (the underlying debit network does not require any notification).
- """
-
- class CreateParamsMandateAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
- """
- ip: NotRequired[str]
- """
- The IP address from which the mandate was accepted or refused by the customer.
- """
- offline: NotRequired["Source.CreateParamsMandateAcceptanceOffline"]
- """
- The parameters required to store a mandate accepted offline. Should only be set if `mandate[type]` is `offline`
- """
- online: NotRequired["Source.CreateParamsMandateAcceptanceOnline"]
- """
- The parameters required to store a mandate accepted online. Should only be set if `mandate[type]` is `online`
- """
- status: Literal["accepted", "pending", "refused", "revoked"]
- """
- The status of the mandate acceptance. Either `accepted` (the mandate was accepted) or `refused` (the mandate was refused).
- """
- type: NotRequired[Literal["offline", "online"]]
- """
- The type of acceptance information included with the mandate. Either `online` or `offline`
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the mandate was accepted or refused by the customer.
- """
-
- class CreateParamsMandateAcceptanceOffline(TypedDict):
- contact_email: str
- """
- An email to contact you with if a copy of the mandate is requested, required if `type` is `offline`.
- """
-
- class CreateParamsMandateAcceptanceOnline(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
- """
- ip: NotRequired[str]
- """
- The IP address from which the mandate was accepted or refused by the customer.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the mandate was accepted or refused by the customer.
- """
-
- class CreateParamsOwner(TypedDict):
- address: NotRequired["Source.CreateParamsOwnerAddress"]
- """
- Owner's address.
- """
- email: NotRequired[str]
- """
- Owner's email address.
- """
- name: NotRequired[str]
- """
- Owner's full name.
- """
- phone: NotRequired[str]
- """
- Owner's phone number.
- """
-
- class CreateParamsOwnerAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsReceiver(TypedDict):
- refund_attributes_method: NotRequired[
- Literal["email", "manual", "none"]
- ]
- """
- The method Stripe should use to request information needed to process a refund or mispayment. Either `email` (an email is sent directly to the customer) or `manual` (a `source.refund_attributes_required` event is sent to your webhooks endpoint). Refer to each payment method's documentation to learn which refund attributes may be required.
- """
-
- class CreateParamsRedirect(TypedDict):
- return_url: str
- """
- The URL you provide to redirect the customer back to you after they authenticated their payment. It can use your application URI scheme in the context of a mobile application.
- """
-
- class CreateParamsSourceOrder(TypedDict):
- items: NotRequired[List["Source.CreateParamsSourceOrderItem"]]
- """
- List of items constituting the order.
- """
- shipping: NotRequired["Source.CreateParamsSourceOrderShipping"]
- """
- Shipping address for the order. Required if any of the SKUs are for products that have `shippable` set to true.
- """
-
- class CreateParamsSourceOrderItem(TypedDict):
- amount: NotRequired[int]
- currency: NotRequired[str]
- description: NotRequired[str]
- parent: NotRequired[str]
- """
- The ID of the SKU being ordered.
- """
- quantity: NotRequired[int]
- """
- The quantity of this order item. When type is `sku`, this is the number of instances of the SKU to be ordered.
- """
- type: NotRequired[Literal["discount", "shipping", "sku", "tax"]]
-
- class CreateParamsSourceOrderShipping(TypedDict):
- address: "Source.CreateParamsSourceOrderShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: NotRequired[str]
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class CreateParamsSourceOrderShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ListSourceTransactionsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ModifyParams(RequestOptions):
- amount: NotRequired[int]
- """
- Amount associated with the source.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- mandate: NotRequired["Source.ModifyParamsMandate"]
- """
- Information about a mandate possibility attached to a source object (generally for bank debits) as well as its acceptance status.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- owner: NotRequired["Source.ModifyParamsOwner"]
- """
- Information about the owner of the payment instrument that may be used or required by particular source types.
- """
- source_order: NotRequired["Source.ModifyParamsSourceOrder"]
- """
- Information about the items and shipping associated with the source. Required for transactional credit (for example Klarna) sources before you can charge it.
- """
-
- class ModifyParamsMandate(TypedDict):
- acceptance: NotRequired["Source.ModifyParamsMandateAcceptance"]
- """
- The parameters required to notify Stripe of a mandate acceptance or refusal by the customer.
- """
- amount: NotRequired["Literal['']|int"]
- """
- The amount specified by the mandate. (Leave null for a mandate covering all amounts)
- """
- currency: NotRequired[str]
- """
- The currency specified by the mandate. (Must match `currency` of the source)
- """
- interval: NotRequired[Literal["one_time", "scheduled", "variable"]]
- """
- The interval of debits permitted by the mandate. Either `one_time` (just permitting a single debit), `scheduled` (with debits on an agreed schedule or for clearly-defined events), or `variable`(for debits with any frequency)
- """
- notification_method: NotRequired[
- Literal[
- "deprecated_none", "email", "manual", "none", "stripe_email"
- ]
- ]
- """
- The method Stripe should use to notify the customer of upcoming debit instructions and/or mandate confirmation as required by the underlying debit network. Either `email` (an email is sent directly to the customer), `manual` (a `source.mandate_notification` event is sent to your webhooks endpoint and you should handle the notification) or `none` (the underlying debit network does not require any notification).
- """
-
- class ModifyParamsMandateAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
- """
- ip: NotRequired[str]
- """
- The IP address from which the mandate was accepted or refused by the customer.
- """
- offline: NotRequired["Source.ModifyParamsMandateAcceptanceOffline"]
- """
- The parameters required to store a mandate accepted offline. Should only be set if `mandate[type]` is `offline`
- """
- online: NotRequired["Source.ModifyParamsMandateAcceptanceOnline"]
- """
- The parameters required to store a mandate accepted online. Should only be set if `mandate[type]` is `online`
- """
- status: Literal["accepted", "pending", "refused", "revoked"]
- """
- The status of the mandate acceptance. Either `accepted` (the mandate was accepted) or `refused` (the mandate was refused).
- """
- type: NotRequired[Literal["offline", "online"]]
- """
- The type of acceptance information included with the mandate. Either `online` or `offline`
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the mandate was accepted or refused by the customer.
- """
-
- class ModifyParamsMandateAcceptanceOffline(TypedDict):
- contact_email: str
- """
- An email to contact you with if a copy of the mandate is requested, required if `type` is `offline`.
- """
-
- class ModifyParamsMandateAcceptanceOnline(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
- """
- ip: NotRequired[str]
- """
- The IP address from which the mandate was accepted or refused by the customer.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the mandate was accepted or refused by the customer.
- """
-
- class ModifyParamsOwner(TypedDict):
- address: NotRequired["Source.ModifyParamsOwnerAddress"]
- """
- Owner's address.
- """
- email: NotRequired[str]
- """
- Owner's email address.
- """
- name: NotRequired[str]
- """
- Owner's full name.
- """
- phone: NotRequired[str]
- """
- Owner's phone number.
- """
-
- class ModifyParamsOwnerAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ModifyParamsSourceOrder(TypedDict):
- items: NotRequired[List["Source.ModifyParamsSourceOrderItem"]]
- """
- List of items constituting the order.
- """
- shipping: NotRequired["Source.ModifyParamsSourceOrderShipping"]
- """
- Shipping address for the order. Required if any of the SKUs are for products that have `shippable` set to true.
- """
-
- class ModifyParamsSourceOrderItem(TypedDict):
- amount: NotRequired[int]
- currency: NotRequired[str]
- description: NotRequired[str]
- parent: NotRequired[str]
- """
- The ID of the SKU being ordered.
- """
- quantity: NotRequired[int]
- """
- The quantity of this order item. When type is `sku`, this is the number of instances of the SKU to be ordered.
- """
- type: NotRequired[Literal["discount", "shipping", "sku", "tax"]]
-
- class ModifyParamsSourceOrderShipping(TypedDict):
- address: "Source.ModifyParamsSourceOrderShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: NotRequired[str]
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class ModifyParamsSourceOrderShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class RetrieveParams(RequestOptions):
- client_secret: NotRequired[str]
- """
- The client secret of the source. Required if a publishable key is used to retrieve the source.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class VerifyParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- values: List[str]
- """
- The values needed to verify the source.
- """
-
ach_credit_transfer: Optional[AchCreditTransfer]
ach_debit: Optional[AchDebit]
acss_debit: Optional[AcssDebit]
@@ -1118,7 +594,7 @@ class VerifyParams(RequestOptions):
wechat: Optional[Wechat]
@classmethod
- def create(cls, **params: Unpack["Source.CreateParams"]) -> "Source":
+ def create(cls, **params: Unpack["SourceCreateParams"]) -> "Source":
"""
Creates a new source object.
"""
@@ -1133,7 +609,7 @@ def create(cls, **params: Unpack["Source.CreateParams"]) -> "Source":
@classmethod
async def create_async(
- cls, **params: Unpack["Source.CreateParams"]
+ cls, **params: Unpack["SourceCreateParams"]
) -> "Source":
"""
Creates a new source object.
@@ -1151,7 +627,7 @@ async def create_async(
def _cls_list_source_transactions(
cls,
source: str,
- **params: Unpack["Source.ListSourceTransactionsParams"],
+ **params: Unpack["SourceListSourceTransactionsParams"],
) -> ListObject["SourceTransaction"]:
"""
List source transactions for a given source.
@@ -1170,7 +646,7 @@ def _cls_list_source_transactions(
@overload
@staticmethod
def list_source_transactions(
- source: str, **params: Unpack["Source.ListSourceTransactionsParams"]
+ source: str, **params: Unpack["SourceListSourceTransactionsParams"]
) -> ListObject["SourceTransaction"]:
"""
List source transactions for a given source.
@@ -1179,7 +655,7 @@ def list_source_transactions(
@overload
def list_source_transactions(
- self, **params: Unpack["Source.ListSourceTransactionsParams"]
+ self, **params: Unpack["SourceListSourceTransactionsParams"]
) -> ListObject["SourceTransaction"]:
"""
List source transactions for a given source.
@@ -1188,7 +664,7 @@ def list_source_transactions(
@class_method_variant("_cls_list_source_transactions")
def list_source_transactions( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Source.ListSourceTransactionsParams"]
+ self, **params: Unpack["SourceListSourceTransactionsParams"]
) -> ListObject["SourceTransaction"]:
"""
List source transactions for a given source.
@@ -1208,7 +684,7 @@ def list_source_transactions( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_list_source_transactions_async(
cls,
source: str,
- **params: Unpack["Source.ListSourceTransactionsParams"],
+ **params: Unpack["SourceListSourceTransactionsParams"],
) -> ListObject["SourceTransaction"]:
"""
List source transactions for a given source.
@@ -1227,7 +703,7 @@ async def _cls_list_source_transactions_async(
@overload
@staticmethod
async def list_source_transactions_async(
- source: str, **params: Unpack["Source.ListSourceTransactionsParams"]
+ source: str, **params: Unpack["SourceListSourceTransactionsParams"]
) -> ListObject["SourceTransaction"]:
"""
List source transactions for a given source.
@@ -1236,7 +712,7 @@ async def list_source_transactions_async(
@overload
async def list_source_transactions_async(
- self, **params: Unpack["Source.ListSourceTransactionsParams"]
+ self, **params: Unpack["SourceListSourceTransactionsParams"]
) -> ListObject["SourceTransaction"]:
"""
List source transactions for a given source.
@@ -1245,7 +721,7 @@ async def list_source_transactions_async(
@class_method_variant("_cls_list_source_transactions_async")
async def list_source_transactions_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Source.ListSourceTransactionsParams"]
+ self, **params: Unpack["SourceListSourceTransactionsParams"]
) -> ListObject["SourceTransaction"]:
"""
List source transactions for a given source.
@@ -1263,7 +739,7 @@ async def list_source_transactions_async( # pyright: ignore[reportGeneralTypeIs
@classmethod
def modify(
- cls, id: str, **params: Unpack["Source.ModifyParams"]
+ cls, id: str, **params: Unpack["SourceModifyParams"]
) -> "Source":
"""
Updates the specified source by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -1282,7 +758,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Source.ModifyParams"]
+ cls, id: str, **params: Unpack["SourceModifyParams"]
) -> "Source":
"""
Updates the specified source by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -1301,7 +777,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Source.RetrieveParams"]
+ cls, id: str, **params: Unpack["SourceRetrieveParams"]
) -> "Source":
"""
Retrieves an existing source object. Supply the unique source ID from a source creation request and Stripe will return the corresponding up-to-date source object information.
@@ -1312,7 +788,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Source.RetrieveParams"]
+ cls, id: str, **params: Unpack["SourceRetrieveParams"]
) -> "Source":
"""
Retrieves an existing source object. Supply the unique source ID from a source creation request and Stripe will return the corresponding up-to-date source object information.
@@ -1323,7 +799,7 @@ async def retrieve_async(
@classmethod
def _cls_verify(
- cls, source: str, **params: Unpack["Source.VerifyParams"]
+ cls, source: str, **params: Unpack["SourceVerifyParams"]
) -> "Source":
"""
Verify a given source.
@@ -1342,7 +818,7 @@ def _cls_verify(
@overload
@staticmethod
def verify(
- source: str, **params: Unpack["Source.VerifyParams"]
+ source: str, **params: Unpack["SourceVerifyParams"]
) -> "Source":
"""
Verify a given source.
@@ -1350,7 +826,7 @@ def verify(
...
@overload
- def verify(self, **params: Unpack["Source.VerifyParams"]) -> "Source":
+ def verify(self, **params: Unpack["SourceVerifyParams"]) -> "Source":
"""
Verify a given source.
"""
@@ -1358,7 +834,7 @@ def verify(self, **params: Unpack["Source.VerifyParams"]) -> "Source":
@class_method_variant("_cls_verify")
def verify( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Source.VerifyParams"]
+ self, **params: Unpack["SourceVerifyParams"]
) -> "Source":
"""
Verify a given source.
@@ -1376,7 +852,7 @@ def verify( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_verify_async(
- cls, source: str, **params: Unpack["Source.VerifyParams"]
+ cls, source: str, **params: Unpack["SourceVerifyParams"]
) -> "Source":
"""
Verify a given source.
@@ -1395,7 +871,7 @@ async def _cls_verify_async(
@overload
@staticmethod
async def verify_async(
- source: str, **params: Unpack["Source.VerifyParams"]
+ source: str, **params: Unpack["SourceVerifyParams"]
) -> "Source":
"""
Verify a given source.
@@ -1404,7 +880,7 @@ async def verify_async(
@overload
async def verify_async(
- self, **params: Unpack["Source.VerifyParams"]
+ self, **params: Unpack["SourceVerifyParams"]
) -> "Source":
"""
Verify a given source.
@@ -1413,7 +889,7 @@ async def verify_async(
@class_method_variant("_cls_verify_async")
async def verify_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Source.VerifyParams"]
+ self, **params: Unpack["SourceVerifyParams"]
) -> "Source":
"""
Verify a given source.
diff --git a/stripe/_source_service.py b/stripe/_source_service.py
index 4a0bf0619..313cc6237 100644
--- a/stripe/_source_service.py
+++ b/stripe/_source_service.py
@@ -8,8 +8,15 @@
from stripe._source_transaction_service import SourceTransactionService
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, Union, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, Union, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._source_create_params import SourceCreateParams
+ from stripe.params._source_detach_params import SourceDetachParams
+ from stripe.params._source_retrieve_params import SourceRetrieveParams
+ from stripe.params._source_update_params import SourceUpdateParams
+ from stripe.params._source_verify_params import SourceVerifyParams
class SourceService(StripeService):
@@ -17,531 +24,11 @@ def __init__(self, requestor):
super().__init__(requestor)
self.transactions = SourceTransactionService(self._requestor)
- class CreateParams(TypedDict):
- amount: NotRequired[int]
- """
- Amount associated with the source. This is the amount for which the source will be chargeable once ready. Required for `single_use` sources. Not supported for `receiver` type sources, where charge amount may not be specified until funds land.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) associated with the source. This is the currency for which the source will be chargeable once ready.
- """
- customer: NotRequired[str]
- """
- The `Customer` to whom the original source is attached to. Must be set when the original source is not a `Source` (e.g., `Card`).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- flow: NotRequired[
- Literal["code_verification", "none", "receiver", "redirect"]
- ]
- """
- The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows.
- """
- mandate: NotRequired["SourceService.CreateParamsMandate"]
- """
- Information about a mandate possibility attached to a source object (generally for bank debits) as well as its acceptance status.
- """
- metadata: NotRequired[Dict[str, str]]
- original_source: NotRequired[str]
- """
- The source to share.
- """
- owner: NotRequired["SourceService.CreateParamsOwner"]
- """
- Information about the owner of the payment instrument that may be used or required by particular source types.
- """
- receiver: NotRequired["SourceService.CreateParamsReceiver"]
- """
- Optional parameters for the receiver flow. Can be set only if the source is a receiver (`flow` is `receiver`).
- """
- redirect: NotRequired["SourceService.CreateParamsRedirect"]
- """
- Parameters required for the redirect flow. Required if the source is authenticated by a redirect (`flow` is `redirect`).
- """
- source_order: NotRequired["SourceService.CreateParamsSourceOrder"]
- """
- Information about the items and shipping associated with the source. Required for transactional credit (for example Klarna) sources before you can charge it.
- """
- statement_descriptor: NotRequired[str]
- """
- An arbitrary string to be displayed on your customer's statement. As an example, if your website is `RunClub` and the item you're charging for is a race ticket, you may want to specify a `statement_descriptor` of `RunClub 5K race ticket.` While many payment types will display this information, some may not display it at all.
- """
- token: NotRequired[str]
- """
- An optional token used to create the source. When passed, token properties will override source parameters.
- """
- type: NotRequired[str]
- """
- The `type` of the source to create. Required unless `customer` and `original_source` are specified (see the [Cloning card Sources](https://stripe.com/docs/sources/connect#cloning-card-sources) guide)
- """
- usage: NotRequired[Literal["reusable", "single_use"]]
-
- class CreateParamsMandate(TypedDict):
- acceptance: NotRequired["SourceService.CreateParamsMandateAcceptance"]
- """
- The parameters required to notify Stripe of a mandate acceptance or refusal by the customer.
- """
- amount: NotRequired["Literal['']|int"]
- """
- The amount specified by the mandate. (Leave null for a mandate covering all amounts)
- """
- currency: NotRequired[str]
- """
- The currency specified by the mandate. (Must match `currency` of the source)
- """
- interval: NotRequired[Literal["one_time", "scheduled", "variable"]]
- """
- The interval of debits permitted by the mandate. Either `one_time` (just permitting a single debit), `scheduled` (with debits on an agreed schedule or for clearly-defined events), or `variable`(for debits with any frequency)
- """
- notification_method: NotRequired[
- Literal[
- "deprecated_none", "email", "manual", "none", "stripe_email"
- ]
- ]
- """
- The method Stripe should use to notify the customer of upcoming debit instructions and/or mandate confirmation as required by the underlying debit network. Either `email` (an email is sent directly to the customer), `manual` (a `source.mandate_notification` event is sent to your webhooks endpoint and you should handle the notification) or `none` (the underlying debit network does not require any notification).
- """
-
- class CreateParamsMandateAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
- """
- ip: NotRequired[str]
- """
- The IP address from which the mandate was accepted or refused by the customer.
- """
- offline: NotRequired[
- "SourceService.CreateParamsMandateAcceptanceOffline"
- ]
- """
- The parameters required to store a mandate accepted offline. Should only be set if `mandate[type]` is `offline`
- """
- online: NotRequired[
- "SourceService.CreateParamsMandateAcceptanceOnline"
- ]
- """
- The parameters required to store a mandate accepted online. Should only be set if `mandate[type]` is `online`
- """
- status: Literal["accepted", "pending", "refused", "revoked"]
- """
- The status of the mandate acceptance. Either `accepted` (the mandate was accepted) or `refused` (the mandate was refused).
- """
- type: NotRequired[Literal["offline", "online"]]
- """
- The type of acceptance information included with the mandate. Either `online` or `offline`
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the mandate was accepted or refused by the customer.
- """
-
- class CreateParamsMandateAcceptanceOffline(TypedDict):
- contact_email: str
- """
- An email to contact you with if a copy of the mandate is requested, required if `type` is `offline`.
- """
-
- class CreateParamsMandateAcceptanceOnline(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
- """
- ip: NotRequired[str]
- """
- The IP address from which the mandate was accepted or refused by the customer.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the mandate was accepted or refused by the customer.
- """
-
- class CreateParamsOwner(TypedDict):
- address: NotRequired["SourceService.CreateParamsOwnerAddress"]
- """
- Owner's address.
- """
- email: NotRequired[str]
- """
- Owner's email address.
- """
- name: NotRequired[str]
- """
- Owner's full name.
- """
- phone: NotRequired[str]
- """
- Owner's phone number.
- """
-
- class CreateParamsOwnerAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsReceiver(TypedDict):
- refund_attributes_method: NotRequired[
- Literal["email", "manual", "none"]
- ]
- """
- The method Stripe should use to request information needed to process a refund or mispayment. Either `email` (an email is sent directly to the customer) or `manual` (a `source.refund_attributes_required` event is sent to your webhooks endpoint). Refer to each payment method's documentation to learn which refund attributes may be required.
- """
-
- class CreateParamsRedirect(TypedDict):
- return_url: str
- """
- The URL you provide to redirect the customer back to you after they authenticated their payment. It can use your application URI scheme in the context of a mobile application.
- """
-
- class CreateParamsSourceOrder(TypedDict):
- items: NotRequired[List["SourceService.CreateParamsSourceOrderItem"]]
- """
- List of items constituting the order.
- """
- shipping: NotRequired["SourceService.CreateParamsSourceOrderShipping"]
- """
- Shipping address for the order. Required if any of the SKUs are for products that have `shippable` set to true.
- """
-
- class CreateParamsSourceOrderItem(TypedDict):
- amount: NotRequired[int]
- currency: NotRequired[str]
- description: NotRequired[str]
- parent: NotRequired[str]
- """
- The ID of the SKU being ordered.
- """
- quantity: NotRequired[int]
- """
- The quantity of this order item. When type is `sku`, this is the number of instances of the SKU to be ordered.
- """
- type: NotRequired[Literal["discount", "shipping", "sku", "tax"]]
-
- class CreateParamsSourceOrderShipping(TypedDict):
- address: "SourceService.CreateParamsSourceOrderShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: NotRequired[str]
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class CreateParamsSourceOrderShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class DetachParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(TypedDict):
- client_secret: NotRequired[str]
- """
- The client secret of the source. Required if a publishable key is used to retrieve the source.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- amount: NotRequired[int]
- """
- Amount associated with the source.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- mandate: NotRequired["SourceService.UpdateParamsMandate"]
- """
- Information about a mandate possibility attached to a source object (generally for bank debits) as well as its acceptance status.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- owner: NotRequired["SourceService.UpdateParamsOwner"]
- """
- Information about the owner of the payment instrument that may be used or required by particular source types.
- """
- source_order: NotRequired["SourceService.UpdateParamsSourceOrder"]
- """
- Information about the items and shipping associated with the source. Required for transactional credit (for example Klarna) sources before you can charge it.
- """
-
- class UpdateParamsMandate(TypedDict):
- acceptance: NotRequired["SourceService.UpdateParamsMandateAcceptance"]
- """
- The parameters required to notify Stripe of a mandate acceptance or refusal by the customer.
- """
- amount: NotRequired["Literal['']|int"]
- """
- The amount specified by the mandate. (Leave null for a mandate covering all amounts)
- """
- currency: NotRequired[str]
- """
- The currency specified by the mandate. (Must match `currency` of the source)
- """
- interval: NotRequired[Literal["one_time", "scheduled", "variable"]]
- """
- The interval of debits permitted by the mandate. Either `one_time` (just permitting a single debit), `scheduled` (with debits on an agreed schedule or for clearly-defined events), or `variable`(for debits with any frequency)
- """
- notification_method: NotRequired[
- Literal[
- "deprecated_none", "email", "manual", "none", "stripe_email"
- ]
- ]
- """
- The method Stripe should use to notify the customer of upcoming debit instructions and/or mandate confirmation as required by the underlying debit network. Either `email` (an email is sent directly to the customer), `manual` (a `source.mandate_notification` event is sent to your webhooks endpoint and you should handle the notification) or `none` (the underlying debit network does not require any notification).
- """
-
- class UpdateParamsMandateAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
- """
- ip: NotRequired[str]
- """
- The IP address from which the mandate was accepted or refused by the customer.
- """
- offline: NotRequired[
- "SourceService.UpdateParamsMandateAcceptanceOffline"
- ]
- """
- The parameters required to store a mandate accepted offline. Should only be set if `mandate[type]` is `offline`
- """
- online: NotRequired[
- "SourceService.UpdateParamsMandateAcceptanceOnline"
- ]
- """
- The parameters required to store a mandate accepted online. Should only be set if `mandate[type]` is `online`
- """
- status: Literal["accepted", "pending", "refused", "revoked"]
- """
- The status of the mandate acceptance. Either `accepted` (the mandate was accepted) or `refused` (the mandate was refused).
- """
- type: NotRequired[Literal["offline", "online"]]
- """
- The type of acceptance information included with the mandate. Either `online` or `offline`
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the mandate was accepted or refused by the customer.
- """
-
- class UpdateParamsMandateAcceptanceOffline(TypedDict):
- contact_email: str
- """
- An email to contact you with if a copy of the mandate is requested, required if `type` is `offline`.
- """
-
- class UpdateParamsMandateAcceptanceOnline(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
- """
- ip: NotRequired[str]
- """
- The IP address from which the mandate was accepted or refused by the customer.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the mandate was accepted or refused by the customer.
- """
-
- class UpdateParamsOwner(TypedDict):
- address: NotRequired["SourceService.UpdateParamsOwnerAddress"]
- """
- Owner's address.
- """
- email: NotRequired[str]
- """
- Owner's email address.
- """
- name: NotRequired[str]
- """
- Owner's full name.
- """
- phone: NotRequired[str]
- """
- Owner's phone number.
- """
-
- class UpdateParamsOwnerAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsSourceOrder(TypedDict):
- items: NotRequired[List["SourceService.UpdateParamsSourceOrderItem"]]
- """
- List of items constituting the order.
- """
- shipping: NotRequired["SourceService.UpdateParamsSourceOrderShipping"]
- """
- Shipping address for the order. Required if any of the SKUs are for products that have `shippable` set to true.
- """
-
- class UpdateParamsSourceOrderItem(TypedDict):
- amount: NotRequired[int]
- currency: NotRequired[str]
- description: NotRequired[str]
- parent: NotRequired[str]
- """
- The ID of the SKU being ordered.
- """
- quantity: NotRequired[int]
- """
- The quantity of this order item. When type is `sku`, this is the number of instances of the SKU to be ordered.
- """
- type: NotRequired[Literal["discount", "shipping", "sku", "tax"]]
-
- class UpdateParamsSourceOrderShipping(TypedDict):
- address: "SourceService.UpdateParamsSourceOrderShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: NotRequired[str]
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class UpdateParamsSourceOrderShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class VerifyParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- values: List[str]
- """
- The values needed to verify the source.
- """
-
def detach(
self,
customer: str,
id: str,
- params: Optional["SourceService.DetachParams"] = None,
+ params: Optional["SourceDetachParams"] = None,
options: Optional[RequestOptions] = None,
) -> Union[Account, BankAccount, Card, Source]:
"""
@@ -565,7 +52,7 @@ async def detach_async(
self,
customer: str,
id: str,
- params: Optional["SourceService.DetachParams"] = None,
+ params: Optional["SourceDetachParams"] = None,
options: Optional[RequestOptions] = None,
) -> Union[Account, BankAccount, Card, Source]:
"""
@@ -588,7 +75,7 @@ async def detach_async(
def retrieve(
self,
source: str,
- params: Optional["SourceService.RetrieveParams"] = None,
+ params: Optional["SourceRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Source:
"""
@@ -608,7 +95,7 @@ def retrieve(
async def retrieve_async(
self,
source: str,
- params: Optional["SourceService.RetrieveParams"] = None,
+ params: Optional["SourceRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Source:
"""
@@ -628,7 +115,7 @@ async def retrieve_async(
def update(
self,
source: str,
- params: Optional["SourceService.UpdateParams"] = None,
+ params: Optional["SourceUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Source:
"""
@@ -650,7 +137,7 @@ def update(
async def update_async(
self,
source: str,
- params: Optional["SourceService.UpdateParams"] = None,
+ params: Optional["SourceUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Source:
"""
@@ -671,7 +158,7 @@ async def update_async(
def create(
self,
- params: Optional["SourceService.CreateParams"] = None,
+ params: Optional["SourceCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Source:
"""
@@ -690,7 +177,7 @@ def create(
async def create_async(
self,
- params: Optional["SourceService.CreateParams"] = None,
+ params: Optional["SourceCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Source:
"""
@@ -710,7 +197,7 @@ async def create_async(
def verify(
self,
source: str,
- params: "SourceService.VerifyParams",
+ params: "SourceVerifyParams",
options: Optional[RequestOptions] = None,
) -> Source:
"""
@@ -732,7 +219,7 @@ def verify(
async def verify_async(
self,
source: str,
- params: "SourceService.VerifyParams",
+ params: "SourceVerifyParams",
options: Optional[RequestOptions] = None,
) -> Source:
"""
diff --git a/stripe/_source_transaction_service.py b/stripe/_source_transaction_service.py
index 23fbfcef8..9c3b9e035 100644
--- a/stripe/_source_transaction_service.py
+++ b/stripe/_source_transaction_service.py
@@ -5,33 +5,20 @@
from stripe._source_transaction import SourceTransaction
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._source_transaction_list_params import (
+ SourceTransactionListParams,
+ )
-class SourceTransactionService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
+class SourceTransactionService(StripeService):
def list(
self,
source: str,
- params: Optional["SourceTransactionService.ListParams"] = None,
+ params: Optional["SourceTransactionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[SourceTransaction]:
"""
@@ -53,7 +40,7 @@ def list(
async def list_async(
self,
source: str,
- params: Optional["SourceTransactionService.ListParams"] = None,
+ params: Optional["SourceTransactionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[SourceTransaction]:
"""
diff --git a/stripe/_subscription.py b/stripe/_subscription.py
index e05078571..1587bd758 100644
--- a/stripe/_subscription.py
+++ b/stripe/_subscription.py
@@ -5,7 +5,6 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._search_result_object import SearchResultObject
from stripe._searchable_api_resource import SearchableAPIResource
from stripe._stripe_object import StripeObject
@@ -22,13 +21,7 @@
cast,
overload,
)
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account
@@ -45,6 +38,31 @@
from stripe._subscription_schedule import SubscriptionSchedule
from stripe._tax_id import TaxId
from stripe._tax_rate import TaxRate
+ from stripe.params._subscription_cancel_params import (
+ SubscriptionCancelParams,
+ )
+ from stripe.params._subscription_create_params import (
+ SubscriptionCreateParams,
+ )
+ from stripe.params._subscription_delete_discount_params import (
+ SubscriptionDeleteDiscountParams,
+ )
+ from stripe.params._subscription_list_params import SubscriptionListParams
+ from stripe.params._subscription_migrate_params import (
+ SubscriptionMigrateParams,
+ )
+ from stripe.params._subscription_modify_params import (
+ SubscriptionModifyParams,
+ )
+ from stripe.params._subscription_resume_params import (
+ SubscriptionResumeParams,
+ )
+ from stripe.params._subscription_retrieve_params import (
+ SubscriptionRetrieveParams,
+ )
+ from stripe.params._subscription_search_params import (
+ SubscriptionSearchParams,
+ )
from stripe.test_helpers._test_clock import TestClock
@@ -492,1722 +510,6 @@ class EndBehavior(StripeObject):
"""
_inner_class_types = {"end_behavior": EndBehavior}
- class CancelParams(RequestOptions):
- cancellation_details: NotRequired[
- "Subscription.CancelParamsCancellationDetails"
- ]
- """
- Details about why this subscription was cancelled
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_now: NotRequired[bool]
- """
- Will generate a final invoice that invoices for any un-invoiced metered usage and new/pending proration invoice items. Defaults to `false`.
- """
- prorate: NotRequired[bool]
- """
- Will generate a proration invoice item that credits remaining unused time until the subscription period end. Defaults to `false`.
- """
-
- class CancelParamsCancellationDetails(TypedDict):
- comment: NotRequired["Literal['']|str"]
- """
- Additional comments about why the user canceled the subscription, if the subscription was canceled explicitly by the user.
- """
- feedback: NotRequired[
- "Literal['']|Literal['customer_service', 'low_quality', 'missing_features', 'other', 'switched_service', 'too_complex', 'too_expensive', 'unused']"
- ]
- """
- The customer submitted reason for why they canceled, if the subscription was canceled explicitly by the user.
- """
-
- class CreateParams(RequestOptions):
- add_invoice_items: NotRequired[
- List["Subscription.CreateParamsAddInvoiceItem"]
- ]
- """
- A list of prices and quantities that will generate invoice items appended to the next invoice for this subscription. You may pass up to 20 items.
- """
- application_fee_percent: NotRequired["Literal['']|float"]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- automatic_tax: NotRequired["Subscription.CreateParamsAutomaticTax"]
- """
- Automatic tax settings for this subscription.
- """
- backdate_start_date: NotRequired[int]
- """
- A past timestamp to backdate the subscription's start date to. If set, the first invoice will contain line items for the timespan between the start date and the current time. Can be combined with trials and the billing cycle anchor.
- """
- billing_cycle_anchor: NotRequired[int]
- """
- A future timestamp in UTC format to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). The anchor is the reference point that aligns future billing cycle dates. It sets the day of week for `week` intervals, the day of month for `month` and `year` intervals, and the month of year for `year` intervals.
- """
- billing_cycle_anchor_config: NotRequired[
- "Subscription.CreateParamsBillingCycleAnchorConfig"
- ]
- """
- Mutually exclusive with billing_cycle_anchor and only valid with monthly and yearly price intervals. When provided, the billing_cycle_anchor is set to the next occurrence of the day_of_month at the hour, minute, and second UTC.
- """
- billing_mode: NotRequired["Subscription.CreateParamsBillingMode"]
- """
- Controls how prorations and invoices for subscriptions are calculated and orchestrated.
- """
- billing_thresholds: NotRequired[
- "Literal['']|Subscription.CreateParamsBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds.
- """
- cancel_at: NotRequired[
- "int|Literal['max_period_end', 'min_period_end']"
- ]
- """
- A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
- """
- cancel_at_period_end: NotRequired[bool]
- """
- Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: str
- """
- The identifier of the customer to subscribe.
- """
- days_until_due: NotRequired[int]
- """
- Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
- """
- default_source: NotRequired[str]
- """
- ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription.
- """
- description: NotRequired[str]
- """
- The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- discounts: NotRequired[
- "Literal['']|List[Subscription.CreateParamsDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription. If not specified or empty, inherits the discount from the subscription's customer.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_settings: NotRequired[
- "Subscription.CreateParamsInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- items: NotRequired[List["Subscription.CreateParamsItem"]]
- """
- A list of up to 20 subscription items, each with an attached price.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- off_session: NotRequired[bool]
- """
- Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account on behalf of which to charge, for each of the subscription's invoices.
- """
- payment_behavior: NotRequired[
- Literal[
- "allow_incomplete",
- "default_incomplete",
- "error_if_incomplete",
- "pending_if_incomplete",
- ]
- ]
- """
- Only applies to subscriptions with `collection_method=charge_automatically`.
-
- Use `allow_incomplete` to create Subscriptions with `status=incomplete` if the first invoice can't be paid. Creating Subscriptions with this status allows you to manage scenarios where additional customer actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
-
- Use `default_incomplete` to create Subscriptions with `status=incomplete` when the first invoice requires payment, otherwise start as active. Subscriptions transition to `status=active` when successfully confirming the PaymentIntent on the first invoice. This allows simpler management of scenarios where additional customer actions are needed to pay a subscription's invoice, such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method. If the PaymentIntent is not confirmed within 23 hours Subscriptions transition to `status=incomplete_expired`, which is a terminal state.
-
- Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice can't be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further customer action is needed, this parameter doesn't create a Subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.
-
- `pending_if_incomplete` is only used with updates and cannot be passed when creating a Subscription.
-
- Subscriptions with `collection_method=send_invoice` are automatically activated regardless of the first Invoice status.
- """
- payment_settings: NotRequired[
- "Subscription.CreateParamsPaymentSettings"
- ]
- """
- Payment settings to pass to invoices created by the subscription.
- """
- pending_invoice_item_interval: NotRequired[
- "Literal['']|Subscription.CreateParamsPendingInvoiceItemInterval"
- ]
- """
- Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) resulting from the `billing_cycle_anchor`. If no value is passed, the default is `create_prorations`.
- """
- transfer_data: NotRequired["Subscription.CreateParamsTransferData"]
- """
- If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges.
- """
- trial_end: NotRequired["Literal['now']|int"]
- """
- Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
- """
- trial_from_plan: NotRequired[bool]
- """
- Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
- """
- trial_period_days: NotRequired[int]
- """
- Integer representing the number of trial period days before the customer is charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
- """
- trial_settings: NotRequired["Subscription.CreateParamsTrialSettings"]
- """
- Settings related to subscription trials.
- """
-
- class CreateParamsAddInvoiceItem(TypedDict):
- discounts: NotRequired[
- List["Subscription.CreateParamsAddInvoiceItemDiscount"]
- ]
- """
- The coupons to redeem into discounts for the item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired["Subscription.CreateParamsAddInvoiceItemPeriod"]
- """
- The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired[
- "Subscription.CreateParamsAddInvoiceItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item. Defaults to 1.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
- """
-
- class CreateParamsAddInvoiceItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsAddInvoiceItemPeriod(TypedDict):
- end: "Subscription.CreateParamsAddInvoiceItemPeriodEnd"
- """
- End of the invoice item period.
- """
- start: "Subscription.CreateParamsAddInvoiceItemPeriodStart"
- """
- Start of the invoice item period.
- """
-
- class CreateParamsAddInvoiceItemPeriodEnd(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
- """
- type: Literal["min_item_period_end", "timestamp"]
- """
- Select how to calculate the end of the invoice item period.
- """
-
- class CreateParamsAddInvoiceItemPeriodStart(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
- """
- type: Literal["max_item_period_start", "now", "timestamp"]
- """
- Select how to calculate the start of the invoice item period.
- """
-
- class CreateParamsAddInvoiceItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
- liability: NotRequired[
- "Subscription.CreateParamsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreateParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsBillingCycleAnchorConfig(TypedDict):
- day_of_month: int
- """
- The day of the month the anchor should be. Ranges from 1 to 31.
- """
- hour: NotRequired[int]
- """
- The hour of the day the anchor should be. Ranges from 0 to 23.
- """
- minute: NotRequired[int]
- """
- The minute of the hour the anchor should be. Ranges from 0 to 59.
- """
- month: NotRequired[int]
- """
- The month to start full cycle periods. Ranges from 1 to 12.
- """
- second: NotRequired[int]
- """
- The second of the minute the anchor should be. Ranges from 0 to 59.
- """
-
- class CreateParamsBillingMode(TypedDict):
- flexible: NotRequired["Subscription.CreateParamsBillingModeFlexible"]
- """
- Configure behavior for flexible billing mode.
- """
- type: Literal["classic", "flexible"]
- """
- Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
- """
-
- class CreateParamsBillingModeFlexible(TypedDict):
- proration_discounts: NotRequired[Literal["included", "itemized"]]
- """
- Controls how invoices and invoice items display proration amounts and discount amounts.
- """
-
- class CreateParamsBillingThresholds(TypedDict):
- amount_gte: NotRequired[int]
- """
- Monetary threshold that triggers the subscription to advance to a new billing period
- """
- reset_billing_cycle_anchor: NotRequired[bool]
- """
- Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
- """
-
- class CreateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsInvoiceSettings(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the subscription. Will be set on invoices generated by the subscription.
- """
- issuer: NotRequired["Subscription.CreateParamsInvoiceSettingsIssuer"]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class CreateParamsInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsItem(TypedDict):
- billing_thresholds: NotRequired[
- "Literal['']|Subscription.CreateParamsItemBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- discounts: NotRequired[
- "Literal['']|List[Subscription.CreateParamsItemDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- plan: NotRequired[str]
- """
- Plan ID for this item, as a string.
- """
- price: NotRequired[str]
- """
- The ID of the price object.
- """
- price_data: NotRequired["Subscription.CreateParamsItemPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class CreateParamsItemBillingThresholds(TypedDict):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class CreateParamsItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: "Subscription.CreateParamsItemPriceDataRecurring"
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class CreateParamsPaymentSettings(TypedDict):
- payment_method_options: NotRequired[
- "Subscription.CreateParamsPaymentSettingsPaymentMethodOptions"
- ]
- """
- Payment-method-specific configuration to provide to invoices created by the subscription.
- """
- payment_method_types: NotRequired[
- "Literal['']|List[Literal['ach_credit_transfer', 'ach_debit', 'acss_debit', 'affirm', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'jp_credit_transfer', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'link', 'multibanco', 'naver_pay', 'nz_bank_account', 'p24', 'payco', 'paynow', 'paypal', 'promptpay', 'revolut_pay', 'sepa_credit_transfer', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
- ]
- """
- The list of payment method types (e.g. card) to provide to the invoice's PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice's default payment method, the subscription's default payment method, the customer's default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice). Should not be specified with payment_method_configuration
- """
- save_default_payment_method: NotRequired[
- Literal["off", "on_subscription"]
- ]
- """
- Configure whether Stripe updates `subscription.default_payment_method` when payment succeeds. Defaults to `off` if unspecified.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "Literal['']|Subscription.CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebit"
- ]
- """
- This sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice's PaymentIntent.
- """
- bancontact: NotRequired[
- "Literal['']|Subscription.CreateParamsPaymentSettingsPaymentMethodOptionsBancontact"
- ]
- """
- This sub-hash contains details about the Bancontact payment method options to pass to the invoice's PaymentIntent.
- """
- card: NotRequired[
- "Literal['']|Subscription.CreateParamsPaymentSettingsPaymentMethodOptionsCard"
- ]
- """
- This sub-hash contains details about the Card payment method options to pass to the invoice's PaymentIntent.
- """
- customer_balance: NotRequired[
- "Literal['']|Subscription.CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance"
- ]
- """
- This sub-hash contains details about the Bank transfer payment method options to pass to the invoice's PaymentIntent.
- """
- konbini: NotRequired[
- "Literal['']|Subscription.CreateParamsPaymentSettingsPaymentMethodOptionsKonbini"
- ]
- """
- This sub-hash contains details about the Konbini payment method options to pass to the invoice's PaymentIntent.
- """
- sepa_debit: NotRequired[
- "Literal['']|Subscription.CreateParamsPaymentSettingsPaymentMethodOptionsSepaDebit"
- ]
- """
- This sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice's PaymentIntent.
- """
- us_bank_account: NotRequired[
- "Literal['']|Subscription.CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount"
- ]
- """
- This sub-hash contains details about the ACH direct debit payment method options to pass to the invoice's PaymentIntent.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebit(TypedDict):
- mandate_options: NotRequired[
- "Subscription.CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions(
- TypedDict,
- ):
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsBancontact(TypedDict):
- preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
- """
- Preferred language of the Bancontact authorization page that the customer is redirected to.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCard(TypedDict):
- mandate_options: NotRequired[
- "Subscription.CreateParamsPaymentSettingsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this Subscription on. Depends on the available networks of the card attached to the Subscription. Can be only set confirm-time.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCardMandateOptions(
- TypedDict,
- ):
- amount: NotRequired[int]
- """
- Amount to be charged for future payments.
- """
- amount_type: NotRequired[Literal["fixed", "maximum"]]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance(
- TypedDict,
- ):
- bank_transfer: NotRequired[
- "Subscription.CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[str]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "Subscription.CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for eu_bank_transfer funding type.
- """
- type: NotRequired[str]
- """
- The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsKonbini(TypedDict):
- pass
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsSepaDebit(TypedDict):
- pass
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount(
- TypedDict,
- ):
- financial_connections: NotRequired[
- "Subscription.CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "Subscription.CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class CreateParamsPendingInvoiceItemInterval(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies invoicing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks).
- """
-
- class CreateParamsTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class CreateParamsTrialSettings(TypedDict):
- end_behavior: "Subscription.CreateParamsTrialSettingsEndBehavior"
- """
- Defines how the subscription should behave when the user's free trial ends.
- """
-
- class CreateParamsTrialSettingsEndBehavior(TypedDict):
- missing_payment_method: Literal["cancel", "create_invoice", "pause"]
- """
- Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
- """
-
- class DeleteDiscountParams(RequestOptions):
- pass
-
- class ListParams(RequestOptions):
- automatic_tax: NotRequired["Subscription.ListParamsAutomaticTax"]
- """
- Filter subscriptions by their automatic tax settings.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- The collection method of the subscriptions to retrieve. Either `charge_automatically` or `send_invoice`.
- """
- created: NotRequired["Subscription.ListParamsCreated|int"]
- """
- Only return subscriptions that were created during the given date interval.
- """
- current_period_end: NotRequired[
- "Subscription.ListParamsCurrentPeriodEnd|int"
- ]
- """
- Only return subscriptions whose minimum item current_period_end falls within the given date interval.
- """
- current_period_start: NotRequired[
- "Subscription.ListParamsCurrentPeriodStart|int"
- ]
- """
- Only return subscriptions whose maximum item current_period_start falls within the given date interval.
- """
- customer: NotRequired[str]
- """
- The ID of the customer whose subscriptions will be retrieved.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- plan: NotRequired[str]
- """
- The ID of the plan whose subscriptions will be retrieved.
- """
- price: NotRequired[str]
- """
- Filter for subscriptions that contain this recurring price ID.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal[
- "active",
- "all",
- "canceled",
- "ended",
- "incomplete",
- "incomplete_expired",
- "past_due",
- "paused",
- "trialing",
- "unpaid",
- ]
- ]
- """
- The status of the subscriptions to retrieve. Passing in a value of `canceled` will return all canceled subscriptions, including those belonging to deleted customers. Pass `ended` to find subscriptions that are canceled and subscriptions that are expired due to [incomplete payment](https://stripe.com/docs/billing/subscriptions/overview#subscription-statuses). Passing in a value of `all` will return subscriptions of all statuses. If no value is supplied, all subscriptions that have not been canceled are returned.
- """
- test_clock: NotRequired[str]
- """
- Filter for subscriptions that are associated with the specified test clock. The response will not include subscriptions with test clocks if this and the customer parameter is not set.
- """
-
- class ListParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsCurrentPeriodEnd(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsCurrentPeriodStart(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class MigrateParams(RequestOptions):
- billing_mode: "Subscription.MigrateParamsBillingMode"
- """
- Controls how prorations and invoices for subscriptions are calculated and orchestrated.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class MigrateParamsBillingMode(TypedDict):
- flexible: NotRequired["Subscription.MigrateParamsBillingModeFlexible"]
- """
- Configure behavior for flexible billing mode.
- """
- type: Literal["flexible"]
- """
- Controls the calculation and orchestration of prorations and invoices for subscriptions.
- """
-
- class MigrateParamsBillingModeFlexible(TypedDict):
- proration_discounts: NotRequired[Literal["included", "itemized"]]
- """
- Controls how invoices and invoice items display proration amounts and discount amounts.
- """
-
- class ModifyParams(RequestOptions):
- add_invoice_items: NotRequired[
- List["Subscription.ModifyParamsAddInvoiceItem"]
- ]
- """
- A list of prices and quantities that will generate invoice items appended to the next invoice for this subscription. You may pass up to 20 items.
- """
- application_fee_percent: NotRequired["Literal['']|float"]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- automatic_tax: NotRequired["Subscription.ModifyParamsAutomaticTax"]
- """
- Automatic tax settings for this subscription. We recommend you only include this parameter when the existing value is being changed.
- """
- billing_cycle_anchor: NotRequired[Literal["now", "unchanged"]]
- """
- Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time (in UTC). For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
- """
- billing_thresholds: NotRequired[
- "Literal['']|Subscription.ModifyParamsBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds.
- """
- cancel_at: NotRequired[
- "Literal['']|int|Literal['max_period_end', 'min_period_end']"
- ]
- """
- A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
- """
- cancel_at_period_end: NotRequired[bool]
- """
- Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`.
- """
- cancellation_details: NotRequired[
- "Subscription.ModifyParamsCancellationDetails"
- ]
- """
- Details about why this subscription was cancelled
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
- """
- days_until_due: NotRequired[int]
- """
- Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
- """
- default_source: NotRequired["Literal['']|str"]
- """
- ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription. Pass an empty string to remove previously-defined tax rates.
- """
- description: NotRequired["Literal['']|str"]
- """
- The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- discounts: NotRequired[
- "Literal['']|List[Subscription.ModifyParamsDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription. If not specified or empty, inherits the discount from the subscription's customer.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_settings: NotRequired[
- "Subscription.ModifyParamsInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- items: NotRequired[List["Subscription.ModifyParamsItem"]]
- """
- A list of up to 20 subscription items, each with an attached price.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- off_session: NotRequired[bool]
- """
- Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account on behalf of which to charge, for each of the subscription's invoices.
- """
- pause_collection: NotRequired[
- "Literal['']|Subscription.ModifyParamsPauseCollection"
- ]
- """
- If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
- """
- payment_behavior: NotRequired[
- Literal[
- "allow_incomplete",
- "default_incomplete",
- "error_if_incomplete",
- "pending_if_incomplete",
- ]
- ]
- """
- Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
-
- Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription's invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
-
- Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
-
- Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://docs.stripe.com/changelog/2019-03-14) to learn more.
- """
- payment_settings: NotRequired[
- "Subscription.ModifyParamsPaymentSettings"
- ]
- """
- Payment settings to pass to invoices created by the subscription.
- """
- pending_invoice_item_interval: NotRequired[
- "Literal['']|Subscription.ModifyParamsPendingInvoiceItemInterval"
- ]
- """
- Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
- """
- proration_date: NotRequired[int]
- """
- If set, prorations will be calculated as though the subscription was updated at the given time. This can be used to apply exactly the same prorations that were previewed with the [create preview](https://stripe.com/docs/api/invoices/create_preview) endpoint. `proration_date` can also be used to implement custom proration logic, such as prorating by day instead of by second, by providing the time that you wish to use for proration calculations.
- """
- transfer_data: NotRequired[
- "Literal['']|Subscription.ModifyParamsTransferData"
- ]
- """
- If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges. This will be unset if you POST an empty value.
- """
- trial_end: NotRequired["Literal['now']|int"]
- """
- Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, `trial_end` will override the default trial period of the plan the customer is being subscribed to. The `billing_cycle_anchor` will be updated to the `trial_end` value. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`.
- """
- trial_from_plan: NotRequired[bool]
- """
- Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
- """
- trial_settings: NotRequired["Subscription.ModifyParamsTrialSettings"]
- """
- Settings related to subscription trials.
- """
-
- class ModifyParamsAddInvoiceItem(TypedDict):
- discounts: NotRequired[
- List["Subscription.ModifyParamsAddInvoiceItemDiscount"]
- ]
- """
- The coupons to redeem into discounts for the item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired["Subscription.ModifyParamsAddInvoiceItemPeriod"]
- """
- The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired[
- "Subscription.ModifyParamsAddInvoiceItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item. Defaults to 1.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
- """
-
- class ModifyParamsAddInvoiceItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class ModifyParamsAddInvoiceItemPeriod(TypedDict):
- end: "Subscription.ModifyParamsAddInvoiceItemPeriodEnd"
- """
- End of the invoice item period.
- """
- start: "Subscription.ModifyParamsAddInvoiceItemPeriodStart"
- """
- Start of the invoice item period.
- """
-
- class ModifyParamsAddInvoiceItemPeriodEnd(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
- """
- type: Literal["min_item_period_end", "timestamp"]
- """
- Select how to calculate the end of the invoice item period.
- """
-
- class ModifyParamsAddInvoiceItemPeriodStart(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
- """
- type: Literal["max_item_period_start", "now", "timestamp"]
- """
- Select how to calculate the start of the invoice item period.
- """
-
- class ModifyParamsAddInvoiceItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class ModifyParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
- liability: NotRequired[
- "Subscription.ModifyParamsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class ModifyParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class ModifyParamsBillingThresholds(TypedDict):
- amount_gte: NotRequired[int]
- """
- Monetary threshold that triggers the subscription to advance to a new billing period
- """
- reset_billing_cycle_anchor: NotRequired[bool]
- """
- Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
- """
-
- class ModifyParamsCancellationDetails(TypedDict):
- comment: NotRequired["Literal['']|str"]
- """
- Additional comments about why the user canceled the subscription, if the subscription was canceled explicitly by the user.
- """
- feedback: NotRequired[
- "Literal['']|Literal['customer_service', 'low_quality', 'missing_features', 'other', 'switched_service', 'too_complex', 'too_expensive', 'unused']"
- ]
- """
- The customer submitted reason for why they canceled, if the subscription was canceled explicitly by the user.
- """
-
- class ModifyParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class ModifyParamsInvoiceSettings(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the subscription. Will be set on invoices generated by the subscription.
- """
- issuer: NotRequired["Subscription.ModifyParamsInvoiceSettingsIssuer"]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class ModifyParamsInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class ModifyParamsItem(TypedDict):
- billing_thresholds: NotRequired[
- "Literal['']|Subscription.ModifyParamsItemBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- clear_usage: NotRequired[bool]
- """
- Delete all usage for a given subscription item. You must pass this when deleting a usage records subscription item. `clear_usage` has no effect if the plan has a billing meter attached.
- """
- deleted: NotRequired[bool]
- """
- A flag that, if set to `true`, will delete the specified item.
- """
- discounts: NotRequired[
- "Literal['']|List[Subscription.ModifyParamsItemDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- id: NotRequired[str]
- """
- Subscription item to update.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- plan: NotRequired[str]
- """
- Plan ID for this item, as a string.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
- """
- price_data: NotRequired["Subscription.ModifyParamsItemPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class ModifyParamsItemBillingThresholds(TypedDict):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class ModifyParamsItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class ModifyParamsItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: "Subscription.ModifyParamsItemPriceDataRecurring"
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class ModifyParamsItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class ModifyParamsPauseCollection(TypedDict):
- behavior: Literal["keep_as_draft", "mark_uncollectible", "void"]
- """
- The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
- """
- resumes_at: NotRequired[int]
- """
- The time after which the subscription will resume collecting payments.
- """
-
- class ModifyParamsPaymentSettings(TypedDict):
- payment_method_options: NotRequired[
- "Subscription.ModifyParamsPaymentSettingsPaymentMethodOptions"
- ]
- """
- Payment-method-specific configuration to provide to invoices created by the subscription.
- """
- payment_method_types: NotRequired[
- "Literal['']|List[Literal['ach_credit_transfer', 'ach_debit', 'acss_debit', 'affirm', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'jp_credit_transfer', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'link', 'multibanco', 'naver_pay', 'nz_bank_account', 'p24', 'payco', 'paynow', 'paypal', 'promptpay', 'revolut_pay', 'sepa_credit_transfer', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
- ]
- """
- The list of payment method types (e.g. card) to provide to the invoice's PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice's default payment method, the subscription's default payment method, the customer's default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice). Should not be specified with payment_method_configuration
- """
- save_default_payment_method: NotRequired[
- Literal["off", "on_subscription"]
- ]
- """
- Configure whether Stripe updates `subscription.default_payment_method` when payment succeeds. Defaults to `off` if unspecified.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "Literal['']|Subscription.ModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebit"
- ]
- """
- This sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice's PaymentIntent.
- """
- bancontact: NotRequired[
- "Literal['']|Subscription.ModifyParamsPaymentSettingsPaymentMethodOptionsBancontact"
- ]
- """
- This sub-hash contains details about the Bancontact payment method options to pass to the invoice's PaymentIntent.
- """
- card: NotRequired[
- "Literal['']|Subscription.ModifyParamsPaymentSettingsPaymentMethodOptionsCard"
- ]
- """
- This sub-hash contains details about the Card payment method options to pass to the invoice's PaymentIntent.
- """
- customer_balance: NotRequired[
- "Literal['']|Subscription.ModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalance"
- ]
- """
- This sub-hash contains details about the Bank transfer payment method options to pass to the invoice's PaymentIntent.
- """
- konbini: NotRequired[
- "Literal['']|Subscription.ModifyParamsPaymentSettingsPaymentMethodOptionsKonbini"
- ]
- """
- This sub-hash contains details about the Konbini payment method options to pass to the invoice's PaymentIntent.
- """
- sepa_debit: NotRequired[
- "Literal['']|Subscription.ModifyParamsPaymentSettingsPaymentMethodOptionsSepaDebit"
- ]
- """
- This sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice's PaymentIntent.
- """
- us_bank_account: NotRequired[
- "Literal['']|Subscription.ModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccount"
- ]
- """
- This sub-hash contains details about the ACH direct debit payment method options to pass to the invoice's PaymentIntent.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebit(TypedDict):
- mandate_options: NotRequired[
- "Subscription.ModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions(
- TypedDict,
- ):
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsBancontact(TypedDict):
- preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
- """
- Preferred language of the Bancontact authorization page that the customer is redirected to.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsCard(TypedDict):
- mandate_options: NotRequired[
- "Subscription.ModifyParamsPaymentSettingsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this Subscription on. Depends on the available networks of the card attached to the Subscription. Can be only set confirm-time.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsCardMandateOptions(
- TypedDict,
- ):
- amount: NotRequired[int]
- """
- Amount to be charged for future payments.
- """
- amount_type: NotRequired[Literal["fixed", "maximum"]]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalance(
- TypedDict,
- ):
- bank_transfer: NotRequired[
- "Subscription.ModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[str]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "Subscription.ModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for eu_bank_transfer funding type.
- """
- type: NotRequired[str]
- """
- The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsKonbini(TypedDict):
- pass
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsSepaDebit(TypedDict):
- pass
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccount(
- TypedDict,
- ):
- financial_connections: NotRequired[
- "Subscription.ModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "Subscription.ModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
-
- class ModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class ModifyParamsPendingInvoiceItemInterval(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies invoicing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks).
- """
-
- class ModifyParamsTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class ModifyParamsTrialSettings(TypedDict):
- end_behavior: "Subscription.ModifyParamsTrialSettingsEndBehavior"
- """
- Defines how the subscription should behave when the user's free trial ends.
- """
-
- class ModifyParamsTrialSettingsEndBehavior(TypedDict):
- missing_payment_method: Literal["cancel", "create_invoice", "pause"]
- """
- Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
- """
-
- class ResumeParams(RequestOptions):
- billing_cycle_anchor: NotRequired[Literal["now", "unchanged"]]
- """
- The billing cycle anchor that applies when the subscription is resumed. Either `now` or `unchanged`. The default is `now`. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) resulting from the `billing_cycle_anchor` being `unchanged`. When the `billing_cycle_anchor` is set to `now` (default value), no prorations are generated. If no value is passed, the default is `create_prorations`.
- """
- proration_date: NotRequired[int]
- """
- If set, prorations will be calculated as though the subscription was resumed at the given time. This can be used to apply exactly the same prorations that were previewed with the [create preview](https://stripe.com/docs/api/invoices/create_preview) endpoint.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SearchParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- page: NotRequired[str]
- """
- A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
- """
- query: str
- """
- The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for subscriptions](https://stripe.com/docs/search#query-fields-for-subscriptions).
- """
-
application: Optional[ExpandableField["Application"]]
"""
ID of the Connect Application that created the subscription.
@@ -2406,7 +708,7 @@ class SearchParams(RequestOptions):
def _cls_cancel(
cls,
subscription_exposed_id: str,
- **params: Unpack["Subscription.CancelParams"],
+ **params: Unpack["SubscriptionCancelParams"],
) -> "Subscription":
"""
Cancels a customer's subscription immediately. The customer won't be charged again for the subscription. After it's canceled, you can no longer update the subscription or its [metadata](https://docs.stripe.com/metadata).
@@ -2432,7 +734,7 @@ def _cls_cancel(
@staticmethod
def cancel(
subscription_exposed_id: str,
- **params: Unpack["Subscription.CancelParams"],
+ **params: Unpack["SubscriptionCancelParams"],
) -> "Subscription":
"""
Cancels a customer's subscription immediately. The customer won't be charged again for the subscription. After it's canceled, you can no longer update the subscription or its [metadata](https://docs.stripe.com/metadata).
@@ -2445,7 +747,7 @@ def cancel(
@overload
def cancel(
- self, **params: Unpack["Subscription.CancelParams"]
+ self, **params: Unpack["SubscriptionCancelParams"]
) -> "Subscription":
"""
Cancels a customer's subscription immediately. The customer won't be charged again for the subscription. After it's canceled, you can no longer update the subscription or its [metadata](https://docs.stripe.com/metadata).
@@ -2458,7 +760,7 @@ def cancel(
@class_method_variant("_cls_cancel")
def cancel( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Subscription.CancelParams"]
+ self, **params: Unpack["SubscriptionCancelParams"]
) -> "Subscription":
"""
Cancels a customer's subscription immediately. The customer won't be charged again for the subscription. After it's canceled, you can no longer update the subscription or its [metadata](https://docs.stripe.com/metadata).
@@ -2482,7 +784,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_cancel_async(
cls,
subscription_exposed_id: str,
- **params: Unpack["Subscription.CancelParams"],
+ **params: Unpack["SubscriptionCancelParams"],
) -> "Subscription":
"""
Cancels a customer's subscription immediately. The customer won't be charged again for the subscription. After it's canceled, you can no longer update the subscription or its [metadata](https://docs.stripe.com/metadata).
@@ -2508,7 +810,7 @@ async def _cls_cancel_async(
@staticmethod
async def cancel_async(
subscription_exposed_id: str,
- **params: Unpack["Subscription.CancelParams"],
+ **params: Unpack["SubscriptionCancelParams"],
) -> "Subscription":
"""
Cancels a customer's subscription immediately. The customer won't be charged again for the subscription. After it's canceled, you can no longer update the subscription or its [metadata](https://docs.stripe.com/metadata).
@@ -2521,7 +823,7 @@ async def cancel_async(
@overload
async def cancel_async(
- self, **params: Unpack["Subscription.CancelParams"]
+ self, **params: Unpack["SubscriptionCancelParams"]
) -> "Subscription":
"""
Cancels a customer's subscription immediately. The customer won't be charged again for the subscription. After it's canceled, you can no longer update the subscription or its [metadata](https://docs.stripe.com/metadata).
@@ -2534,7 +836,7 @@ async def cancel_async(
@class_method_variant("_cls_cancel_async")
async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Subscription.CancelParams"]
+ self, **params: Unpack["SubscriptionCancelParams"]
) -> "Subscription":
"""
Cancels a customer's subscription immediately. The customer won't be charged again for the subscription. After it's canceled, you can no longer update the subscription or its [metadata](https://docs.stripe.com/metadata).
@@ -2556,7 +858,7 @@ async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def create(
- cls, **params: Unpack["Subscription.CreateParams"]
+ cls, **params: Unpack["SubscriptionCreateParams"]
) -> "Subscription":
"""
Creates a new subscription on an existing customer. Each customer can have up to 500 active or scheduled subscriptions.
@@ -2578,7 +880,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["Subscription.CreateParams"]
+ cls, **params: Unpack["SubscriptionCreateParams"]
) -> "Subscription":
"""
Creates a new subscription on an existing customer. Each customer can have up to 500 active or scheduled subscriptions.
@@ -2602,7 +904,7 @@ async def create_async(
def _cls_delete_discount(
cls,
subscription_exposed_id: str,
- **params: Unpack["Subscription.DeleteDiscountParams"],
+ **params: Unpack["SubscriptionDeleteDiscountParams"],
) -> "Discount":
"""
Removes the currently applied discount on a subscription.
@@ -2624,7 +926,7 @@ def _cls_delete_discount(
@staticmethod
def delete_discount(
subscription_exposed_id: str,
- **params: Unpack["Subscription.DeleteDiscountParams"],
+ **params: Unpack["SubscriptionDeleteDiscountParams"],
) -> "Discount":
"""
Removes the currently applied discount on a subscription.
@@ -2633,7 +935,7 @@ def delete_discount(
@overload
def delete_discount(
- self, **params: Unpack["Subscription.DeleteDiscountParams"]
+ self, **params: Unpack["SubscriptionDeleteDiscountParams"]
) -> "Discount":
"""
Removes the currently applied discount on a subscription.
@@ -2642,7 +944,7 @@ def delete_discount(
@class_method_variant("_cls_delete_discount")
def delete_discount( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Subscription.DeleteDiscountParams"]
+ self, **params: Unpack["SubscriptionDeleteDiscountParams"]
) -> "Discount":
"""
Removes the currently applied discount on a subscription.
@@ -2662,7 +964,7 @@ def delete_discount( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_delete_discount_async(
cls,
subscription_exposed_id: str,
- **params: Unpack["Subscription.DeleteDiscountParams"],
+ **params: Unpack["SubscriptionDeleteDiscountParams"],
) -> "Discount":
"""
Removes the currently applied discount on a subscription.
@@ -2684,7 +986,7 @@ async def _cls_delete_discount_async(
@staticmethod
async def delete_discount_async(
subscription_exposed_id: str,
- **params: Unpack["Subscription.DeleteDiscountParams"],
+ **params: Unpack["SubscriptionDeleteDiscountParams"],
) -> "Discount":
"""
Removes the currently applied discount on a subscription.
@@ -2693,7 +995,7 @@ async def delete_discount_async(
@overload
async def delete_discount_async(
- self, **params: Unpack["Subscription.DeleteDiscountParams"]
+ self, **params: Unpack["SubscriptionDeleteDiscountParams"]
) -> "Discount":
"""
Removes the currently applied discount on a subscription.
@@ -2702,7 +1004,7 @@ async def delete_discount_async(
@class_method_variant("_cls_delete_discount_async")
async def delete_discount_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Subscription.DeleteDiscountParams"]
+ self, **params: Unpack["SubscriptionDeleteDiscountParams"]
) -> "Discount":
"""
Removes the currently applied discount on a subscription.
@@ -2720,7 +1022,7 @@ async def delete_discount_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["Subscription.ListParams"]
+ cls, **params: Unpack["SubscriptionListParams"]
) -> ListObject["Subscription"]:
"""
By default, returns a list of subscriptions that have not been canceled. In order to list canceled subscriptions, specify status=canceled.
@@ -2740,7 +1042,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Subscription.ListParams"]
+ cls, **params: Unpack["SubscriptionListParams"]
) -> ListObject["Subscription"]:
"""
By default, returns a list of subscriptions that have not been canceled. In order to list canceled subscriptions, specify status=canceled.
@@ -2760,7 +1062,7 @@ async def list_async(
@classmethod
def _cls_migrate(
- cls, subscription: str, **params: Unpack["Subscription.MigrateParams"]
+ cls, subscription: str, **params: Unpack["SubscriptionMigrateParams"]
) -> "Subscription":
"""
Upgrade the billing_mode of an existing subscription.
@@ -2779,7 +1081,7 @@ def _cls_migrate(
@overload
@staticmethod
def migrate(
- subscription: str, **params: Unpack["Subscription.MigrateParams"]
+ subscription: str, **params: Unpack["SubscriptionMigrateParams"]
) -> "Subscription":
"""
Upgrade the billing_mode of an existing subscription.
@@ -2788,7 +1090,7 @@ def migrate(
@overload
def migrate(
- self, **params: Unpack["Subscription.MigrateParams"]
+ self, **params: Unpack["SubscriptionMigrateParams"]
) -> "Subscription":
"""
Upgrade the billing_mode of an existing subscription.
@@ -2797,7 +1099,7 @@ def migrate(
@class_method_variant("_cls_migrate")
def migrate( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Subscription.MigrateParams"]
+ self, **params: Unpack["SubscriptionMigrateParams"]
) -> "Subscription":
"""
Upgrade the billing_mode of an existing subscription.
@@ -2815,7 +1117,7 @@ def migrate( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_migrate_async(
- cls, subscription: str, **params: Unpack["Subscription.MigrateParams"]
+ cls, subscription: str, **params: Unpack["SubscriptionMigrateParams"]
) -> "Subscription":
"""
Upgrade the billing_mode of an existing subscription.
@@ -2834,7 +1136,7 @@ async def _cls_migrate_async(
@overload
@staticmethod
async def migrate_async(
- subscription: str, **params: Unpack["Subscription.MigrateParams"]
+ subscription: str, **params: Unpack["SubscriptionMigrateParams"]
) -> "Subscription":
"""
Upgrade the billing_mode of an existing subscription.
@@ -2843,7 +1145,7 @@ async def migrate_async(
@overload
async def migrate_async(
- self, **params: Unpack["Subscription.MigrateParams"]
+ self, **params: Unpack["SubscriptionMigrateParams"]
) -> "Subscription":
"""
Upgrade the billing_mode of an existing subscription.
@@ -2852,7 +1154,7 @@ async def migrate_async(
@class_method_variant("_cls_migrate_async")
async def migrate_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Subscription.MigrateParams"]
+ self, **params: Unpack["SubscriptionMigrateParams"]
) -> "Subscription":
"""
Upgrade the billing_mode of an existing subscription.
@@ -2870,7 +1172,7 @@ async def migrate_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def modify(
- cls, id: str, **params: Unpack["Subscription.ModifyParams"]
+ cls, id: str, **params: Unpack["SubscriptionModifyParams"]
) -> "Subscription":
"""
Updates an existing subscription to match the specified parameters.
@@ -2907,7 +1209,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Subscription.ModifyParams"]
+ cls, id: str, **params: Unpack["SubscriptionModifyParams"]
) -> "Subscription":
"""
Updates an existing subscription to match the specified parameters.
@@ -2944,7 +1246,7 @@ async def modify_async(
@classmethod
def _cls_resume(
- cls, subscription: str, **params: Unpack["Subscription.ResumeParams"]
+ cls, subscription: str, **params: Unpack["SubscriptionResumeParams"]
) -> "Subscription":
"""
Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. If a resumption invoice is generated, it must be paid or marked uncollectible before the subscription will be unpaused. If payment succeeds the subscription will become active, and if payment fails the subscription will be past_due. The resumption invoice will void automatically if not paid by the expiration date.
@@ -2963,7 +1265,7 @@ def _cls_resume(
@overload
@staticmethod
def resume(
- subscription: str, **params: Unpack["Subscription.ResumeParams"]
+ subscription: str, **params: Unpack["SubscriptionResumeParams"]
) -> "Subscription":
"""
Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. If a resumption invoice is generated, it must be paid or marked uncollectible before the subscription will be unpaused. If payment succeeds the subscription will become active, and if payment fails the subscription will be past_due. The resumption invoice will void automatically if not paid by the expiration date.
@@ -2972,7 +1274,7 @@ def resume(
@overload
def resume(
- self, **params: Unpack["Subscription.ResumeParams"]
+ self, **params: Unpack["SubscriptionResumeParams"]
) -> "Subscription":
"""
Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. If a resumption invoice is generated, it must be paid or marked uncollectible before the subscription will be unpaused. If payment succeeds the subscription will become active, and if payment fails the subscription will be past_due. The resumption invoice will void automatically if not paid by the expiration date.
@@ -2981,7 +1283,7 @@ def resume(
@class_method_variant("_cls_resume")
def resume( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Subscription.ResumeParams"]
+ self, **params: Unpack["SubscriptionResumeParams"]
) -> "Subscription":
"""
Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. If a resumption invoice is generated, it must be paid or marked uncollectible before the subscription will be unpaused. If payment succeeds the subscription will become active, and if payment fails the subscription will be past_due. The resumption invoice will void automatically if not paid by the expiration date.
@@ -2999,7 +1301,7 @@ def resume( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_resume_async(
- cls, subscription: str, **params: Unpack["Subscription.ResumeParams"]
+ cls, subscription: str, **params: Unpack["SubscriptionResumeParams"]
) -> "Subscription":
"""
Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. If a resumption invoice is generated, it must be paid or marked uncollectible before the subscription will be unpaused. If payment succeeds the subscription will become active, and if payment fails the subscription will be past_due. The resumption invoice will void automatically if not paid by the expiration date.
@@ -3018,7 +1320,7 @@ async def _cls_resume_async(
@overload
@staticmethod
async def resume_async(
- subscription: str, **params: Unpack["Subscription.ResumeParams"]
+ subscription: str, **params: Unpack["SubscriptionResumeParams"]
) -> "Subscription":
"""
Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. If a resumption invoice is generated, it must be paid or marked uncollectible before the subscription will be unpaused. If payment succeeds the subscription will become active, and if payment fails the subscription will be past_due. The resumption invoice will void automatically if not paid by the expiration date.
@@ -3027,7 +1329,7 @@ async def resume_async(
@overload
async def resume_async(
- self, **params: Unpack["Subscription.ResumeParams"]
+ self, **params: Unpack["SubscriptionResumeParams"]
) -> "Subscription":
"""
Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. If a resumption invoice is generated, it must be paid or marked uncollectible before the subscription will be unpaused. If payment succeeds the subscription will become active, and if payment fails the subscription will be past_due. The resumption invoice will void automatically if not paid by the expiration date.
@@ -3036,7 +1338,7 @@ async def resume_async(
@class_method_variant("_cls_resume_async")
async def resume_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Subscription.ResumeParams"]
+ self, **params: Unpack["SubscriptionResumeParams"]
) -> "Subscription":
"""
Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. If a resumption invoice is generated, it must be paid or marked uncollectible before the subscription will be unpaused. If payment succeeds the subscription will become active, and if payment fails the subscription will be past_due. The resumption invoice will void automatically if not paid by the expiration date.
@@ -3054,7 +1356,7 @@ async def resume_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Subscription.RetrieveParams"]
+ cls, id: str, **params: Unpack["SubscriptionRetrieveParams"]
) -> "Subscription":
"""
Retrieves the subscription with the given ID.
@@ -3065,7 +1367,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Subscription.RetrieveParams"]
+ cls, id: str, **params: Unpack["SubscriptionRetrieveParams"]
) -> "Subscription":
"""
Retrieves the subscription with the given ID.
@@ -3076,7 +1378,7 @@ async def retrieve_async(
@classmethod
def search(
- cls, *args, **kwargs: Unpack["Subscription.SearchParams"]
+ cls, *args, **kwargs: Unpack["SubscriptionSearchParams"]
) -> SearchResultObject["Subscription"]:
"""
Search for subscriptions you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
@@ -3090,7 +1392,7 @@ def search(
@classmethod
async def search_async(
- cls, *args, **kwargs: Unpack["Subscription.SearchParams"]
+ cls, *args, **kwargs: Unpack["SubscriptionSearchParams"]
) -> SearchResultObject["Subscription"]:
"""
Search for subscriptions you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
@@ -3104,13 +1406,13 @@ async def search_async(
@classmethod
def search_auto_paging_iter(
- cls, *args, **kwargs: Unpack["Subscription.SearchParams"]
+ cls, *args, **kwargs: Unpack["SubscriptionSearchParams"]
) -> Iterator["Subscription"]:
return cls.search(*args, **kwargs).auto_paging_iter()
@classmethod
async def search_auto_paging_iter_async(
- cls, *args, **kwargs: Unpack["Subscription.SearchParams"]
+ cls, *args, **kwargs: Unpack["SubscriptionSearchParams"]
) -> AsyncIterator["Subscription"]:
return (await cls.search_async(*args, **kwargs)).auto_paging_iter()
diff --git a/stripe/_subscription_item.py b/stripe/_subscription_item.py
index a8c821bee..939eb0b82 100644
--- a/stripe/_subscription_item.py
+++ b/stripe/_subscription_item.py
@@ -5,24 +5,32 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._discount import Discount
from stripe._plan import Plan
from stripe._price import Price
from stripe._tax_rate import TaxRate
+ from stripe.params._subscription_item_create_params import (
+ SubscriptionItemCreateParams,
+ )
+ from stripe.params._subscription_item_delete_params import (
+ SubscriptionItemDeleteParams,
+ )
+ from stripe.params._subscription_item_list_params import (
+ SubscriptionItemListParams,
+ )
+ from stripe.params._subscription_item_modify_params import (
+ SubscriptionItemModifyParams,
+ )
+ from stripe.params._subscription_item_retrieve_params import (
+ SubscriptionItemRetrieveParams,
+ )
class SubscriptionItem(
@@ -44,312 +52,6 @@ class BillingThresholds(StripeObject):
Usage threshold that triggers the subscription to create an invoice
"""
- class CreateParams(RequestOptions):
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionItem.CreateParamsBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionItem.CreateParamsDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- payment_behavior: NotRequired[
- Literal[
- "allow_incomplete",
- "default_incomplete",
- "error_if_incomplete",
- "pending_if_incomplete",
- ]
- ]
- """
- Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
-
- Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription's invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
-
- Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
-
- Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://docs.stripe.com/changelog/2019-03-14) to learn more.
- """
- plan: NotRequired[str]
- """
- The identifier of the plan to add to the subscription.
- """
- price: NotRequired[str]
- """
- The ID of the price object.
- """
- price_data: NotRequired["SubscriptionItem.CreateParamsPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
- """
- proration_date: NotRequired[int]
- """
- If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
- """
- quantity: NotRequired[int]
- """
- The quantity you'd like to apply to the subscription item you're creating.
- """
- subscription: str
- """
- The identifier of the subscription to modify.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class CreateParamsBillingThresholds(TypedDict):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class CreateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: "SubscriptionItem.CreateParamsPriceDataRecurring"
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class DeleteParams(RequestOptions):
- clear_usage: NotRequired[bool]
- """
- Delete all usage for the given subscription item. Allowed only when the current plan's `usage_type` is `metered`.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
- """
- proration_date: NotRequired[int]
- """
- If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
- """
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- subscription: str
- """
- The ID of the subscription whose items will be retrieved.
- """
-
- class ModifyParams(RequestOptions):
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionItem.ModifyParamsBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionItem.ModifyParamsDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- off_session: NotRequired[bool]
- """
- Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
- """
- payment_behavior: NotRequired[
- Literal[
- "allow_incomplete",
- "default_incomplete",
- "error_if_incomplete",
- "pending_if_incomplete",
- ]
- ]
- """
- Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
-
- Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription's invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
-
- Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
-
- Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://docs.stripe.com/changelog/2019-03-14) to learn more.
- """
- plan: NotRequired[str]
- """
- The identifier of the new plan for this subscription item.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
- """
- price_data: NotRequired["SubscriptionItem.ModifyParamsPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
- """
- proration_date: NotRequired[int]
- """
- If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
- """
- quantity: NotRequired[int]
- """
- The quantity you'd like to apply to the subscription item you're creating.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class ModifyParamsBillingThresholds(TypedDict):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class ModifyParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class ModifyParamsPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: "SubscriptionItem.ModifyParamsPriceDataRecurring"
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class ModifyParamsPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
billing_thresholds: Optional[BillingThresholds]
"""
Define thresholds at which an invoice will be sent, and the related subscription advanced to a new billing period
@@ -421,7 +123,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["SubscriptionItem.CreateParams"]
+ cls, **params: Unpack["SubscriptionItemCreateParams"]
) -> "SubscriptionItem":
"""
Adds a new item to an existing subscription. No existing items will be changed or replaced.
@@ -437,7 +139,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["SubscriptionItem.CreateParams"]
+ cls, **params: Unpack["SubscriptionItemCreateParams"]
) -> "SubscriptionItem":
"""
Adds a new item to an existing subscription. No existing items will be changed or replaced.
@@ -453,7 +155,7 @@ async def create_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["SubscriptionItem.DeleteParams"]
+ cls, sid: str, **params: Unpack["SubscriptionItemDeleteParams"]
) -> "SubscriptionItem":
"""
Deletes an item from the subscription. Removing a subscription item from a subscription will not cancel the subscription.
@@ -471,7 +173,7 @@ def _cls_delete(
@overload
@staticmethod
def delete(
- sid: str, **params: Unpack["SubscriptionItem.DeleteParams"]
+ sid: str, **params: Unpack["SubscriptionItemDeleteParams"]
) -> "SubscriptionItem":
"""
Deletes an item from the subscription. Removing a subscription item from a subscription will not cancel the subscription.
@@ -480,7 +182,7 @@ def delete(
@overload
def delete(
- self, **params: Unpack["SubscriptionItem.DeleteParams"]
+ self, **params: Unpack["SubscriptionItemDeleteParams"]
) -> "SubscriptionItem":
"""
Deletes an item from the subscription. Removing a subscription item from a subscription will not cancel the subscription.
@@ -489,7 +191,7 @@ def delete(
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["SubscriptionItem.DeleteParams"]
+ self, **params: Unpack["SubscriptionItemDeleteParams"]
) -> "SubscriptionItem":
"""
Deletes an item from the subscription. Removing a subscription item from a subscription will not cancel the subscription.
@@ -502,7 +204,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["SubscriptionItem.DeleteParams"]
+ cls, sid: str, **params: Unpack["SubscriptionItemDeleteParams"]
) -> "SubscriptionItem":
"""
Deletes an item from the subscription. Removing a subscription item from a subscription will not cancel the subscription.
@@ -520,7 +222,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["SubscriptionItem.DeleteParams"]
+ sid: str, **params: Unpack["SubscriptionItemDeleteParams"]
) -> "SubscriptionItem":
"""
Deletes an item from the subscription. Removing a subscription item from a subscription will not cancel the subscription.
@@ -529,7 +231,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["SubscriptionItem.DeleteParams"]
+ self, **params: Unpack["SubscriptionItemDeleteParams"]
) -> "SubscriptionItem":
"""
Deletes an item from the subscription. Removing a subscription item from a subscription will not cancel the subscription.
@@ -538,7 +240,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["SubscriptionItem.DeleteParams"]
+ self, **params: Unpack["SubscriptionItemDeleteParams"]
) -> "SubscriptionItem":
"""
Deletes an item from the subscription. Removing a subscription item from a subscription will not cancel the subscription.
@@ -551,7 +253,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["SubscriptionItem.ListParams"]
+ cls, **params: Unpack["SubscriptionItemListParams"]
) -> ListObject["SubscriptionItem"]:
"""
Returns a list of your subscription items for a given subscription.
@@ -571,7 +273,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["SubscriptionItem.ListParams"]
+ cls, **params: Unpack["SubscriptionItemListParams"]
) -> ListObject["SubscriptionItem"]:
"""
Returns a list of your subscription items for a given subscription.
@@ -591,7 +293,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["SubscriptionItem.ModifyParams"]
+ cls, id: str, **params: Unpack["SubscriptionItemModifyParams"]
) -> "SubscriptionItem":
"""
Updates the plan or quantity of an item on a current subscription.
@@ -608,7 +310,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["SubscriptionItem.ModifyParams"]
+ cls, id: str, **params: Unpack["SubscriptionItemModifyParams"]
) -> "SubscriptionItem":
"""
Updates the plan or quantity of an item on a current subscription.
@@ -625,7 +327,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["SubscriptionItem.RetrieveParams"]
+ cls, id: str, **params: Unpack["SubscriptionItemRetrieveParams"]
) -> "SubscriptionItem":
"""
Retrieves the subscription item with the given ID.
@@ -636,7 +338,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["SubscriptionItem.RetrieveParams"]
+ cls, id: str, **params: Unpack["SubscriptionItemRetrieveParams"]
) -> "SubscriptionItem":
"""
Retrieves the subscription item with the given ID.
diff --git a/stripe/_subscription_item_service.py b/stripe/_subscription_item_service.py
index 07620fc28..fc930d4a3 100644
--- a/stripe/_subscription_item_service.py
+++ b/stripe/_subscription_item_service.py
@@ -5,325 +5,32 @@
from stripe._stripe_service import StripeService
from stripe._subscription_item import SubscriptionItem
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._subscription_item_create_params import (
+ SubscriptionItemCreateParams,
+ )
+ from stripe.params._subscription_item_delete_params import (
+ SubscriptionItemDeleteParams,
+ )
+ from stripe.params._subscription_item_list_params import (
+ SubscriptionItemListParams,
+ )
+ from stripe.params._subscription_item_retrieve_params import (
+ SubscriptionItemRetrieveParams,
+ )
+ from stripe.params._subscription_item_update_params import (
+ SubscriptionItemUpdateParams,
+ )
class SubscriptionItemService(StripeService):
- class CreateParams(TypedDict):
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionItemService.CreateParamsBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionItemService.CreateParamsDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- payment_behavior: NotRequired[
- Literal[
- "allow_incomplete",
- "default_incomplete",
- "error_if_incomplete",
- "pending_if_incomplete",
- ]
- ]
- """
- Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
-
- Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription's invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
-
- Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
-
- Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://docs.stripe.com/changelog/2019-03-14) to learn more.
- """
- plan: NotRequired[str]
- """
- The identifier of the plan to add to the subscription.
- """
- price: NotRequired[str]
- """
- The ID of the price object.
- """
- price_data: NotRequired[
- "SubscriptionItemService.CreateParamsPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
- """
- proration_date: NotRequired[int]
- """
- If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
- """
- quantity: NotRequired[int]
- """
- The quantity you'd like to apply to the subscription item you're creating.
- """
- subscription: str
- """
- The identifier of the subscription to modify.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class CreateParamsBillingThresholds(TypedDict):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class CreateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: "SubscriptionItemService.CreateParamsPriceDataRecurring"
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class DeleteParams(TypedDict):
- clear_usage: NotRequired[bool]
- """
- Delete all usage for the given subscription item. Allowed only when the current plan's `usage_type` is `metered`.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
- """
- proration_date: NotRequired[int]
- """
- If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
- """
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- subscription: str
- """
- The ID of the subscription whose items will be retrieved.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionItemService.UpdateParamsBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionItemService.UpdateParamsDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- off_session: NotRequired[bool]
- """
- Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
- """
- payment_behavior: NotRequired[
- Literal[
- "allow_incomplete",
- "default_incomplete",
- "error_if_incomplete",
- "pending_if_incomplete",
- ]
- ]
- """
- Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
-
- Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription's invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
-
- Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
-
- Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://docs.stripe.com/changelog/2019-03-14) to learn more.
- """
- plan: NotRequired[str]
- """
- The identifier of the new plan for this subscription item.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
- """
- price_data: NotRequired[
- "SubscriptionItemService.UpdateParamsPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
- """
- proration_date: NotRequired[int]
- """
- If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
- """
- quantity: NotRequired[int]
- """
- The quantity you'd like to apply to the subscription item you're creating.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class UpdateParamsBillingThresholds(TypedDict):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class UpdateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class UpdateParamsPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: "SubscriptionItemService.UpdateParamsPriceDataRecurring"
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class UpdateParamsPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
def delete(
self,
item: str,
- params: Optional["SubscriptionItemService.DeleteParams"] = None,
+ params: Optional["SubscriptionItemDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionItem:
"""
@@ -343,7 +50,7 @@ def delete(
async def delete_async(
self,
item: str,
- params: Optional["SubscriptionItemService.DeleteParams"] = None,
+ params: Optional["SubscriptionItemDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionItem:
"""
@@ -363,7 +70,7 @@ async def delete_async(
def retrieve(
self,
item: str,
- params: Optional["SubscriptionItemService.RetrieveParams"] = None,
+ params: Optional["SubscriptionItemRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionItem:
"""
@@ -383,7 +90,7 @@ def retrieve(
async def retrieve_async(
self,
item: str,
- params: Optional["SubscriptionItemService.RetrieveParams"] = None,
+ params: Optional["SubscriptionItemRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionItem:
"""
@@ -403,7 +110,7 @@ async def retrieve_async(
def update(
self,
item: str,
- params: Optional["SubscriptionItemService.UpdateParams"] = None,
+ params: Optional["SubscriptionItemUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionItem:
"""
@@ -423,7 +130,7 @@ def update(
async def update_async(
self,
item: str,
- params: Optional["SubscriptionItemService.UpdateParams"] = None,
+ params: Optional["SubscriptionItemUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionItem:
"""
@@ -442,7 +149,7 @@ async def update_async(
def list(
self,
- params: "SubscriptionItemService.ListParams",
+ params: "SubscriptionItemListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[SubscriptionItem]:
"""
@@ -461,7 +168,7 @@ def list(
async def list_async(
self,
- params: "SubscriptionItemService.ListParams",
+ params: "SubscriptionItemListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[SubscriptionItem]:
"""
@@ -480,7 +187,7 @@ async def list_async(
def create(
self,
- params: "SubscriptionItemService.CreateParams",
+ params: "SubscriptionItemCreateParams",
options: Optional[RequestOptions] = None,
) -> SubscriptionItem:
"""
@@ -499,7 +206,7 @@ def create(
async def create_async(
self,
- params: "SubscriptionItemService.CreateParams",
+ params: "SubscriptionItemCreateParams",
options: Optional[RequestOptions] = None,
) -> SubscriptionItem:
"""
diff --git a/stripe/_subscription_schedule.py b/stripe/_subscription_schedule.py
index f3bc9694b..3a2279d16 100644
--- a/stripe/_subscription_schedule.py
+++ b/stripe/_subscription_schedule.py
@@ -4,18 +4,11 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account
@@ -30,6 +23,24 @@
from stripe._subscription import Subscription
from stripe._tax_id import TaxId
from stripe._tax_rate import TaxRate
+ from stripe.params._subscription_schedule_cancel_params import (
+ SubscriptionScheduleCancelParams,
+ )
+ from stripe.params._subscription_schedule_create_params import (
+ SubscriptionScheduleCreateParams,
+ )
+ from stripe.params._subscription_schedule_list_params import (
+ SubscriptionScheduleListParams,
+ )
+ from stripe.params._subscription_schedule_modify_params import (
+ SubscriptionScheduleModifyParams,
+ )
+ from stripe.params._subscription_schedule_release_params import (
+ SubscriptionScheduleReleaseParams,
+ )
+ from stripe.params._subscription_schedule_retrieve_params import (
+ SubscriptionScheduleRetrieveParams,
+ )
from stripe.test_helpers._test_clock import TestClock
@@ -487,1298 +498,6 @@ class TransferData(StripeObject):
"transfer_data": TransferData,
}
- class CancelParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_now: NotRequired[bool]
- """
- If the subscription schedule is `active`, indicates if a final invoice will be generated that contains any un-invoiced metered usage and new/pending proration invoice items. Defaults to `true`.
- """
- prorate: NotRequired[bool]
- """
- If the subscription schedule is `active`, indicates if the cancellation should be prorated. Defaults to `true`.
- """
-
- class CreateParams(RequestOptions):
- billing_mode: NotRequired[
- "SubscriptionSchedule.CreateParamsBillingMode"
- ]
- """
- Controls how prorations and invoices for subscriptions are calculated and orchestrated.
- """
- customer: NotRequired[str]
- """
- The identifier of the customer to create the subscription schedule for.
- """
- default_settings: NotRequired[
- "SubscriptionSchedule.CreateParamsDefaultSettings"
- ]
- """
- Object representing the subscription schedule's default settings.
- """
- end_behavior: NotRequired[
- Literal["cancel", "none", "release", "renew"]
- ]
- """
- Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- from_subscription: NotRequired[str]
- """
- Migrate an existing subscription to be managed by a subscription schedule. If this parameter is set, a subscription schedule will be created using the subscription's item(s), set to auto-renew using the subscription's interval. When using this parameter, other parameters (such as phase values) cannot be set. To create a subscription schedule with other modifications, we recommend making two separate API calls.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- phases: NotRequired[List["SubscriptionSchedule.CreateParamsPhase"]]
- """
- List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.
- """
- start_date: NotRequired["int|Literal['now']"]
- """
- When the subscription schedule starts. We recommend using `now` so that it starts the subscription immediately. You can also use a Unix timestamp to backdate the subscription so that it starts on a past date, or set a future date for the subscription to start on.
- """
-
- class CreateParamsBillingMode(TypedDict):
- flexible: NotRequired[
- "SubscriptionSchedule.CreateParamsBillingModeFlexible"
- ]
- """
- Configure behavior for flexible billing mode.
- """
- type: Literal["classic", "flexible"]
- """
- Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
- """
-
- class CreateParamsBillingModeFlexible(TypedDict):
- proration_discounts: NotRequired[Literal["included", "itemized"]]
- """
- Controls how invoices and invoice items display proration amounts and discount amounts.
- """
-
- class CreateParamsDefaultSettings(TypedDict):
- application_fee_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- automatic_tax: NotRequired[
- "SubscriptionSchedule.CreateParamsDefaultSettingsAutomaticTax"
- ]
- """
- Default settings for automatic tax computation.
- """
- billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
- """
- Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
- """
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionSchedule.CreateParamsDefaultSettingsBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
- """
- description: NotRequired["Literal['']|str"]
- """
- Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- invoice_settings: NotRequired[
- "SubscriptionSchedule.CreateParamsDefaultSettingsInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account on behalf of which to charge, for each of the associated subscription's invoices.
- """
- transfer_data: NotRequired[
- "Literal['']|SubscriptionSchedule.CreateParamsDefaultSettingsTransferData"
- ]
- """
- The data with which to automatically create a Transfer for each of the associated subscription's invoices.
- """
-
- class CreateParamsDefaultSettingsAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
- liability: NotRequired[
- "SubscriptionSchedule.CreateParamsDefaultSettingsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreateParamsDefaultSettingsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsDefaultSettingsBillingThresholds(TypedDict):
- amount_gte: NotRequired[int]
- """
- Monetary threshold that triggers the subscription to advance to a new billing period
- """
- reset_billing_cycle_anchor: NotRequired[bool]
- """
- Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
- """
-
- class CreateParamsDefaultSettingsInvoiceSettings(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the subscription schedule. Will be set on invoices generated by the subscription schedule.
- """
- days_until_due: NotRequired[int]
- """
- Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `collection_method=charge_automatically`.
- """
- issuer: NotRequired[
- "SubscriptionSchedule.CreateParamsDefaultSettingsInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class CreateParamsDefaultSettingsInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsDefaultSettingsTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class CreateParamsPhase(TypedDict):
- add_invoice_items: NotRequired[
- List["SubscriptionSchedule.CreateParamsPhaseAddInvoiceItem"]
- ]
- """
- A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
- """
- application_fee_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- automatic_tax: NotRequired[
- "SubscriptionSchedule.CreateParamsPhaseAutomaticTax"
- ]
- """
- Automatic tax settings for this phase.
- """
- billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
- """
- Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
- """
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionSchedule.CreateParamsPhaseBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
- """
- description: NotRequired["Literal['']|str"]
- """
- Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionSchedule.CreateParamsPhaseDiscount]"
- ]
- """
- The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
- """
- duration: NotRequired["SubscriptionSchedule.CreateParamsPhaseDuration"]
- """
- The number of intervals the phase should last. If set, `end_date` must not be set.
- """
- end_date: NotRequired[int]
- """
- The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
- """
- invoice_settings: NotRequired[
- "SubscriptionSchedule.CreateParamsPhaseInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- items: List["SubscriptionSchedule.CreateParamsPhaseItem"]
- """
- List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The account on behalf of which to charge, for each of the associated subscription's invoices.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. It's different from the request-level [proration_behavior](https://stripe.com/docs/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration (item price, quantity, etc.) of the current phase.
- """
- transfer_data: NotRequired[
- "SubscriptionSchedule.CreateParamsPhaseTransferData"
- ]
- """
- The data with which to automatically create a Transfer for each of the associated subscription's invoices.
- """
- trial: NotRequired[bool]
- """
- If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
- """
- trial_end: NotRequired[int]
- """
- Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
- """
-
- class CreateParamsPhaseAddInvoiceItem(TypedDict):
- discounts: NotRequired[
- List[
- "SubscriptionSchedule.CreateParamsPhaseAddInvoiceItemDiscount"
- ]
- ]
- """
- The coupons to redeem into discounts for the item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired[
- "SubscriptionSchedule.CreateParamsPhaseAddInvoiceItemPeriod"
- ]
- """
- The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired[
- "SubscriptionSchedule.CreateParamsPhaseAddInvoiceItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item. Defaults to 1.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
- """
-
- class CreateParamsPhaseAddInvoiceItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsPhaseAddInvoiceItemPeriod(TypedDict):
- end: "SubscriptionSchedule.CreateParamsPhaseAddInvoiceItemPeriodEnd"
- """
- End of the invoice item period.
- """
- start: (
- "SubscriptionSchedule.CreateParamsPhaseAddInvoiceItemPeriodStart"
- )
- """
- Start of the invoice item period.
- """
-
- class CreateParamsPhaseAddInvoiceItemPeriodEnd(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
- """
- type: Literal["min_item_period_end", "phase_end", "timestamp"]
- """
- Select how to calculate the end of the invoice item period.
- """
-
- class CreateParamsPhaseAddInvoiceItemPeriodStart(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
- """
- type: Literal["max_item_period_start", "phase_start", "timestamp"]
- """
- Select how to calculate the start of the invoice item period.
- """
-
- class CreateParamsPhaseAddInvoiceItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsPhaseAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
- liability: NotRequired[
- "SubscriptionSchedule.CreateParamsPhaseAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreateParamsPhaseAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsPhaseBillingThresholds(TypedDict):
- amount_gte: NotRequired[int]
- """
- Monetary threshold that triggers the subscription to advance to a new billing period
- """
- reset_billing_cycle_anchor: NotRequired[bool]
- """
- Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
- """
-
- class CreateParamsPhaseDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsPhaseDuration(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies phase duration. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The multiplier applied to the interval.
- """
-
- class CreateParamsPhaseInvoiceSettings(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
- """
- days_until_due: NotRequired[int]
- """
- Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
- """
- issuer: NotRequired[
- "SubscriptionSchedule.CreateParamsPhaseInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class CreateParamsPhaseInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsPhaseItem(TypedDict):
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionSchedule.CreateParamsPhaseItemBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionSchedule.CreateParamsPhaseItemDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
- """
- plan: NotRequired[str]
- """
- The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
- """
- price: NotRequired[str]
- """
- The ID of the price object.
- """
- price_data: NotRequired[
- "SubscriptionSchedule.CreateParamsPhaseItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- quantity: NotRequired[int]
- """
- Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class CreateParamsPhaseItemBillingThresholds(TypedDict):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class CreateParamsPhaseItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsPhaseItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: (
- "SubscriptionSchedule.CreateParamsPhaseItemPriceDataRecurring"
- )
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsPhaseItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class CreateParamsPhaseTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class ListParams(RequestOptions):
- canceled_at: NotRequired[
- "SubscriptionSchedule.ListParamsCanceledAt|int"
- ]
- """
- Only return subscription schedules that were created canceled the given date interval.
- """
- completed_at: NotRequired[
- "SubscriptionSchedule.ListParamsCompletedAt|int"
- ]
- """
- Only return subscription schedules that completed during the given date interval.
- """
- created: NotRequired["SubscriptionSchedule.ListParamsCreated|int"]
- """
- Only return subscription schedules that were created during the given date interval.
- """
- customer: NotRequired[str]
- """
- Only return subscription schedules for the given customer.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- released_at: NotRequired[
- "SubscriptionSchedule.ListParamsReleasedAt|int"
- ]
- """
- Only return subscription schedules that were released during the given date interval.
- """
- scheduled: NotRequired[bool]
- """
- Only return subscription schedules that have not started yet.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCanceledAt(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsCompletedAt(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsReleasedAt(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- default_settings: NotRequired[
- "SubscriptionSchedule.ModifyParamsDefaultSettings"
- ]
- """
- Object representing the subscription schedule's default settings.
- """
- end_behavior: NotRequired[
- Literal["cancel", "none", "release", "renew"]
- ]
- """
- Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- phases: NotRequired[List["SubscriptionSchedule.ModifyParamsPhase"]]
- """
- List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase. Note that past phases can be omitted.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- If the update changes the billing configuration (item price, quantity, etc.) of the current phase, indicates how prorations from this change should be handled. The default value is `create_prorations`.
- """
-
- class ModifyParamsDefaultSettings(TypedDict):
- application_fee_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- automatic_tax: NotRequired[
- "SubscriptionSchedule.ModifyParamsDefaultSettingsAutomaticTax"
- ]
- """
- Default settings for automatic tax computation.
- """
- billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
- """
- Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
- """
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionSchedule.ModifyParamsDefaultSettingsBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
- """
- description: NotRequired["Literal['']|str"]
- """
- Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- invoice_settings: NotRequired[
- "SubscriptionSchedule.ModifyParamsDefaultSettingsInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account on behalf of which to charge, for each of the associated subscription's invoices.
- """
- transfer_data: NotRequired[
- "Literal['']|SubscriptionSchedule.ModifyParamsDefaultSettingsTransferData"
- ]
- """
- The data with which to automatically create a Transfer for each of the associated subscription's invoices.
- """
-
- class ModifyParamsDefaultSettingsAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
- liability: NotRequired[
- "SubscriptionSchedule.ModifyParamsDefaultSettingsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class ModifyParamsDefaultSettingsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class ModifyParamsDefaultSettingsBillingThresholds(TypedDict):
- amount_gte: NotRequired[int]
- """
- Monetary threshold that triggers the subscription to advance to a new billing period
- """
- reset_billing_cycle_anchor: NotRequired[bool]
- """
- Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
- """
-
- class ModifyParamsDefaultSettingsInvoiceSettings(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the subscription schedule. Will be set on invoices generated by the subscription schedule.
- """
- days_until_due: NotRequired[int]
- """
- Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `collection_method=charge_automatically`.
- """
- issuer: NotRequired[
- "SubscriptionSchedule.ModifyParamsDefaultSettingsInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class ModifyParamsDefaultSettingsInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class ModifyParamsDefaultSettingsTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class ModifyParamsPhase(TypedDict):
- add_invoice_items: NotRequired[
- List["SubscriptionSchedule.ModifyParamsPhaseAddInvoiceItem"]
- ]
- """
- A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
- """
- application_fee_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- automatic_tax: NotRequired[
- "SubscriptionSchedule.ModifyParamsPhaseAutomaticTax"
- ]
- """
- Automatic tax settings for this phase.
- """
- billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
- """
- Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
- """
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionSchedule.ModifyParamsPhaseBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
- """
- description: NotRequired["Literal['']|str"]
- """
- Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionSchedule.ModifyParamsPhaseDiscount]"
- ]
- """
- The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
- """
- duration: NotRequired["SubscriptionSchedule.ModifyParamsPhaseDuration"]
- """
- The number of intervals the phase should last. If set, `end_date` must not be set.
- """
- end_date: NotRequired["int|Literal['now']"]
- """
- The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
- """
- invoice_settings: NotRequired[
- "SubscriptionSchedule.ModifyParamsPhaseInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- items: List["SubscriptionSchedule.ModifyParamsPhaseItem"]
- """
- List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The account on behalf of which to charge, for each of the associated subscription's invoices.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. It's different from the request-level [proration_behavior](https://stripe.com/docs/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration (item price, quantity, etc.) of the current phase.
- """
- start_date: NotRequired["int|Literal['now']"]
- """
- The date at which this phase of the subscription schedule starts or `now`. Must be set on the first phase.
- """
- transfer_data: NotRequired[
- "SubscriptionSchedule.ModifyParamsPhaseTransferData"
- ]
- """
- The data with which to automatically create a Transfer for each of the associated subscription's invoices.
- """
- trial: NotRequired[bool]
- """
- If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
- """
- trial_end: NotRequired["int|Literal['now']"]
- """
- Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
- """
-
- class ModifyParamsPhaseAddInvoiceItem(TypedDict):
- discounts: NotRequired[
- List[
- "SubscriptionSchedule.ModifyParamsPhaseAddInvoiceItemDiscount"
- ]
- ]
- """
- The coupons to redeem into discounts for the item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired[
- "SubscriptionSchedule.ModifyParamsPhaseAddInvoiceItemPeriod"
- ]
- """
- The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired[
- "SubscriptionSchedule.ModifyParamsPhaseAddInvoiceItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item. Defaults to 1.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
- """
-
- class ModifyParamsPhaseAddInvoiceItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class ModifyParamsPhaseAddInvoiceItemPeriod(TypedDict):
- end: "SubscriptionSchedule.ModifyParamsPhaseAddInvoiceItemPeriodEnd"
- """
- End of the invoice item period.
- """
- start: (
- "SubscriptionSchedule.ModifyParamsPhaseAddInvoiceItemPeriodStart"
- )
- """
- Start of the invoice item period.
- """
-
- class ModifyParamsPhaseAddInvoiceItemPeriodEnd(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
- """
- type: Literal["min_item_period_end", "phase_end", "timestamp"]
- """
- Select how to calculate the end of the invoice item period.
- """
-
- class ModifyParamsPhaseAddInvoiceItemPeriodStart(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
- """
- type: Literal["max_item_period_start", "phase_start", "timestamp"]
- """
- Select how to calculate the start of the invoice item period.
- """
-
- class ModifyParamsPhaseAddInvoiceItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class ModifyParamsPhaseAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
- liability: NotRequired[
- "SubscriptionSchedule.ModifyParamsPhaseAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class ModifyParamsPhaseAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class ModifyParamsPhaseBillingThresholds(TypedDict):
- amount_gte: NotRequired[int]
- """
- Monetary threshold that triggers the subscription to advance to a new billing period
- """
- reset_billing_cycle_anchor: NotRequired[bool]
- """
- Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
- """
-
- class ModifyParamsPhaseDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class ModifyParamsPhaseDuration(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies phase duration. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The multiplier applied to the interval.
- """
-
- class ModifyParamsPhaseInvoiceSettings(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
- """
- days_until_due: NotRequired[int]
- """
- Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
- """
- issuer: NotRequired[
- "SubscriptionSchedule.ModifyParamsPhaseInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class ModifyParamsPhaseInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class ModifyParamsPhaseItem(TypedDict):
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionSchedule.ModifyParamsPhaseItemBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionSchedule.ModifyParamsPhaseItemDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
- """
- plan: NotRequired[str]
- """
- The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
- """
- price: NotRequired[str]
- """
- The ID of the price object.
- """
- price_data: NotRequired[
- "SubscriptionSchedule.ModifyParamsPhaseItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- quantity: NotRequired[int]
- """
- Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class ModifyParamsPhaseItemBillingThresholds(TypedDict):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class ModifyParamsPhaseItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class ModifyParamsPhaseItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: (
- "SubscriptionSchedule.ModifyParamsPhaseItemPriceDataRecurring"
- )
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class ModifyParamsPhaseItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class ModifyParamsPhaseTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class ReleaseParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- preserve_cancel_date: NotRequired[bool]
- """
- Keep any cancellation on the subscription that the schedule has set
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
application: Optional[ExpandableField["Application"]]
"""
ID of the Connect Application that created the schedule.
@@ -1859,7 +578,7 @@ class RetrieveParams(RequestOptions):
def _cls_cancel(
cls,
schedule: str,
- **params: Unpack["SubscriptionSchedule.CancelParams"],
+ **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.
@@ -1878,7 +597,7 @@ def _cls_cancel(
@overload
@staticmethod
def cancel(
- schedule: str, **params: Unpack["SubscriptionSchedule.CancelParams"]
+ 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.
@@ -1887,7 +606,7 @@ def cancel(
@overload
def cancel(
- self, **params: Unpack["SubscriptionSchedule.CancelParams"]
+ self, **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.
@@ -1896,7 +615,7 @@ def cancel(
@class_method_variant("_cls_cancel")
def cancel( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["SubscriptionSchedule.CancelParams"]
+ self, **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.
@@ -1916,7 +635,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_cancel_async(
cls,
schedule: str,
- **params: Unpack["SubscriptionSchedule.CancelParams"],
+ **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.
@@ -1935,7 +654,7 @@ async def _cls_cancel_async(
@overload
@staticmethod
async def cancel_async(
- schedule: str, **params: Unpack["SubscriptionSchedule.CancelParams"]
+ 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.
@@ -1944,7 +663,7 @@ async def cancel_async(
@overload
async def cancel_async(
- self, **params: Unpack["SubscriptionSchedule.CancelParams"]
+ self, **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.
@@ -1953,7 +672,7 @@ async def cancel_async(
@class_method_variant("_cls_cancel_async")
async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["SubscriptionSchedule.CancelParams"]
+ self, **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.
@@ -1971,7 +690,7 @@ async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def create(
- cls, **params: Unpack["SubscriptionSchedule.CreateParams"]
+ cls, **params: Unpack["SubscriptionScheduleCreateParams"]
) -> "SubscriptionSchedule":
"""
Creates a new subscription schedule object. Each customer can have up to 500 active or scheduled subscriptions.
@@ -1987,7 +706,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["SubscriptionSchedule.CreateParams"]
+ cls, **params: Unpack["SubscriptionScheduleCreateParams"]
) -> "SubscriptionSchedule":
"""
Creates a new subscription schedule object. Each customer can have up to 500 active or scheduled subscriptions.
@@ -2003,7 +722,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["SubscriptionSchedule.ListParams"]
+ cls, **params: Unpack["SubscriptionScheduleListParams"]
) -> ListObject["SubscriptionSchedule"]:
"""
Retrieves the list of your subscription schedules.
@@ -2023,7 +742,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["SubscriptionSchedule.ListParams"]
+ cls, **params: Unpack["SubscriptionScheduleListParams"]
) -> ListObject["SubscriptionSchedule"]:
"""
Retrieves the list of your subscription schedules.
@@ -2043,7 +762,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["SubscriptionSchedule.ModifyParams"]
+ cls, id: str, **params: Unpack["SubscriptionScheduleModifyParams"]
) -> "SubscriptionSchedule":
"""
Updates an existing subscription schedule.
@@ -2060,7 +779,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["SubscriptionSchedule.ModifyParams"]
+ cls, id: str, **params: Unpack["SubscriptionScheduleModifyParams"]
) -> "SubscriptionSchedule":
"""
Updates an existing subscription schedule.
@@ -2079,7 +798,7 @@ async def modify_async(
def _cls_release(
cls,
schedule: str,
- **params: Unpack["SubscriptionSchedule.ReleaseParams"],
+ **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.
@@ -2098,7 +817,7 @@ def _cls_release(
@overload
@staticmethod
def release(
- schedule: str, **params: Unpack["SubscriptionSchedule.ReleaseParams"]
+ 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.
@@ -2107,7 +826,7 @@ def release(
@overload
def release(
- self, **params: Unpack["SubscriptionSchedule.ReleaseParams"]
+ self, **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.
@@ -2116,7 +835,7 @@ def release(
@class_method_variant("_cls_release")
def release( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["SubscriptionSchedule.ReleaseParams"]
+ self, **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.
@@ -2136,7 +855,7 @@ def release( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_release_async(
cls,
schedule: str,
- **params: Unpack["SubscriptionSchedule.ReleaseParams"],
+ **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.
@@ -2155,7 +874,7 @@ async def _cls_release_async(
@overload
@staticmethod
async def release_async(
- schedule: str, **params: Unpack["SubscriptionSchedule.ReleaseParams"]
+ 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.
@@ -2164,7 +883,7 @@ async def release_async(
@overload
async def release_async(
- self, **params: Unpack["SubscriptionSchedule.ReleaseParams"]
+ self, **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.
@@ -2173,7 +892,7 @@ async def release_async(
@class_method_variant("_cls_release_async")
async def release_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["SubscriptionSchedule.ReleaseParams"]
+ self, **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.
@@ -2191,7 +910,7 @@ async def release_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["SubscriptionSchedule.RetrieveParams"]
+ cls, id: str, **params: Unpack["SubscriptionScheduleRetrieveParams"]
) -> "SubscriptionSchedule":
"""
Retrieves the details of an existing subscription schedule. You only need to supply the unique subscription schedule identifier that was returned upon subscription schedule creation.
@@ -2202,7 +921,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["SubscriptionSchedule.RetrieveParams"]
+ cls, id: str, **params: Unpack["SubscriptionScheduleRetrieveParams"]
) -> "SubscriptionSchedule":
"""
Retrieves the details of an existing subscription schedule. You only need to supply the unique subscription schedule identifier that was returned upon subscription schedule creation.
diff --git a/stripe/_subscription_schedule_service.py b/stripe/_subscription_schedule_service.py
index e386ebdfb..c95c766da 100644
--- a/stripe/_subscription_schedule_service.py
+++ b/stripe/_subscription_schedule_service.py
@@ -5,1308 +5,34 @@
from stripe._stripe_service import StripeService
from stripe._subscription_schedule import SubscriptionSchedule
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._subscription_schedule_cancel_params import (
+ SubscriptionScheduleCancelParams,
+ )
+ from stripe.params._subscription_schedule_create_params import (
+ SubscriptionScheduleCreateParams,
+ )
+ from stripe.params._subscription_schedule_list_params import (
+ SubscriptionScheduleListParams,
+ )
+ from stripe.params._subscription_schedule_release_params import (
+ SubscriptionScheduleReleaseParams,
+ )
+ from stripe.params._subscription_schedule_retrieve_params import (
+ SubscriptionScheduleRetrieveParams,
+ )
+ from stripe.params._subscription_schedule_update_params import (
+ SubscriptionScheduleUpdateParams,
+ )
class SubscriptionScheduleService(StripeService):
- class CancelParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_now: NotRequired[bool]
- """
- If the subscription schedule is `active`, indicates if a final invoice will be generated that contains any un-invoiced metered usage and new/pending proration invoice items. Defaults to `true`.
- """
- prorate: NotRequired[bool]
- """
- If the subscription schedule is `active`, indicates if the cancellation should be prorated. Defaults to `true`.
- """
-
- class CreateParams(TypedDict):
- billing_mode: NotRequired[
- "SubscriptionScheduleService.CreateParamsBillingMode"
- ]
- """
- Controls how prorations and invoices for subscriptions are calculated and orchestrated.
- """
- customer: NotRequired[str]
- """
- The identifier of the customer to create the subscription schedule for.
- """
- default_settings: NotRequired[
- "SubscriptionScheduleService.CreateParamsDefaultSettings"
- ]
- """
- Object representing the subscription schedule's default settings.
- """
- end_behavior: NotRequired[
- Literal["cancel", "none", "release", "renew"]
- ]
- """
- Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- from_subscription: NotRequired[str]
- """
- Migrate an existing subscription to be managed by a subscription schedule. If this parameter is set, a subscription schedule will be created using the subscription's item(s), set to auto-renew using the subscription's interval. When using this parameter, other parameters (such as phase values) cannot be set. To create a subscription schedule with other modifications, we recommend making two separate API calls.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- phases: NotRequired[
- List["SubscriptionScheduleService.CreateParamsPhase"]
- ]
- """
- List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.
- """
- start_date: NotRequired["int|Literal['now']"]
- """
- When the subscription schedule starts. We recommend using `now` so that it starts the subscription immediately. You can also use a Unix timestamp to backdate the subscription so that it starts on a past date, or set a future date for the subscription to start on.
- """
-
- class CreateParamsBillingMode(TypedDict):
- flexible: NotRequired[
- "SubscriptionScheduleService.CreateParamsBillingModeFlexible"
- ]
- """
- Configure behavior for flexible billing mode.
- """
- type: Literal["classic", "flexible"]
- """
- Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
- """
-
- class CreateParamsBillingModeFlexible(TypedDict):
- proration_discounts: NotRequired[Literal["included", "itemized"]]
- """
- Controls how invoices and invoice items display proration amounts and discount amounts.
- """
-
- class CreateParamsDefaultSettings(TypedDict):
- application_fee_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- automatic_tax: NotRequired[
- "SubscriptionScheduleService.CreateParamsDefaultSettingsAutomaticTax"
- ]
- """
- Default settings for automatic tax computation.
- """
- billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
- """
- Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
- """
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionScheduleService.CreateParamsDefaultSettingsBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
- """
- description: NotRequired["Literal['']|str"]
- """
- Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- invoice_settings: NotRequired[
- "SubscriptionScheduleService.CreateParamsDefaultSettingsInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account on behalf of which to charge, for each of the associated subscription's invoices.
- """
- transfer_data: NotRequired[
- "Literal['']|SubscriptionScheduleService.CreateParamsDefaultSettingsTransferData"
- ]
- """
- The data with which to automatically create a Transfer for each of the associated subscription's invoices.
- """
-
- class CreateParamsDefaultSettingsAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
- liability: NotRequired[
- "SubscriptionScheduleService.CreateParamsDefaultSettingsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreateParamsDefaultSettingsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsDefaultSettingsBillingThresholds(TypedDict):
- amount_gte: NotRequired[int]
- """
- Monetary threshold that triggers the subscription to advance to a new billing period
- """
- reset_billing_cycle_anchor: NotRequired[bool]
- """
- Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
- """
-
- class CreateParamsDefaultSettingsInvoiceSettings(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the subscription schedule. Will be set on invoices generated by the subscription schedule.
- """
- days_until_due: NotRequired[int]
- """
- Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `collection_method=charge_automatically`.
- """
- issuer: NotRequired[
- "SubscriptionScheduleService.CreateParamsDefaultSettingsInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class CreateParamsDefaultSettingsInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsDefaultSettingsTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class CreateParamsPhase(TypedDict):
- add_invoice_items: NotRequired[
- List["SubscriptionScheduleService.CreateParamsPhaseAddInvoiceItem"]
- ]
- """
- A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
- """
- application_fee_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- automatic_tax: NotRequired[
- "SubscriptionScheduleService.CreateParamsPhaseAutomaticTax"
- ]
- """
- Automatic tax settings for this phase.
- """
- billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
- """
- Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
- """
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionScheduleService.CreateParamsPhaseBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
- """
- description: NotRequired["Literal['']|str"]
- """
- Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionScheduleService.CreateParamsPhaseDiscount]"
- ]
- """
- The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
- """
- duration: NotRequired[
- "SubscriptionScheduleService.CreateParamsPhaseDuration"
- ]
- """
- The number of intervals the phase should last. If set, `end_date` must not be set.
- """
- end_date: NotRequired[int]
- """
- The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
- """
- invoice_settings: NotRequired[
- "SubscriptionScheduleService.CreateParamsPhaseInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- items: List["SubscriptionScheduleService.CreateParamsPhaseItem"]
- """
- List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The account on behalf of which to charge, for each of the associated subscription's invoices.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. It's different from the request-level [proration_behavior](https://stripe.com/docs/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration (item price, quantity, etc.) of the current phase.
- """
- transfer_data: NotRequired[
- "SubscriptionScheduleService.CreateParamsPhaseTransferData"
- ]
- """
- The data with which to automatically create a Transfer for each of the associated subscription's invoices.
- """
- trial: NotRequired[bool]
- """
- If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
- """
- trial_end: NotRequired[int]
- """
- Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
- """
-
- class CreateParamsPhaseAddInvoiceItem(TypedDict):
- discounts: NotRequired[
- List[
- "SubscriptionScheduleService.CreateParamsPhaseAddInvoiceItemDiscount"
- ]
- ]
- """
- The coupons to redeem into discounts for the item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired[
- "SubscriptionScheduleService.CreateParamsPhaseAddInvoiceItemPeriod"
- ]
- """
- The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired[
- "SubscriptionScheduleService.CreateParamsPhaseAddInvoiceItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item. Defaults to 1.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
- """
-
- class CreateParamsPhaseAddInvoiceItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsPhaseAddInvoiceItemPeriod(TypedDict):
- end: "SubscriptionScheduleService.CreateParamsPhaseAddInvoiceItemPeriodEnd"
- """
- End of the invoice item period.
- """
- start: "SubscriptionScheduleService.CreateParamsPhaseAddInvoiceItemPeriodStart"
- """
- Start of the invoice item period.
- """
-
- class CreateParamsPhaseAddInvoiceItemPeriodEnd(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
- """
- type: Literal["min_item_period_end", "phase_end", "timestamp"]
- """
- Select how to calculate the end of the invoice item period.
- """
-
- class CreateParamsPhaseAddInvoiceItemPeriodStart(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
- """
- type: Literal["max_item_period_start", "phase_start", "timestamp"]
- """
- Select how to calculate the start of the invoice item period.
- """
-
- class CreateParamsPhaseAddInvoiceItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsPhaseAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
- liability: NotRequired[
- "SubscriptionScheduleService.CreateParamsPhaseAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreateParamsPhaseAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsPhaseBillingThresholds(TypedDict):
- amount_gte: NotRequired[int]
- """
- Monetary threshold that triggers the subscription to advance to a new billing period
- """
- reset_billing_cycle_anchor: NotRequired[bool]
- """
- Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
- """
-
- class CreateParamsPhaseDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsPhaseDuration(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies phase duration. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The multiplier applied to the interval.
- """
-
- class CreateParamsPhaseInvoiceSettings(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
- """
- days_until_due: NotRequired[int]
- """
- Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
- """
- issuer: NotRequired[
- "SubscriptionScheduleService.CreateParamsPhaseInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class CreateParamsPhaseInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsPhaseItem(TypedDict):
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionScheduleService.CreateParamsPhaseItemBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionScheduleService.CreateParamsPhaseItemDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
- """
- plan: NotRequired[str]
- """
- The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
- """
- price: NotRequired[str]
- """
- The ID of the price object.
- """
- price_data: NotRequired[
- "SubscriptionScheduleService.CreateParamsPhaseItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- quantity: NotRequired[int]
- """
- Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class CreateParamsPhaseItemBillingThresholds(TypedDict):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class CreateParamsPhaseItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsPhaseItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: "SubscriptionScheduleService.CreateParamsPhaseItemPriceDataRecurring"
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsPhaseItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class CreateParamsPhaseTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class ListParams(TypedDict):
- canceled_at: NotRequired[
- "SubscriptionScheduleService.ListParamsCanceledAt|int"
- ]
- """
- Only return subscription schedules that were created canceled the given date interval.
- """
- completed_at: NotRequired[
- "SubscriptionScheduleService.ListParamsCompletedAt|int"
- ]
- """
- Only return subscription schedules that completed during the given date interval.
- """
- created: NotRequired[
- "SubscriptionScheduleService.ListParamsCreated|int"
- ]
- """
- Only return subscription schedules that were created during the given date interval.
- """
- customer: NotRequired[str]
- """
- Only return subscription schedules for the given customer.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- released_at: NotRequired[
- "SubscriptionScheduleService.ListParamsReleasedAt|int"
- ]
- """
- Only return subscription schedules that were released during the given date interval.
- """
- scheduled: NotRequired[bool]
- """
- Only return subscription schedules that have not started yet.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCanceledAt(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsCompletedAt(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsReleasedAt(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ReleaseParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- preserve_cancel_date: NotRequired[bool]
- """
- Keep any cancellation on the subscription that the schedule has set
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- default_settings: NotRequired[
- "SubscriptionScheduleService.UpdateParamsDefaultSettings"
- ]
- """
- Object representing the subscription schedule's default settings.
- """
- end_behavior: NotRequired[
- Literal["cancel", "none", "release", "renew"]
- ]
- """
- Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- phases: NotRequired[
- List["SubscriptionScheduleService.UpdateParamsPhase"]
- ]
- """
- List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase. Note that past phases can be omitted.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- If the update changes the billing configuration (item price, quantity, etc.) of the current phase, indicates how prorations from this change should be handled. The default value is `create_prorations`.
- """
-
- class UpdateParamsDefaultSettings(TypedDict):
- application_fee_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- automatic_tax: NotRequired[
- "SubscriptionScheduleService.UpdateParamsDefaultSettingsAutomaticTax"
- ]
- """
- Default settings for automatic tax computation.
- """
- billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
- """
- Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
- """
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionScheduleService.UpdateParamsDefaultSettingsBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
- """
- description: NotRequired["Literal['']|str"]
- """
- Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- invoice_settings: NotRequired[
- "SubscriptionScheduleService.UpdateParamsDefaultSettingsInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account on behalf of which to charge, for each of the associated subscription's invoices.
- """
- transfer_data: NotRequired[
- "Literal['']|SubscriptionScheduleService.UpdateParamsDefaultSettingsTransferData"
- ]
- """
- The data with which to automatically create a Transfer for each of the associated subscription's invoices.
- """
-
- class UpdateParamsDefaultSettingsAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
- liability: NotRequired[
- "SubscriptionScheduleService.UpdateParamsDefaultSettingsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class UpdateParamsDefaultSettingsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class UpdateParamsDefaultSettingsBillingThresholds(TypedDict):
- amount_gte: NotRequired[int]
- """
- Monetary threshold that triggers the subscription to advance to a new billing period
- """
- reset_billing_cycle_anchor: NotRequired[bool]
- """
- Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
- """
-
- class UpdateParamsDefaultSettingsInvoiceSettings(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the subscription schedule. Will be set on invoices generated by the subscription schedule.
- """
- days_until_due: NotRequired[int]
- """
- Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `collection_method=charge_automatically`.
- """
- issuer: NotRequired[
- "SubscriptionScheduleService.UpdateParamsDefaultSettingsInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class UpdateParamsDefaultSettingsInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class UpdateParamsDefaultSettingsTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class UpdateParamsPhase(TypedDict):
- add_invoice_items: NotRequired[
- List["SubscriptionScheduleService.UpdateParamsPhaseAddInvoiceItem"]
- ]
- """
- A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
- """
- application_fee_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- automatic_tax: NotRequired[
- "SubscriptionScheduleService.UpdateParamsPhaseAutomaticTax"
- ]
- """
- Automatic tax settings for this phase.
- """
- billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
- """
- Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
- """
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionScheduleService.UpdateParamsPhaseBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
- """
- description: NotRequired["Literal['']|str"]
- """
- Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionScheduleService.UpdateParamsPhaseDiscount]"
- ]
- """
- The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
- """
- duration: NotRequired[
- "SubscriptionScheduleService.UpdateParamsPhaseDuration"
- ]
- """
- The number of intervals the phase should last. If set, `end_date` must not be set.
- """
- end_date: NotRequired["int|Literal['now']"]
- """
- The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
- """
- invoice_settings: NotRequired[
- "SubscriptionScheduleService.UpdateParamsPhaseInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- items: List["SubscriptionScheduleService.UpdateParamsPhaseItem"]
- """
- List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The account on behalf of which to charge, for each of the associated subscription's invoices.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. It's different from the request-level [proration_behavior](https://stripe.com/docs/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration (item price, quantity, etc.) of the current phase.
- """
- start_date: NotRequired["int|Literal['now']"]
- """
- The date at which this phase of the subscription schedule starts or `now`. Must be set on the first phase.
- """
- transfer_data: NotRequired[
- "SubscriptionScheduleService.UpdateParamsPhaseTransferData"
- ]
- """
- The data with which to automatically create a Transfer for each of the associated subscription's invoices.
- """
- trial: NotRequired[bool]
- """
- If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
- """
- trial_end: NotRequired["int|Literal['now']"]
- """
- Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
- """
-
- class UpdateParamsPhaseAddInvoiceItem(TypedDict):
- discounts: NotRequired[
- List[
- "SubscriptionScheduleService.UpdateParamsPhaseAddInvoiceItemDiscount"
- ]
- ]
- """
- The coupons to redeem into discounts for the item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired[
- "SubscriptionScheduleService.UpdateParamsPhaseAddInvoiceItemPeriod"
- ]
- """
- The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired[
- "SubscriptionScheduleService.UpdateParamsPhaseAddInvoiceItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item. Defaults to 1.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
- """
-
- class UpdateParamsPhaseAddInvoiceItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class UpdateParamsPhaseAddInvoiceItemPeriod(TypedDict):
- end: "SubscriptionScheduleService.UpdateParamsPhaseAddInvoiceItemPeriodEnd"
- """
- End of the invoice item period.
- """
- start: "SubscriptionScheduleService.UpdateParamsPhaseAddInvoiceItemPeriodStart"
- """
- Start of the invoice item period.
- """
-
- class UpdateParamsPhaseAddInvoiceItemPeriodEnd(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
- """
- type: Literal["min_item_period_end", "phase_end", "timestamp"]
- """
- Select how to calculate the end of the invoice item period.
- """
-
- class UpdateParamsPhaseAddInvoiceItemPeriodStart(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
- """
- type: Literal["max_item_period_start", "phase_start", "timestamp"]
- """
- Select how to calculate the start of the invoice item period.
- """
-
- class UpdateParamsPhaseAddInvoiceItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class UpdateParamsPhaseAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
- liability: NotRequired[
- "SubscriptionScheduleService.UpdateParamsPhaseAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class UpdateParamsPhaseAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class UpdateParamsPhaseBillingThresholds(TypedDict):
- amount_gte: NotRequired[int]
- """
- Monetary threshold that triggers the subscription to advance to a new billing period
- """
- reset_billing_cycle_anchor: NotRequired[bool]
- """
- Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
- """
-
- class UpdateParamsPhaseDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class UpdateParamsPhaseDuration(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies phase duration. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The multiplier applied to the interval.
- """
-
- class UpdateParamsPhaseInvoiceSettings(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
- """
- days_until_due: NotRequired[int]
- """
- Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
- """
- issuer: NotRequired[
- "SubscriptionScheduleService.UpdateParamsPhaseInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class UpdateParamsPhaseInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class UpdateParamsPhaseItem(TypedDict):
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionScheduleService.UpdateParamsPhaseItemBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionScheduleService.UpdateParamsPhaseItemDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
- """
- plan: NotRequired[str]
- """
- The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
- """
- price: NotRequired[str]
- """
- The ID of the price object.
- """
- price_data: NotRequired[
- "SubscriptionScheduleService.UpdateParamsPhaseItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- quantity: NotRequired[int]
- """
- Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class UpdateParamsPhaseItemBillingThresholds(TypedDict):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class UpdateParamsPhaseItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class UpdateParamsPhaseItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: "SubscriptionScheduleService.UpdateParamsPhaseItemPriceDataRecurring"
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class UpdateParamsPhaseItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class UpdateParamsPhaseTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
def list(
self,
- params: Optional["SubscriptionScheduleService.ListParams"] = None,
+ params: Optional["SubscriptionScheduleListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[SubscriptionSchedule]:
"""
@@ -1325,7 +51,7 @@ def list(
async def list_async(
self,
- params: Optional["SubscriptionScheduleService.ListParams"] = None,
+ params: Optional["SubscriptionScheduleListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[SubscriptionSchedule]:
"""
@@ -1344,7 +70,7 @@ async def list_async(
def create(
self,
- params: Optional["SubscriptionScheduleService.CreateParams"] = None,
+ params: Optional["SubscriptionScheduleCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionSchedule:
"""
@@ -1363,7 +89,7 @@ def create(
async def create_async(
self,
- params: Optional["SubscriptionScheduleService.CreateParams"] = None,
+ params: Optional["SubscriptionScheduleCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionSchedule:
"""
@@ -1383,7 +109,7 @@ async def create_async(
def retrieve(
self,
schedule: str,
- params: Optional["SubscriptionScheduleService.RetrieveParams"] = None,
+ params: Optional["SubscriptionScheduleRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionSchedule:
"""
@@ -1405,7 +131,7 @@ def retrieve(
async def retrieve_async(
self,
schedule: str,
- params: Optional["SubscriptionScheduleService.RetrieveParams"] = None,
+ params: Optional["SubscriptionScheduleRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionSchedule:
"""
@@ -1427,7 +153,7 @@ async def retrieve_async(
def update(
self,
schedule: str,
- params: Optional["SubscriptionScheduleService.UpdateParams"] = None,
+ params: Optional["SubscriptionScheduleUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionSchedule:
"""
@@ -1449,7 +175,7 @@ def update(
async def update_async(
self,
schedule: str,
- params: Optional["SubscriptionScheduleService.UpdateParams"] = None,
+ params: Optional["SubscriptionScheduleUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionSchedule:
"""
@@ -1471,7 +197,7 @@ async def update_async(
def cancel(
self,
schedule: str,
- params: Optional["SubscriptionScheduleService.CancelParams"] = None,
+ params: Optional["SubscriptionScheduleCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionSchedule:
"""
@@ -1493,7 +219,7 @@ def cancel(
async def cancel_async(
self,
schedule: str,
- params: Optional["SubscriptionScheduleService.CancelParams"] = None,
+ params: Optional["SubscriptionScheduleCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionSchedule:
"""
@@ -1515,7 +241,7 @@ async def cancel_async(
def release(
self,
schedule: str,
- params: Optional["SubscriptionScheduleService.ReleaseParams"] = None,
+ params: Optional["SubscriptionScheduleReleaseParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionSchedule:
"""
@@ -1537,7 +263,7 @@ def release(
async def release_async(
self,
schedule: str,
- params: Optional["SubscriptionScheduleService.ReleaseParams"] = None,
+ params: Optional["SubscriptionScheduleReleaseParams"] = None,
options: Optional[RequestOptions] = None,
) -> SubscriptionSchedule:
"""
diff --git a/stripe/_subscription_service.py b/stripe/_subscription_service.py
index df55586de..c19659a4f 100644
--- a/stripe/_subscription_service.py
+++ b/stripe/_subscription_service.py
@@ -7,1765 +7,42 @@
from stripe._stripe_service import StripeService
from stripe._subscription import Subscription
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._subscription_cancel_params import (
+ SubscriptionCancelParams,
+ )
+ from stripe.params._subscription_create_params import (
+ SubscriptionCreateParams,
+ )
+ from stripe.params._subscription_delete_discount_params import (
+ SubscriptionDeleteDiscountParams,
+ )
+ from stripe.params._subscription_list_params import SubscriptionListParams
+ from stripe.params._subscription_migrate_params import (
+ SubscriptionMigrateParams,
+ )
+ from stripe.params._subscription_resume_params import (
+ SubscriptionResumeParams,
+ )
+ from stripe.params._subscription_retrieve_params import (
+ SubscriptionRetrieveParams,
+ )
+ from stripe.params._subscription_search_params import (
+ SubscriptionSearchParams,
+ )
+ from stripe.params._subscription_update_params import (
+ SubscriptionUpdateParams,
+ )
class SubscriptionService(StripeService):
- class CancelParams(TypedDict):
- cancellation_details: NotRequired[
- "SubscriptionService.CancelParamsCancellationDetails"
- ]
- """
- Details about why this subscription was cancelled
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_now: NotRequired[bool]
- """
- Will generate a final invoice that invoices for any un-invoiced metered usage and new/pending proration invoice items. Defaults to `false`.
- """
- prorate: NotRequired[bool]
- """
- Will generate a proration invoice item that credits remaining unused time until the subscription period end. Defaults to `false`.
- """
-
- class CancelParamsCancellationDetails(TypedDict):
- comment: NotRequired["Literal['']|str"]
- """
- Additional comments about why the user canceled the subscription, if the subscription was canceled explicitly by the user.
- """
- feedback: NotRequired[
- "Literal['']|Literal['customer_service', 'low_quality', 'missing_features', 'other', 'switched_service', 'too_complex', 'too_expensive', 'unused']"
- ]
- """
- The customer submitted reason for why they canceled, if the subscription was canceled explicitly by the user.
- """
-
- class CreateParams(TypedDict):
- add_invoice_items: NotRequired[
- List["SubscriptionService.CreateParamsAddInvoiceItem"]
- ]
- """
- A list of prices and quantities that will generate invoice items appended to the next invoice for this subscription. You may pass up to 20 items.
- """
- application_fee_percent: NotRequired["Literal['']|float"]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- automatic_tax: NotRequired[
- "SubscriptionService.CreateParamsAutomaticTax"
- ]
- """
- Automatic tax settings for this subscription.
- """
- backdate_start_date: NotRequired[int]
- """
- A past timestamp to backdate the subscription's start date to. If set, the first invoice will contain line items for the timespan between the start date and the current time. Can be combined with trials and the billing cycle anchor.
- """
- billing_cycle_anchor: NotRequired[int]
- """
- A future timestamp in UTC format to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). The anchor is the reference point that aligns future billing cycle dates. It sets the day of week for `week` intervals, the day of month for `month` and `year` intervals, and the month of year for `year` intervals.
- """
- billing_cycle_anchor_config: NotRequired[
- "SubscriptionService.CreateParamsBillingCycleAnchorConfig"
- ]
- """
- Mutually exclusive with billing_cycle_anchor and only valid with monthly and yearly price intervals. When provided, the billing_cycle_anchor is set to the next occurrence of the day_of_month at the hour, minute, and second UTC.
- """
- billing_mode: NotRequired[
- "SubscriptionService.CreateParamsBillingMode"
- ]
- """
- Controls how prorations and invoices for subscriptions are calculated and orchestrated.
- """
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionService.CreateParamsBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds.
- """
- cancel_at: NotRequired[
- "int|Literal['max_period_end', 'min_period_end']"
- ]
- """
- A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
- """
- cancel_at_period_end: NotRequired[bool]
- """
- Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: str
- """
- The identifier of the customer to subscribe.
- """
- days_until_due: NotRequired[int]
- """
- Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
- """
- default_source: NotRequired[str]
- """
- ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription.
- """
- description: NotRequired[str]
- """
- The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionService.CreateParamsDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription. If not specified or empty, inherits the discount from the subscription's customer.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_settings: NotRequired[
- "SubscriptionService.CreateParamsInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- items: NotRequired[List["SubscriptionService.CreateParamsItem"]]
- """
- A list of up to 20 subscription items, each with an attached price.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- off_session: NotRequired[bool]
- """
- Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account on behalf of which to charge, for each of the subscription's invoices.
- """
- payment_behavior: NotRequired[
- Literal[
- "allow_incomplete",
- "default_incomplete",
- "error_if_incomplete",
- "pending_if_incomplete",
- ]
- ]
- """
- Only applies to subscriptions with `collection_method=charge_automatically`.
-
- Use `allow_incomplete` to create Subscriptions with `status=incomplete` if the first invoice can't be paid. Creating Subscriptions with this status allows you to manage scenarios where additional customer actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
-
- Use `default_incomplete` to create Subscriptions with `status=incomplete` when the first invoice requires payment, otherwise start as active. Subscriptions transition to `status=active` when successfully confirming the PaymentIntent on the first invoice. This allows simpler management of scenarios where additional customer actions are needed to pay a subscription's invoice, such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method. If the PaymentIntent is not confirmed within 23 hours Subscriptions transition to `status=incomplete_expired`, which is a terminal state.
-
- Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice can't be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further customer action is needed, this parameter doesn't create a Subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.
-
- `pending_if_incomplete` is only used with updates and cannot be passed when creating a Subscription.
-
- Subscriptions with `collection_method=send_invoice` are automatically activated regardless of the first Invoice status.
- """
- payment_settings: NotRequired[
- "SubscriptionService.CreateParamsPaymentSettings"
- ]
- """
- Payment settings to pass to invoices created by the subscription.
- """
- pending_invoice_item_interval: NotRequired[
- "Literal['']|SubscriptionService.CreateParamsPendingInvoiceItemInterval"
- ]
- """
- Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) resulting from the `billing_cycle_anchor`. If no value is passed, the default is `create_prorations`.
- """
- transfer_data: NotRequired[
- "SubscriptionService.CreateParamsTransferData"
- ]
- """
- If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges.
- """
- trial_end: NotRequired["Literal['now']|int"]
- """
- Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
- """
- trial_from_plan: NotRequired[bool]
- """
- Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
- """
- trial_period_days: NotRequired[int]
- """
- Integer representing the number of trial period days before the customer is charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
- """
- trial_settings: NotRequired[
- "SubscriptionService.CreateParamsTrialSettings"
- ]
- """
- Settings related to subscription trials.
- """
-
- class CreateParamsAddInvoiceItem(TypedDict):
- discounts: NotRequired[
- List["SubscriptionService.CreateParamsAddInvoiceItemDiscount"]
- ]
- """
- The coupons to redeem into discounts for the item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired[
- "SubscriptionService.CreateParamsAddInvoiceItemPeriod"
- ]
- """
- The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired[
- "SubscriptionService.CreateParamsAddInvoiceItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item. Defaults to 1.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
- """
-
- class CreateParamsAddInvoiceItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsAddInvoiceItemPeriod(TypedDict):
- end: "SubscriptionService.CreateParamsAddInvoiceItemPeriodEnd"
- """
- End of the invoice item period.
- """
- start: "SubscriptionService.CreateParamsAddInvoiceItemPeriodStart"
- """
- Start of the invoice item period.
- """
-
- class CreateParamsAddInvoiceItemPeriodEnd(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
- """
- type: Literal["min_item_period_end", "timestamp"]
- """
- Select how to calculate the end of the invoice item period.
- """
-
- class CreateParamsAddInvoiceItemPeriodStart(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
- """
- type: Literal["max_item_period_start", "now", "timestamp"]
- """
- Select how to calculate the start of the invoice item period.
- """
-
- class CreateParamsAddInvoiceItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
- liability: NotRequired[
- "SubscriptionService.CreateParamsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreateParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsBillingCycleAnchorConfig(TypedDict):
- day_of_month: int
- """
- The day of the month the anchor should be. Ranges from 1 to 31.
- """
- hour: NotRequired[int]
- """
- The hour of the day the anchor should be. Ranges from 0 to 23.
- """
- minute: NotRequired[int]
- """
- The minute of the hour the anchor should be. Ranges from 0 to 59.
- """
- month: NotRequired[int]
- """
- The month to start full cycle periods. Ranges from 1 to 12.
- """
- second: NotRequired[int]
- """
- The second of the minute the anchor should be. Ranges from 0 to 59.
- """
-
- class CreateParamsBillingMode(TypedDict):
- flexible: NotRequired[
- "SubscriptionService.CreateParamsBillingModeFlexible"
- ]
- """
- Configure behavior for flexible billing mode.
- """
- type: Literal["classic", "flexible"]
- """
- Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
- """
-
- class CreateParamsBillingModeFlexible(TypedDict):
- proration_discounts: NotRequired[Literal["included", "itemized"]]
- """
- Controls how invoices and invoice items display proration amounts and discount amounts.
- """
-
- class CreateParamsBillingThresholds(TypedDict):
- amount_gte: NotRequired[int]
- """
- Monetary threshold that triggers the subscription to advance to a new billing period
- """
- reset_billing_cycle_anchor: NotRequired[bool]
- """
- Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
- """
-
- class CreateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsInvoiceSettings(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the subscription. Will be set on invoices generated by the subscription.
- """
- issuer: NotRequired[
- "SubscriptionService.CreateParamsInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class CreateParamsInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsItem(TypedDict):
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionService.CreateParamsItemBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionService.CreateParamsItemDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- plan: NotRequired[str]
- """
- Plan ID for this item, as a string.
- """
- price: NotRequired[str]
- """
- The ID of the price object.
- """
- price_data: NotRequired[
- "SubscriptionService.CreateParamsItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class CreateParamsItemBillingThresholds(TypedDict):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class CreateParamsItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class CreateParamsItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: "SubscriptionService.CreateParamsItemPriceDataRecurring"
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class CreateParamsPaymentSettings(TypedDict):
- payment_method_options: NotRequired[
- "SubscriptionService.CreateParamsPaymentSettingsPaymentMethodOptions"
- ]
- """
- Payment-method-specific configuration to provide to invoices created by the subscription.
- """
- payment_method_types: NotRequired[
- "Literal['']|List[Literal['ach_credit_transfer', 'ach_debit', 'acss_debit', 'affirm', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'jp_credit_transfer', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'link', 'multibanco', 'naver_pay', 'nz_bank_account', 'p24', 'payco', 'paynow', 'paypal', 'promptpay', 'revolut_pay', 'sepa_credit_transfer', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
- ]
- """
- The list of payment method types (e.g. card) to provide to the invoice's PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice's default payment method, the subscription's default payment method, the customer's default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice). Should not be specified with payment_method_configuration
- """
- save_default_payment_method: NotRequired[
- Literal["off", "on_subscription"]
- ]
- """
- Configure whether Stripe updates `subscription.default_payment_method` when payment succeeds. Defaults to `off` if unspecified.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "Literal['']|SubscriptionService.CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebit"
- ]
- """
- This sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice's PaymentIntent.
- """
- bancontact: NotRequired[
- "Literal['']|SubscriptionService.CreateParamsPaymentSettingsPaymentMethodOptionsBancontact"
- ]
- """
- This sub-hash contains details about the Bancontact payment method options to pass to the invoice's PaymentIntent.
- """
- card: NotRequired[
- "Literal['']|SubscriptionService.CreateParamsPaymentSettingsPaymentMethodOptionsCard"
- ]
- """
- This sub-hash contains details about the Card payment method options to pass to the invoice's PaymentIntent.
- """
- customer_balance: NotRequired[
- "Literal['']|SubscriptionService.CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance"
- ]
- """
- This sub-hash contains details about the Bank transfer payment method options to pass to the invoice's PaymentIntent.
- """
- konbini: NotRequired[
- "Literal['']|SubscriptionService.CreateParamsPaymentSettingsPaymentMethodOptionsKonbini"
- ]
- """
- This sub-hash contains details about the Konbini payment method options to pass to the invoice's PaymentIntent.
- """
- sepa_debit: NotRequired[
- "Literal['']|SubscriptionService.CreateParamsPaymentSettingsPaymentMethodOptionsSepaDebit"
- ]
- """
- This sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice's PaymentIntent.
- """
- us_bank_account: NotRequired[
- "Literal['']|SubscriptionService.CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount"
- ]
- """
- This sub-hash contains details about the ACH direct debit payment method options to pass to the invoice's PaymentIntent.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebit(TypedDict):
- mandate_options: NotRequired[
- "SubscriptionService.CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions(
- TypedDict,
- ):
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsBancontact(TypedDict):
- preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
- """
- Preferred language of the Bancontact authorization page that the customer is redirected to.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCard(TypedDict):
- mandate_options: NotRequired[
- "SubscriptionService.CreateParamsPaymentSettingsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this Subscription on. Depends on the available networks of the card attached to the Subscription. Can be only set confirm-time.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCardMandateOptions(
- TypedDict,
- ):
- amount: NotRequired[int]
- """
- Amount to be charged for future payments.
- """
- amount_type: NotRequired[Literal["fixed", "maximum"]]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance(
- TypedDict,
- ):
- bank_transfer: NotRequired[
- "SubscriptionService.CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[str]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "SubscriptionService.CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for eu_bank_transfer funding type.
- """
- type: NotRequired[str]
- """
- The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsKonbini(TypedDict):
- pass
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsSepaDebit(TypedDict):
- pass
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount(
- TypedDict,
- ):
- financial_connections: NotRequired[
- "SubscriptionService.CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "SubscriptionService.CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
-
- class CreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class CreateParamsPendingInvoiceItemInterval(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies invoicing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks).
- """
-
- class CreateParamsTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class CreateParamsTrialSettings(TypedDict):
- end_behavior: (
- "SubscriptionService.CreateParamsTrialSettingsEndBehavior"
- )
- """
- Defines how the subscription should behave when the user's free trial ends.
- """
-
- class CreateParamsTrialSettingsEndBehavior(TypedDict):
- missing_payment_method: Literal["cancel", "create_invoice", "pause"]
- """
- Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
- """
-
- class DeleteDiscountParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- automatic_tax: NotRequired[
- "SubscriptionService.ListParamsAutomaticTax"
- ]
- """
- Filter subscriptions by their automatic tax settings.
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- The collection method of the subscriptions to retrieve. Either `charge_automatically` or `send_invoice`.
- """
- created: NotRequired["SubscriptionService.ListParamsCreated|int"]
- """
- Only return subscriptions that were created during the given date interval.
- """
- current_period_end: NotRequired[
- "SubscriptionService.ListParamsCurrentPeriodEnd|int"
- ]
- """
- Only return subscriptions whose minimum item current_period_end falls within the given date interval.
- """
- current_period_start: NotRequired[
- "SubscriptionService.ListParamsCurrentPeriodStart|int"
- ]
- """
- Only return subscriptions whose maximum item current_period_start falls within the given date interval.
- """
- customer: NotRequired[str]
- """
- The ID of the customer whose subscriptions will be retrieved.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- plan: NotRequired[str]
- """
- The ID of the plan whose subscriptions will be retrieved.
- """
- price: NotRequired[str]
- """
- Filter for subscriptions that contain this recurring price ID.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal[
- "active",
- "all",
- "canceled",
- "ended",
- "incomplete",
- "incomplete_expired",
- "past_due",
- "paused",
- "trialing",
- "unpaid",
- ]
- ]
- """
- The status of the subscriptions to retrieve. Passing in a value of `canceled` will return all canceled subscriptions, including those belonging to deleted customers. Pass `ended` to find subscriptions that are canceled and subscriptions that are expired due to [incomplete payment](https://stripe.com/docs/billing/subscriptions/overview#subscription-statuses). Passing in a value of `all` will return subscriptions of all statuses. If no value is supplied, all subscriptions that have not been canceled are returned.
- """
- test_clock: NotRequired[str]
- """
- Filter for subscriptions that are associated with the specified test clock. The response will not include subscriptions with test clocks if this and the customer parameter is not set.
- """
-
- class ListParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsCurrentPeriodEnd(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsCurrentPeriodStart(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class MigrateParams(TypedDict):
- billing_mode: "SubscriptionService.MigrateParamsBillingMode"
- """
- Controls how prorations and invoices for subscriptions are calculated and orchestrated.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class MigrateParamsBillingMode(TypedDict):
- flexible: NotRequired[
- "SubscriptionService.MigrateParamsBillingModeFlexible"
- ]
- """
- Configure behavior for flexible billing mode.
- """
- type: Literal["flexible"]
- """
- Controls the calculation and orchestration of prorations and invoices for subscriptions.
- """
-
- class MigrateParamsBillingModeFlexible(TypedDict):
- proration_discounts: NotRequired[Literal["included", "itemized"]]
- """
- Controls how invoices and invoice items display proration amounts and discount amounts.
- """
-
- class ResumeParams(TypedDict):
- billing_cycle_anchor: NotRequired[Literal["now", "unchanged"]]
- """
- The billing cycle anchor that applies when the subscription is resumed. Either `now` or `unchanged`. The default is `now`. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) resulting from the `billing_cycle_anchor` being `unchanged`. When the `billing_cycle_anchor` is set to `now` (default value), no prorations are generated. If no value is passed, the default is `create_prorations`.
- """
- proration_date: NotRequired[int]
- """
- If set, prorations will be calculated as though the subscription was resumed at the given time. This can be used to apply exactly the same prorations that were previewed with the [create preview](https://stripe.com/docs/api/invoices/create_preview) endpoint.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SearchParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- page: NotRequired[str]
- """
- A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
- """
- query: str
- """
- The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for subscriptions](https://stripe.com/docs/search#query-fields-for-subscriptions).
- """
-
- class UpdateParams(TypedDict):
- add_invoice_items: NotRequired[
- List["SubscriptionService.UpdateParamsAddInvoiceItem"]
- ]
- """
- A list of prices and quantities that will generate invoice items appended to the next invoice for this subscription. You may pass up to 20 items.
- """
- application_fee_percent: NotRequired["Literal['']|float"]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- automatic_tax: NotRequired[
- "SubscriptionService.UpdateParamsAutomaticTax"
- ]
- """
- Automatic tax settings for this subscription. We recommend you only include this parameter when the existing value is being changed.
- """
- billing_cycle_anchor: NotRequired[Literal["now", "unchanged"]]
- """
- Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time (in UTC). For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
- """
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionService.UpdateParamsBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds.
- """
- cancel_at: NotRequired[
- "Literal['']|int|Literal['max_period_end', 'min_period_end']"
- ]
- """
- A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
- """
- cancel_at_period_end: NotRequired[bool]
- """
- Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`.
- """
- cancellation_details: NotRequired[
- "SubscriptionService.UpdateParamsCancellationDetails"
- ]
- """
- Details about why this subscription was cancelled
- """
- collection_method: NotRequired[
- Literal["charge_automatically", "send_invoice"]
- ]
- """
- Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
- """
- days_until_due: NotRequired[int]
- """
- Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.
- """
- default_payment_method: NotRequired[str]
- """
- ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
- """
- default_source: NotRequired["Literal['']|str"]
- """
- ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
- """
- default_tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription. Pass an empty string to remove previously-defined tax rates.
- """
- description: NotRequired["Literal['']|str"]
- """
- The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionService.UpdateParamsDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription. If not specified or empty, inherits the discount from the subscription's customer.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- invoice_settings: NotRequired[
- "SubscriptionService.UpdateParamsInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- items: NotRequired[List["SubscriptionService.UpdateParamsItem"]]
- """
- A list of up to 20 subscription items, each with an attached price.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- off_session: NotRequired[bool]
- """
- Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
- """
- on_behalf_of: NotRequired["Literal['']|str"]
- """
- The account on behalf of which to charge, for each of the subscription's invoices.
- """
- pause_collection: NotRequired[
- "Literal['']|SubscriptionService.UpdateParamsPauseCollection"
- ]
- """
- If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
- """
- payment_behavior: NotRequired[
- Literal[
- "allow_incomplete",
- "default_incomplete",
- "error_if_incomplete",
- "pending_if_incomplete",
- ]
- ]
- """
- Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
-
- Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription's invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
-
- Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
-
- Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://docs.stripe.com/changelog/2019-03-14) to learn more.
- """
- payment_settings: NotRequired[
- "SubscriptionService.UpdateParamsPaymentSettings"
- ]
- """
- Payment settings to pass to invoices created by the subscription.
- """
- pending_invoice_item_interval: NotRequired[
- "Literal['']|SubscriptionService.UpdateParamsPendingInvoiceItemInterval"
- ]
- """
- Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
- """
- proration_date: NotRequired[int]
- """
- If set, prorations will be calculated as though the subscription was updated at the given time. This can be used to apply exactly the same prorations that were previewed with the [create preview](https://stripe.com/docs/api/invoices/create_preview) endpoint. `proration_date` can also be used to implement custom proration logic, such as prorating by day instead of by second, by providing the time that you wish to use for proration calculations.
- """
- transfer_data: NotRequired[
- "Literal['']|SubscriptionService.UpdateParamsTransferData"
- ]
- """
- If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges. This will be unset if you POST an empty value.
- """
- trial_end: NotRequired["Literal['now']|int"]
- """
- Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, `trial_end` will override the default trial period of the plan the customer is being subscribed to. The `billing_cycle_anchor` will be updated to the `trial_end` value. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`.
- """
- trial_from_plan: NotRequired[bool]
- """
- Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
- """
- trial_settings: NotRequired[
- "SubscriptionService.UpdateParamsTrialSettings"
- ]
- """
- Settings related to subscription trials.
- """
-
- class UpdateParamsAddInvoiceItem(TypedDict):
- discounts: NotRequired[
- List["SubscriptionService.UpdateParamsAddInvoiceItemDiscount"]
- ]
- """
- The coupons to redeem into discounts for the item.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- period: NotRequired[
- "SubscriptionService.UpdateParamsAddInvoiceItemPeriod"
- ]
- """
- The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired[
- "SubscriptionService.UpdateParamsAddInvoiceItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item. Defaults to 1.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
- """
-
- class UpdateParamsAddInvoiceItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class UpdateParamsAddInvoiceItemPeriod(TypedDict):
- end: "SubscriptionService.UpdateParamsAddInvoiceItemPeriodEnd"
- """
- End of the invoice item period.
- """
- start: "SubscriptionService.UpdateParamsAddInvoiceItemPeriodStart"
- """
- Start of the invoice item period.
- """
-
- class UpdateParamsAddInvoiceItemPeriodEnd(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
- """
- type: Literal["min_item_period_end", "timestamp"]
- """
- Select how to calculate the end of the invoice item period.
- """
-
- class UpdateParamsAddInvoiceItemPeriodStart(TypedDict):
- timestamp: NotRequired[int]
- """
- A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
- """
- type: Literal["max_item_period_start", "now", "timestamp"]
- """
- Select how to calculate the start of the invoice item period.
- """
-
- class UpdateParamsAddInvoiceItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class UpdateParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
- """
- liability: NotRequired[
- "SubscriptionService.UpdateParamsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class UpdateParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class UpdateParamsBillingThresholds(TypedDict):
- amount_gte: NotRequired[int]
- """
- Monetary threshold that triggers the subscription to advance to a new billing period
- """
- reset_billing_cycle_anchor: NotRequired[bool]
- """
- Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
- """
-
- class UpdateParamsCancellationDetails(TypedDict):
- comment: NotRequired["Literal['']|str"]
- """
- Additional comments about why the user canceled the subscription, if the subscription was canceled explicitly by the user.
- """
- feedback: NotRequired[
- "Literal['']|Literal['customer_service', 'low_quality', 'missing_features', 'other', 'switched_service', 'too_complex', 'too_expensive', 'unused']"
- ]
- """
- The customer submitted reason for why they canceled, if the subscription was canceled explicitly by the user.
- """
-
- class UpdateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class UpdateParamsInvoiceSettings(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the subscription. Will be set on invoices generated by the subscription.
- """
- issuer: NotRequired[
- "SubscriptionService.UpdateParamsInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class UpdateParamsInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class UpdateParamsItem(TypedDict):
- billing_thresholds: NotRequired[
- "Literal['']|SubscriptionService.UpdateParamsItemBillingThresholds"
- ]
- """
- Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
- """
- clear_usage: NotRequired[bool]
- """
- Delete all usage for a given subscription item. You must pass this when deleting a usage records subscription item. `clear_usage` has no effect if the plan has a billing meter attached.
- """
- deleted: NotRequired[bool]
- """
- A flag that, if set to `true`, will delete the specified item.
- """
- discounts: NotRequired[
- "Literal['']|List[SubscriptionService.UpdateParamsItemDiscount]"
- ]
- """
- The coupons to redeem into discounts for the subscription item.
- """
- id: NotRequired[str]
- """
- Subscription item to update.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- plan: NotRequired[str]
- """
- Plan ID for this item, as a string.
- """
- price: NotRequired[str]
- """
- The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
- """
- price_data: NotRequired[
- "SubscriptionService.UpdateParamsItemPriceData"
- ]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- Quantity for this item.
- """
- tax_rates: NotRequired["Literal['']|List[str]"]
- """
- A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
- """
-
- class UpdateParamsItemBillingThresholds(TypedDict):
- usage_gte: int
- """
- Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
- """
-
- class UpdateParamsItemDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- ID of the coupon to create a new discount for.
- """
- discount: NotRequired[str]
- """
- ID of an existing discount on the object (or one of its ancestors) to reuse.
- """
- promotion_code: NotRequired[str]
- """
- ID of the promotion code to create a new discount for.
- """
-
- class UpdateParamsItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: str
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
- """
- recurring: "SubscriptionService.UpdateParamsItemPriceDataRecurring"
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class UpdateParamsItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class UpdateParamsPauseCollection(TypedDict):
- behavior: Literal["keep_as_draft", "mark_uncollectible", "void"]
- """
- The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
- """
- resumes_at: NotRequired[int]
- """
- The time after which the subscription will resume collecting payments.
- """
-
- class UpdateParamsPaymentSettings(TypedDict):
- payment_method_options: NotRequired[
- "SubscriptionService.UpdateParamsPaymentSettingsPaymentMethodOptions"
- ]
- """
- Payment-method-specific configuration to provide to invoices created by the subscription.
- """
- payment_method_types: NotRequired[
- "Literal['']|List[Literal['ach_credit_transfer', 'ach_debit', 'acss_debit', 'affirm', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'jp_credit_transfer', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'link', 'multibanco', 'naver_pay', 'nz_bank_account', 'p24', 'payco', 'paynow', 'paypal', 'promptpay', 'revolut_pay', 'sepa_credit_transfer', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
- ]
- """
- The list of payment method types (e.g. card) to provide to the invoice's PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice's default payment method, the subscription's default payment method, the customer's default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice). Should not be specified with payment_method_configuration
- """
- save_default_payment_method: NotRequired[
- Literal["off", "on_subscription"]
- ]
- """
- Configure whether Stripe updates `subscription.default_payment_method` when payment succeeds. Defaults to `off` if unspecified.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "Literal['']|SubscriptionService.UpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebit"
- ]
- """
- This sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice's PaymentIntent.
- """
- bancontact: NotRequired[
- "Literal['']|SubscriptionService.UpdateParamsPaymentSettingsPaymentMethodOptionsBancontact"
- ]
- """
- This sub-hash contains details about the Bancontact payment method options to pass to the invoice's PaymentIntent.
- """
- card: NotRequired[
- "Literal['']|SubscriptionService.UpdateParamsPaymentSettingsPaymentMethodOptionsCard"
- ]
- """
- This sub-hash contains details about the Card payment method options to pass to the invoice's PaymentIntent.
- """
- customer_balance: NotRequired[
- "Literal['']|SubscriptionService.UpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance"
- ]
- """
- This sub-hash contains details about the Bank transfer payment method options to pass to the invoice's PaymentIntent.
- """
- konbini: NotRequired[
- "Literal['']|SubscriptionService.UpdateParamsPaymentSettingsPaymentMethodOptionsKonbini"
- ]
- """
- This sub-hash contains details about the Konbini payment method options to pass to the invoice's PaymentIntent.
- """
- sepa_debit: NotRequired[
- "Literal['']|SubscriptionService.UpdateParamsPaymentSettingsPaymentMethodOptionsSepaDebit"
- ]
- """
- This sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice's PaymentIntent.
- """
- us_bank_account: NotRequired[
- "Literal['']|SubscriptionService.UpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount"
- ]
- """
- This sub-hash contains details about the ACH direct debit payment method options to pass to the invoice's PaymentIntent.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebit(TypedDict):
- mandate_options: NotRequired[
- "SubscriptionService.UpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions(
- TypedDict,
- ):
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsBancontact(TypedDict):
- preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
- """
- Preferred language of the Bancontact authorization page that the customer is redirected to.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsCard(TypedDict):
- mandate_options: NotRequired[
- "SubscriptionService.UpdateParamsPaymentSettingsPaymentMethodOptionsCardMandateOptions"
- ]
- """
- Configuration options for setting up an eMandate for cards issued in India.
- """
- network: NotRequired[
- Literal[
- "amex",
- "cartes_bancaires",
- "diners",
- "discover",
- "eftpos_au",
- "girocard",
- "interac",
- "jcb",
- "link",
- "mastercard",
- "unionpay",
- "unknown",
- "visa",
- ]
- ]
- """
- Selected network to process this Subscription on. Depends on the available networks of the card attached to the Subscription. Can be only set confirm-time.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsCardMandateOptions(
- TypedDict,
- ):
- amount: NotRequired[int]
- """
- Amount to be charged for future payments.
- """
- amount_type: NotRequired[Literal["fixed", "maximum"]]
- """
- One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
- """
- description: NotRequired[str]
- """
- A description of the mandate or subscription that is meant to be displayed to the customer.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance(
- TypedDict,
- ):
- bank_transfer: NotRequired[
- "SubscriptionService.UpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[str]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "SubscriptionService.UpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for eu_bank_transfer funding type.
- """
- type: NotRequired[str]
- """
- The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsKonbini(TypedDict):
- pass
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsSepaDebit(TypedDict):
- pass
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount(
- TypedDict,
- ):
- financial_connections: NotRequired[
- "SubscriptionService.UpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- filters: NotRequired[
- "SubscriptionService.UpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
- ]
- """
- Provide filters for the linked accounts that the customer can select for the payment method.
- """
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
-
- class UpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
- TypedDict,
- ):
- account_subcategories: NotRequired[
- List[Literal["checking", "savings"]]
- ]
- """
- The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
- """
-
- class UpdateParamsPendingInvoiceItemInterval(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies invoicing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks).
- """
-
- class UpdateParamsTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class UpdateParamsTrialSettings(TypedDict):
- end_behavior: (
- "SubscriptionService.UpdateParamsTrialSettingsEndBehavior"
- )
- """
- Defines how the subscription should behave when the user's free trial ends.
- """
-
- class UpdateParamsTrialSettingsEndBehavior(TypedDict):
- missing_payment_method: Literal["cancel", "create_invoice", "pause"]
- """
- Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
- """
-
def cancel(
self,
subscription_exposed_id: str,
- params: Optional["SubscriptionService.CancelParams"] = None,
+ params: Optional["SubscriptionCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> Subscription:
"""
@@ -1793,7 +70,7 @@ def cancel(
async def cancel_async(
self,
subscription_exposed_id: str,
- params: Optional["SubscriptionService.CancelParams"] = None,
+ params: Optional["SubscriptionCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> Subscription:
"""
@@ -1821,7 +98,7 @@ async def cancel_async(
def retrieve(
self,
subscription_exposed_id: str,
- params: Optional["SubscriptionService.RetrieveParams"] = None,
+ params: Optional["SubscriptionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Subscription:
"""
@@ -1845,7 +122,7 @@ def retrieve(
async def retrieve_async(
self,
subscription_exposed_id: str,
- params: Optional["SubscriptionService.RetrieveParams"] = None,
+ params: Optional["SubscriptionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Subscription:
"""
@@ -1869,7 +146,7 @@ async def retrieve_async(
def update(
self,
subscription_exposed_id: str,
- params: Optional["SubscriptionService.UpdateParams"] = None,
+ params: Optional["SubscriptionUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Subscription:
"""
@@ -1913,7 +190,7 @@ def update(
async def update_async(
self,
subscription_exposed_id: str,
- params: Optional["SubscriptionService.UpdateParams"] = None,
+ params: Optional["SubscriptionUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Subscription:
"""
@@ -1957,7 +234,7 @@ async def update_async(
def delete_discount(
self,
subscription_exposed_id: str,
- params: Optional["SubscriptionService.DeleteDiscountParams"] = None,
+ params: Optional["SubscriptionDeleteDiscountParams"] = None,
options: Optional[RequestOptions] = None,
) -> Discount:
"""
@@ -1981,7 +258,7 @@ def delete_discount(
async def delete_discount_async(
self,
subscription_exposed_id: str,
- params: Optional["SubscriptionService.DeleteDiscountParams"] = None,
+ params: Optional["SubscriptionDeleteDiscountParams"] = None,
options: Optional[RequestOptions] = None,
) -> Discount:
"""
@@ -2004,7 +281,7 @@ async def delete_discount_async(
def list(
self,
- params: Optional["SubscriptionService.ListParams"] = None,
+ params: Optional["SubscriptionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Subscription]:
"""
@@ -2023,7 +300,7 @@ def list(
async def list_async(
self,
- params: Optional["SubscriptionService.ListParams"] = None,
+ params: Optional["SubscriptionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Subscription]:
"""
@@ -2042,7 +319,7 @@ async def list_async(
def create(
self,
- params: "SubscriptionService.CreateParams",
+ params: "SubscriptionCreateParams",
options: Optional[RequestOptions] = None,
) -> Subscription:
"""
@@ -2067,7 +344,7 @@ def create(
async def create_async(
self,
- params: "SubscriptionService.CreateParams",
+ params: "SubscriptionCreateParams",
options: Optional[RequestOptions] = None,
) -> Subscription:
"""
@@ -2092,7 +369,7 @@ async def create_async(
def search(
self,
- params: "SubscriptionService.SearchParams",
+ params: "SubscriptionSearchParams",
options: Optional[RequestOptions] = None,
) -> SearchResultObject[Subscription]:
"""
@@ -2114,7 +391,7 @@ def search(
async def search_async(
self,
- params: "SubscriptionService.SearchParams",
+ params: "SubscriptionSearchParams",
options: Optional[RequestOptions] = None,
) -> SearchResultObject[Subscription]:
"""
@@ -2137,7 +414,7 @@ async def search_async(
def migrate(
self,
subscription: str,
- params: "SubscriptionService.MigrateParams",
+ params: "SubscriptionMigrateParams",
options: Optional[RequestOptions] = None,
) -> Subscription:
"""
@@ -2159,7 +436,7 @@ def migrate(
async def migrate_async(
self,
subscription: str,
- params: "SubscriptionService.MigrateParams",
+ params: "SubscriptionMigrateParams",
options: Optional[RequestOptions] = None,
) -> Subscription:
"""
@@ -2181,7 +458,7 @@ async def migrate_async(
def resume(
self,
subscription: str,
- params: Optional["SubscriptionService.ResumeParams"] = None,
+ params: Optional["SubscriptionResumeParams"] = None,
options: Optional[RequestOptions] = None,
) -> Subscription:
"""
@@ -2203,7 +480,7 @@ def resume(
async def resume_async(
self,
subscription: str,
- params: Optional["SubscriptionService.ResumeParams"] = None,
+ params: Optional["SubscriptionResumeParams"] = None,
options: Optional[RequestOptions] = None,
) -> Subscription:
"""
diff --git a/stripe/_tax_code.py b/stripe/_tax_code.py
index e9160c8b1..281a4985a 100644
--- a/stripe/_tax_code.py
+++ b/stripe/_tax_code.py
@@ -2,9 +2,12 @@
# File generated from our OpenAPI spec
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
-from typing import ClassVar, List
-from typing_extensions import Literal, NotRequired, Unpack
+from typing import ClassVar
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._tax_code_list_params import TaxCodeListParams
+ from stripe.params._tax_code_retrieve_params import TaxCodeRetrieveParams
class TaxCode(ListableAPIResource["TaxCode"]):
@@ -13,31 +16,6 @@ class TaxCode(ListableAPIResource["TaxCode"]):
"""
OBJECT_NAME: ClassVar[Literal["tax_code"]] = "tax_code"
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
description: str
"""
A detailed description of which types of products the tax code represents.
@@ -57,7 +35,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["TaxCode.ListParams"]
+ cls, **params: Unpack["TaxCodeListParams"]
) -> ListObject["TaxCode"]:
"""
A list of [all tax codes available](https://stripe.com/docs/tax/tax-categories) to add to Products in order to allow specific tax calculations.
@@ -77,7 +55,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["TaxCode.ListParams"]
+ cls, **params: Unpack["TaxCodeListParams"]
) -> ListObject["TaxCode"]:
"""
A list of [all tax codes available](https://stripe.com/docs/tax/tax-categories) to add to Products in order to allow specific tax calculations.
@@ -97,7 +75,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["TaxCode.RetrieveParams"]
+ cls, id: str, **params: Unpack["TaxCodeRetrieveParams"]
) -> "TaxCode":
"""
Retrieves the details of an existing tax code. Supply the unique tax code ID and Stripe will return the corresponding tax code information.
@@ -108,7 +86,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["TaxCode.RetrieveParams"]
+ cls, id: str, **params: Unpack["TaxCodeRetrieveParams"]
) -> "TaxCode":
"""
Retrieves the details of an existing tax code. Supply the unique tax code ID and Stripe will return the corresponding tax code information.
diff --git a/stripe/_tax_code_service.py b/stripe/_tax_code_service.py
index eebd0ff1d..5fc32c68f 100644
--- a/stripe/_tax_code_service.py
+++ b/stripe/_tax_code_service.py
@@ -5,38 +5,18 @@
from stripe._stripe_service import StripeService
from stripe._tax_code import TaxCode
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._tax_code_list_params import TaxCodeListParams
+ from stripe.params._tax_code_retrieve_params import TaxCodeRetrieveParams
-class TaxCodeService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class TaxCodeService(StripeService):
def list(
self,
- params: Optional["TaxCodeService.ListParams"] = None,
+ params: Optional["TaxCodeListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[TaxCode]:
"""
@@ -55,7 +35,7 @@ def list(
async def list_async(
self,
- params: Optional["TaxCodeService.ListParams"] = None,
+ params: Optional["TaxCodeListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[TaxCode]:
"""
@@ -75,7 +55,7 @@ async def list_async(
def retrieve(
self,
id: str,
- params: Optional["TaxCodeService.RetrieveParams"] = None,
+ params: Optional["TaxCodeRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> TaxCode:
"""
@@ -95,7 +75,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["TaxCodeService.RetrieveParams"] = None,
+ params: Optional["TaxCodeRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> TaxCode:
"""
diff --git a/stripe/_tax_id.py b/stripe/_tax_id.py
index 8ec276c9d..2a508a400 100644
--- a/stripe/_tax_id.py
+++ b/stripe/_tax_id.py
@@ -5,22 +5,19 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account
from stripe._application import Application
from stripe._customer import Customer
+ from stripe.params._tax_id_create_params import TaxIdCreateParams
+ from stripe.params._tax_id_delete_params import TaxIdDeleteParams
+ from stripe.params._tax_id_list_params import TaxIdListParams
+ from stripe.params._tax_id_retrieve_params import TaxIdRetrieveParams
class TaxId(
@@ -69,194 +66,6 @@ class Verification(StripeObject):
Verified name.
"""
- class CreateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- owner: NotRequired["TaxId.CreateParamsOwner"]
- """
- The account or customer the tax ID belongs to. Defaults to `owner[type]=self`.
- """
- type: Literal[
- "ad_nrt",
- "ae_trn",
- "al_tin",
- "am_tin",
- "ao_tin",
- "ar_cuit",
- "au_abn",
- "au_arn",
- "aw_tin",
- "az_tin",
- "ba_tin",
- "bb_tin",
- "bd_bin",
- "bf_ifu",
- "bg_uic",
- "bh_vat",
- "bj_ifu",
- "bo_tin",
- "br_cnpj",
- "br_cpf",
- "bs_tin",
- "by_tin",
- "ca_bn",
- "ca_gst_hst",
- "ca_pst_bc",
- "ca_pst_mb",
- "ca_pst_sk",
- "ca_qst",
- "cd_nif",
- "ch_uid",
- "ch_vat",
- "cl_tin",
- "cm_niu",
- "cn_tin",
- "co_nit",
- "cr_tin",
- "cv_nif",
- "de_stn",
- "do_rcn",
- "ec_ruc",
- "eg_tin",
- "es_cif",
- "et_tin",
- "eu_oss_vat",
- "eu_vat",
- "gb_vat",
- "ge_vat",
- "gn_nif",
- "hk_br",
- "hr_oib",
- "hu_tin",
- "id_npwp",
- "il_vat",
- "in_gst",
- "is_vat",
- "jp_cn",
- "jp_rn",
- "jp_trn",
- "ke_pin",
- "kg_tin",
- "kh_tin",
- "kr_brn",
- "kz_bin",
- "la_tin",
- "li_uid",
- "li_vat",
- "ma_vat",
- "md_vat",
- "me_pib",
- "mk_vat",
- "mr_nif",
- "mx_rfc",
- "my_frp",
- "my_itn",
- "my_sst",
- "ng_tin",
- "no_vat",
- "no_voec",
- "np_pan",
- "nz_gst",
- "om_vat",
- "pe_ruc",
- "ph_tin",
- "ro_tin",
- "rs_pib",
- "ru_inn",
- "ru_kpp",
- "sa_vat",
- "sg_gst",
- "sg_uen",
- "si_tin",
- "sn_ninea",
- "sr_fin",
- "sv_nit",
- "th_vat",
- "tj_tin",
- "tr_tin",
- "tw_vat",
- "tz_vat",
- "ua_vat",
- "ug_tin",
- "us_ein",
- "uy_ruc",
- "uz_tin",
- "uz_vat",
- "ve_rif",
- "vn_tin",
- "za_vat",
- "zm_tin",
- "zw_tin",
- ]
- """
- Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
- """
- value: str
- """
- Value of the tax ID.
- """
-
- class CreateParamsOwner(TypedDict):
- account: NotRequired[str]
- """
- Account the tax ID belongs to. Required when `type=account`
- """
- customer: NotRequired[str]
- """
- Customer the tax ID belongs to. Required when `type=customer`
- """
- type: Literal["account", "application", "customer", "self"]
- """
- Type of owner referenced.
- """
-
- class DeleteParams(RequestOptions):
- pass
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- owner: NotRequired["TaxId.ListParamsOwner"]
- """
- The account or customer the tax ID belongs to. Defaults to `owner[type]=self`.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsOwner(TypedDict):
- account: NotRequired[str]
- """
- Account the tax ID belongs to. Required when `type=account`
- """
- customer: NotRequired[str]
- """
- Customer the tax ID belongs to. Required when `type=customer`
- """
- type: Literal["account", "application", "customer", "self"]
- """
- Type of owner referenced.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
country: Optional[str]
"""
Two-letter ISO code representing the country of the tax ID.
@@ -415,7 +224,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["TaxId.CreateParams"]) -> "TaxId":
+ def create(cls, **params: Unpack["TaxIdCreateParams"]) -> "TaxId":
"""
Creates a new account or customer tax_id object.
"""
@@ -430,7 +239,7 @@ def create(cls, **params: Unpack["TaxId.CreateParams"]) -> "TaxId":
@classmethod
async def create_async(
- cls, **params: Unpack["TaxId.CreateParams"]
+ cls, **params: Unpack["TaxIdCreateParams"]
) -> "TaxId":
"""
Creates a new account or customer tax_id object.
@@ -446,7 +255,7 @@ async def create_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["TaxId.DeleteParams"]
+ cls, sid: str, **params: Unpack["TaxIdDeleteParams"]
) -> "TaxId":
"""
Deletes an existing account or customer tax_id object.
@@ -463,14 +272,14 @@ def _cls_delete(
@overload
@staticmethod
- def delete(sid: str, **params: Unpack["TaxId.DeleteParams"]) -> "TaxId":
+ def delete(sid: str, **params: Unpack["TaxIdDeleteParams"]) -> "TaxId":
"""
Deletes an existing account or customer tax_id object.
"""
...
@overload
- def delete(self, **params: Unpack["TaxId.DeleteParams"]) -> "TaxId":
+ def delete(self, **params: Unpack["TaxIdDeleteParams"]) -> "TaxId":
"""
Deletes an existing account or customer tax_id object.
"""
@@ -478,7 +287,7 @@ def delete(self, **params: Unpack["TaxId.DeleteParams"]) -> "TaxId":
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["TaxId.DeleteParams"]
+ self, **params: Unpack["TaxIdDeleteParams"]
) -> "TaxId":
"""
Deletes an existing account or customer tax_id object.
@@ -491,7 +300,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["TaxId.DeleteParams"]
+ cls, sid: str, **params: Unpack["TaxIdDeleteParams"]
) -> "TaxId":
"""
Deletes an existing account or customer tax_id object.
@@ -509,7 +318,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["TaxId.DeleteParams"]
+ sid: str, **params: Unpack["TaxIdDeleteParams"]
) -> "TaxId":
"""
Deletes an existing account or customer tax_id object.
@@ -518,7 +327,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["TaxId.DeleteParams"]
+ self, **params: Unpack["TaxIdDeleteParams"]
) -> "TaxId":
"""
Deletes an existing account or customer tax_id object.
@@ -527,7 +336,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["TaxId.DeleteParams"]
+ self, **params: Unpack["TaxIdDeleteParams"]
) -> "TaxId":
"""
Deletes an existing account or customer tax_id object.
@@ -539,7 +348,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
)
@classmethod
- def list(cls, **params: Unpack["TaxId.ListParams"]) -> ListObject["TaxId"]:
+ def list(cls, **params: Unpack["TaxIdListParams"]) -> ListObject["TaxId"]:
"""
Returns a list of tax IDs.
"""
@@ -558,7 +367,7 @@ def list(cls, **params: Unpack["TaxId.ListParams"]) -> ListObject["TaxId"]:
@classmethod
async def list_async(
- cls, **params: Unpack["TaxId.ListParams"]
+ cls, **params: Unpack["TaxIdListParams"]
) -> ListObject["TaxId"]:
"""
Returns a list of tax IDs.
@@ -578,7 +387,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["TaxId.RetrieveParams"]
+ cls, id: str, **params: Unpack["TaxIdRetrieveParams"]
) -> "TaxId":
"""
Retrieves an account or customer tax_id object.
@@ -589,7 +398,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["TaxId.RetrieveParams"]
+ cls, id: str, **params: Unpack["TaxIdRetrieveParams"]
) -> "TaxId":
"""
Retrieves an account or customer tax_id object.
diff --git a/stripe/_tax_id_service.py b/stripe/_tax_id_service.py
index 3152ec1ad..f830c3616 100644
--- a/stripe/_tax_id_service.py
+++ b/stripe/_tax_id_service.py
@@ -5,203 +5,21 @@
from stripe._stripe_service import StripeService
from stripe._tax_id import TaxId
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._tax_id_create_params import TaxIdCreateParams
+ from stripe.params._tax_id_delete_params import TaxIdDeleteParams
+ from stripe.params._tax_id_list_params import TaxIdListParams
+ from stripe.params._tax_id_retrieve_params import TaxIdRetrieveParams
-class TaxIdService(StripeService):
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- owner: NotRequired["TaxIdService.CreateParamsOwner"]
- """
- The account or customer the tax ID belongs to. Defaults to `owner[type]=self`.
- """
- type: Literal[
- "ad_nrt",
- "ae_trn",
- "al_tin",
- "am_tin",
- "ao_tin",
- "ar_cuit",
- "au_abn",
- "au_arn",
- "aw_tin",
- "az_tin",
- "ba_tin",
- "bb_tin",
- "bd_bin",
- "bf_ifu",
- "bg_uic",
- "bh_vat",
- "bj_ifu",
- "bo_tin",
- "br_cnpj",
- "br_cpf",
- "bs_tin",
- "by_tin",
- "ca_bn",
- "ca_gst_hst",
- "ca_pst_bc",
- "ca_pst_mb",
- "ca_pst_sk",
- "ca_qst",
- "cd_nif",
- "ch_uid",
- "ch_vat",
- "cl_tin",
- "cm_niu",
- "cn_tin",
- "co_nit",
- "cr_tin",
- "cv_nif",
- "de_stn",
- "do_rcn",
- "ec_ruc",
- "eg_tin",
- "es_cif",
- "et_tin",
- "eu_oss_vat",
- "eu_vat",
- "gb_vat",
- "ge_vat",
- "gn_nif",
- "hk_br",
- "hr_oib",
- "hu_tin",
- "id_npwp",
- "il_vat",
- "in_gst",
- "is_vat",
- "jp_cn",
- "jp_rn",
- "jp_trn",
- "ke_pin",
- "kg_tin",
- "kh_tin",
- "kr_brn",
- "kz_bin",
- "la_tin",
- "li_uid",
- "li_vat",
- "ma_vat",
- "md_vat",
- "me_pib",
- "mk_vat",
- "mr_nif",
- "mx_rfc",
- "my_frp",
- "my_itn",
- "my_sst",
- "ng_tin",
- "no_vat",
- "no_voec",
- "np_pan",
- "nz_gst",
- "om_vat",
- "pe_ruc",
- "ph_tin",
- "ro_tin",
- "rs_pib",
- "ru_inn",
- "ru_kpp",
- "sa_vat",
- "sg_gst",
- "sg_uen",
- "si_tin",
- "sn_ninea",
- "sr_fin",
- "sv_nit",
- "th_vat",
- "tj_tin",
- "tr_tin",
- "tw_vat",
- "tz_vat",
- "ua_vat",
- "ug_tin",
- "us_ein",
- "uy_ruc",
- "uz_tin",
- "uz_vat",
- "ve_rif",
- "vn_tin",
- "za_vat",
- "zm_tin",
- "zw_tin",
- ]
- """
- Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
- """
- value: str
- """
- Value of the tax ID.
- """
-
- class CreateParamsOwner(TypedDict):
- account: NotRequired[str]
- """
- Account the tax ID belongs to. Required when `type=account`
- """
- customer: NotRequired[str]
- """
- Customer the tax ID belongs to. Required when `type=customer`
- """
- type: Literal["account", "application", "customer", "self"]
- """
- Type of owner referenced.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- owner: NotRequired["TaxIdService.ListParamsOwner"]
- """
- The account or customer the tax ID belongs to. Defaults to `owner[type]=self`.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsOwner(TypedDict):
- account: NotRequired[str]
- """
- Account the tax ID belongs to. Required when `type=account`
- """
- customer: NotRequired[str]
- """
- Customer the tax ID belongs to. Required when `type=customer`
- """
- type: Literal["account", "application", "customer", "self"]
- """
- Type of owner referenced.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class TaxIdService(StripeService):
def delete(
self,
id: str,
- params: Optional["TaxIdService.DeleteParams"] = None,
+ params: Optional["TaxIdDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> TaxId:
"""
@@ -221,7 +39,7 @@ def delete(
async def delete_async(
self,
id: str,
- params: Optional["TaxIdService.DeleteParams"] = None,
+ params: Optional["TaxIdDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> TaxId:
"""
@@ -241,7 +59,7 @@ async def delete_async(
def retrieve(
self,
id: str,
- params: Optional["TaxIdService.RetrieveParams"] = None,
+ params: Optional["TaxIdRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> TaxId:
"""
@@ -261,7 +79,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["TaxIdService.RetrieveParams"] = None,
+ params: Optional["TaxIdRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> TaxId:
"""
@@ -280,7 +98,7 @@ async def retrieve_async(
def list(
self,
- params: Optional["TaxIdService.ListParams"] = None,
+ params: Optional["TaxIdListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[TaxId]:
"""
@@ -299,7 +117,7 @@ def list(
async def list_async(
self,
- params: Optional["TaxIdService.ListParams"] = None,
+ params: Optional["TaxIdListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[TaxId]:
"""
@@ -318,7 +136,7 @@ async def list_async(
def create(
self,
- params: "TaxIdService.CreateParams",
+ params: "TaxIdCreateParams",
options: Optional[RequestOptions] = None,
) -> TaxId:
"""
@@ -337,7 +155,7 @@ def create(
async def create_async(
self,
- params: "TaxIdService.CreateParams",
+ params: "TaxIdCreateParams",
options: Optional[RequestOptions] = None,
) -> TaxId:
"""
diff --git a/stripe/_tax_rate.py b/stripe/_tax_rate.py
index 1be651bc2..ec57166e9 100644
--- a/stripe/_tax_rate.py
+++ b/stripe/_tax_rate.py
@@ -3,12 +3,17 @@
from stripe._createable_api_resource import CreateableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import sanitize_id
-from typing import ClassVar, Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing import ClassVar, Dict, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._tax_rate_create_params import TaxRateCreateParams
+ from stripe.params._tax_rate_list_params import TaxRateListParams
+ from stripe.params._tax_rate_modify_params import TaxRateModifyParams
+ from stripe.params._tax_rate_retrieve_params import TaxRateRetrieveParams
class TaxRate(
@@ -34,178 +39,6 @@ class FlatAmount(StripeObject):
Three-letter ISO currency code, in lowercase.
"""
- class CreateParams(RequestOptions):
- active: NotRequired[bool]
- """
- Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
- """
- display_name: str
- """
- The display name of the tax rate, which will be shown to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- inclusive: bool
- """
- This specifies if the tax rate is inclusive or exclusive.
- """
- jurisdiction: NotRequired[str]
- """
- The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer's invoice.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- percentage: float
- """
- This represents the tax rate percent out of 100.
- """
- state: NotRequired[str]
- """
- [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2), without country prefix. For example, "NY" for New York, United States.
- """
- tax_type: NotRequired[
- Literal[
- "amusement_tax",
- "communications_tax",
- "gst",
- "hst",
- "igst",
- "jct",
- "lease_tax",
- "pst",
- "qst",
- "retail_delivery_fee",
- "rst",
- "sales_tax",
- "service_tax",
- "vat",
- ]
- ]
- """
- The high-level tax type, such as `vat` or `sales_tax`.
- """
-
- class ListParams(RequestOptions):
- active: NotRequired[bool]
- """
- Optional flag to filter by tax rates that are either active or inactive (archived).
- """
- created: NotRequired["TaxRate.ListParamsCreated|int"]
- """
- Optional range for filtering created date.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- inclusive: NotRequired[bool]
- """
- Optional flag to filter by tax rates that are inclusive (or those that are not inclusive).
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- active: NotRequired[bool]
- """
- Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
- """
- display_name: NotRequired[str]
- """
- The display name of the tax rate, which will be shown to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- jurisdiction: NotRequired[str]
- """
- The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer's invoice.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- state: NotRequired[str]
- """
- [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2), without country prefix. For example, "NY" for New York, United States.
- """
- tax_type: NotRequired[
- Literal[
- "amusement_tax",
- "communications_tax",
- "gst",
- "hst",
- "igst",
- "jct",
- "lease_tax",
- "pst",
- "qst",
- "retail_delivery_fee",
- "rst",
- "sales_tax",
- "service_tax",
- "vat",
- ]
- ]
- """
- The high-level tax type, such as `vat` or `sales_tax`.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
active: bool
"""
Defaults to `true`. When set to `false`, this tax rate cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.
@@ -301,7 +134,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["TaxRate.CreateParams"]) -> "TaxRate":
+ def create(cls, **params: Unpack["TaxRateCreateParams"]) -> "TaxRate":
"""
Creates a new tax rate.
"""
@@ -316,7 +149,7 @@ def create(cls, **params: Unpack["TaxRate.CreateParams"]) -> "TaxRate":
@classmethod
async def create_async(
- cls, **params: Unpack["TaxRate.CreateParams"]
+ cls, **params: Unpack["TaxRateCreateParams"]
) -> "TaxRate":
"""
Creates a new tax rate.
@@ -332,7 +165,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["TaxRate.ListParams"]
+ cls, **params: Unpack["TaxRateListParams"]
) -> ListObject["TaxRate"]:
"""
Returns a list of your tax rates. Tax rates are returned sorted by creation date, with the most recently created tax rates appearing first.
@@ -352,7 +185,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["TaxRate.ListParams"]
+ cls, **params: Unpack["TaxRateListParams"]
) -> ListObject["TaxRate"]:
"""
Returns a list of your tax rates. Tax rates are returned sorted by creation date, with the most recently created tax rates appearing first.
@@ -372,7 +205,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["TaxRate.ModifyParams"]
+ cls, id: str, **params: Unpack["TaxRateModifyParams"]
) -> "TaxRate":
"""
Updates an existing tax rate.
@@ -389,7 +222,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["TaxRate.ModifyParams"]
+ cls, id: str, **params: Unpack["TaxRateModifyParams"]
) -> "TaxRate":
"""
Updates an existing tax rate.
@@ -406,7 +239,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["TaxRate.RetrieveParams"]
+ cls, id: str, **params: Unpack["TaxRateRetrieveParams"]
) -> "TaxRate":
"""
Retrieves a tax rate with the given ID
@@ -417,7 +250,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["TaxRate.RetrieveParams"]
+ cls, id: str, **params: Unpack["TaxRateRetrieveParams"]
) -> "TaxRate":
"""
Retrieves a tax rate with the given ID
diff --git a/stripe/_tax_rate_service.py b/stripe/_tax_rate_service.py
index bffa61e43..62030d13f 100644
--- a/stripe/_tax_rate_service.py
+++ b/stripe/_tax_rate_service.py
@@ -5,186 +5,20 @@
from stripe._stripe_service import StripeService
from stripe._tax_rate import TaxRate
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._tax_rate_create_params import TaxRateCreateParams
+ from stripe.params._tax_rate_list_params import TaxRateListParams
+ from stripe.params._tax_rate_retrieve_params import TaxRateRetrieveParams
+ from stripe.params._tax_rate_update_params import TaxRateUpdateParams
-class TaxRateService(StripeService):
- class CreateParams(TypedDict):
- active: NotRequired[bool]
- """
- Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
- """
- display_name: str
- """
- The display name of the tax rate, which will be shown to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- inclusive: bool
- """
- This specifies if the tax rate is inclusive or exclusive.
- """
- jurisdiction: NotRequired[str]
- """
- The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer's invoice.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- percentage: float
- """
- This represents the tax rate percent out of 100.
- """
- state: NotRequired[str]
- """
- [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2), without country prefix. For example, "NY" for New York, United States.
- """
- tax_type: NotRequired[
- Literal[
- "amusement_tax",
- "communications_tax",
- "gst",
- "hst",
- "igst",
- "jct",
- "lease_tax",
- "pst",
- "qst",
- "retail_delivery_fee",
- "rst",
- "sales_tax",
- "service_tax",
- "vat",
- ]
- ]
- """
- The high-level tax type, such as `vat` or `sales_tax`.
- """
-
- class ListParams(TypedDict):
- active: NotRequired[bool]
- """
- Optional flag to filter by tax rates that are either active or inactive (archived).
- """
- created: NotRequired["TaxRateService.ListParamsCreated|int"]
- """
- Optional range for filtering created date.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- inclusive: NotRequired[bool]
- """
- Optional flag to filter by tax rates that are inclusive (or those that are not inclusive).
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- active: NotRequired[bool]
- """
- Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
- """
- display_name: NotRequired[str]
- """
- The display name of the tax rate, which will be shown to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- jurisdiction: NotRequired[str]
- """
- The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer's invoice.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- state: NotRequired[str]
- """
- [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2), without country prefix. For example, "NY" for New York, United States.
- """
- tax_type: NotRequired[
- Literal[
- "amusement_tax",
- "communications_tax",
- "gst",
- "hst",
- "igst",
- "jct",
- "lease_tax",
- "pst",
- "qst",
- "retail_delivery_fee",
- "rst",
- "sales_tax",
- "service_tax",
- "vat",
- ]
- ]
- """
- The high-level tax type, such as `vat` or `sales_tax`.
- """
+class TaxRateService(StripeService):
def list(
self,
- params: Optional["TaxRateService.ListParams"] = None,
+ params: Optional["TaxRateListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[TaxRate]:
"""
@@ -203,7 +37,7 @@ def list(
async def list_async(
self,
- params: Optional["TaxRateService.ListParams"] = None,
+ params: Optional["TaxRateListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[TaxRate]:
"""
@@ -222,7 +56,7 @@ async def list_async(
def create(
self,
- params: "TaxRateService.CreateParams",
+ params: "TaxRateCreateParams",
options: Optional[RequestOptions] = None,
) -> TaxRate:
"""
@@ -241,7 +75,7 @@ def create(
async def create_async(
self,
- params: "TaxRateService.CreateParams",
+ params: "TaxRateCreateParams",
options: Optional[RequestOptions] = None,
) -> TaxRate:
"""
@@ -261,7 +95,7 @@ async def create_async(
def retrieve(
self,
tax_rate: str,
- params: Optional["TaxRateService.RetrieveParams"] = None,
+ params: Optional["TaxRateRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> TaxRate:
"""
@@ -283,7 +117,7 @@ def retrieve(
async def retrieve_async(
self,
tax_rate: str,
- params: Optional["TaxRateService.RetrieveParams"] = None,
+ params: Optional["TaxRateRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> TaxRate:
"""
@@ -305,7 +139,7 @@ async def retrieve_async(
def update(
self,
tax_rate: str,
- params: Optional["TaxRateService.UpdateParams"] = None,
+ params: Optional["TaxRateUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> TaxRate:
"""
@@ -327,7 +161,7 @@ def update(
async def update_async(
self,
tax_rate: str,
- params: Optional["TaxRateService.UpdateParams"] = None,
+ params: Optional["TaxRateUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> TaxRate:
"""
diff --git a/stripe/_token.py b/stripe/_token.py
index 84e72f495..bf02e107e 100644
--- a/stripe/_token.py
+++ b/stripe/_token.py
@@ -1,19 +1,14 @@
# -*- coding: utf-8 -*-
# File generated from our OpenAPI spec
from stripe._createable_api_resource import CreateableAPIResource
-from stripe._request_options import RequestOptions
-from typing import ClassVar, Dict, List, Optional, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._bank_account import BankAccount
from stripe._card import Card
+ from stripe.params._token_create_params import TokenCreateParams
+ from stripe.params._token_retrieve_params import TokenRetrieveParams
class Token(CreateableAPIResource["Token"]):
@@ -41,1162 +36,6 @@ class Token(CreateableAPIResource["Token"]):
"""
OBJECT_NAME: ClassVar[Literal["token"]] = "token"
-
- class CreateParams(RequestOptions):
- account: NotRequired["Token.CreateParamsAccount"]
- """
- Information for the account this token represents.
- """
- bank_account: NotRequired["Token.CreateParamsBankAccount"]
- """
- The bank account this token will represent.
- """
- card: NotRequired["Token.CreateParamsCard|str"]
- """
- The card this token will represent. If you also pass in a customer, the card must be the ID of a card belonging to the customer. Otherwise, if you do not pass in a customer, this is a dictionary containing a user's credit card details, with the options described below.
- """
- customer: NotRequired[str]
- """
- Create a token for the customer, which is owned by the application's account. You can only use this with an [OAuth access token](https://stripe.com/docs/connect/standard-accounts) or [Stripe-Account header](https://stripe.com/docs/connect/authentication). Learn more about [cloning saved payment methods](https://stripe.com/docs/connect/cloning-saved-payment-methods).
- """
- cvc_update: NotRequired["Token.CreateParamsCvcUpdate"]
- """
- The updated CVC value this token represents.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- person: NotRequired["Token.CreateParamsPerson"]
- """
- Information for the person this token represents.
- """
- pii: NotRequired["Token.CreateParamsPii"]
- """
- The PII this token represents.
- """
-
- class CreateParamsAccount(TypedDict):
- business_type: NotRequired[
- Literal["company", "government_entity", "individual", "non_profit"]
- ]
- """
- The business type.
- """
- company: NotRequired["Token.CreateParamsAccountCompany"]
- """
- Information about the company or business.
- """
- individual: NotRequired["Token.CreateParamsAccountIndividual"]
- """
- Information about the person represented by the account.
- """
- tos_shown_and_accepted: NotRequired[bool]
- """
- Whether the user described by the data in the token has been shown [the Stripe Connected Account Agreement](https://docs.stripe.com/connect/account-tokens#stripe-connected-account-agreement). When creating an account token to create a new Connect account, this value must be `true`.
- """
-
- class CreateParamsAccountCompany(TypedDict):
- address: NotRequired["Token.CreateParamsAccountCompanyAddress"]
- """
- The company's primary address.
- """
- address_kana: NotRequired[
- "Token.CreateParamsAccountCompanyAddressKana"
- ]
- """
- The Kana variation of the company's primary address (Japan only).
- """
- address_kanji: NotRequired[
- "Token.CreateParamsAccountCompanyAddressKanji"
- ]
- """
- The Kanji variation of the company's primary address (Japan only).
- """
- directors_provided: NotRequired[bool]
- """
- Whether the company's directors have been provided. Set this Boolean to `true` after creating all the company's directors with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.director` requirement. This value is not automatically set to `true` after creating directors, so it needs to be updated to indicate all directors have been provided.
- """
- directorship_declaration: NotRequired[
- "Token.CreateParamsAccountCompanyDirectorshipDeclaration"
- ]
- """
- This hash is used to attest that the directors information provided to Stripe is both current and correct.
- """
- executives_provided: NotRequired[bool]
- """
- Whether the company's executives have been provided. Set this Boolean to `true` after creating all the company's executives with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.executive` requirement.
- """
- export_license_id: NotRequired[str]
- """
- The export license ID number of the company, also referred as Import Export Code (India only).
- """
- export_purpose_code: NotRequired[str]
- """
- The purpose code to use for export transactions (India only).
- """
- name: NotRequired[str]
- """
- The company's legal name.
- """
- name_kana: NotRequired[str]
- """
- The Kana variation of the company's legal name (Japan only).
- """
- name_kanji: NotRequired[str]
- """
- The Kanji variation of the company's legal name (Japan only).
- """
- owners_provided: NotRequired[bool]
- """
- Whether the company's owners have been provided. Set this Boolean to `true` after creating all the company's owners with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.owner` requirement.
- """
- ownership_declaration: NotRequired[
- "Token.CreateParamsAccountCompanyOwnershipDeclaration"
- ]
- """
- This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
- """
- ownership_declaration_shown_and_signed: NotRequired[bool]
- """
- Whether the user described by the data in the token has been shown the Ownership Declaration and indicated that it is correct.
- """
- ownership_exemption_reason: NotRequired[
- "Literal['']|Literal['qualified_entity_exceeds_ownership_threshold', 'qualifies_as_financial_institution']"
- ]
- """
- This value is used to determine if a business is exempt from providing ultimate beneficial owners. See [this support article](https://support.stripe.com/questions/exemption-from-providing-ownership-details) and [changelog](https://docs.stripe.com/changelog/acacia/2025-01-27/ownership-exemption-reason-accounts-api) for more details.
- """
- phone: NotRequired[str]
- """
- The company's phone number (used for verification).
- """
- registration_date: NotRequired[
- "Literal['']|Token.CreateParamsAccountCompanyRegistrationDate"
- ]
- """
- When the business was incorporated or registered.
- """
- registration_number: NotRequired[str]
- """
- The identification number given to a company when it is registered or incorporated, if distinct from the identification number used for filing taxes. (Examples are the CIN for companies and LLP IN for partnerships in India, and the Company Registration Number in Hong Kong).
- """
- structure: NotRequired[
- "Literal['']|Literal['free_zone_establishment', 'free_zone_llc', 'government_instrumentality', 'governmental_unit', 'incorporated_non_profit', 'incorporated_partnership', 'limited_liability_partnership', 'llc', 'multi_member_llc', 'private_company', 'private_corporation', 'private_partnership', 'public_company', 'public_corporation', 'public_partnership', 'registered_charity', 'single_member_llc', 'sole_establishment', 'sole_proprietorship', 'tax_exempt_government_instrumentality', 'unincorporated_association', 'unincorporated_non_profit', 'unincorporated_partnership']"
- ]
- """
- The category identifying the legal structure of the company or legal entity. See [Business structure](https://docs.stripe.com/connect/identity-verification#business-structure) for more details. Pass an empty string to unset this value.
- """
- tax_id: NotRequired[str]
- """
- The business ID number of the company, as appropriate for the company's country. (Examples are an Employer ID Number in the U.S., a Business Number in Canada, or a Company Number in the UK.)
- """
- tax_id_registrar: NotRequired[str]
- """
- The jurisdiction in which the `tax_id` is registered (Germany-based companies only).
- """
- vat_id: NotRequired[str]
- """
- The VAT number of the company.
- """
- verification: NotRequired[
- "Token.CreateParamsAccountCompanyVerification"
- ]
- """
- Information on the verification state of the company.
- """
-
- class CreateParamsAccountCompanyAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsAccountCompanyAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsAccountCompanyAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsAccountCompanyDirectorshipDeclaration(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the directorship declaration attestation was made.
- """
- ip: NotRequired[str]
- """
- The IP address from which the directorship declaration attestation was made.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the directorship declaration attestation was made.
- """
-
- class CreateParamsAccountCompanyOwnershipDeclaration(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the beneficial owner attestation was made.
- """
- ip: NotRequired[str]
- """
- The IP address from which the beneficial owner attestation was made.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the beneficial owner attestation was made.
- """
-
- class CreateParamsAccountCompanyRegistrationDate(TypedDict):
- day: int
- """
- The day of registration, between 1 and 31.
- """
- month: int
- """
- The month of registration, between 1 and 12.
- """
- year: int
- """
- The four-digit year of registration.
- """
-
- class CreateParamsAccountCompanyVerification(TypedDict):
- document: NotRequired[
- "Token.CreateParamsAccountCompanyVerificationDocument"
- ]
- """
- A document verifying the business.
- """
-
- class CreateParamsAccountCompanyVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsAccountIndividual(TypedDict):
- address: NotRequired["Token.CreateParamsAccountIndividualAddress"]
- """
- The individual's primary address.
- """
- address_kana: NotRequired[
- "Token.CreateParamsAccountIndividualAddressKana"
- ]
- """
- The Kana variation of the individual's primary address (Japan only).
- """
- address_kanji: NotRequired[
- "Token.CreateParamsAccountIndividualAddressKanji"
- ]
- """
- The Kanji variation of the individual's primary address (Japan only).
- """
- dob: NotRequired["Literal['']|Token.CreateParamsAccountIndividualDob"]
- """
- The individual's date of birth.
- """
- email: NotRequired[str]
- """
- The individual's email address.
- """
- first_name: NotRequired[str]
- """
- The individual's first name.
- """
- first_name_kana: NotRequired[str]
- """
- The Kana variation of the individual's first name (Japan only).
- """
- first_name_kanji: NotRequired[str]
- """
- The Kanji variation of the individual's first name (Japan only).
- """
- full_name_aliases: NotRequired["Literal['']|List[str]"]
- """
- A list of alternate names or aliases that the individual is known by.
- """
- gender: NotRequired[str]
- """
- The individual's gender
- """
- id_number: NotRequired[str]
- """
- The government-issued ID number of the individual, as appropriate for the representative's country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in Canada). Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- id_number_secondary: NotRequired[str]
- """
- The government-issued secondary ID number of the individual, as appropriate for the representative's country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- last_name: NotRequired[str]
- """
- The individual's last name.
- """
- last_name_kana: NotRequired[str]
- """
- The Kana variation of the individual's last name (Japan only).
- """
- last_name_kanji: NotRequired[str]
- """
- The Kanji variation of the individual's last name (Japan only).
- """
- maiden_name: NotRequired[str]
- """
- The individual's maiden name.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- phone: NotRequired[str]
- """
- The individual's phone number.
- """
- political_exposure: NotRequired[Literal["existing", "none"]]
- """
- Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
- """
- registered_address: NotRequired[
- "Token.CreateParamsAccountIndividualRegisteredAddress"
- ]
- """
- The individual's registered address.
- """
- relationship: NotRequired[
- "Token.CreateParamsAccountIndividualRelationship"
- ]
- """
- Describes the person's relationship to the account.
- """
- ssn_last_4: NotRequired[str]
- """
- The last four digits of the individual's Social Security Number (U.S. only).
- """
- verification: NotRequired[
- "Token.CreateParamsAccountIndividualVerification"
- ]
- """
- The individual's verification document information.
- """
-
- class CreateParamsAccountIndividualAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsAccountIndividualAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsAccountIndividualAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsAccountIndividualDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsAccountIndividualRegisteredAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsAccountIndividualRelationship(TypedDict):
- director: NotRequired[bool]
- """
- Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
- """
- executive: NotRequired[bool]
- """
- Whether the person has significant responsibility to control, manage, or direct the organization.
- """
- owner: NotRequired[bool]
- """
- Whether the person is an owner of the account's legal entity.
- """
- percent_ownership: NotRequired["Literal['']|float"]
- """
- The percent owned by the person of the account's legal entity.
- """
- title: NotRequired[str]
- """
- The person's title (e.g., CEO, Support Engineer).
- """
-
- class CreateParamsAccountIndividualVerification(TypedDict):
- additional_document: NotRequired[
- "Token.CreateParamsAccountIndividualVerificationAdditionalDocument"
- ]
- """
- A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
- """
- document: NotRequired[
- "Token.CreateParamsAccountIndividualVerificationDocument"
- ]
- """
- An identifying document, either a passport or local ID card.
- """
-
- class CreateParamsAccountIndividualVerificationAdditionalDocument(
- TypedDict,
- ):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsAccountIndividualVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name of the person or business that owns the bank account. This field is required when attaching the bank account to a `Customer` object.
- """
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
- """
- account_number: str
- """
- The account number for the bank account, in string form. Must be a checking account.
- """
- account_type: NotRequired[
- Literal["checking", "futsu", "savings", "toza"]
- ]
- """
- The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`.
- """
- country: str
- """
- The country in which the bank account is located.
- """
- currency: NotRequired[str]
- """
- The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](https://stripe.com/docs/payouts)
- """
- payment_method: NotRequired[str]
- """
- The ID of a Payment Method with a `type` of `us_bank_account`. The Payment Method's bank account information will be copied and returned as a Bank Account Token. This parameter is exclusive with respect to all other parameters in the `bank_account` hash. You must include the top-level `customer` parameter if the Payment Method is attached to a `Customer` object. If the Payment Method is not attached to a `Customer` object, it will be consumed and cannot be used again. You may not use Payment Methods which were created by a Setup Intent with `attach_to_self=true`.
- """
- routing_number: NotRequired[str]
- """
- The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
- """
-
- class CreateParamsCard(TypedDict):
- address_city: NotRequired[str]
- """
- City / District / Suburb / Town / Village.
- """
- address_country: NotRequired[str]
- """
- Billing address country, if provided.
- """
- address_line1: NotRequired[str]
- """
- Address line 1 (Street address / PO Box / Company name).
- """
- address_line2: NotRequired[str]
- """
- Address line 2 (Apartment / Suite / Unit / Building).
- """
- address_state: NotRequired[str]
- """
- State / County / Province / Region.
- """
- address_zip: NotRequired[str]
- """
- ZIP or postal code.
- """
- currency: NotRequired[str]
- """
- Required in order to add the card to an account; in all other cases, this parameter is not used. When added to an account, the card (which must be a debit card) can be used as a transfer destination for funds in this currency.
- """
- cvc: NotRequired[str]
- """
- Card security code. Highly recommended to always include this value.
- """
- exp_month: str
- """
- Two-digit number representing the card's expiration month.
- """
- exp_year: str
- """
- Two- or four-digit number representing the card's expiration year.
- """
- name: NotRequired[str]
- """
- Cardholder's full name.
- """
- networks: NotRequired["Token.CreateParamsCardNetworks"]
- """
- Contains information about card networks used to process the payment.
- """
- number: str
- """
- The card number, as a string without any separators.
- """
-
- class CreateParamsCardNetworks(TypedDict):
- preferred: NotRequired[
- Literal["cartes_bancaires", "mastercard", "visa"]
- ]
- """
- The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
- """
-
- class CreateParamsCvcUpdate(TypedDict):
- cvc: str
- """
- The CVC value, in string form.
- """
-
- class CreateParamsPerson(TypedDict):
- additional_tos_acceptances: NotRequired[
- "Token.CreateParamsPersonAdditionalTosAcceptances"
- ]
- """
- Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.
- """
- address: NotRequired["Token.CreateParamsPersonAddress"]
- """
- The person's address.
- """
- address_kana: NotRequired["Token.CreateParamsPersonAddressKana"]
- """
- The Kana variation of the person's address (Japan only).
- """
- address_kanji: NotRequired["Token.CreateParamsPersonAddressKanji"]
- """
- The Kanji variation of the person's address (Japan only).
- """
- dob: NotRequired["Literal['']|Token.CreateParamsPersonDob"]
- """
- The person's date of birth.
- """
- documents: NotRequired["Token.CreateParamsPersonDocuments"]
- """
- Documents that may be submitted to satisfy various informational requests.
- """
- email: NotRequired[str]
- """
- The person's email address.
- """
- first_name: NotRequired[str]
- """
- The person's first name.
- """
- first_name_kana: NotRequired[str]
- """
- The Kana variation of the person's first name (Japan only).
- """
- first_name_kanji: NotRequired[str]
- """
- The Kanji variation of the person's first name (Japan only).
- """
- full_name_aliases: NotRequired["Literal['']|List[str]"]
- """
- A list of alternate names or aliases that the person is known by.
- """
- gender: NotRequired[str]
- """
- The person's gender (International regulations require either "male" or "female").
- """
- id_number: NotRequired[str]
- """
- The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- id_number_secondary: NotRequired[str]
- """
- The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- last_name: NotRequired[str]
- """
- The person's last name.
- """
- last_name_kana: NotRequired[str]
- """
- The Kana variation of the person's last name (Japan only).
- """
- last_name_kanji: NotRequired[str]
- """
- The Kanji variation of the person's last name (Japan only).
- """
- maiden_name: NotRequired[str]
- """
- The person's maiden name.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nationality: NotRequired[str]
- """
- The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or "XX" if unavailable.
- """
- phone: NotRequired[str]
- """
- The person's phone number.
- """
- political_exposure: NotRequired[Literal["existing", "none"]]
- """
- Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
- """
- registered_address: NotRequired[
- "Token.CreateParamsPersonRegisteredAddress"
- ]
- """
- The person's registered address.
- """
- relationship: NotRequired["Token.CreateParamsPersonRelationship"]
- """
- The relationship that this person has with the account's legal entity.
- """
- ssn_last_4: NotRequired[str]
- """
- The last four digits of the person's Social Security number (U.S. only).
- """
- us_cfpb_data: NotRequired["Token.CreateParamsPersonUsCfpbData"]
- """
- Demographic data related to the person.
- """
- verification: NotRequired["Token.CreateParamsPersonVerification"]
- """
- The person's verification status.
- """
-
- class CreateParamsPersonAdditionalTosAcceptances(TypedDict):
- account: NotRequired[
- "Token.CreateParamsPersonAdditionalTosAcceptancesAccount"
- ]
- """
- Details on the legal guardian's acceptance of the main Stripe service agreement.
- """
-
- class CreateParamsPersonAdditionalTosAcceptancesAccount(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the account representative accepted the service agreement.
- """
- ip: NotRequired[str]
- """
- The IP address from which the account representative accepted the service agreement.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the account representative accepted the service agreement.
- """
-
- class CreateParamsPersonAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsPersonAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsPersonAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsPersonDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsPersonDocuments(TypedDict):
- company_authorization: NotRequired[
- "Token.CreateParamsPersonDocumentsCompanyAuthorization"
- ]
- """
- One or more documents that demonstrate proof that this person is authorized to represent the company.
- """
- passport: NotRequired["Token.CreateParamsPersonDocumentsPassport"]
- """
- One or more documents showing the person's passport page with photo and personal data.
- """
- visa: NotRequired["Token.CreateParamsPersonDocumentsVisa"]
- """
- One or more documents showing the person's visa required for living in the country where they are residing.
- """
-
- class CreateParamsPersonDocumentsCompanyAuthorization(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsPersonDocumentsPassport(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsPersonDocumentsVisa(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsPersonRegisteredAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsPersonRelationship(TypedDict):
- authorizer: NotRequired[bool]
- """
- Whether the person is the authorizer of the account's representative.
- """
- director: NotRequired[bool]
- """
- Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
- """
- executive: NotRequired[bool]
- """
- Whether the person has significant responsibility to control, manage, or direct the organization.
- """
- legal_guardian: NotRequired[bool]
- """
- Whether the person is the legal guardian of the account's representative.
- """
- owner: NotRequired[bool]
- """
- Whether the person is an owner of the account's legal entity.
- """
- percent_ownership: NotRequired["Literal['']|float"]
- """
- The percent owned by the person of the account's legal entity.
- """
- representative: NotRequired[bool]
- """
- Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
- """
- title: NotRequired[str]
- """
- The person's title (e.g., CEO, Support Engineer).
- """
-
- class CreateParamsPersonUsCfpbData(TypedDict):
- ethnicity_details: NotRequired[
- "Token.CreateParamsPersonUsCfpbDataEthnicityDetails"
- ]
- """
- The persons ethnicity details
- """
- race_details: NotRequired[
- "Token.CreateParamsPersonUsCfpbDataRaceDetails"
- ]
- """
- The persons race details
- """
- self_identified_gender: NotRequired[str]
- """
- The persons self-identified gender
- """
-
- class CreateParamsPersonUsCfpbDataEthnicityDetails(TypedDict):
- ethnicity: NotRequired[
- List[
- Literal[
- "cuban",
- "hispanic_or_latino",
- "mexican",
- "not_hispanic_or_latino",
- "other_hispanic_or_latino",
- "prefer_not_to_answer",
- "puerto_rican",
- ]
- ]
- ]
- """
- The persons ethnicity
- """
- ethnicity_other: NotRequired[str]
- """
- Please specify your origin, when other is selected.
- """
-
- class CreateParamsPersonUsCfpbDataRaceDetails(TypedDict):
- race: NotRequired[
- List[
- Literal[
- "african_american",
- "american_indian_or_alaska_native",
- "asian",
- "asian_indian",
- "black_or_african_american",
- "chinese",
- "ethiopian",
- "filipino",
- "guamanian_or_chamorro",
- "haitian",
- "jamaican",
- "japanese",
- "korean",
- "native_hawaiian",
- "native_hawaiian_or_other_pacific_islander",
- "nigerian",
- "other_asian",
- "other_black_or_african_american",
- "other_pacific_islander",
- "prefer_not_to_answer",
- "samoan",
- "somali",
- "vietnamese",
- "white",
- ]
- ]
- ]
- """
- The persons race.
- """
- race_other: NotRequired[str]
- """
- Please specify your race, when other is selected.
- """
-
- class CreateParamsPersonVerification(TypedDict):
- additional_document: NotRequired[
- "Token.CreateParamsPersonVerificationAdditionalDocument"
- ]
- """
- A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
- """
- document: NotRequired["Token.CreateParamsPersonVerificationDocument"]
- """
- An identifying document, either a passport or local ID card.
- """
-
- class CreateParamsPersonVerificationAdditionalDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsPersonVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsPii(TypedDict):
- id_number: NotRequired[str]
- """
- The `id_number` for the PII, in string form.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
bank_account: Optional["BankAccount"]
"""
These bank accounts are payment methods on `Customer` objects.
@@ -1245,7 +84,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["Token.CreateParams"]) -> "Token":
+ def create(cls, **params: Unpack["TokenCreateParams"]) -> "Token":
"""
Creates a single-use token that represents a bank account's details.
You can use this token with any v1 API method in place of a bank account dictionary. You can only use this token once. To do so, attach it to a [connected account](https://docs.stripe.com/api#accounts) where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is application, which includes Custom accounts.
@@ -1261,7 +100,7 @@ def create(cls, **params: Unpack["Token.CreateParams"]) -> "Token":
@classmethod
async def create_async(
- cls, **params: Unpack["Token.CreateParams"]
+ cls, **params: Unpack["TokenCreateParams"]
) -> "Token":
"""
Creates a single-use token that represents a bank account's details.
@@ -1278,7 +117,7 @@ async def create_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Token.RetrieveParams"]
+ cls, id: str, **params: Unpack["TokenRetrieveParams"]
) -> "Token":
"""
Retrieves the token with the given ID.
@@ -1289,7 +128,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Token.RetrieveParams"]
+ cls, id: str, **params: Unpack["TokenRetrieveParams"]
) -> "Token":
"""
Retrieves the token with the given ID.
diff --git a/stripe/_token_service.py b/stripe/_token_service.py
index 06c6a66ae..f42c261e7 100644
--- a/stripe/_token_service.py
+++ b/stripe/_token_service.py
@@ -4,1184 +4,19 @@
from stripe._stripe_service import StripeService
from stripe._token import Token
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._token_create_params import TokenCreateParams
+ from stripe.params._token_retrieve_params import TokenRetrieveParams
-class TokenService(StripeService):
- class CreateParams(TypedDict):
- account: NotRequired["TokenService.CreateParamsAccount"]
- """
- Information for the account this token represents.
- """
- bank_account: NotRequired["TokenService.CreateParamsBankAccount"]
- """
- The bank account this token will represent.
- """
- card: NotRequired["TokenService.CreateParamsCard|str"]
- """
- The card this token will represent. If you also pass in a customer, the card must be the ID of a card belonging to the customer. Otherwise, if you do not pass in a customer, this is a dictionary containing a user's credit card details, with the options described below.
- """
- customer: NotRequired[str]
- """
- Create a token for the customer, which is owned by the application's account. You can only use this with an [OAuth access token](https://stripe.com/docs/connect/standard-accounts) or [Stripe-Account header](https://stripe.com/docs/connect/authentication). Learn more about [cloning saved payment methods](https://stripe.com/docs/connect/cloning-saved-payment-methods).
- """
- cvc_update: NotRequired["TokenService.CreateParamsCvcUpdate"]
- """
- The updated CVC value this token represents.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- person: NotRequired["TokenService.CreateParamsPerson"]
- """
- Information for the person this token represents.
- """
- pii: NotRequired["TokenService.CreateParamsPii"]
- """
- The PII this token represents.
- """
-
- class CreateParamsAccount(TypedDict):
- business_type: NotRequired[
- Literal["company", "government_entity", "individual", "non_profit"]
- ]
- """
- The business type.
- """
- company: NotRequired["TokenService.CreateParamsAccountCompany"]
- """
- Information about the company or business.
- """
- individual: NotRequired["TokenService.CreateParamsAccountIndividual"]
- """
- Information about the person represented by the account.
- """
- tos_shown_and_accepted: NotRequired[bool]
- """
- Whether the user described by the data in the token has been shown [the Stripe Connected Account Agreement](https://docs.stripe.com/connect/account-tokens#stripe-connected-account-agreement). When creating an account token to create a new Connect account, this value must be `true`.
- """
-
- class CreateParamsAccountCompany(TypedDict):
- address: NotRequired["TokenService.CreateParamsAccountCompanyAddress"]
- """
- The company's primary address.
- """
- address_kana: NotRequired[
- "TokenService.CreateParamsAccountCompanyAddressKana"
- ]
- """
- The Kana variation of the company's primary address (Japan only).
- """
- address_kanji: NotRequired[
- "TokenService.CreateParamsAccountCompanyAddressKanji"
- ]
- """
- The Kanji variation of the company's primary address (Japan only).
- """
- directors_provided: NotRequired[bool]
- """
- Whether the company's directors have been provided. Set this Boolean to `true` after creating all the company's directors with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.director` requirement. This value is not automatically set to `true` after creating directors, so it needs to be updated to indicate all directors have been provided.
- """
- directorship_declaration: NotRequired[
- "TokenService.CreateParamsAccountCompanyDirectorshipDeclaration"
- ]
- """
- This hash is used to attest that the directors information provided to Stripe is both current and correct.
- """
- executives_provided: NotRequired[bool]
- """
- Whether the company's executives have been provided. Set this Boolean to `true` after creating all the company's executives with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.executive` requirement.
- """
- export_license_id: NotRequired[str]
- """
- The export license ID number of the company, also referred as Import Export Code (India only).
- """
- export_purpose_code: NotRequired[str]
- """
- The purpose code to use for export transactions (India only).
- """
- name: NotRequired[str]
- """
- The company's legal name.
- """
- name_kana: NotRequired[str]
- """
- The Kana variation of the company's legal name (Japan only).
- """
- name_kanji: NotRequired[str]
- """
- The Kanji variation of the company's legal name (Japan only).
- """
- owners_provided: NotRequired[bool]
- """
- Whether the company's owners have been provided. Set this Boolean to `true` after creating all the company's owners with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.owner` requirement.
- """
- ownership_declaration: NotRequired[
- "TokenService.CreateParamsAccountCompanyOwnershipDeclaration"
- ]
- """
- This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
- """
- ownership_declaration_shown_and_signed: NotRequired[bool]
- """
- Whether the user described by the data in the token has been shown the Ownership Declaration and indicated that it is correct.
- """
- ownership_exemption_reason: NotRequired[
- "Literal['']|Literal['qualified_entity_exceeds_ownership_threshold', 'qualifies_as_financial_institution']"
- ]
- """
- This value is used to determine if a business is exempt from providing ultimate beneficial owners. See [this support article](https://support.stripe.com/questions/exemption-from-providing-ownership-details) and [changelog](https://docs.stripe.com/changelog/acacia/2025-01-27/ownership-exemption-reason-accounts-api) for more details.
- """
- phone: NotRequired[str]
- """
- The company's phone number (used for verification).
- """
- registration_date: NotRequired[
- "Literal['']|TokenService.CreateParamsAccountCompanyRegistrationDate"
- ]
- """
- When the business was incorporated or registered.
- """
- registration_number: NotRequired[str]
- """
- The identification number given to a company when it is registered or incorporated, if distinct from the identification number used for filing taxes. (Examples are the CIN for companies and LLP IN for partnerships in India, and the Company Registration Number in Hong Kong).
- """
- structure: NotRequired[
- "Literal['']|Literal['free_zone_establishment', 'free_zone_llc', 'government_instrumentality', 'governmental_unit', 'incorporated_non_profit', 'incorporated_partnership', 'limited_liability_partnership', 'llc', 'multi_member_llc', 'private_company', 'private_corporation', 'private_partnership', 'public_company', 'public_corporation', 'public_partnership', 'registered_charity', 'single_member_llc', 'sole_establishment', 'sole_proprietorship', 'tax_exempt_government_instrumentality', 'unincorporated_association', 'unincorporated_non_profit', 'unincorporated_partnership']"
- ]
- """
- The category identifying the legal structure of the company or legal entity. See [Business structure](https://docs.stripe.com/connect/identity-verification#business-structure) for more details. Pass an empty string to unset this value.
- """
- tax_id: NotRequired[str]
- """
- The business ID number of the company, as appropriate for the company's country. (Examples are an Employer ID Number in the U.S., a Business Number in Canada, or a Company Number in the UK.)
- """
- tax_id_registrar: NotRequired[str]
- """
- The jurisdiction in which the `tax_id` is registered (Germany-based companies only).
- """
- vat_id: NotRequired[str]
- """
- The VAT number of the company.
- """
- verification: NotRequired[
- "TokenService.CreateParamsAccountCompanyVerification"
- ]
- """
- Information on the verification state of the company.
- """
-
- class CreateParamsAccountCompanyAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsAccountCompanyAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsAccountCompanyAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsAccountCompanyDirectorshipDeclaration(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the directorship declaration attestation was made.
- """
- ip: NotRequired[str]
- """
- The IP address from which the directorship declaration attestation was made.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the directorship declaration attestation was made.
- """
-
- class CreateParamsAccountCompanyOwnershipDeclaration(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the beneficial owner attestation was made.
- """
- ip: NotRequired[str]
- """
- The IP address from which the beneficial owner attestation was made.
- """
- user_agent: NotRequired[str]
- """
- The user agent of the browser from which the beneficial owner attestation was made.
- """
-
- class CreateParamsAccountCompanyRegistrationDate(TypedDict):
- day: int
- """
- The day of registration, between 1 and 31.
- """
- month: int
- """
- The month of registration, between 1 and 12.
- """
- year: int
- """
- The four-digit year of registration.
- """
-
- class CreateParamsAccountCompanyVerification(TypedDict):
- document: NotRequired[
- "TokenService.CreateParamsAccountCompanyVerificationDocument"
- ]
- """
- A document verifying the business.
- """
-
- class CreateParamsAccountCompanyVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsAccountIndividual(TypedDict):
- address: NotRequired[
- "TokenService.CreateParamsAccountIndividualAddress"
- ]
- """
- The individual's primary address.
- """
- address_kana: NotRequired[
- "TokenService.CreateParamsAccountIndividualAddressKana"
- ]
- """
- The Kana variation of the individual's primary address (Japan only).
- """
- address_kanji: NotRequired[
- "TokenService.CreateParamsAccountIndividualAddressKanji"
- ]
- """
- The Kanji variation of the individual's primary address (Japan only).
- """
- dob: NotRequired[
- "Literal['']|TokenService.CreateParamsAccountIndividualDob"
- ]
- """
- The individual's date of birth.
- """
- email: NotRequired[str]
- """
- The individual's email address.
- """
- first_name: NotRequired[str]
- """
- The individual's first name.
- """
- first_name_kana: NotRequired[str]
- """
- The Kana variation of the individual's first name (Japan only).
- """
- first_name_kanji: NotRequired[str]
- """
- The Kanji variation of the individual's first name (Japan only).
- """
- full_name_aliases: NotRequired["Literal['']|List[str]"]
- """
- A list of alternate names or aliases that the individual is known by.
- """
- gender: NotRequired[str]
- """
- The individual's gender
- """
- id_number: NotRequired[str]
- """
- The government-issued ID number of the individual, as appropriate for the representative's country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in Canada). Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- id_number_secondary: NotRequired[str]
- """
- The government-issued secondary ID number of the individual, as appropriate for the representative's country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- last_name: NotRequired[str]
- """
- The individual's last name.
- """
- last_name_kana: NotRequired[str]
- """
- The Kana variation of the individual's last name (Japan only).
- """
- last_name_kanji: NotRequired[str]
- """
- The Kanji variation of the individual's last name (Japan only).
- """
- maiden_name: NotRequired[str]
- """
- The individual's maiden name.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- phone: NotRequired[str]
- """
- The individual's phone number.
- """
- political_exposure: NotRequired[Literal["existing", "none"]]
- """
- Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
- """
- registered_address: NotRequired[
- "TokenService.CreateParamsAccountIndividualRegisteredAddress"
- ]
- """
- The individual's registered address.
- """
- relationship: NotRequired[
- "TokenService.CreateParamsAccountIndividualRelationship"
- ]
- """
- Describes the person's relationship to the account.
- """
- ssn_last_4: NotRequired[str]
- """
- The last four digits of the individual's Social Security Number (U.S. only).
- """
- verification: NotRequired[
- "TokenService.CreateParamsAccountIndividualVerification"
- ]
- """
- The individual's verification document information.
- """
-
- class CreateParamsAccountIndividualAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsAccountIndividualAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsAccountIndividualAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsAccountIndividualDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsAccountIndividualRegisteredAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsAccountIndividualRelationship(TypedDict):
- director: NotRequired[bool]
- """
- Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
- """
- executive: NotRequired[bool]
- """
- Whether the person has significant responsibility to control, manage, or direct the organization.
- """
- owner: NotRequired[bool]
- """
- Whether the person is an owner of the account's legal entity.
- """
- percent_ownership: NotRequired["Literal['']|float"]
- """
- The percent owned by the person of the account's legal entity.
- """
- title: NotRequired[str]
- """
- The person's title (e.g., CEO, Support Engineer).
- """
-
- class CreateParamsAccountIndividualVerification(TypedDict):
- additional_document: NotRequired[
- "TokenService.CreateParamsAccountIndividualVerificationAdditionalDocument"
- ]
- """
- A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
- """
- document: NotRequired[
- "TokenService.CreateParamsAccountIndividualVerificationDocument"
- ]
- """
- An identifying document, either a passport or local ID card.
- """
-
- class CreateParamsAccountIndividualVerificationAdditionalDocument(
- TypedDict,
- ):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsAccountIndividualVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name of the person or business that owns the bank account. This field is required when attaching the bank account to a `Customer` object.
- """
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
- """
- account_number: str
- """
- The account number for the bank account, in string form. Must be a checking account.
- """
- account_type: NotRequired[
- Literal["checking", "futsu", "savings", "toza"]
- ]
- """
- The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`.
- """
- country: str
- """
- The country in which the bank account is located.
- """
- currency: NotRequired[str]
- """
- The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](https://stripe.com/docs/payouts)
- """
- payment_method: NotRequired[str]
- """
- The ID of a Payment Method with a `type` of `us_bank_account`. The Payment Method's bank account information will be copied and returned as a Bank Account Token. This parameter is exclusive with respect to all other parameters in the `bank_account` hash. You must include the top-level `customer` parameter if the Payment Method is attached to a `Customer` object. If the Payment Method is not attached to a `Customer` object, it will be consumed and cannot be used again. You may not use Payment Methods which were created by a Setup Intent with `attach_to_self=true`.
- """
- routing_number: NotRequired[str]
- """
- The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
- """
-
- class CreateParamsCard(TypedDict):
- address_city: NotRequired[str]
- """
- City / District / Suburb / Town / Village.
- """
- address_country: NotRequired[str]
- """
- Billing address country, if provided.
- """
- address_line1: NotRequired[str]
- """
- Address line 1 (Street address / PO Box / Company name).
- """
- address_line2: NotRequired[str]
- """
- Address line 2 (Apartment / Suite / Unit / Building).
- """
- address_state: NotRequired[str]
- """
- State / County / Province / Region.
- """
- address_zip: NotRequired[str]
- """
- ZIP or postal code.
- """
- currency: NotRequired[str]
- """
- Required in order to add the card to an account; in all other cases, this parameter is not used. When added to an account, the card (which must be a debit card) can be used as a transfer destination for funds in this currency.
- """
- cvc: NotRequired[str]
- """
- Card security code. Highly recommended to always include this value.
- """
- exp_month: str
- """
- Two-digit number representing the card's expiration month.
- """
- exp_year: str
- """
- Two- or four-digit number representing the card's expiration year.
- """
- name: NotRequired[str]
- """
- Cardholder's full name.
- """
- networks: NotRequired["TokenService.CreateParamsCardNetworks"]
- """
- Contains information about card networks used to process the payment.
- """
- number: str
- """
- The card number, as a string without any separators.
- """
-
- class CreateParamsCardNetworks(TypedDict):
- preferred: NotRequired[
- Literal["cartes_bancaires", "mastercard", "visa"]
- ]
- """
- The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
- """
-
- class CreateParamsCvcUpdate(TypedDict):
- cvc: str
- """
- The CVC value, in string form.
- """
-
- class CreateParamsPerson(TypedDict):
- additional_tos_acceptances: NotRequired[
- "TokenService.CreateParamsPersonAdditionalTosAcceptances"
- ]
- """
- Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.
- """
- address: NotRequired["TokenService.CreateParamsPersonAddress"]
- """
- The person's address.
- """
- address_kana: NotRequired["TokenService.CreateParamsPersonAddressKana"]
- """
- The Kana variation of the person's address (Japan only).
- """
- address_kanji: NotRequired[
- "TokenService.CreateParamsPersonAddressKanji"
- ]
- """
- The Kanji variation of the person's address (Japan only).
- """
- dob: NotRequired["Literal['']|TokenService.CreateParamsPersonDob"]
- """
- The person's date of birth.
- """
- documents: NotRequired["TokenService.CreateParamsPersonDocuments"]
- """
- Documents that may be submitted to satisfy various informational requests.
- """
- email: NotRequired[str]
- """
- The person's email address.
- """
- first_name: NotRequired[str]
- """
- The person's first name.
- """
- first_name_kana: NotRequired[str]
- """
- The Kana variation of the person's first name (Japan only).
- """
- first_name_kanji: NotRequired[str]
- """
- The Kanji variation of the person's first name (Japan only).
- """
- full_name_aliases: NotRequired["Literal['']|List[str]"]
- """
- A list of alternate names or aliases that the person is known by.
- """
- gender: NotRequired[str]
- """
- The person's gender (International regulations require either "male" or "female").
- """
- id_number: NotRequired[str]
- """
- The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- id_number_secondary: NotRequired[str]
- """
- The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
- """
- last_name: NotRequired[str]
- """
- The person's last name.
- """
- last_name_kana: NotRequired[str]
- """
- The Kana variation of the person's last name (Japan only).
- """
- last_name_kanji: NotRequired[str]
- """
- The Kanji variation of the person's last name (Japan only).
- """
- maiden_name: NotRequired[str]
- """
- The person's maiden name.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nationality: NotRequired[str]
- """
- The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or "XX" if unavailable.
- """
- phone: NotRequired[str]
- """
- The person's phone number.
- """
- political_exposure: NotRequired[Literal["existing", "none"]]
- """
- Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
- """
- registered_address: NotRequired[
- "TokenService.CreateParamsPersonRegisteredAddress"
- ]
- """
- The person's registered address.
- """
- relationship: NotRequired[
- "TokenService.CreateParamsPersonRelationship"
- ]
- """
- The relationship that this person has with the account's legal entity.
- """
- ssn_last_4: NotRequired[str]
- """
- The last four digits of the person's Social Security number (U.S. only).
- """
- us_cfpb_data: NotRequired["TokenService.CreateParamsPersonUsCfpbData"]
- """
- Demographic data related to the person.
- """
- verification: NotRequired[
- "TokenService.CreateParamsPersonVerification"
- ]
- """
- The person's verification status.
- """
-
- class CreateParamsPersonAdditionalTosAcceptances(TypedDict):
- account: NotRequired[
- "TokenService.CreateParamsPersonAdditionalTosAcceptancesAccount"
- ]
- """
- Details on the legal guardian's acceptance of the main Stripe service agreement.
- """
-
- class CreateParamsPersonAdditionalTosAcceptancesAccount(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the account representative accepted the service agreement.
- """
- ip: NotRequired[str]
- """
- The IP address from which the account representative accepted the service agreement.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the account representative accepted the service agreement.
- """
-
- class CreateParamsPersonAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsPersonAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsPersonAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsPersonDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsPersonDocuments(TypedDict):
- company_authorization: NotRequired[
- "TokenService.CreateParamsPersonDocumentsCompanyAuthorization"
- ]
- """
- One or more documents that demonstrate proof that this person is authorized to represent the company.
- """
- passport: NotRequired[
- "TokenService.CreateParamsPersonDocumentsPassport"
- ]
- """
- One or more documents showing the person's passport page with photo and personal data.
- """
- visa: NotRequired["TokenService.CreateParamsPersonDocumentsVisa"]
- """
- One or more documents showing the person's visa required for living in the country where they are residing.
- """
-
- class CreateParamsPersonDocumentsCompanyAuthorization(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsPersonDocumentsPassport(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsPersonDocumentsVisa(TypedDict):
- files: NotRequired[List[str]]
- """
- One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
- """
-
- class CreateParamsPersonRegisteredAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsPersonRelationship(TypedDict):
- authorizer: NotRequired[bool]
- """
- Whether the person is the authorizer of the account's representative.
- """
- director: NotRequired[bool]
- """
- Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
- """
- executive: NotRequired[bool]
- """
- Whether the person has significant responsibility to control, manage, or direct the organization.
- """
- legal_guardian: NotRequired[bool]
- """
- Whether the person is the legal guardian of the account's representative.
- """
- owner: NotRequired[bool]
- """
- Whether the person is an owner of the account's legal entity.
- """
- percent_ownership: NotRequired["Literal['']|float"]
- """
- The percent owned by the person of the account's legal entity.
- """
- representative: NotRequired[bool]
- """
- Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
- """
- title: NotRequired[str]
- """
- The person's title (e.g., CEO, Support Engineer).
- """
-
- class CreateParamsPersonUsCfpbData(TypedDict):
- ethnicity_details: NotRequired[
- "TokenService.CreateParamsPersonUsCfpbDataEthnicityDetails"
- ]
- """
- The persons ethnicity details
- """
- race_details: NotRequired[
- "TokenService.CreateParamsPersonUsCfpbDataRaceDetails"
- ]
- """
- The persons race details
- """
- self_identified_gender: NotRequired[str]
- """
- The persons self-identified gender
- """
-
- class CreateParamsPersonUsCfpbDataEthnicityDetails(TypedDict):
- ethnicity: NotRequired[
- List[
- Literal[
- "cuban",
- "hispanic_or_latino",
- "mexican",
- "not_hispanic_or_latino",
- "other_hispanic_or_latino",
- "prefer_not_to_answer",
- "puerto_rican",
- ]
- ]
- ]
- """
- The persons ethnicity
- """
- ethnicity_other: NotRequired[str]
- """
- Please specify your origin, when other is selected.
- """
-
- class CreateParamsPersonUsCfpbDataRaceDetails(TypedDict):
- race: NotRequired[
- List[
- Literal[
- "african_american",
- "american_indian_or_alaska_native",
- "asian",
- "asian_indian",
- "black_or_african_american",
- "chinese",
- "ethiopian",
- "filipino",
- "guamanian_or_chamorro",
- "haitian",
- "jamaican",
- "japanese",
- "korean",
- "native_hawaiian",
- "native_hawaiian_or_other_pacific_islander",
- "nigerian",
- "other_asian",
- "other_black_or_african_american",
- "other_pacific_islander",
- "prefer_not_to_answer",
- "samoan",
- "somali",
- "vietnamese",
- "white",
- ]
- ]
- ]
- """
- The persons race.
- """
- race_other: NotRequired[str]
- """
- Please specify your race, when other is selected.
- """
-
- class CreateParamsPersonVerification(TypedDict):
- additional_document: NotRequired[
- "TokenService.CreateParamsPersonVerificationAdditionalDocument"
- ]
- """
- A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
- """
- document: NotRequired[
- "TokenService.CreateParamsPersonVerificationDocument"
- ]
- """
- An identifying document, either a passport or local ID card.
- """
-
- class CreateParamsPersonVerificationAdditionalDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsPersonVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
- """
-
- class CreateParamsPii(TypedDict):
- id_number: NotRequired[str]
- """
- The `id_number` for the PII, in string form.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class TokenService(StripeService):
def retrieve(
self,
token: str,
- params: Optional["TokenService.RetrieveParams"] = None,
+ params: Optional["TokenRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Token:
"""
@@ -1201,7 +36,7 @@ def retrieve(
async def retrieve_async(
self,
token: str,
- params: Optional["TokenService.RetrieveParams"] = None,
+ params: Optional["TokenRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Token:
"""
@@ -1220,7 +55,7 @@ async def retrieve_async(
def create(
self,
- params: Optional["TokenService.CreateParams"] = None,
+ params: Optional["TokenCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Token:
"""
@@ -1240,7 +75,7 @@ def create(
async def create_async(
self,
- params: Optional["TokenService.CreateParams"] = None,
+ params: Optional["TokenCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Token:
"""
diff --git a/stripe/_topup.py b/stripe/_topup.py
index 9c1dc0004..e95ddfd20 100644
--- a/stripe/_topup.py
+++ b/stripe/_topup.py
@@ -4,21 +4,19 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Dict, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._balance_transaction import BalanceTransaction
from stripe._source import Source
+ from stripe.params._topup_cancel_params import TopupCancelParams
+ from stripe.params._topup_create_params import TopupCreateParams
+ from stripe.params._topup_list_params import TopupListParams
+ from stripe.params._topup_modify_params import TopupModifyParams
+ from stripe.params._topup_retrieve_params import TopupRetrieveParams
class Topup(
@@ -35,135 +33,6 @@ class Topup(
"""
OBJECT_NAME: ClassVar[Literal["topup"]] = "topup"
-
- class CancelParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(RequestOptions):
- amount: int
- """
- A positive integer representing how much to transfer.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- source: NotRequired[str]
- """
- The ID of a source to transfer funds from. For most users, this should be left unspecified which will use the bank account that was set up in the dashboard for the specified currency. In test mode, this can be a test bank token (see [Testing Top-ups](https://stripe.com/docs/connect/testing#testing-top-ups)).
- """
- statement_descriptor: NotRequired[str]
- """
- Extra information about a top-up for the source's bank statement. Limited to 15 ASCII characters.
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies this top-up as part of a group.
- """
-
- class ListParams(RequestOptions):
- amount: NotRequired["Topup.ListParamsAmount|int"]
- """
- A positive integer representing how much to transfer.
- """
- created: NotRequired["Topup.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["canceled", "failed", "pending", "succeeded"]
- ]
- """
- Only return top-ups that have the given status. One of `canceled`, `failed`, `pending` or `succeeded`.
- """
-
- class ListParamsAmount(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount: int
"""
Amount transferred.
@@ -231,7 +100,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def _cls_cancel(
- cls, topup: str, **params: Unpack["Topup.CancelParams"]
+ cls, topup: str, **params: Unpack["TopupCancelParams"]
) -> "Topup":
"""
Cancels a top-up. Only pending top-ups can be canceled.
@@ -247,14 +116,14 @@ def _cls_cancel(
@overload
@staticmethod
- def cancel(topup: str, **params: Unpack["Topup.CancelParams"]) -> "Topup":
+ def cancel(topup: str, **params: Unpack["TopupCancelParams"]) -> "Topup":
"""
Cancels a top-up. Only pending top-ups can be canceled.
"""
...
@overload
- def cancel(self, **params: Unpack["Topup.CancelParams"]) -> "Topup":
+ def cancel(self, **params: Unpack["TopupCancelParams"]) -> "Topup":
"""
Cancels a top-up. Only pending top-ups can be canceled.
"""
@@ -262,7 +131,7 @@ def cancel(self, **params: Unpack["Topup.CancelParams"]) -> "Topup":
@class_method_variant("_cls_cancel")
def cancel( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Topup.CancelParams"]
+ self, **params: Unpack["TopupCancelParams"]
) -> "Topup":
"""
Cancels a top-up. Only pending top-ups can be canceled.
@@ -280,7 +149,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_cancel_async(
- cls, topup: str, **params: Unpack["Topup.CancelParams"]
+ cls, topup: str, **params: Unpack["TopupCancelParams"]
) -> "Topup":
"""
Cancels a top-up. Only pending top-ups can be canceled.
@@ -297,7 +166,7 @@ async def _cls_cancel_async(
@overload
@staticmethod
async def cancel_async(
- topup: str, **params: Unpack["Topup.CancelParams"]
+ topup: str, **params: Unpack["TopupCancelParams"]
) -> "Topup":
"""
Cancels a top-up. Only pending top-ups can be canceled.
@@ -306,7 +175,7 @@ async def cancel_async(
@overload
async def cancel_async(
- self, **params: Unpack["Topup.CancelParams"]
+ self, **params: Unpack["TopupCancelParams"]
) -> "Topup":
"""
Cancels a top-up. Only pending top-ups can be canceled.
@@ -315,7 +184,7 @@ async def cancel_async(
@class_method_variant("_cls_cancel_async")
async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Topup.CancelParams"]
+ self, **params: Unpack["TopupCancelParams"]
) -> "Topup":
"""
Cancels a top-up. Only pending top-ups can be canceled.
@@ -332,7 +201,7 @@ async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
)
@classmethod
- def create(cls, **params: Unpack["Topup.CreateParams"]) -> "Topup":
+ def create(cls, **params: Unpack["TopupCreateParams"]) -> "Topup":
"""
Top up the balance of an account
"""
@@ -347,7 +216,7 @@ def create(cls, **params: Unpack["Topup.CreateParams"]) -> "Topup":
@classmethod
async def create_async(
- cls, **params: Unpack["Topup.CreateParams"]
+ cls, **params: Unpack["TopupCreateParams"]
) -> "Topup":
"""
Top up the balance of an account
@@ -362,7 +231,7 @@ async def create_async(
)
@classmethod
- def list(cls, **params: Unpack["Topup.ListParams"]) -> ListObject["Topup"]:
+ def list(cls, **params: Unpack["TopupListParams"]) -> ListObject["Topup"]:
"""
Returns a list of top-ups.
"""
@@ -381,7 +250,7 @@ def list(cls, **params: Unpack["Topup.ListParams"]) -> ListObject["Topup"]:
@classmethod
async def list_async(
- cls, **params: Unpack["Topup.ListParams"]
+ cls, **params: Unpack["TopupListParams"]
) -> ListObject["Topup"]:
"""
Returns a list of top-ups.
@@ -400,9 +269,7 @@ async def list_async(
return result
@classmethod
- def modify(
- cls, id: str, **params: Unpack["Topup.ModifyParams"]
- ) -> "Topup":
+ def modify(cls, id: str, **params: Unpack["TopupModifyParams"]) -> "Topup":
"""
Updates the metadata of a top-up. Other top-up details are not editable by design.
"""
@@ -418,7 +285,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Topup.ModifyParams"]
+ cls, id: str, **params: Unpack["TopupModifyParams"]
) -> "Topup":
"""
Updates the metadata of a top-up. Other top-up details are not editable by design.
@@ -435,7 +302,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Topup.RetrieveParams"]
+ cls, id: str, **params: Unpack["TopupRetrieveParams"]
) -> "Topup":
"""
Retrieves the details of a top-up that has previously been created. Supply the unique top-up ID that was returned from your previous request, and Stripe will return the corresponding top-up information.
@@ -446,7 +313,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Topup.RetrieveParams"]
+ cls, id: str, **params: Unpack["TopupRetrieveParams"]
) -> "Topup":
"""
Retrieves the details of a top-up that has previously been created. Supply the unique top-up ID that was returned from your previous request, and Stripe will return the corresponding top-up information.
diff --git a/stripe/_topup_service.py b/stripe/_topup_service.py
index c76f99123..5e29002e9 100644
--- a/stripe/_topup_service.py
+++ b/stripe/_topup_service.py
@@ -5,142 +5,21 @@
from stripe._stripe_service import StripeService
from stripe._topup import Topup
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params._topup_cancel_params import TopupCancelParams
+ from stripe.params._topup_create_params import TopupCreateParams
+ from stripe.params._topup_list_params import TopupListParams
+ from stripe.params._topup_retrieve_params import TopupRetrieveParams
+ from stripe.params._topup_update_params import TopupUpdateParams
-class TopupService(StripeService):
- class CancelParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(TypedDict):
- amount: int
- """
- A positive integer representing how much to transfer.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- source: NotRequired[str]
- """
- The ID of a source to transfer funds from. For most users, this should be left unspecified which will use the bank account that was set up in the dashboard for the specified currency. In test mode, this can be a test bank token (see [Testing Top-ups](https://stripe.com/docs/connect/testing#testing-top-ups)).
- """
- statement_descriptor: NotRequired[str]
- """
- Extra information about a top-up for the source's bank statement. Limited to 15 ASCII characters.
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies this top-up as part of a group.
- """
-
- class ListParams(TypedDict):
- amount: NotRequired["TopupService.ListParamsAmount|int"]
- """
- A positive integer representing how much to transfer.
- """
- created: NotRequired["TopupService.ListParamsCreated|int"]
- """
- A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["canceled", "failed", "pending", "succeeded"]
- ]
- """
- Only return top-ups that have the given status. One of `canceled`, `failed`, `pending` or `succeeded`.
- """
-
- class ListParamsAmount(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
+class TopupService(StripeService):
def list(
self,
- params: Optional["TopupService.ListParams"] = None,
+ params: Optional["TopupListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Topup]:
"""
@@ -159,7 +38,7 @@ def list(
async def list_async(
self,
- params: Optional["TopupService.ListParams"] = None,
+ params: Optional["TopupListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Topup]:
"""
@@ -178,7 +57,7 @@ async def list_async(
def create(
self,
- params: "TopupService.CreateParams",
+ params: "TopupCreateParams",
options: Optional[RequestOptions] = None,
) -> Topup:
"""
@@ -197,7 +76,7 @@ def create(
async def create_async(
self,
- params: "TopupService.CreateParams",
+ params: "TopupCreateParams",
options: Optional[RequestOptions] = None,
) -> Topup:
"""
@@ -217,7 +96,7 @@ async def create_async(
def retrieve(
self,
topup: str,
- params: Optional["TopupService.RetrieveParams"] = None,
+ params: Optional["TopupRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Topup:
"""
@@ -237,7 +116,7 @@ def retrieve(
async def retrieve_async(
self,
topup: str,
- params: Optional["TopupService.RetrieveParams"] = None,
+ params: Optional["TopupRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Topup:
"""
@@ -257,7 +136,7 @@ async def retrieve_async(
def update(
self,
topup: str,
- params: Optional["TopupService.UpdateParams"] = None,
+ params: Optional["TopupUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Topup:
"""
@@ -277,7 +156,7 @@ def update(
async def update_async(
self,
topup: str,
- params: Optional["TopupService.UpdateParams"] = None,
+ params: Optional["TopupUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Topup:
"""
@@ -297,7 +176,7 @@ async def update_async(
def cancel(
self,
topup: str,
- params: Optional["TopupService.CancelParams"] = None,
+ params: Optional["TopupCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> Topup:
"""
@@ -317,7 +196,7 @@ def cancel(
async def cancel_async(
self,
topup: str,
- params: Optional["TopupService.CancelParams"] = None,
+ params: Optional["TopupCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> Topup:
"""
diff --git a/stripe/_transfer.py b/stripe/_transfer.py
index 93daa6844..b45980e9f 100644
--- a/stripe/_transfer.py
+++ b/stripe/_transfer.py
@@ -5,23 +5,32 @@
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
from stripe._nested_resource_class_methods import nested_resource_class_methods
-from stripe._request_options import RequestOptions
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import sanitize_id
-from typing import ClassVar, Dict, List, Optional, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Dict, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account
from stripe._balance_transaction import BalanceTransaction
from stripe._charge import Charge
from stripe._reversal import Reversal
+ from stripe.params._transfer_create_params import TransferCreateParams
+ from stripe.params._transfer_create_reversal_params import (
+ TransferCreateReversalParams,
+ )
+ from stripe.params._transfer_list_params import TransferListParams
+ from stripe.params._transfer_list_reversals_params import (
+ TransferListReversalsParams,
+ )
+ from stripe.params._transfer_modify_params import TransferModifyParams
+ from stripe.params._transfer_modify_reversal_params import (
+ TransferModifyReversalParams,
+ )
+ from stripe.params._transfer_retrieve_params import TransferRetrieveParams
+ from stripe.params._transfer_retrieve_reversal_params import (
+ TransferRetrieveReversalParams,
+ )
@nested_resource_class_methods("reversal")
@@ -44,169 +53,6 @@ class Transfer(
"""
OBJECT_NAME: ClassVar[Literal["transfer"]] = "transfer"
-
- class CreateParams(RequestOptions):
- amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) representing how much to transfer.
- """
- currency: str
- """
- Three-letter [ISO code for currency](https://www.iso.org/iso-4217-currency-codes.html) in lowercase. Must be a [supported currency](https://docs.stripe.com/currencies).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- destination: str
- """
- The ID of a connected Stripe account. [See the Connect documentation](https://docs.stripe.com/docs/connect/separate-charges-and-transfers) for details.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- source_transaction: NotRequired[str]
- """
- You can use this parameter to transfer funds from a charge before they are added to your available balance. A pending balance will transfer immediately but the funds will not become available until the original charge becomes available. [See the Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-availability) for details.
- """
- source_type: NotRequired[Literal["bank_account", "card", "fpx"]]
- """
- The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`.
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
- """
-
- class CreateReversalParams(RequestOptions):
- amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) representing how much of this transfer to reverse. Can only reverse up to the unreversed amount remaining of the transfer. Partial transfer reversals are only allowed for transfers to Stripe Accounts. Defaults to the entire transfer amount.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to a reversal object. This will be unset if you POST an empty value.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- refund_application_fee: NotRequired[bool]
- """
- Boolean indicating whether the application fee should be refunded when reversing this transfer. If a full transfer reversal is given, the full application fee will be refunded. Otherwise, the application fee will be refunded with an amount proportional to the amount of the transfer reversed.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["Transfer.ListParamsCreated|int"]
- """
- Only return transfers that were created during the given date interval.
- """
- destination: NotRequired[str]
- """
- Only return transfers for the destination specified by this account ID.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- transfer_group: NotRequired[str]
- """
- Only return transfers with the specified transfer group.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListReversalsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ModifyParams(RequestOptions):
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class ModifyReversalParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveReversalParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount: int
"""
Amount in cents (or local equivalent) to be transferred.
@@ -277,7 +123,7 @@ class RetrieveReversalParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["Transfer.CreateParams"]) -> "Transfer":
+ def create(cls, **params: Unpack["TransferCreateParams"]) -> "Transfer":
"""
To send funds from your Stripe account to a connected account, you create a new transfer object. Your [Stripe balance](https://docs.stripe.com/api#balance) must be able to cover the transfer amount, or you'll receive an “Insufficient Funds” error.
"""
@@ -292,7 +138,7 @@ def create(cls, **params: Unpack["Transfer.CreateParams"]) -> "Transfer":
@classmethod
async def create_async(
- cls, **params: Unpack["Transfer.CreateParams"]
+ cls, **params: Unpack["TransferCreateParams"]
) -> "Transfer":
"""
To send funds from your Stripe account to a connected account, you create a new transfer object. Your [Stripe balance](https://docs.stripe.com/api#balance) must be able to cover the transfer amount, or you'll receive an “Insufficient Funds” error.
@@ -308,7 +154,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["Transfer.ListParams"]
+ cls, **params: Unpack["TransferListParams"]
) -> ListObject["Transfer"]:
"""
Returns a list of existing transfers sent to connected accounts. The transfers are returned in sorted order, with the most recently created transfers appearing first.
@@ -328,7 +174,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Transfer.ListParams"]
+ cls, **params: Unpack["TransferListParams"]
) -> ListObject["Transfer"]:
"""
Returns a list of existing transfers sent to connected accounts. The transfers are returned in sorted order, with the most recently created transfers appearing first.
@@ -348,7 +194,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Transfer.ModifyParams"]
+ cls, id: str, **params: Unpack["TransferModifyParams"]
) -> "Transfer":
"""
Updates the specified transfer by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -367,7 +213,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Transfer.ModifyParams"]
+ cls, id: str, **params: Unpack["TransferModifyParams"]
) -> "Transfer":
"""
Updates the specified transfer by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -386,7 +232,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Transfer.RetrieveParams"]
+ cls, id: str, **params: Unpack["TransferRetrieveParams"]
) -> "Transfer":
"""
Retrieves the details of an existing transfer. Supply the unique transfer ID from either a transfer creation request or the transfer list, and Stripe will return the corresponding transfer information.
@@ -397,7 +243,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Transfer.RetrieveParams"]
+ cls, id: str, **params: Unpack["TransferRetrieveParams"]
) -> "Transfer":
"""
Retrieves the details of an existing transfer. Supply the unique transfer ID from either a transfer creation request or the transfer list, and Stripe will return the corresponding transfer information.
@@ -408,7 +254,7 @@ async def retrieve_async(
@classmethod
def list_reversals(
- cls, id: str, **params: Unpack["Transfer.ListReversalsParams"]
+ 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.
@@ -424,7 +270,7 @@ def list_reversals(
@classmethod
async def list_reversals_async(
- cls, id: str, **params: Unpack["Transfer.ListReversalsParams"]
+ 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.
@@ -440,7 +286,7 @@ async def list_reversals_async(
@classmethod
def create_reversal(
- cls, id: str, **params: Unpack["Transfer.CreateReversalParams"]
+ cls, id: str, **params: Unpack["TransferCreateReversalParams"]
) -> "Reversal":
"""
When you create a new reversal, you must specify a transfer to create it on.
@@ -460,7 +306,7 @@ def create_reversal(
@classmethod
async def create_reversal_async(
- cls, id: str, **params: Unpack["Transfer.CreateReversalParams"]
+ cls, id: str, **params: Unpack["TransferCreateReversalParams"]
) -> "Reversal":
"""
When you create a new reversal, you must specify a transfer to create it on.
@@ -483,7 +329,7 @@ def retrieve_reversal(
cls,
transfer: str,
id: str,
- **params: Unpack["Transfer.RetrieveReversalParams"],
+ **params: Unpack["TransferRetrieveReversalParams"],
) -> "Reversal":
"""
By default, you can see the 10 most recent reversals stored directly on the transfer object, but you can also retrieve details about a specific reversal stored on the transfer.
@@ -504,7 +350,7 @@ async def retrieve_reversal_async(
cls,
transfer: str,
id: str,
- **params: Unpack["Transfer.RetrieveReversalParams"],
+ **params: Unpack["TransferRetrieveReversalParams"],
) -> "Reversal":
"""
By default, you can see the 10 most recent reversals stored directly on the transfer object, but you can also retrieve details about a specific reversal stored on the transfer.
@@ -525,7 +371,7 @@ def modify_reversal(
cls,
transfer: str,
id: str,
- **params: Unpack["Transfer.ModifyReversalParams"],
+ **params: Unpack["TransferModifyReversalParams"],
) -> "Reversal":
"""
Updates the specified reversal by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -548,7 +394,7 @@ async def modify_reversal_async(
cls,
transfer: str,
id: str,
- **params: Unpack["Transfer.ModifyReversalParams"],
+ **params: Unpack["TransferModifyReversalParams"],
) -> "Reversal":
"""
Updates the specified reversal by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
diff --git a/stripe/_transfer_reversal_service.py b/stripe/_transfer_reversal_service.py
index f3269092f..b3bf2ada1 100644
--- a/stripe/_transfer_reversal_service.py
+++ b/stripe/_transfer_reversal_service.py
@@ -5,71 +5,29 @@
from stripe._reversal import Reversal
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._transfer_reversal_create_params import (
+ TransferReversalCreateParams,
+ )
+ from stripe.params._transfer_reversal_list_params import (
+ TransferReversalListParams,
+ )
+ from stripe.params._transfer_reversal_retrieve_params import (
+ TransferReversalRetrieveParams,
+ )
+ from stripe.params._transfer_reversal_update_params import (
+ TransferReversalUpdateParams,
+ )
class TransferReversalService(StripeService):
- class CreateParams(TypedDict):
- amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) representing how much of this transfer to reverse. Can only reverse up to the unreversed amount remaining of the transfer. Partial transfer reversals are only allowed for transfers to Stripe Accounts. Defaults to the entire transfer amount.
- """
- description: NotRequired[str]
- """
- An arbitrary string which you can attach to a reversal object. This will be unset if you POST an empty value.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- refund_application_fee: NotRequired[bool]
- """
- Boolean indicating whether the application fee should be refunded when reversing this transfer. If a full transfer reversal is given, the full application fee will be refunded. Otherwise, the application fee will be refunded with an amount proportional to the amount of the transfer reversed.
- """
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
def list(
self,
id: str,
- params: Optional["TransferReversalService.ListParams"] = None,
+ params: Optional["TransferReversalListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Reversal]:
"""
@@ -89,7 +47,7 @@ def list(
async def list_async(
self,
id: str,
- params: Optional["TransferReversalService.ListParams"] = None,
+ params: Optional["TransferReversalListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Reversal]:
"""
@@ -109,7 +67,7 @@ async def list_async(
def create(
self,
id: str,
- params: Optional["TransferReversalService.CreateParams"] = None,
+ params: Optional["TransferReversalCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reversal:
"""
@@ -133,7 +91,7 @@ def create(
async def create_async(
self,
id: str,
- params: Optional["TransferReversalService.CreateParams"] = None,
+ params: Optional["TransferReversalCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reversal:
"""
@@ -158,7 +116,7 @@ def retrieve(
self,
transfer: str,
id: str,
- params: Optional["TransferReversalService.RetrieveParams"] = None,
+ params: Optional["TransferReversalRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reversal:
"""
@@ -182,7 +140,7 @@ async def retrieve_async(
self,
transfer: str,
id: str,
- params: Optional["TransferReversalService.RetrieveParams"] = None,
+ params: Optional["TransferReversalRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reversal:
"""
@@ -206,7 +164,7 @@ def update(
self,
transfer: str,
id: str,
- params: Optional["TransferReversalService.UpdateParams"] = None,
+ params: Optional["TransferReversalUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reversal:
"""
@@ -232,7 +190,7 @@ async def update_async(
self,
transfer: str,
id: str,
- params: Optional["TransferReversalService.UpdateParams"] = None,
+ params: Optional["TransferReversalUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reversal:
"""
diff --git a/stripe/_transfer_service.py b/stripe/_transfer_service.py
index 2061d8cd1..d379a0762 100644
--- a/stripe/_transfer_service.py
+++ b/stripe/_transfer_service.py
@@ -6,8 +6,14 @@
from stripe._transfer import Transfer
from stripe._transfer_reversal_service import TransferReversalService
from stripe._util import sanitize_id
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._transfer_create_params import TransferCreateParams
+ from stripe.params._transfer_list_params import TransferListParams
+ from stripe.params._transfer_retrieve_params import TransferRetrieveParams
+ from stripe.params._transfer_update_params import TransferUpdateParams
class TransferService(StripeService):
@@ -15,115 +21,9 @@ def __init__(self, requestor):
super().__init__(requestor)
self.reversals = TransferReversalService(self._requestor)
- class CreateParams(TypedDict):
- amount: NotRequired[int]
- """
- A positive integer in cents (or local equivalent) representing how much to transfer.
- """
- currency: str
- """
- Three-letter [ISO code for currency](https://www.iso.org/iso-4217-currency-codes.html) in lowercase. Must be a [supported currency](https://docs.stripe.com/currencies).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- destination: str
- """
- The ID of a connected Stripe account. [See the Connect documentation](https://docs.stripe.com/docs/connect/separate-charges-and-transfers) for details.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- source_transaction: NotRequired[str]
- """
- You can use this parameter to transfer funds from a charge before they are added to your available balance. A pending balance will transfer immediately but the funds will not become available until the original charge becomes available. [See the Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-availability) for details.
- """
- source_type: NotRequired[Literal["bank_account", "card", "fpx"]]
- """
- The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`.
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
- """
-
- class ListParams(TypedDict):
- created: NotRequired["TransferService.ListParamsCreated|int"]
- """
- Only return transfers that were created during the given date interval.
- """
- destination: NotRequired[str]
- """
- Only return transfers for the destination specified by this account ID.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- transfer_group: NotRequired[str]
- """
- Only return transfers with the specified transfer group.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
def list(
self,
- params: Optional["TransferService.ListParams"] = None,
+ params: Optional["TransferListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Transfer]:
"""
@@ -142,7 +42,7 @@ def list(
async def list_async(
self,
- params: Optional["TransferService.ListParams"] = None,
+ params: Optional["TransferListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Transfer]:
"""
@@ -161,7 +61,7 @@ async def list_async(
def create(
self,
- params: "TransferService.CreateParams",
+ params: "TransferCreateParams",
options: Optional[RequestOptions] = None,
) -> Transfer:
"""
@@ -180,7 +80,7 @@ def create(
async def create_async(
self,
- params: "TransferService.CreateParams",
+ params: "TransferCreateParams",
options: Optional[RequestOptions] = None,
) -> Transfer:
"""
@@ -200,7 +100,7 @@ async def create_async(
def retrieve(
self,
transfer: str,
- params: Optional["TransferService.RetrieveParams"] = None,
+ params: Optional["TransferRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transfer:
"""
@@ -222,7 +122,7 @@ def retrieve(
async def retrieve_async(
self,
transfer: str,
- params: Optional["TransferService.RetrieveParams"] = None,
+ params: Optional["TransferRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transfer:
"""
@@ -244,7 +144,7 @@ async def retrieve_async(
def update(
self,
transfer: str,
- params: Optional["TransferService.UpdateParams"] = None,
+ params: Optional["TransferUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transfer:
"""
@@ -268,7 +168,7 @@ def update(
async def update_async(
self,
transfer: str,
- params: Optional["TransferService.UpdateParams"] = None,
+ params: Optional["TransferUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transfer:
"""
diff --git a/stripe/_webhook_endpoint.py b/stripe/_webhook_endpoint.py
index 264b5f494..50c1d8cf0 100644
--- a/stripe/_webhook_endpoint.py
+++ b/stripe/_webhook_endpoint.py
@@ -4,11 +4,27 @@
from stripe._deletable_api_resource import DeletableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import Literal, NotRequired, Unpack
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._webhook_endpoint_create_params import (
+ WebhookEndpointCreateParams,
+ )
+ from stripe.params._webhook_endpoint_delete_params import (
+ WebhookEndpointDeleteParams,
+ )
+ from stripe.params._webhook_endpoint_list_params import (
+ WebhookEndpointListParams,
+ )
+ from stripe.params._webhook_endpoint_modify_params import (
+ WebhookEndpointModifyParams,
+ )
+ from stripe.params._webhook_endpoint_retrieve_params import (
+ WebhookEndpointRetrieveParams,
+ )
class WebhookEndpoint(
@@ -28,717 +44,6 @@ class WebhookEndpoint(
"""
OBJECT_NAME: ClassVar[Literal["webhook_endpoint"]] = "webhook_endpoint"
-
- class CreateParams(RequestOptions):
- api_version: NotRequired[
- Literal[
- "2011-01-01",
- "2011-06-21",
- "2011-06-28",
- "2011-08-01",
- "2011-09-15",
- "2011-11-17",
- "2012-02-23",
- "2012-03-25",
- "2012-06-18",
- "2012-06-28",
- "2012-07-09",
- "2012-09-24",
- "2012-10-26",
- "2012-11-07",
- "2013-02-11",
- "2013-02-13",
- "2013-07-05",
- "2013-08-12",
- "2013-08-13",
- "2013-10-29",
- "2013-12-03",
- "2014-01-31",
- "2014-03-13",
- "2014-03-28",
- "2014-05-19",
- "2014-06-13",
- "2014-06-17",
- "2014-07-22",
- "2014-07-26",
- "2014-08-04",
- "2014-08-20",
- "2014-09-08",
- "2014-10-07",
- "2014-11-05",
- "2014-11-20",
- "2014-12-08",
- "2014-12-17",
- "2014-12-22",
- "2015-01-11",
- "2015-01-26",
- "2015-02-10",
- "2015-02-16",
- "2015-02-18",
- "2015-03-24",
- "2015-04-07",
- "2015-06-15",
- "2015-07-07",
- "2015-07-13",
- "2015-07-28",
- "2015-08-07",
- "2015-08-19",
- "2015-09-03",
- "2015-09-08",
- "2015-09-23",
- "2015-10-01",
- "2015-10-12",
- "2015-10-16",
- "2016-02-03",
- "2016-02-19",
- "2016-02-22",
- "2016-02-23",
- "2016-02-29",
- "2016-03-07",
- "2016-06-15",
- "2016-07-06",
- "2016-10-19",
- "2017-01-27",
- "2017-02-14",
- "2017-04-06",
- "2017-05-25",
- "2017-06-05",
- "2017-08-15",
- "2017-12-14",
- "2018-01-23",
- "2018-02-05",
- "2018-02-06",
- "2018-02-28",
- "2018-05-21",
- "2018-07-27",
- "2018-08-23",
- "2018-09-06",
- "2018-09-24",
- "2018-10-31",
- "2018-11-08",
- "2019-02-11",
- "2019-02-19",
- "2019-03-14",
- "2019-05-16",
- "2019-08-14",
- "2019-09-09",
- "2019-10-08",
- "2019-10-17",
- "2019-11-05",
- "2019-12-03",
- "2020-03-02",
- "2020-08-27",
- "2022-08-01",
- "2022-11-15",
- "2023-08-16",
- "2023-10-16",
- "2024-04-10",
- "2024-06-20",
- "2024-09-30.acacia",
- "2024-10-28.acacia",
- "2024-11-20.acacia",
- "2024-12-18.acacia",
- "2025-01-27.acacia",
- "2025-02-24.acacia",
- "2025-03-01.dashboard",
- "2025-03-31.basil",
- "2025-04-30.basil",
- "2025-05-28.basil",
- "2025-06-30.basil",
- "2025-07-30.basil",
- "2025-08-27.basil",
- "2025-09-30.clover",
- ]
- ]
- """
- Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version.
- """
- connect: NotRequired[bool]
- """
- Whether this endpoint should receive events from connected accounts (`true`), or from your account (`false`). Defaults to `false`.
- """
- description: NotRequired["Literal['']|str"]
- """
- An optional description of what the webhook is used for.
- """
- enabled_events: List[
- Literal[
- "*",
- "account.application.authorized",
- "account.application.deauthorized",
- "account.external_account.created",
- "account.external_account.deleted",
- "account.external_account.updated",
- "account.updated",
- "application_fee.created",
- "application_fee.refund.updated",
- "application_fee.refunded",
- "balance.available",
- "billing.alert.triggered",
- "billing_portal.configuration.created",
- "billing_portal.configuration.updated",
- "billing_portal.session.created",
- "capability.updated",
- "cash_balance.funds_available",
- "charge.captured",
- "charge.dispute.closed",
- "charge.dispute.created",
- "charge.dispute.funds_reinstated",
- "charge.dispute.funds_withdrawn",
- "charge.dispute.updated",
- "charge.expired",
- "charge.failed",
- "charge.pending",
- "charge.refund.updated",
- "charge.refunded",
- "charge.succeeded",
- "charge.updated",
- "checkout.session.async_payment_failed",
- "checkout.session.async_payment_succeeded",
- "checkout.session.completed",
- "checkout.session.expired",
- "climate.order.canceled",
- "climate.order.created",
- "climate.order.delayed",
- "climate.order.delivered",
- "climate.order.product_substituted",
- "climate.product.created",
- "climate.product.pricing_updated",
- "coupon.created",
- "coupon.deleted",
- "coupon.updated",
- "credit_note.created",
- "credit_note.updated",
- "credit_note.voided",
- "customer.created",
- "customer.deleted",
- "customer.discount.created",
- "customer.discount.deleted",
- "customer.discount.updated",
- "customer.source.created",
- "customer.source.deleted",
- "customer.source.expiring",
- "customer.source.updated",
- "customer.subscription.created",
- "customer.subscription.deleted",
- "customer.subscription.paused",
- "customer.subscription.pending_update_applied",
- "customer.subscription.pending_update_expired",
- "customer.subscription.resumed",
- "customer.subscription.trial_will_end",
- "customer.subscription.updated",
- "customer.tax_id.created",
- "customer.tax_id.deleted",
- "customer.tax_id.updated",
- "customer.updated",
- "customer_cash_balance_transaction.created",
- "entitlements.active_entitlement_summary.updated",
- "file.created",
- "financial_connections.account.created",
- "financial_connections.account.deactivated",
- "financial_connections.account.disconnected",
- "financial_connections.account.reactivated",
- "financial_connections.account.refreshed_balance",
- "financial_connections.account.refreshed_ownership",
- "financial_connections.account.refreshed_transactions",
- "identity.verification_session.canceled",
- "identity.verification_session.created",
- "identity.verification_session.processing",
- "identity.verification_session.redacted",
- "identity.verification_session.requires_input",
- "identity.verification_session.verified",
- "invoice.created",
- "invoice.deleted",
- "invoice.finalization_failed",
- "invoice.finalized",
- "invoice.marked_uncollectible",
- "invoice.overdue",
- "invoice.overpaid",
- "invoice.paid",
- "invoice.payment_action_required",
- "invoice.payment_failed",
- "invoice.payment_succeeded",
- "invoice.sent",
- "invoice.upcoming",
- "invoice.updated",
- "invoice.voided",
- "invoice.will_be_due",
- "invoice_payment.paid",
- "invoiceitem.created",
- "invoiceitem.deleted",
- "issuing_authorization.created",
- "issuing_authorization.request",
- "issuing_authorization.updated",
- "issuing_card.created",
- "issuing_card.updated",
- "issuing_cardholder.created",
- "issuing_cardholder.updated",
- "issuing_dispute.closed",
- "issuing_dispute.created",
- "issuing_dispute.funds_reinstated",
- "issuing_dispute.funds_rescinded",
- "issuing_dispute.submitted",
- "issuing_dispute.updated",
- "issuing_personalization_design.activated",
- "issuing_personalization_design.deactivated",
- "issuing_personalization_design.rejected",
- "issuing_personalization_design.updated",
- "issuing_token.created",
- "issuing_token.updated",
- "issuing_transaction.created",
- "issuing_transaction.purchase_details_receipt_updated",
- "issuing_transaction.updated",
- "mandate.updated",
- "payment_intent.amount_capturable_updated",
- "payment_intent.canceled",
- "payment_intent.created",
- "payment_intent.partially_funded",
- "payment_intent.payment_failed",
- "payment_intent.processing",
- "payment_intent.requires_action",
- "payment_intent.succeeded",
- "payment_link.created",
- "payment_link.updated",
- "payment_method.attached",
- "payment_method.automatically_updated",
- "payment_method.detached",
- "payment_method.updated",
- "payout.canceled",
- "payout.created",
- "payout.failed",
- "payout.paid",
- "payout.reconciliation_completed",
- "payout.updated",
- "person.created",
- "person.deleted",
- "person.updated",
- "plan.created",
- "plan.deleted",
- "plan.updated",
- "price.created",
- "price.deleted",
- "price.updated",
- "product.created",
- "product.deleted",
- "product.updated",
- "promotion_code.created",
- "promotion_code.updated",
- "quote.accepted",
- "quote.canceled",
- "quote.created",
- "quote.finalized",
- "radar.early_fraud_warning.created",
- "radar.early_fraud_warning.updated",
- "refund.created",
- "refund.failed",
- "refund.updated",
- "reporting.report_run.failed",
- "reporting.report_run.succeeded",
- "reporting.report_type.updated",
- "review.closed",
- "review.opened",
- "setup_intent.canceled",
- "setup_intent.created",
- "setup_intent.requires_action",
- "setup_intent.setup_failed",
- "setup_intent.succeeded",
- "sigma.scheduled_query_run.created",
- "source.canceled",
- "source.chargeable",
- "source.failed",
- "source.mandate_notification",
- "source.refund_attributes_required",
- "source.transaction.created",
- "source.transaction.updated",
- "subscription_schedule.aborted",
- "subscription_schedule.canceled",
- "subscription_schedule.completed",
- "subscription_schedule.created",
- "subscription_schedule.expiring",
- "subscription_schedule.released",
- "subscription_schedule.updated",
- "tax.settings.updated",
- "tax_rate.created",
- "tax_rate.updated",
- "terminal.reader.action_failed",
- "terminal.reader.action_succeeded",
- "terminal.reader.action_updated",
- "test_helpers.test_clock.advancing",
- "test_helpers.test_clock.created",
- "test_helpers.test_clock.deleted",
- "test_helpers.test_clock.internal_failure",
- "test_helpers.test_clock.ready",
- "topup.canceled",
- "topup.created",
- "topup.failed",
- "topup.reversed",
- "topup.succeeded",
- "transfer.created",
- "transfer.reversed",
- "transfer.updated",
- "treasury.credit_reversal.created",
- "treasury.credit_reversal.posted",
- "treasury.debit_reversal.completed",
- "treasury.debit_reversal.created",
- "treasury.debit_reversal.initial_credit_granted",
- "treasury.financial_account.closed",
- "treasury.financial_account.created",
- "treasury.financial_account.features_status_updated",
- "treasury.inbound_transfer.canceled",
- "treasury.inbound_transfer.created",
- "treasury.inbound_transfer.failed",
- "treasury.inbound_transfer.succeeded",
- "treasury.outbound_payment.canceled",
- "treasury.outbound_payment.created",
- "treasury.outbound_payment.expected_arrival_date_updated",
- "treasury.outbound_payment.failed",
- "treasury.outbound_payment.posted",
- "treasury.outbound_payment.returned",
- "treasury.outbound_payment.tracking_details_updated",
- "treasury.outbound_transfer.canceled",
- "treasury.outbound_transfer.created",
- "treasury.outbound_transfer.expected_arrival_date_updated",
- "treasury.outbound_transfer.failed",
- "treasury.outbound_transfer.posted",
- "treasury.outbound_transfer.returned",
- "treasury.outbound_transfer.tracking_details_updated",
- "treasury.received_credit.created",
- "treasury.received_credit.failed",
- "treasury.received_credit.succeeded",
- "treasury.received_debit.created",
- "billing.credit_balance_transaction.created",
- "billing.credit_grant.created",
- "billing.credit_grant.updated",
- "billing.meter.created",
- "billing.meter.deactivated",
- "billing.meter.reactivated",
- "billing.meter.updated",
- ]
- ]
- """
- The list of events to enable for this endpoint. You may specify `['*']` to enable all events, except those that require explicit selection.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- url: str
- """
- The URL of the webhook endpoint.
- """
-
- class DeleteParams(RequestOptions):
- pass
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ModifyParams(RequestOptions):
- description: NotRequired["Literal['']|str"]
- """
- An optional description of what the webhook is used for.
- """
- disabled: NotRequired[bool]
- """
- Disable the webhook endpoint if set to true.
- """
- enabled_events: NotRequired[
- List[
- Literal[
- "*",
- "account.application.authorized",
- "account.application.deauthorized",
- "account.external_account.created",
- "account.external_account.deleted",
- "account.external_account.updated",
- "account.updated",
- "application_fee.created",
- "application_fee.refund.updated",
- "application_fee.refunded",
- "balance.available",
- "billing.alert.triggered",
- "billing_portal.configuration.created",
- "billing_portal.configuration.updated",
- "billing_portal.session.created",
- "capability.updated",
- "cash_balance.funds_available",
- "charge.captured",
- "charge.dispute.closed",
- "charge.dispute.created",
- "charge.dispute.funds_reinstated",
- "charge.dispute.funds_withdrawn",
- "charge.dispute.updated",
- "charge.expired",
- "charge.failed",
- "charge.pending",
- "charge.refund.updated",
- "charge.refunded",
- "charge.succeeded",
- "charge.updated",
- "checkout.session.async_payment_failed",
- "checkout.session.async_payment_succeeded",
- "checkout.session.completed",
- "checkout.session.expired",
- "climate.order.canceled",
- "climate.order.created",
- "climate.order.delayed",
- "climate.order.delivered",
- "climate.order.product_substituted",
- "climate.product.created",
- "climate.product.pricing_updated",
- "coupon.created",
- "coupon.deleted",
- "coupon.updated",
- "credit_note.created",
- "credit_note.updated",
- "credit_note.voided",
- "customer.created",
- "customer.deleted",
- "customer.discount.created",
- "customer.discount.deleted",
- "customer.discount.updated",
- "customer.source.created",
- "customer.source.deleted",
- "customer.source.expiring",
- "customer.source.updated",
- "customer.subscription.created",
- "customer.subscription.deleted",
- "customer.subscription.paused",
- "customer.subscription.pending_update_applied",
- "customer.subscription.pending_update_expired",
- "customer.subscription.resumed",
- "customer.subscription.trial_will_end",
- "customer.subscription.updated",
- "customer.tax_id.created",
- "customer.tax_id.deleted",
- "customer.tax_id.updated",
- "customer.updated",
- "customer_cash_balance_transaction.created",
- "entitlements.active_entitlement_summary.updated",
- "file.created",
- "financial_connections.account.created",
- "financial_connections.account.deactivated",
- "financial_connections.account.disconnected",
- "financial_connections.account.reactivated",
- "financial_connections.account.refreshed_balance",
- "financial_connections.account.refreshed_ownership",
- "financial_connections.account.refreshed_transactions",
- "identity.verification_session.canceled",
- "identity.verification_session.created",
- "identity.verification_session.processing",
- "identity.verification_session.redacted",
- "identity.verification_session.requires_input",
- "identity.verification_session.verified",
- "invoice.created",
- "invoice.deleted",
- "invoice.finalization_failed",
- "invoice.finalized",
- "invoice.marked_uncollectible",
- "invoice.overdue",
- "invoice.overpaid",
- "invoice.paid",
- "invoice.payment_action_required",
- "invoice.payment_failed",
- "invoice.payment_succeeded",
- "invoice.sent",
- "invoice.upcoming",
- "invoice.updated",
- "invoice.voided",
- "invoice.will_be_due",
- "invoice_payment.paid",
- "invoiceitem.created",
- "invoiceitem.deleted",
- "issuing_authorization.created",
- "issuing_authorization.request",
- "issuing_authorization.updated",
- "issuing_card.created",
- "issuing_card.updated",
- "issuing_cardholder.created",
- "issuing_cardholder.updated",
- "issuing_dispute.closed",
- "issuing_dispute.created",
- "issuing_dispute.funds_reinstated",
- "issuing_dispute.funds_rescinded",
- "issuing_dispute.submitted",
- "issuing_dispute.updated",
- "issuing_personalization_design.activated",
- "issuing_personalization_design.deactivated",
- "issuing_personalization_design.rejected",
- "issuing_personalization_design.updated",
- "issuing_token.created",
- "issuing_token.updated",
- "issuing_transaction.created",
- "issuing_transaction.purchase_details_receipt_updated",
- "issuing_transaction.updated",
- "mandate.updated",
- "payment_intent.amount_capturable_updated",
- "payment_intent.canceled",
- "payment_intent.created",
- "payment_intent.partially_funded",
- "payment_intent.payment_failed",
- "payment_intent.processing",
- "payment_intent.requires_action",
- "payment_intent.succeeded",
- "payment_link.created",
- "payment_link.updated",
- "payment_method.attached",
- "payment_method.automatically_updated",
- "payment_method.detached",
- "payment_method.updated",
- "payout.canceled",
- "payout.created",
- "payout.failed",
- "payout.paid",
- "payout.reconciliation_completed",
- "payout.updated",
- "person.created",
- "person.deleted",
- "person.updated",
- "plan.created",
- "plan.deleted",
- "plan.updated",
- "price.created",
- "price.deleted",
- "price.updated",
- "product.created",
- "product.deleted",
- "product.updated",
- "promotion_code.created",
- "promotion_code.updated",
- "quote.accepted",
- "quote.canceled",
- "quote.created",
- "quote.finalized",
- "radar.early_fraud_warning.created",
- "radar.early_fraud_warning.updated",
- "refund.created",
- "refund.failed",
- "refund.updated",
- "reporting.report_run.failed",
- "reporting.report_run.succeeded",
- "reporting.report_type.updated",
- "review.closed",
- "review.opened",
- "setup_intent.canceled",
- "setup_intent.created",
- "setup_intent.requires_action",
- "setup_intent.setup_failed",
- "setup_intent.succeeded",
- "sigma.scheduled_query_run.created",
- "source.canceled",
- "source.chargeable",
- "source.failed",
- "source.mandate_notification",
- "source.refund_attributes_required",
- "source.transaction.created",
- "source.transaction.updated",
- "subscription_schedule.aborted",
- "subscription_schedule.canceled",
- "subscription_schedule.completed",
- "subscription_schedule.created",
- "subscription_schedule.expiring",
- "subscription_schedule.released",
- "subscription_schedule.updated",
- "tax.settings.updated",
- "tax_rate.created",
- "tax_rate.updated",
- "terminal.reader.action_failed",
- "terminal.reader.action_succeeded",
- "terminal.reader.action_updated",
- "test_helpers.test_clock.advancing",
- "test_helpers.test_clock.created",
- "test_helpers.test_clock.deleted",
- "test_helpers.test_clock.internal_failure",
- "test_helpers.test_clock.ready",
- "topup.canceled",
- "topup.created",
- "topup.failed",
- "topup.reversed",
- "topup.succeeded",
- "transfer.created",
- "transfer.reversed",
- "transfer.updated",
- "treasury.credit_reversal.created",
- "treasury.credit_reversal.posted",
- "treasury.debit_reversal.completed",
- "treasury.debit_reversal.created",
- "treasury.debit_reversal.initial_credit_granted",
- "treasury.financial_account.closed",
- "treasury.financial_account.created",
- "treasury.financial_account.features_status_updated",
- "treasury.inbound_transfer.canceled",
- "treasury.inbound_transfer.created",
- "treasury.inbound_transfer.failed",
- "treasury.inbound_transfer.succeeded",
- "treasury.outbound_payment.canceled",
- "treasury.outbound_payment.created",
- "treasury.outbound_payment.expected_arrival_date_updated",
- "treasury.outbound_payment.failed",
- "treasury.outbound_payment.posted",
- "treasury.outbound_payment.returned",
- "treasury.outbound_payment.tracking_details_updated",
- "treasury.outbound_transfer.canceled",
- "treasury.outbound_transfer.created",
- "treasury.outbound_transfer.expected_arrival_date_updated",
- "treasury.outbound_transfer.failed",
- "treasury.outbound_transfer.posted",
- "treasury.outbound_transfer.returned",
- "treasury.outbound_transfer.tracking_details_updated",
- "treasury.received_credit.created",
- "treasury.received_credit.failed",
- "treasury.received_credit.succeeded",
- "treasury.received_debit.created",
- "billing.credit_balance_transaction.created",
- "billing.credit_grant.created",
- "billing.credit_grant.updated",
- "billing.meter.created",
- "billing.meter.deactivated",
- "billing.meter.reactivated",
- "billing.meter.updated",
- ]
- ]
- ]
- """
- The list of events to enable for this endpoint. You may specify `['*']` to enable all events, except those that require explicit selection.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- url: NotRequired[str]
- """
- The URL of the webhook endpoint.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
api_version: Optional[str]
"""
The API version events are rendered as for this webhook endpoint.
@@ -794,7 +99,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["WebhookEndpoint.CreateParams"]
+ cls, **params: Unpack["WebhookEndpointCreateParams"]
) -> "WebhookEndpoint":
"""
A webhook endpoint must have a url and a list of enabled_events. You may optionally specify the Boolean connect parameter. If set to true, then a Connect webhook endpoint that notifies the specified url about events from all connected accounts is created; otherwise an account webhook endpoint that notifies the specified url only about events from your account is created. You can also create webhook endpoints in the [webhooks settings](https://dashboard.stripe.com/account/webhooks) section of the Dashboard.
@@ -810,7 +115,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["WebhookEndpoint.CreateParams"]
+ cls, **params: Unpack["WebhookEndpointCreateParams"]
) -> "WebhookEndpoint":
"""
A webhook endpoint must have a url and a list of enabled_events. You may optionally specify the Boolean connect parameter. If set to true, then a Connect webhook endpoint that notifies the specified url about events from all connected accounts is created; otherwise an account webhook endpoint that notifies the specified url only about events from your account is created. You can also create webhook endpoints in the [webhooks settings](https://dashboard.stripe.com/account/webhooks) section of the Dashboard.
@@ -826,7 +131,7 @@ async def create_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["WebhookEndpoint.DeleteParams"]
+ cls, sid: str, **params: Unpack["WebhookEndpointDeleteParams"]
) -> "WebhookEndpoint":
"""
You can also delete webhook endpoints via the [webhook endpoint management](https://dashboard.stripe.com/account/webhooks) page of the Stripe dashboard.
@@ -844,7 +149,7 @@ def _cls_delete(
@overload
@staticmethod
def delete(
- sid: str, **params: Unpack["WebhookEndpoint.DeleteParams"]
+ sid: str, **params: Unpack["WebhookEndpointDeleteParams"]
) -> "WebhookEndpoint":
"""
You can also delete webhook endpoints via the [webhook endpoint management](https://dashboard.stripe.com/account/webhooks) page of the Stripe dashboard.
@@ -853,7 +158,7 @@ def delete(
@overload
def delete(
- self, **params: Unpack["WebhookEndpoint.DeleteParams"]
+ self, **params: Unpack["WebhookEndpointDeleteParams"]
) -> "WebhookEndpoint":
"""
You can also delete webhook endpoints via the [webhook endpoint management](https://dashboard.stripe.com/account/webhooks) page of the Stripe dashboard.
@@ -862,7 +167,7 @@ def delete(
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["WebhookEndpoint.DeleteParams"]
+ self, **params: Unpack["WebhookEndpointDeleteParams"]
) -> "WebhookEndpoint":
"""
You can also delete webhook endpoints via the [webhook endpoint management](https://dashboard.stripe.com/account/webhooks) page of the Stripe dashboard.
@@ -875,7 +180,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["WebhookEndpoint.DeleteParams"]
+ cls, sid: str, **params: Unpack["WebhookEndpointDeleteParams"]
) -> "WebhookEndpoint":
"""
You can also delete webhook endpoints via the [webhook endpoint management](https://dashboard.stripe.com/account/webhooks) page of the Stripe dashboard.
@@ -893,7 +198,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["WebhookEndpoint.DeleteParams"]
+ sid: str, **params: Unpack["WebhookEndpointDeleteParams"]
) -> "WebhookEndpoint":
"""
You can also delete webhook endpoints via the [webhook endpoint management](https://dashboard.stripe.com/account/webhooks) page of the Stripe dashboard.
@@ -902,7 +207,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["WebhookEndpoint.DeleteParams"]
+ self, **params: Unpack["WebhookEndpointDeleteParams"]
) -> "WebhookEndpoint":
"""
You can also delete webhook endpoints via the [webhook endpoint management](https://dashboard.stripe.com/account/webhooks) page of the Stripe dashboard.
@@ -911,7 +216,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["WebhookEndpoint.DeleteParams"]
+ self, **params: Unpack["WebhookEndpointDeleteParams"]
) -> "WebhookEndpoint":
"""
You can also delete webhook endpoints via the [webhook endpoint management](https://dashboard.stripe.com/account/webhooks) page of the Stripe dashboard.
@@ -924,7 +229,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["WebhookEndpoint.ListParams"]
+ cls, **params: Unpack["WebhookEndpointListParams"]
) -> ListObject["WebhookEndpoint"]:
"""
Returns a list of your webhook endpoints.
@@ -944,7 +249,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["WebhookEndpoint.ListParams"]
+ cls, **params: Unpack["WebhookEndpointListParams"]
) -> ListObject["WebhookEndpoint"]:
"""
Returns a list of your webhook endpoints.
@@ -964,7 +269,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["WebhookEndpoint.ModifyParams"]
+ cls, id: str, **params: Unpack["WebhookEndpointModifyParams"]
) -> "WebhookEndpoint":
"""
Updates the webhook endpoint. You may edit the url, the list of enabled_events, and the status of your endpoint.
@@ -981,7 +286,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["WebhookEndpoint.ModifyParams"]
+ cls, id: str, **params: Unpack["WebhookEndpointModifyParams"]
) -> "WebhookEndpoint":
"""
Updates the webhook endpoint. You may edit the url, the list of enabled_events, and the status of your endpoint.
@@ -998,7 +303,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["WebhookEndpoint.RetrieveParams"]
+ cls, id: str, **params: Unpack["WebhookEndpointRetrieveParams"]
) -> "WebhookEndpoint":
"""
Retrieves the webhook endpoint with the given ID.
@@ -1009,7 +314,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["WebhookEndpoint.RetrieveParams"]
+ cls, id: str, **params: Unpack["WebhookEndpointRetrieveParams"]
) -> "WebhookEndpoint":
"""
Retrieves the webhook endpoint with the given ID.
diff --git a/stripe/_webhook_endpoint_service.py b/stripe/_webhook_endpoint_service.py
index 8a523fb73..66714d6da 100644
--- a/stripe/_webhook_endpoint_service.py
+++ b/stripe/_webhook_endpoint_service.py
@@ -5,725 +5,32 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe._webhook_endpoint import WebhookEndpoint
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params._webhook_endpoint_create_params import (
+ WebhookEndpointCreateParams,
+ )
+ from stripe.params._webhook_endpoint_delete_params import (
+ WebhookEndpointDeleteParams,
+ )
+ from stripe.params._webhook_endpoint_list_params import (
+ WebhookEndpointListParams,
+ )
+ from stripe.params._webhook_endpoint_retrieve_params import (
+ WebhookEndpointRetrieveParams,
+ )
+ from stripe.params._webhook_endpoint_update_params import (
+ WebhookEndpointUpdateParams,
+ )
class WebhookEndpointService(StripeService):
- class CreateParams(TypedDict):
- api_version: NotRequired[
- Literal[
- "2011-01-01",
- "2011-06-21",
- "2011-06-28",
- "2011-08-01",
- "2011-09-15",
- "2011-11-17",
- "2012-02-23",
- "2012-03-25",
- "2012-06-18",
- "2012-06-28",
- "2012-07-09",
- "2012-09-24",
- "2012-10-26",
- "2012-11-07",
- "2013-02-11",
- "2013-02-13",
- "2013-07-05",
- "2013-08-12",
- "2013-08-13",
- "2013-10-29",
- "2013-12-03",
- "2014-01-31",
- "2014-03-13",
- "2014-03-28",
- "2014-05-19",
- "2014-06-13",
- "2014-06-17",
- "2014-07-22",
- "2014-07-26",
- "2014-08-04",
- "2014-08-20",
- "2014-09-08",
- "2014-10-07",
- "2014-11-05",
- "2014-11-20",
- "2014-12-08",
- "2014-12-17",
- "2014-12-22",
- "2015-01-11",
- "2015-01-26",
- "2015-02-10",
- "2015-02-16",
- "2015-02-18",
- "2015-03-24",
- "2015-04-07",
- "2015-06-15",
- "2015-07-07",
- "2015-07-13",
- "2015-07-28",
- "2015-08-07",
- "2015-08-19",
- "2015-09-03",
- "2015-09-08",
- "2015-09-23",
- "2015-10-01",
- "2015-10-12",
- "2015-10-16",
- "2016-02-03",
- "2016-02-19",
- "2016-02-22",
- "2016-02-23",
- "2016-02-29",
- "2016-03-07",
- "2016-06-15",
- "2016-07-06",
- "2016-10-19",
- "2017-01-27",
- "2017-02-14",
- "2017-04-06",
- "2017-05-25",
- "2017-06-05",
- "2017-08-15",
- "2017-12-14",
- "2018-01-23",
- "2018-02-05",
- "2018-02-06",
- "2018-02-28",
- "2018-05-21",
- "2018-07-27",
- "2018-08-23",
- "2018-09-06",
- "2018-09-24",
- "2018-10-31",
- "2018-11-08",
- "2019-02-11",
- "2019-02-19",
- "2019-03-14",
- "2019-05-16",
- "2019-08-14",
- "2019-09-09",
- "2019-10-08",
- "2019-10-17",
- "2019-11-05",
- "2019-12-03",
- "2020-03-02",
- "2020-08-27",
- "2022-08-01",
- "2022-11-15",
- "2023-08-16",
- "2023-10-16",
- "2024-04-10",
- "2024-06-20",
- "2024-09-30.acacia",
- "2024-10-28.acacia",
- "2024-11-20.acacia",
- "2024-12-18.acacia",
- "2025-01-27.acacia",
- "2025-02-24.acacia",
- "2025-03-01.dashboard",
- "2025-03-31.basil",
- "2025-04-30.basil",
- "2025-05-28.basil",
- "2025-06-30.basil",
- "2025-07-30.basil",
- "2025-08-27.basil",
- "2025-09-30.clover",
- ]
- ]
- """
- Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version.
- """
- connect: NotRequired[bool]
- """
- Whether this endpoint should receive events from connected accounts (`true`), or from your account (`false`). Defaults to `false`.
- """
- description: NotRequired["Literal['']|str"]
- """
- An optional description of what the webhook is used for.
- """
- enabled_events: List[
- Literal[
- "*",
- "account.application.authorized",
- "account.application.deauthorized",
- "account.external_account.created",
- "account.external_account.deleted",
- "account.external_account.updated",
- "account.updated",
- "application_fee.created",
- "application_fee.refund.updated",
- "application_fee.refunded",
- "balance.available",
- "billing.alert.triggered",
- "billing_portal.configuration.created",
- "billing_portal.configuration.updated",
- "billing_portal.session.created",
- "capability.updated",
- "cash_balance.funds_available",
- "charge.captured",
- "charge.dispute.closed",
- "charge.dispute.created",
- "charge.dispute.funds_reinstated",
- "charge.dispute.funds_withdrawn",
- "charge.dispute.updated",
- "charge.expired",
- "charge.failed",
- "charge.pending",
- "charge.refund.updated",
- "charge.refunded",
- "charge.succeeded",
- "charge.updated",
- "checkout.session.async_payment_failed",
- "checkout.session.async_payment_succeeded",
- "checkout.session.completed",
- "checkout.session.expired",
- "climate.order.canceled",
- "climate.order.created",
- "climate.order.delayed",
- "climate.order.delivered",
- "climate.order.product_substituted",
- "climate.product.created",
- "climate.product.pricing_updated",
- "coupon.created",
- "coupon.deleted",
- "coupon.updated",
- "credit_note.created",
- "credit_note.updated",
- "credit_note.voided",
- "customer.created",
- "customer.deleted",
- "customer.discount.created",
- "customer.discount.deleted",
- "customer.discount.updated",
- "customer.source.created",
- "customer.source.deleted",
- "customer.source.expiring",
- "customer.source.updated",
- "customer.subscription.created",
- "customer.subscription.deleted",
- "customer.subscription.paused",
- "customer.subscription.pending_update_applied",
- "customer.subscription.pending_update_expired",
- "customer.subscription.resumed",
- "customer.subscription.trial_will_end",
- "customer.subscription.updated",
- "customer.tax_id.created",
- "customer.tax_id.deleted",
- "customer.tax_id.updated",
- "customer.updated",
- "customer_cash_balance_transaction.created",
- "entitlements.active_entitlement_summary.updated",
- "file.created",
- "financial_connections.account.created",
- "financial_connections.account.deactivated",
- "financial_connections.account.disconnected",
- "financial_connections.account.reactivated",
- "financial_connections.account.refreshed_balance",
- "financial_connections.account.refreshed_ownership",
- "financial_connections.account.refreshed_transactions",
- "identity.verification_session.canceled",
- "identity.verification_session.created",
- "identity.verification_session.processing",
- "identity.verification_session.redacted",
- "identity.verification_session.requires_input",
- "identity.verification_session.verified",
- "invoice.created",
- "invoice.deleted",
- "invoice.finalization_failed",
- "invoice.finalized",
- "invoice.marked_uncollectible",
- "invoice.overdue",
- "invoice.overpaid",
- "invoice.paid",
- "invoice.payment_action_required",
- "invoice.payment_failed",
- "invoice.payment_succeeded",
- "invoice.sent",
- "invoice.upcoming",
- "invoice.updated",
- "invoice.voided",
- "invoice.will_be_due",
- "invoice_payment.paid",
- "invoiceitem.created",
- "invoiceitem.deleted",
- "issuing_authorization.created",
- "issuing_authorization.request",
- "issuing_authorization.updated",
- "issuing_card.created",
- "issuing_card.updated",
- "issuing_cardholder.created",
- "issuing_cardholder.updated",
- "issuing_dispute.closed",
- "issuing_dispute.created",
- "issuing_dispute.funds_reinstated",
- "issuing_dispute.funds_rescinded",
- "issuing_dispute.submitted",
- "issuing_dispute.updated",
- "issuing_personalization_design.activated",
- "issuing_personalization_design.deactivated",
- "issuing_personalization_design.rejected",
- "issuing_personalization_design.updated",
- "issuing_token.created",
- "issuing_token.updated",
- "issuing_transaction.created",
- "issuing_transaction.purchase_details_receipt_updated",
- "issuing_transaction.updated",
- "mandate.updated",
- "payment_intent.amount_capturable_updated",
- "payment_intent.canceled",
- "payment_intent.created",
- "payment_intent.partially_funded",
- "payment_intent.payment_failed",
- "payment_intent.processing",
- "payment_intent.requires_action",
- "payment_intent.succeeded",
- "payment_link.created",
- "payment_link.updated",
- "payment_method.attached",
- "payment_method.automatically_updated",
- "payment_method.detached",
- "payment_method.updated",
- "payout.canceled",
- "payout.created",
- "payout.failed",
- "payout.paid",
- "payout.reconciliation_completed",
- "payout.updated",
- "person.created",
- "person.deleted",
- "person.updated",
- "plan.created",
- "plan.deleted",
- "plan.updated",
- "price.created",
- "price.deleted",
- "price.updated",
- "product.created",
- "product.deleted",
- "product.updated",
- "promotion_code.created",
- "promotion_code.updated",
- "quote.accepted",
- "quote.canceled",
- "quote.created",
- "quote.finalized",
- "radar.early_fraud_warning.created",
- "radar.early_fraud_warning.updated",
- "refund.created",
- "refund.failed",
- "refund.updated",
- "reporting.report_run.failed",
- "reporting.report_run.succeeded",
- "reporting.report_type.updated",
- "review.closed",
- "review.opened",
- "setup_intent.canceled",
- "setup_intent.created",
- "setup_intent.requires_action",
- "setup_intent.setup_failed",
- "setup_intent.succeeded",
- "sigma.scheduled_query_run.created",
- "source.canceled",
- "source.chargeable",
- "source.failed",
- "source.mandate_notification",
- "source.refund_attributes_required",
- "source.transaction.created",
- "source.transaction.updated",
- "subscription_schedule.aborted",
- "subscription_schedule.canceled",
- "subscription_schedule.completed",
- "subscription_schedule.created",
- "subscription_schedule.expiring",
- "subscription_schedule.released",
- "subscription_schedule.updated",
- "tax.settings.updated",
- "tax_rate.created",
- "tax_rate.updated",
- "terminal.reader.action_failed",
- "terminal.reader.action_succeeded",
- "terminal.reader.action_updated",
- "test_helpers.test_clock.advancing",
- "test_helpers.test_clock.created",
- "test_helpers.test_clock.deleted",
- "test_helpers.test_clock.internal_failure",
- "test_helpers.test_clock.ready",
- "topup.canceled",
- "topup.created",
- "topup.failed",
- "topup.reversed",
- "topup.succeeded",
- "transfer.created",
- "transfer.reversed",
- "transfer.updated",
- "treasury.credit_reversal.created",
- "treasury.credit_reversal.posted",
- "treasury.debit_reversal.completed",
- "treasury.debit_reversal.created",
- "treasury.debit_reversal.initial_credit_granted",
- "treasury.financial_account.closed",
- "treasury.financial_account.created",
- "treasury.financial_account.features_status_updated",
- "treasury.inbound_transfer.canceled",
- "treasury.inbound_transfer.created",
- "treasury.inbound_transfer.failed",
- "treasury.inbound_transfer.succeeded",
- "treasury.outbound_payment.canceled",
- "treasury.outbound_payment.created",
- "treasury.outbound_payment.expected_arrival_date_updated",
- "treasury.outbound_payment.failed",
- "treasury.outbound_payment.posted",
- "treasury.outbound_payment.returned",
- "treasury.outbound_payment.tracking_details_updated",
- "treasury.outbound_transfer.canceled",
- "treasury.outbound_transfer.created",
- "treasury.outbound_transfer.expected_arrival_date_updated",
- "treasury.outbound_transfer.failed",
- "treasury.outbound_transfer.posted",
- "treasury.outbound_transfer.returned",
- "treasury.outbound_transfer.tracking_details_updated",
- "treasury.received_credit.created",
- "treasury.received_credit.failed",
- "treasury.received_credit.succeeded",
- "treasury.received_debit.created",
- "billing.credit_balance_transaction.created",
- "billing.credit_grant.created",
- "billing.credit_grant.updated",
- "billing.meter.created",
- "billing.meter.deactivated",
- "billing.meter.reactivated",
- "billing.meter.updated",
- ]
- ]
- """
- The list of events to enable for this endpoint. You may specify `['*']` to enable all events, except those that require explicit selection.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- url: str
- """
- The URL of the webhook endpoint.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- description: NotRequired["Literal['']|str"]
- """
- An optional description of what the webhook is used for.
- """
- disabled: NotRequired[bool]
- """
- Disable the webhook endpoint if set to true.
- """
- enabled_events: NotRequired[
- List[
- Literal[
- "*",
- "account.application.authorized",
- "account.application.deauthorized",
- "account.external_account.created",
- "account.external_account.deleted",
- "account.external_account.updated",
- "account.updated",
- "application_fee.created",
- "application_fee.refund.updated",
- "application_fee.refunded",
- "balance.available",
- "billing.alert.triggered",
- "billing_portal.configuration.created",
- "billing_portal.configuration.updated",
- "billing_portal.session.created",
- "capability.updated",
- "cash_balance.funds_available",
- "charge.captured",
- "charge.dispute.closed",
- "charge.dispute.created",
- "charge.dispute.funds_reinstated",
- "charge.dispute.funds_withdrawn",
- "charge.dispute.updated",
- "charge.expired",
- "charge.failed",
- "charge.pending",
- "charge.refund.updated",
- "charge.refunded",
- "charge.succeeded",
- "charge.updated",
- "checkout.session.async_payment_failed",
- "checkout.session.async_payment_succeeded",
- "checkout.session.completed",
- "checkout.session.expired",
- "climate.order.canceled",
- "climate.order.created",
- "climate.order.delayed",
- "climate.order.delivered",
- "climate.order.product_substituted",
- "climate.product.created",
- "climate.product.pricing_updated",
- "coupon.created",
- "coupon.deleted",
- "coupon.updated",
- "credit_note.created",
- "credit_note.updated",
- "credit_note.voided",
- "customer.created",
- "customer.deleted",
- "customer.discount.created",
- "customer.discount.deleted",
- "customer.discount.updated",
- "customer.source.created",
- "customer.source.deleted",
- "customer.source.expiring",
- "customer.source.updated",
- "customer.subscription.created",
- "customer.subscription.deleted",
- "customer.subscription.paused",
- "customer.subscription.pending_update_applied",
- "customer.subscription.pending_update_expired",
- "customer.subscription.resumed",
- "customer.subscription.trial_will_end",
- "customer.subscription.updated",
- "customer.tax_id.created",
- "customer.tax_id.deleted",
- "customer.tax_id.updated",
- "customer.updated",
- "customer_cash_balance_transaction.created",
- "entitlements.active_entitlement_summary.updated",
- "file.created",
- "financial_connections.account.created",
- "financial_connections.account.deactivated",
- "financial_connections.account.disconnected",
- "financial_connections.account.reactivated",
- "financial_connections.account.refreshed_balance",
- "financial_connections.account.refreshed_ownership",
- "financial_connections.account.refreshed_transactions",
- "identity.verification_session.canceled",
- "identity.verification_session.created",
- "identity.verification_session.processing",
- "identity.verification_session.redacted",
- "identity.verification_session.requires_input",
- "identity.verification_session.verified",
- "invoice.created",
- "invoice.deleted",
- "invoice.finalization_failed",
- "invoice.finalized",
- "invoice.marked_uncollectible",
- "invoice.overdue",
- "invoice.overpaid",
- "invoice.paid",
- "invoice.payment_action_required",
- "invoice.payment_failed",
- "invoice.payment_succeeded",
- "invoice.sent",
- "invoice.upcoming",
- "invoice.updated",
- "invoice.voided",
- "invoice.will_be_due",
- "invoice_payment.paid",
- "invoiceitem.created",
- "invoiceitem.deleted",
- "issuing_authorization.created",
- "issuing_authorization.request",
- "issuing_authorization.updated",
- "issuing_card.created",
- "issuing_card.updated",
- "issuing_cardholder.created",
- "issuing_cardholder.updated",
- "issuing_dispute.closed",
- "issuing_dispute.created",
- "issuing_dispute.funds_reinstated",
- "issuing_dispute.funds_rescinded",
- "issuing_dispute.submitted",
- "issuing_dispute.updated",
- "issuing_personalization_design.activated",
- "issuing_personalization_design.deactivated",
- "issuing_personalization_design.rejected",
- "issuing_personalization_design.updated",
- "issuing_token.created",
- "issuing_token.updated",
- "issuing_transaction.created",
- "issuing_transaction.purchase_details_receipt_updated",
- "issuing_transaction.updated",
- "mandate.updated",
- "payment_intent.amount_capturable_updated",
- "payment_intent.canceled",
- "payment_intent.created",
- "payment_intent.partially_funded",
- "payment_intent.payment_failed",
- "payment_intent.processing",
- "payment_intent.requires_action",
- "payment_intent.succeeded",
- "payment_link.created",
- "payment_link.updated",
- "payment_method.attached",
- "payment_method.automatically_updated",
- "payment_method.detached",
- "payment_method.updated",
- "payout.canceled",
- "payout.created",
- "payout.failed",
- "payout.paid",
- "payout.reconciliation_completed",
- "payout.updated",
- "person.created",
- "person.deleted",
- "person.updated",
- "plan.created",
- "plan.deleted",
- "plan.updated",
- "price.created",
- "price.deleted",
- "price.updated",
- "product.created",
- "product.deleted",
- "product.updated",
- "promotion_code.created",
- "promotion_code.updated",
- "quote.accepted",
- "quote.canceled",
- "quote.created",
- "quote.finalized",
- "radar.early_fraud_warning.created",
- "radar.early_fraud_warning.updated",
- "refund.created",
- "refund.failed",
- "refund.updated",
- "reporting.report_run.failed",
- "reporting.report_run.succeeded",
- "reporting.report_type.updated",
- "review.closed",
- "review.opened",
- "setup_intent.canceled",
- "setup_intent.created",
- "setup_intent.requires_action",
- "setup_intent.setup_failed",
- "setup_intent.succeeded",
- "sigma.scheduled_query_run.created",
- "source.canceled",
- "source.chargeable",
- "source.failed",
- "source.mandate_notification",
- "source.refund_attributes_required",
- "source.transaction.created",
- "source.transaction.updated",
- "subscription_schedule.aborted",
- "subscription_schedule.canceled",
- "subscription_schedule.completed",
- "subscription_schedule.created",
- "subscription_schedule.expiring",
- "subscription_schedule.released",
- "subscription_schedule.updated",
- "tax.settings.updated",
- "tax_rate.created",
- "tax_rate.updated",
- "terminal.reader.action_failed",
- "terminal.reader.action_succeeded",
- "terminal.reader.action_updated",
- "test_helpers.test_clock.advancing",
- "test_helpers.test_clock.created",
- "test_helpers.test_clock.deleted",
- "test_helpers.test_clock.internal_failure",
- "test_helpers.test_clock.ready",
- "topup.canceled",
- "topup.created",
- "topup.failed",
- "topup.reversed",
- "topup.succeeded",
- "transfer.created",
- "transfer.reversed",
- "transfer.updated",
- "treasury.credit_reversal.created",
- "treasury.credit_reversal.posted",
- "treasury.debit_reversal.completed",
- "treasury.debit_reversal.created",
- "treasury.debit_reversal.initial_credit_granted",
- "treasury.financial_account.closed",
- "treasury.financial_account.created",
- "treasury.financial_account.features_status_updated",
- "treasury.inbound_transfer.canceled",
- "treasury.inbound_transfer.created",
- "treasury.inbound_transfer.failed",
- "treasury.inbound_transfer.succeeded",
- "treasury.outbound_payment.canceled",
- "treasury.outbound_payment.created",
- "treasury.outbound_payment.expected_arrival_date_updated",
- "treasury.outbound_payment.failed",
- "treasury.outbound_payment.posted",
- "treasury.outbound_payment.returned",
- "treasury.outbound_payment.tracking_details_updated",
- "treasury.outbound_transfer.canceled",
- "treasury.outbound_transfer.created",
- "treasury.outbound_transfer.expected_arrival_date_updated",
- "treasury.outbound_transfer.failed",
- "treasury.outbound_transfer.posted",
- "treasury.outbound_transfer.returned",
- "treasury.outbound_transfer.tracking_details_updated",
- "treasury.received_credit.created",
- "treasury.received_credit.failed",
- "treasury.received_credit.succeeded",
- "treasury.received_debit.created",
- "billing.credit_balance_transaction.created",
- "billing.credit_grant.created",
- "billing.credit_grant.updated",
- "billing.meter.created",
- "billing.meter.deactivated",
- "billing.meter.reactivated",
- "billing.meter.updated",
- ]
- ]
- ]
- """
- The list of events to enable for this endpoint. You may specify `['*']` to enable all events, except those that require explicit selection.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- url: NotRequired[str]
- """
- The URL of the webhook endpoint.
- """
-
def delete(
self,
webhook_endpoint: str,
- params: Optional["WebhookEndpointService.DeleteParams"] = None,
+ params: Optional["WebhookEndpointDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> WebhookEndpoint:
"""
@@ -745,7 +52,7 @@ def delete(
async def delete_async(
self,
webhook_endpoint: str,
- params: Optional["WebhookEndpointService.DeleteParams"] = None,
+ params: Optional["WebhookEndpointDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> WebhookEndpoint:
"""
@@ -767,7 +74,7 @@ async def delete_async(
def retrieve(
self,
webhook_endpoint: str,
- params: Optional["WebhookEndpointService.RetrieveParams"] = None,
+ params: Optional["WebhookEndpointRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> WebhookEndpoint:
"""
@@ -789,7 +96,7 @@ def retrieve(
async def retrieve_async(
self,
webhook_endpoint: str,
- params: Optional["WebhookEndpointService.RetrieveParams"] = None,
+ params: Optional["WebhookEndpointRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> WebhookEndpoint:
"""
@@ -811,7 +118,7 @@ async def retrieve_async(
def update(
self,
webhook_endpoint: str,
- params: Optional["WebhookEndpointService.UpdateParams"] = None,
+ params: Optional["WebhookEndpointUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> WebhookEndpoint:
"""
@@ -833,7 +140,7 @@ def update(
async def update_async(
self,
webhook_endpoint: str,
- params: Optional["WebhookEndpointService.UpdateParams"] = None,
+ params: Optional["WebhookEndpointUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> WebhookEndpoint:
"""
@@ -854,7 +161,7 @@ async def update_async(
def list(
self,
- params: Optional["WebhookEndpointService.ListParams"] = None,
+ params: Optional["WebhookEndpointListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[WebhookEndpoint]:
"""
@@ -873,7 +180,7 @@ def list(
async def list_async(
self,
- params: Optional["WebhookEndpointService.ListParams"] = None,
+ params: Optional["WebhookEndpointListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[WebhookEndpoint]:
"""
@@ -892,7 +199,7 @@ async def list_async(
def create(
self,
- params: "WebhookEndpointService.CreateParams",
+ params: "WebhookEndpointCreateParams",
options: Optional[RequestOptions] = None,
) -> WebhookEndpoint:
"""
@@ -911,7 +218,7 @@ def create(
async def create_async(
self,
- params: "WebhookEndpointService.CreateParams",
+ params: "WebhookEndpointCreateParams",
options: Optional[RequestOptions] = None,
) -> WebhookEndpoint:
"""
diff --git a/stripe/apps/_secret.py b/stripe/apps/_secret.py
index f79259ba8..9ff3f402a 100644
--- a/stripe/apps/_secret.py
+++ b/stripe/apps/_secret.py
@@ -3,10 +3,17 @@
from stripe._createable_api_resource import CreateableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
-from typing import ClassVar, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing import ClassVar, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.apps._secret_create_params import SecretCreateParams
+ from stripe.params.apps._secret_delete_where_params import (
+ SecretDeleteWhereParams,
+ )
+ from stripe.params.apps._secret_find_params import SecretFindParams
+ from stripe.params.apps._secret_list_params import SecretListParams
class Secret(CreateableAPIResource["Secret"], ListableAPIResource["Secret"]):
@@ -34,118 +41,6 @@ class Scope(StripeObject):
The user ID, if type is set to "user"
"""
- class CreateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- The Unix timestamp for the expiry time of the secret, after which the secret deletes.
- """
- name: str
- """
- A name for the secret that's unique within the scope.
- """
- payload: str
- """
- The plaintext secret value to be stored.
- """
- scope: "Secret.CreateParamsScope"
- """
- Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
- """
-
- class CreateParamsScope(TypedDict):
- type: Literal["account", "user"]
- """
- The secret scope type.
- """
- user: NotRequired[str]
- """
- The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
- """
-
- class DeleteWhereParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- name: str
- """
- A name for the secret that's unique within the scope.
- """
- scope: "Secret.DeleteWhereParamsScope"
- """
- Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
- """
-
- class DeleteWhereParamsScope(TypedDict):
- type: Literal["account", "user"]
- """
- The secret scope type.
- """
- user: NotRequired[str]
- """
- The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
- """
-
- class FindParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- name: str
- """
- A name for the secret that's unique within the scope.
- """
- scope: "Secret.FindParamsScope"
- """
- Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
- """
-
- class FindParamsScope(TypedDict):
- type: Literal["account", "user"]
- """
- The secret scope type.
- """
- user: NotRequired[str]
- """
- The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
- """
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- scope: "Secret.ListParamsScope"
- """
- Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsScope(TypedDict):
- type: Literal["account", "user"]
- """
- The secret scope type.
- """
- user: NotRequired[str]
- """
- The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -181,7 +76,7 @@ class ListParamsScope(TypedDict):
scope: Scope
@classmethod
- def create(cls, **params: Unpack["Secret.CreateParams"]) -> "Secret":
+ def create(cls, **params: Unpack["SecretCreateParams"]) -> "Secret":
"""
Create or replace a secret in the secret store.
"""
@@ -196,7 +91,7 @@ def create(cls, **params: Unpack["Secret.CreateParams"]) -> "Secret":
@classmethod
async def create_async(
- cls, **params: Unpack["Secret.CreateParams"]
+ cls, **params: Unpack["SecretCreateParams"]
) -> "Secret":
"""
Create or replace a secret in the secret store.
@@ -212,7 +107,7 @@ async def create_async(
@classmethod
def delete_where(
- cls, **params: Unpack["Secret.DeleteWhereParams"]
+ cls, **params: Unpack["SecretDeleteWhereParams"]
) -> "Secret":
"""
Deletes a secret from the secret store by name and scope.
@@ -228,7 +123,7 @@ def delete_where(
@classmethod
async def delete_where_async(
- cls, **params: Unpack["Secret.DeleteWhereParams"]
+ cls, **params: Unpack["SecretDeleteWhereParams"]
) -> "Secret":
"""
Deletes a secret from the secret store by name and scope.
@@ -243,7 +138,7 @@ async def delete_where_async(
)
@classmethod
- def find(cls, **params: Unpack["Secret.FindParams"]) -> "Secret":
+ def find(cls, **params: Unpack["SecretFindParams"]) -> "Secret":
"""
Finds a secret in the secret store by name and scope.
"""
@@ -258,7 +153,7 @@ def find(cls, **params: Unpack["Secret.FindParams"]) -> "Secret":
@classmethod
async def find_async(
- cls, **params: Unpack["Secret.FindParams"]
+ cls, **params: Unpack["SecretFindParams"]
) -> "Secret":
"""
Finds a secret in the secret store by name and scope.
@@ -274,7 +169,7 @@ async def find_async(
@classmethod
def list(
- cls, **params: Unpack["Secret.ListParams"]
+ cls, **params: Unpack["SecretListParams"]
) -> ListObject["Secret"]:
"""
List all secrets stored on the given scope.
@@ -294,7 +189,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Secret.ListParams"]
+ cls, **params: Unpack["SecretListParams"]
) -> ListObject["Secret"]:
"""
List all secrets stored on the given scope.
diff --git a/stripe/apps/_secret_service.py b/stripe/apps/_secret_service.py
index 385eb66f1..0bc15330e 100644
--- a/stripe/apps/_secret_service.py
+++ b/stripe/apps/_secret_service.py
@@ -4,126 +4,22 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe.apps._secret import Secret
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.apps._secret_create_params import SecretCreateParams
+ from stripe.params.apps._secret_delete_where_params import (
+ SecretDeleteWhereParams,
+ )
+ from stripe.params.apps._secret_find_params import SecretFindParams
+ from stripe.params.apps._secret_list_params import SecretListParams
-class SecretService(StripeService):
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- The Unix timestamp for the expiry time of the secret, after which the secret deletes.
- """
- name: str
- """
- A name for the secret that's unique within the scope.
- """
- payload: str
- """
- The plaintext secret value to be stored.
- """
- scope: "SecretService.CreateParamsScope"
- """
- Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
- """
-
- class CreateParamsScope(TypedDict):
- type: Literal["account", "user"]
- """
- The secret scope type.
- """
- user: NotRequired[str]
- """
- The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
- """
-
- class DeleteWhereParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- name: str
- """
- A name for the secret that's unique within the scope.
- """
- scope: "SecretService.DeleteWhereParamsScope"
- """
- Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
- """
-
- class DeleteWhereParamsScope(TypedDict):
- type: Literal["account", "user"]
- """
- The secret scope type.
- """
- user: NotRequired[str]
- """
- The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
- """
-
- class FindParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- name: str
- """
- A name for the secret that's unique within the scope.
- """
- scope: "SecretService.FindParamsScope"
- """
- Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
- """
-
- class FindParamsScope(TypedDict):
- type: Literal["account", "user"]
- """
- The secret scope type.
- """
- user: NotRequired[str]
- """
- The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
- """
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- scope: "SecretService.ListParamsScope"
- """
- Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsScope(TypedDict):
- type: Literal["account", "user"]
- """
- The secret scope type.
- """
- user: NotRequired[str]
- """
- The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
- """
+class SecretService(StripeService):
def list(
self,
- params: "SecretService.ListParams",
+ params: "SecretListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[Secret]:
"""
@@ -142,7 +38,7 @@ def list(
async def list_async(
self,
- params: "SecretService.ListParams",
+ params: "SecretListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[Secret]:
"""
@@ -161,7 +57,7 @@ async def list_async(
def create(
self,
- params: "SecretService.CreateParams",
+ params: "SecretCreateParams",
options: Optional[RequestOptions] = None,
) -> Secret:
"""
@@ -180,7 +76,7 @@ def create(
async def create_async(
self,
- params: "SecretService.CreateParams",
+ params: "SecretCreateParams",
options: Optional[RequestOptions] = None,
) -> Secret:
"""
@@ -199,7 +95,7 @@ async def create_async(
def find(
self,
- params: "SecretService.FindParams",
+ params: "SecretFindParams",
options: Optional[RequestOptions] = None,
) -> Secret:
"""
@@ -218,7 +114,7 @@ def find(
async def find_async(
self,
- params: "SecretService.FindParams",
+ params: "SecretFindParams",
options: Optional[RequestOptions] = None,
) -> Secret:
"""
@@ -237,7 +133,7 @@ async def find_async(
def delete_where(
self,
- params: "SecretService.DeleteWhereParams",
+ params: "SecretDeleteWhereParams",
options: Optional[RequestOptions] = None,
) -> Secret:
"""
@@ -256,7 +152,7 @@ def delete_where(
async def delete_where_async(
self,
- params: "SecretService.DeleteWhereParams",
+ params: "SecretDeleteWhereParams",
options: Optional[RequestOptions] = None,
) -> Secret:
"""
diff --git a/stripe/billing/_alert.py b/stripe/billing/_alert.py
index de4baafdf..e7b6b800c 100644
--- a/stripe/billing/_alert.py
+++ b/stripe/billing/_alert.py
@@ -4,21 +4,26 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._customer import Customer
from stripe.billing._meter import Meter
+ from stripe.params.billing._alert_activate_params import (
+ AlertActivateParams,
+ )
+ from stripe.params.billing._alert_archive_params import AlertArchiveParams
+ from stripe.params.billing._alert_create_params import AlertCreateParams
+ from stripe.params.billing._alert_deactivate_params import (
+ AlertDeactivateParams,
+ )
+ from stripe.params.billing._alert_list_params import AlertListParams
+ from stripe.params.billing._alert_retrieve_params import (
+ AlertRetrieveParams,
+ )
class Alert(CreateableAPIResource["Alert"], ListableAPIResource["Alert"]):
@@ -54,102 +59,6 @@ class Filter(StripeObject):
"""
_inner_class_types = {"filters": Filter}
- class ActivateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ArchiveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(RequestOptions):
- alert_type: Literal["usage_threshold"]
- """
- The type of alert to create.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- title: str
- """
- The title of the alert.
- """
- usage_threshold: NotRequired["Alert.CreateParamsUsageThreshold"]
- """
- The configuration of the usage threshold.
- """
-
- class CreateParamsUsageThreshold(TypedDict):
- filters: NotRequired[List["Alert.CreateParamsUsageThresholdFilter"]]
- """
- The filters allows limiting the scope of this usage alert. You can only specify up to one filter at this time.
- """
- gte: int
- """
- Defines at which value the alert will fire.
- """
- meter: str
- """
- The [Billing Meter](https://docs.stripe.com/api/billing/meter) ID whose usage is monitored.
- """
- recurrence: Literal["one_time"]
- """
- Defines how the alert will behave.
- """
-
- class CreateParamsUsageThresholdFilter(TypedDict):
- customer: NotRequired[str]
- """
- Limit the scope to this usage alert only to this customer.
- """
- type: Literal["customer"]
- """
- What type of filter is being applied to this usage alert.
- """
-
- class DeactivateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(RequestOptions):
- alert_type: NotRequired[Literal["usage_threshold"]]
- """
- Filter results to only include this type of alert.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- meter: NotRequired[str]
- """
- Filter results to only include alerts with the given meter.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
alert_type: Literal["usage_threshold"]
"""
Defines the type of the alert.
@@ -181,7 +90,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def _cls_activate(
- cls, id: str, **params: Unpack["Alert.ActivateParams"]
+ cls, id: str, **params: Unpack["AlertActivateParams"]
) -> "Alert":
"""
Reactivates this alert, allowing it to trigger again.
@@ -197,14 +106,14 @@ def _cls_activate(
@overload
@staticmethod
- def activate(id: str, **params: Unpack["Alert.ActivateParams"]) -> "Alert":
+ def activate(id: str, **params: Unpack["AlertActivateParams"]) -> "Alert":
"""
Reactivates this alert, allowing it to trigger again.
"""
...
@overload
- def activate(self, **params: Unpack["Alert.ActivateParams"]) -> "Alert":
+ def activate(self, **params: Unpack["AlertActivateParams"]) -> "Alert":
"""
Reactivates this alert, allowing it to trigger again.
"""
@@ -212,7 +121,7 @@ def activate(self, **params: Unpack["Alert.ActivateParams"]) -> "Alert":
@class_method_variant("_cls_activate")
def activate( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Alert.ActivateParams"]
+ self, **params: Unpack["AlertActivateParams"]
) -> "Alert":
"""
Reactivates this alert, allowing it to trigger again.
@@ -230,7 +139,7 @@ def activate( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_activate_async(
- cls, id: str, **params: Unpack["Alert.ActivateParams"]
+ cls, id: str, **params: Unpack["AlertActivateParams"]
) -> "Alert":
"""
Reactivates this alert, allowing it to trigger again.
@@ -247,7 +156,7 @@ async def _cls_activate_async(
@overload
@staticmethod
async def activate_async(
- id: str, **params: Unpack["Alert.ActivateParams"]
+ id: str, **params: Unpack["AlertActivateParams"]
) -> "Alert":
"""
Reactivates this alert, allowing it to trigger again.
@@ -256,7 +165,7 @@ async def activate_async(
@overload
async def activate_async(
- self, **params: Unpack["Alert.ActivateParams"]
+ self, **params: Unpack["AlertActivateParams"]
) -> "Alert":
"""
Reactivates this alert, allowing it to trigger again.
@@ -265,7 +174,7 @@ async def activate_async(
@class_method_variant("_cls_activate_async")
async def activate_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Alert.ActivateParams"]
+ self, **params: Unpack["AlertActivateParams"]
) -> "Alert":
"""
Reactivates this alert, allowing it to trigger again.
@@ -283,7 +192,7 @@ async def activate_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_archive(
- cls, id: str, **params: Unpack["Alert.ArchiveParams"]
+ cls, id: str, **params: Unpack["AlertArchiveParams"]
) -> "Alert":
"""
Archives this alert, removing it from the list view and APIs. This is non-reversible.
@@ -299,14 +208,14 @@ def _cls_archive(
@overload
@staticmethod
- def archive(id: str, **params: Unpack["Alert.ArchiveParams"]) -> "Alert":
+ def archive(id: str, **params: Unpack["AlertArchiveParams"]) -> "Alert":
"""
Archives this alert, removing it from the list view and APIs. This is non-reversible.
"""
...
@overload
- def archive(self, **params: Unpack["Alert.ArchiveParams"]) -> "Alert":
+ def archive(self, **params: Unpack["AlertArchiveParams"]) -> "Alert":
"""
Archives this alert, removing it from the list view and APIs. This is non-reversible.
"""
@@ -314,7 +223,7 @@ def archive(self, **params: Unpack["Alert.ArchiveParams"]) -> "Alert":
@class_method_variant("_cls_archive")
def archive( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Alert.ArchiveParams"]
+ self, **params: Unpack["AlertArchiveParams"]
) -> "Alert":
"""
Archives this alert, removing it from the list view and APIs. This is non-reversible.
@@ -332,7 +241,7 @@ def archive( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_archive_async(
- cls, id: str, **params: Unpack["Alert.ArchiveParams"]
+ cls, id: str, **params: Unpack["AlertArchiveParams"]
) -> "Alert":
"""
Archives this alert, removing it from the list view and APIs. This is non-reversible.
@@ -349,7 +258,7 @@ async def _cls_archive_async(
@overload
@staticmethod
async def archive_async(
- id: str, **params: Unpack["Alert.ArchiveParams"]
+ id: str, **params: Unpack["AlertArchiveParams"]
) -> "Alert":
"""
Archives this alert, removing it from the list view and APIs. This is non-reversible.
@@ -358,7 +267,7 @@ async def archive_async(
@overload
async def archive_async(
- self, **params: Unpack["Alert.ArchiveParams"]
+ self, **params: Unpack["AlertArchiveParams"]
) -> "Alert":
"""
Archives this alert, removing it from the list view and APIs. This is non-reversible.
@@ -367,7 +276,7 @@ async def archive_async(
@class_method_variant("_cls_archive_async")
async def archive_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Alert.ArchiveParams"]
+ self, **params: Unpack["AlertArchiveParams"]
) -> "Alert":
"""
Archives this alert, removing it from the list view and APIs. This is non-reversible.
@@ -384,7 +293,7 @@ async def archive_async( # pyright: ignore[reportGeneralTypeIssues]
)
@classmethod
- def create(cls, **params: Unpack["Alert.CreateParams"]) -> "Alert":
+ def create(cls, **params: Unpack["AlertCreateParams"]) -> "Alert":
"""
Creates a billing alert
"""
@@ -399,7 +308,7 @@ def create(cls, **params: Unpack["Alert.CreateParams"]) -> "Alert":
@classmethod
async def create_async(
- cls, **params: Unpack["Alert.CreateParams"]
+ cls, **params: Unpack["AlertCreateParams"]
) -> "Alert":
"""
Creates a billing alert
@@ -415,7 +324,7 @@ async def create_async(
@classmethod
def _cls_deactivate(
- cls, id: str, **params: Unpack["Alert.DeactivateParams"]
+ cls, id: str, **params: Unpack["AlertDeactivateParams"]
) -> "Alert":
"""
Deactivates this alert, preventing it from triggering.
@@ -434,7 +343,7 @@ def _cls_deactivate(
@overload
@staticmethod
def deactivate(
- id: str, **params: Unpack["Alert.DeactivateParams"]
+ id: str, **params: Unpack["AlertDeactivateParams"]
) -> "Alert":
"""
Deactivates this alert, preventing it from triggering.
@@ -442,9 +351,7 @@ def deactivate(
...
@overload
- def deactivate(
- self, **params: Unpack["Alert.DeactivateParams"]
- ) -> "Alert":
+ def deactivate(self, **params: Unpack["AlertDeactivateParams"]) -> "Alert":
"""
Deactivates this alert, preventing it from triggering.
"""
@@ -452,7 +359,7 @@ def deactivate(
@class_method_variant("_cls_deactivate")
def deactivate( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Alert.DeactivateParams"]
+ self, **params: Unpack["AlertDeactivateParams"]
) -> "Alert":
"""
Deactivates this alert, preventing it from triggering.
@@ -470,7 +377,7 @@ def deactivate( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_deactivate_async(
- cls, id: str, **params: Unpack["Alert.DeactivateParams"]
+ cls, id: str, **params: Unpack["AlertDeactivateParams"]
) -> "Alert":
"""
Deactivates this alert, preventing it from triggering.
@@ -489,7 +396,7 @@ async def _cls_deactivate_async(
@overload
@staticmethod
async def deactivate_async(
- id: str, **params: Unpack["Alert.DeactivateParams"]
+ id: str, **params: Unpack["AlertDeactivateParams"]
) -> "Alert":
"""
Deactivates this alert, preventing it from triggering.
@@ -498,7 +405,7 @@ async def deactivate_async(
@overload
async def deactivate_async(
- self, **params: Unpack["Alert.DeactivateParams"]
+ self, **params: Unpack["AlertDeactivateParams"]
) -> "Alert":
"""
Deactivates this alert, preventing it from triggering.
@@ -507,7 +414,7 @@ async def deactivate_async(
@class_method_variant("_cls_deactivate_async")
async def deactivate_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Alert.DeactivateParams"]
+ self, **params: Unpack["AlertDeactivateParams"]
) -> "Alert":
"""
Deactivates this alert, preventing it from triggering.
@@ -524,7 +431,7 @@ async def deactivate_async( # pyright: ignore[reportGeneralTypeIssues]
)
@classmethod
- def list(cls, **params: Unpack["Alert.ListParams"]) -> ListObject["Alert"]:
+ def list(cls, **params: Unpack["AlertListParams"]) -> ListObject["Alert"]:
"""
Lists billing active and inactive alerts
"""
@@ -543,7 +450,7 @@ def list(cls, **params: Unpack["Alert.ListParams"]) -> ListObject["Alert"]:
@classmethod
async def list_async(
- cls, **params: Unpack["Alert.ListParams"]
+ cls, **params: Unpack["AlertListParams"]
) -> ListObject["Alert"]:
"""
Lists billing active and inactive alerts
@@ -563,7 +470,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Alert.RetrieveParams"]
+ cls, id: str, **params: Unpack["AlertRetrieveParams"]
) -> "Alert":
"""
Retrieves a billing alert given an ID
@@ -574,7 +481,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Alert.RetrieveParams"]
+ cls, id: str, **params: Unpack["AlertRetrieveParams"]
) -> "Alert":
"""
Retrieves a billing alert given an ID
diff --git a/stripe/billing/_alert_service.py b/stripe/billing/_alert_service.py
index cc9bd9231..5abb8a18c 100644
--- a/stripe/billing/_alert_service.py
+++ b/stripe/billing/_alert_service.py
@@ -5,112 +5,28 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.billing._alert import Alert
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.billing._alert_activate_params import (
+ AlertActivateParams,
+ )
+ from stripe.params.billing._alert_archive_params import AlertArchiveParams
+ from stripe.params.billing._alert_create_params import AlertCreateParams
+ from stripe.params.billing._alert_deactivate_params import (
+ AlertDeactivateParams,
+ )
+ from stripe.params.billing._alert_list_params import AlertListParams
+ from stripe.params.billing._alert_retrieve_params import (
+ AlertRetrieveParams,
+ )
-class AlertService(StripeService):
- class ActivateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ArchiveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(TypedDict):
- alert_type: Literal["usage_threshold"]
- """
- The type of alert to create.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- title: str
- """
- The title of the alert.
- """
- usage_threshold: NotRequired["AlertService.CreateParamsUsageThreshold"]
- """
- The configuration of the usage threshold.
- """
-
- class CreateParamsUsageThreshold(TypedDict):
- filters: NotRequired[
- List["AlertService.CreateParamsUsageThresholdFilter"]
- ]
- """
- The filters allows limiting the scope of this usage alert. You can only specify up to one filter at this time.
- """
- gte: int
- """
- Defines at which value the alert will fire.
- """
- meter: str
- """
- The [Billing Meter](https://docs.stripe.com/api/billing/meter) ID whose usage is monitored.
- """
- recurrence: Literal["one_time"]
- """
- Defines how the alert will behave.
- """
-
- class CreateParamsUsageThresholdFilter(TypedDict):
- customer: NotRequired[str]
- """
- Limit the scope to this usage alert only to this customer.
- """
- type: Literal["customer"]
- """
- What type of filter is being applied to this usage alert.
- """
-
- class DeactivateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(TypedDict):
- alert_type: NotRequired[Literal["usage_threshold"]]
- """
- Filter results to only include this type of alert.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- meter: NotRequired[str]
- """
- Filter results to only include alerts with the given meter.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class AlertService(StripeService):
def list(
self,
- params: Optional["AlertService.ListParams"] = None,
+ params: Optional["AlertListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Alert]:
"""
@@ -129,7 +45,7 @@ def list(
async def list_async(
self,
- params: Optional["AlertService.ListParams"] = None,
+ params: Optional["AlertListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Alert]:
"""
@@ -148,7 +64,7 @@ async def list_async(
def create(
self,
- params: "AlertService.CreateParams",
+ params: "AlertCreateParams",
options: Optional[RequestOptions] = None,
) -> Alert:
"""
@@ -167,7 +83,7 @@ def create(
async def create_async(
self,
- params: "AlertService.CreateParams",
+ params: "AlertCreateParams",
options: Optional[RequestOptions] = None,
) -> Alert:
"""
@@ -187,7 +103,7 @@ async def create_async(
def retrieve(
self,
id: str,
- params: Optional["AlertService.RetrieveParams"] = None,
+ params: Optional["AlertRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Alert:
"""
@@ -207,7 +123,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["AlertService.RetrieveParams"] = None,
+ params: Optional["AlertRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Alert:
"""
@@ -227,7 +143,7 @@ async def retrieve_async(
def activate(
self,
id: str,
- params: Optional["AlertService.ActivateParams"] = None,
+ params: Optional["AlertActivateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Alert:
"""
@@ -247,7 +163,7 @@ def activate(
async def activate_async(
self,
id: str,
- params: Optional["AlertService.ActivateParams"] = None,
+ params: Optional["AlertActivateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Alert:
"""
@@ -267,7 +183,7 @@ async def activate_async(
def archive(
self,
id: str,
- params: Optional["AlertService.ArchiveParams"] = None,
+ params: Optional["AlertArchiveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Alert:
"""
@@ -287,7 +203,7 @@ def archive(
async def archive_async(
self,
id: str,
- params: Optional["AlertService.ArchiveParams"] = None,
+ params: Optional["AlertArchiveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Alert:
"""
@@ -307,7 +223,7 @@ async def archive_async(
def deactivate(
self,
id: str,
- params: Optional["AlertService.DeactivateParams"] = None,
+ params: Optional["AlertDeactivateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Alert:
"""
@@ -329,7 +245,7 @@ def deactivate(
async def deactivate_async(
self,
id: str,
- params: Optional["AlertService.DeactivateParams"] = None,
+ params: Optional["AlertDeactivateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Alert:
"""
diff --git a/stripe/billing/_credit_balance_summary.py b/stripe/billing/_credit_balance_summary.py
index e94dc59dd..27c5eedce 100644
--- a/stripe/billing/_credit_balance_summary.py
+++ b/stripe/billing/_credit_balance_summary.py
@@ -1,20 +1,16 @@
# -*- coding: utf-8 -*-
# File generated from our OpenAPI spec
from stripe._expandable_field import ExpandableField
-from stripe._request_options import RequestOptions
from stripe._singleton_api_resource import SingletonAPIResource
from stripe._stripe_object import StripeObject
from typing import ClassVar, List, Optional
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._customer import Customer
+ from stripe.params.billing._credit_balance_summary_retrieve_params import (
+ CreditBalanceSummaryRetrieveParams,
+ )
class CreditBalanceSummary(SingletonAPIResource["CreditBalanceSummary"]):
@@ -76,56 +72,6 @@ class Monetary(StripeObject):
"ledger_balance": LedgerBalance,
}
- class RetrieveParams(RequestOptions):
- customer: str
- """
- The customer for which to fetch credit balance summary.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- filter: "CreditBalanceSummary.RetrieveParamsFilter"
- """
- The filter criteria for the credit balance summary.
- """
-
- class RetrieveParamsFilter(TypedDict):
- applicability_scope: NotRequired[
- "CreditBalanceSummary.RetrieveParamsFilterApplicabilityScope"
- ]
- """
- The billing credit applicability scope for which to fetch credit balance summary.
- """
- credit_grant: NotRequired[str]
- """
- The credit grant for which to fetch credit balance summary.
- """
- type: Literal["applicability_scope", "credit_grant"]
- """
- Specify the type of this filter.
- """
-
- class RetrieveParamsFilterApplicabilityScope(TypedDict):
- price_type: NotRequired[Literal["metered"]]
- """
- The price type that credit grants can apply to. We currently only support the `metered` price type. Cannot be used in combination with `prices`.
- """
- prices: NotRequired[
- List[
- "CreditBalanceSummary.RetrieveParamsFilterApplicabilityScopePrice"
- ]
- ]
- """
- A list of prices that the credit grant can apply to. We currently only support the `metered` prices. Cannot be used in combination with `price_type`.
- """
-
- class RetrieveParamsFilterApplicabilityScopePrice(TypedDict):
- id: str
- """
- The price ID this credit grant should apply to.
- """
-
balances: List[Balance]
"""
The billing credit balances. One entry per credit grant currency. If a customer only has credit grants in a single currency, then this will have a single balance entry.
@@ -145,7 +91,7 @@ class RetrieveParamsFilterApplicabilityScopePrice(TypedDict):
@classmethod
def retrieve(
- cls, **params: Unpack["CreditBalanceSummary.RetrieveParams"]
+ cls, **params: Unpack["CreditBalanceSummaryRetrieveParams"]
) -> "CreditBalanceSummary":
"""
Retrieves the credit balance summary for a customer.
@@ -156,7 +102,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, **params: Unpack["CreditBalanceSummary.RetrieveParams"]
+ cls, **params: Unpack["CreditBalanceSummaryRetrieveParams"]
) -> "CreditBalanceSummary":
"""
Retrieves the credit balance summary for a customer.
diff --git a/stripe/billing/_credit_balance_summary_service.py b/stripe/billing/_credit_balance_summary_service.py
index 780ae5bdb..c2862ce42 100644
--- a/stripe/billing/_credit_balance_summary_service.py
+++ b/stripe/billing/_credit_balance_summary_service.py
@@ -3,64 +3,19 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe.billing._credit_balance_summary import CreditBalanceSummary
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.billing._credit_balance_summary_retrieve_params import (
+ CreditBalanceSummaryRetrieveParams,
+ )
-class CreditBalanceSummaryService(StripeService):
- class RetrieveParams(TypedDict):
- customer: str
- """
- The customer for which to fetch credit balance summary.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- filter: "CreditBalanceSummaryService.RetrieveParamsFilter"
- """
- The filter criteria for the credit balance summary.
- """
-
- class RetrieveParamsFilter(TypedDict):
- applicability_scope: NotRequired[
- "CreditBalanceSummaryService.RetrieveParamsFilterApplicabilityScope"
- ]
- """
- The billing credit applicability scope for which to fetch credit balance summary.
- """
- credit_grant: NotRequired[str]
- """
- The credit grant for which to fetch credit balance summary.
- """
- type: Literal["applicability_scope", "credit_grant"]
- """
- Specify the type of this filter.
- """
-
- class RetrieveParamsFilterApplicabilityScope(TypedDict):
- price_type: NotRequired[Literal["metered"]]
- """
- The price type that credit grants can apply to. We currently only support the `metered` price type. Cannot be used in combination with `prices`.
- """
- prices: NotRequired[
- List[
- "CreditBalanceSummaryService.RetrieveParamsFilterApplicabilityScopePrice"
- ]
- ]
- """
- A list of prices that the credit grant can apply to. We currently only support the `metered` prices. Cannot be used in combination with `price_type`.
- """
-
- class RetrieveParamsFilterApplicabilityScopePrice(TypedDict):
- id: str
- """
- The price ID this credit grant should apply to.
- """
+class CreditBalanceSummaryService(StripeService):
def retrieve(
self,
- params: "CreditBalanceSummaryService.RetrieveParams",
+ params: "CreditBalanceSummaryRetrieveParams",
options: Optional[RequestOptions] = None,
) -> CreditBalanceSummary:
"""
@@ -79,7 +34,7 @@ def retrieve(
async def retrieve_async(
self,
- params: "CreditBalanceSummaryService.RetrieveParams",
+ params: "CreditBalanceSummaryRetrieveParams",
options: Optional[RequestOptions] = None,
) -> CreditBalanceSummary:
"""
diff --git a/stripe/billing/_credit_balance_transaction.py b/stripe/billing/_credit_balance_transaction.py
index 630cb3693..f66eb7b02 100644
--- a/stripe/billing/_credit_balance_transaction.py
+++ b/stripe/billing/_credit_balance_transaction.py
@@ -3,14 +3,19 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
-from typing import ClassVar, List, Optional
-from typing_extensions import Literal, NotRequired, Unpack, TYPE_CHECKING
+from typing import ClassVar, Optional
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._invoice import Invoice
from stripe.billing._credit_grant import CreditGrant
+ from stripe.params.billing._credit_balance_transaction_list_params import (
+ CreditBalanceTransactionListParams,
+ )
+ from stripe.params.billing._credit_balance_transaction_retrieve_params import (
+ CreditBalanceTransactionRetrieveParams,
+ )
from stripe.test_helpers._test_clock import TestClock
@@ -119,38 +124,6 @@ class CreditsApplied(StripeObject):
"credits_applied": CreditsApplied,
}
- class ListParams(RequestOptions):
- credit_grant: NotRequired[str]
- """
- The credit grant for which to fetch credit balance transactions.
- """
- customer: str
- """
- The customer for which to fetch credit balance transactions.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -194,7 +167,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["CreditBalanceTransaction.ListParams"]
+ cls, **params: Unpack["CreditBalanceTransactionListParams"]
) -> ListObject["CreditBalanceTransaction"]:
"""
Retrieve a list of credit balance transactions.
@@ -214,7 +187,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["CreditBalanceTransaction.ListParams"]
+ cls, **params: Unpack["CreditBalanceTransactionListParams"]
) -> ListObject["CreditBalanceTransaction"]:
"""
Retrieve a list of credit balance transactions.
@@ -236,7 +209,7 @@ async def list_async(
def retrieve(
cls,
id: str,
- **params: Unpack["CreditBalanceTransaction.RetrieveParams"],
+ **params: Unpack["CreditBalanceTransactionRetrieveParams"],
) -> "CreditBalanceTransaction":
"""
Retrieves a credit balance transaction.
@@ -249,7 +222,7 @@ def retrieve(
async def retrieve_async(
cls,
id: str,
- **params: Unpack["CreditBalanceTransaction.RetrieveParams"],
+ **params: Unpack["CreditBalanceTransactionRetrieveParams"],
) -> "CreditBalanceTransaction":
"""
Retrieves a credit balance transaction.
diff --git a/stripe/billing/_credit_balance_transaction_service.py b/stripe/billing/_credit_balance_transaction_service.py
index df20ac446..e9a17758e 100644
--- a/stripe/billing/_credit_balance_transaction_service.py
+++ b/stripe/billing/_credit_balance_transaction_service.py
@@ -5,46 +5,22 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.billing._credit_balance_transaction import CreditBalanceTransaction
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.billing._credit_balance_transaction_list_params import (
+ CreditBalanceTransactionListParams,
+ )
+ from stripe.params.billing._credit_balance_transaction_retrieve_params import (
+ CreditBalanceTransactionRetrieveParams,
+ )
-class CreditBalanceTransactionService(StripeService):
- class ListParams(TypedDict):
- credit_grant: NotRequired[str]
- """
- The credit grant for which to fetch credit balance transactions.
- """
- customer: str
- """
- The customer for which to fetch credit balance transactions.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class CreditBalanceTransactionService(StripeService):
def list(
self,
- params: "CreditBalanceTransactionService.ListParams",
+ params: "CreditBalanceTransactionListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[CreditBalanceTransaction]:
"""
@@ -63,7 +39,7 @@ def list(
async def list_async(
self,
- params: "CreditBalanceTransactionService.ListParams",
+ params: "CreditBalanceTransactionListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[CreditBalanceTransaction]:
"""
@@ -83,9 +59,7 @@ async def list_async(
def retrieve(
self,
id: str,
- params: Optional[
- "CreditBalanceTransactionService.RetrieveParams"
- ] = None,
+ params: Optional["CreditBalanceTransactionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditBalanceTransaction:
"""
@@ -107,9 +81,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional[
- "CreditBalanceTransactionService.RetrieveParams"
- ] = None,
+ params: Optional["CreditBalanceTransactionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditBalanceTransaction:
"""
diff --git a/stripe/billing/_credit_grant.py b/stripe/billing/_credit_grant.py
index c8fbabf2a..fda5610a2 100644
--- a/stripe/billing/_credit_grant.py
+++ b/stripe/billing/_credit_grant.py
@@ -4,21 +4,32 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._customer import Customer
+ from stripe.params.billing._credit_grant_create_params import (
+ CreditGrantCreateParams,
+ )
+ from stripe.params.billing._credit_grant_expire_params import (
+ CreditGrantExpireParams,
+ )
+ from stripe.params.billing._credit_grant_list_params import (
+ CreditGrantListParams,
+ )
+ from stripe.params.billing._credit_grant_modify_params import (
+ CreditGrantModifyParams,
+ )
+ from stripe.params.billing._credit_grant_retrieve_params import (
+ CreditGrantRetrieveParams,
+ )
+ from stripe.params.billing._credit_grant_void_grant_params import (
+ CreditGrantVoidGrantParams,
+ )
from stripe.test_helpers._test_clock import TestClock
@@ -79,146 +90,6 @@ class Price(StripeObject):
scope: Scope
_inner_class_types = {"scope": Scope}
- class CreateParams(RequestOptions):
- amount: "CreditGrant.CreateParamsAmount"
- """
- Amount of this credit grant.
- """
- applicability_config: "CreditGrant.CreateParamsApplicabilityConfig"
- """
- Configuration specifying what this credit grant applies to. We currently only support `metered` prices that have a [Billing Meter](https://docs.stripe.com/api/billing/meter) attached to them.
- """
- category: Literal["paid", "promotional"]
- """
- The category of this credit grant.
- """
- customer: str
- """
- ID of the customer to receive the billing credits.
- """
- effective_at: NotRequired[int]
- """
- The time when the billing credits become effective-when they're eligible for use. It defaults to the current timestamp if not specified.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- The time when the billing credits expire. If not specified, the billing credits don't expire.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of key-value pairs that you can attach to an object. You can use this to store additional information about the object (for example, cost basis) in a structured format.
- """
- name: NotRequired[str]
- """
- A descriptive name shown in the Dashboard.
- """
- priority: NotRequired[int]
- """
- The desired priority for applying this credit grant. If not specified, it will be set to the default value of 50. The highest priority is 0 and the lowest is 100.
- """
-
- class CreateParamsAmount(TypedDict):
- monetary: NotRequired["CreditGrant.CreateParamsAmountMonetary"]
- """
- The monetary amount.
- """
- type: Literal["monetary"]
- """
- The type of this amount. We currently only support `monetary` billing credits.
- """
-
- class CreateParamsAmountMonetary(TypedDict):
- currency: str
- """
- Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `value` parameter.
- """
- value: int
- """
- A positive integer representing the amount of the credit grant.
- """
-
- class CreateParamsApplicabilityConfig(TypedDict):
- scope: "CreditGrant.CreateParamsApplicabilityConfigScope"
- """
- Specify the scope of this applicability config.
- """
-
- class CreateParamsApplicabilityConfigScope(TypedDict):
- price_type: NotRequired[Literal["metered"]]
- """
- The price type that credit grants can apply to. We currently only support the `metered` price type. Cannot be used in combination with `prices`.
- """
- prices: NotRequired[
- List["CreditGrant.CreateParamsApplicabilityConfigScopePrice"]
- ]
- """
- A list of prices that the credit grant can apply to. We currently only support the `metered` prices. Cannot be used in combination with `price_type`.
- """
-
- class CreateParamsApplicabilityConfigScopePrice(TypedDict):
- id: str
- """
- The price ID this credit grant should apply to.
- """
-
- class ExpireParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(RequestOptions):
- customer: NotRequired[str]
- """
- Only return credit grants for this customer.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ModifyParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired["Literal['']|int"]
- """
- The time when the billing credits created by this credit grant expire. If set to empty, the billing credits never expire.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of key-value pairs you can attach to an object. You can use this to store additional information about the object (for example, cost basis) in a structured format.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class VoidGrantParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount: Amount
applicability_config: ApplicabilityConfig
category: Literal["paid", "promotional"]
@@ -280,7 +151,7 @@ class VoidGrantParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["CreditGrant.CreateParams"]
+ cls, **params: Unpack["CreditGrantCreateParams"]
) -> "CreditGrant":
"""
Creates a credit grant.
@@ -296,7 +167,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["CreditGrant.CreateParams"]
+ cls, **params: Unpack["CreditGrantCreateParams"]
) -> "CreditGrant":
"""
Creates a credit grant.
@@ -312,7 +183,7 @@ async def create_async(
@classmethod
def _cls_expire(
- cls, id: str, **params: Unpack["CreditGrant.ExpireParams"]
+ cls, id: str, **params: Unpack["CreditGrantExpireParams"]
) -> "CreditGrant":
"""
Expires a credit grant.
@@ -331,7 +202,7 @@ def _cls_expire(
@overload
@staticmethod
def expire(
- id: str, **params: Unpack["CreditGrant.ExpireParams"]
+ id: str, **params: Unpack["CreditGrantExpireParams"]
) -> "CreditGrant":
"""
Expires a credit grant.
@@ -340,7 +211,7 @@ def expire(
@overload
def expire(
- self, **params: Unpack["CreditGrant.ExpireParams"]
+ self, **params: Unpack["CreditGrantExpireParams"]
) -> "CreditGrant":
"""
Expires a credit grant.
@@ -349,7 +220,7 @@ def expire(
@class_method_variant("_cls_expire")
def expire( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["CreditGrant.ExpireParams"]
+ self, **params: Unpack["CreditGrantExpireParams"]
) -> "CreditGrant":
"""
Expires a credit grant.
@@ -367,7 +238,7 @@ def expire( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_expire_async(
- cls, id: str, **params: Unpack["CreditGrant.ExpireParams"]
+ cls, id: str, **params: Unpack["CreditGrantExpireParams"]
) -> "CreditGrant":
"""
Expires a credit grant.
@@ -386,7 +257,7 @@ async def _cls_expire_async(
@overload
@staticmethod
async def expire_async(
- id: str, **params: Unpack["CreditGrant.ExpireParams"]
+ id: str, **params: Unpack["CreditGrantExpireParams"]
) -> "CreditGrant":
"""
Expires a credit grant.
@@ -395,7 +266,7 @@ async def expire_async(
@overload
async def expire_async(
- self, **params: Unpack["CreditGrant.ExpireParams"]
+ self, **params: Unpack["CreditGrantExpireParams"]
) -> "CreditGrant":
"""
Expires a credit grant.
@@ -404,7 +275,7 @@ async def expire_async(
@class_method_variant("_cls_expire_async")
async def expire_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["CreditGrant.ExpireParams"]
+ self, **params: Unpack["CreditGrantExpireParams"]
) -> "CreditGrant":
"""
Expires a credit grant.
@@ -422,7 +293,7 @@ async def expire_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["CreditGrant.ListParams"]
+ cls, **params: Unpack["CreditGrantListParams"]
) -> ListObject["CreditGrant"]:
"""
Retrieve a list of credit grants.
@@ -442,7 +313,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["CreditGrant.ListParams"]
+ cls, **params: Unpack["CreditGrantListParams"]
) -> ListObject["CreditGrant"]:
"""
Retrieve a list of credit grants.
@@ -462,7 +333,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["CreditGrant.ModifyParams"]
+ cls, id: str, **params: Unpack["CreditGrantModifyParams"]
) -> "CreditGrant":
"""
Updates a credit grant.
@@ -479,7 +350,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["CreditGrant.ModifyParams"]
+ cls, id: str, **params: Unpack["CreditGrantModifyParams"]
) -> "CreditGrant":
"""
Updates a credit grant.
@@ -496,7 +367,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["CreditGrant.RetrieveParams"]
+ cls, id: str, **params: Unpack["CreditGrantRetrieveParams"]
) -> "CreditGrant":
"""
Retrieves a credit grant.
@@ -507,7 +378,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["CreditGrant.RetrieveParams"]
+ cls, id: str, **params: Unpack["CreditGrantRetrieveParams"]
) -> "CreditGrant":
"""
Retrieves a credit grant.
@@ -518,7 +389,7 @@ async def retrieve_async(
@classmethod
def _cls_void_grant(
- cls, id: str, **params: Unpack["CreditGrant.VoidGrantParams"]
+ cls, id: str, **params: Unpack["CreditGrantVoidGrantParams"]
) -> "CreditGrant":
"""
Voids a credit grant.
@@ -537,7 +408,7 @@ def _cls_void_grant(
@overload
@staticmethod
def void_grant(
- id: str, **params: Unpack["CreditGrant.VoidGrantParams"]
+ id: str, **params: Unpack["CreditGrantVoidGrantParams"]
) -> "CreditGrant":
"""
Voids a credit grant.
@@ -546,7 +417,7 @@ def void_grant(
@overload
def void_grant(
- self, **params: Unpack["CreditGrant.VoidGrantParams"]
+ self, **params: Unpack["CreditGrantVoidGrantParams"]
) -> "CreditGrant":
"""
Voids a credit grant.
@@ -555,7 +426,7 @@ def void_grant(
@class_method_variant("_cls_void_grant")
def void_grant( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["CreditGrant.VoidGrantParams"]
+ self, **params: Unpack["CreditGrantVoidGrantParams"]
) -> "CreditGrant":
"""
Voids a credit grant.
@@ -573,7 +444,7 @@ def void_grant( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_void_grant_async(
- cls, id: str, **params: Unpack["CreditGrant.VoidGrantParams"]
+ cls, id: str, **params: Unpack["CreditGrantVoidGrantParams"]
) -> "CreditGrant":
"""
Voids a credit grant.
@@ -592,7 +463,7 @@ async def _cls_void_grant_async(
@overload
@staticmethod
async def void_grant_async(
- id: str, **params: Unpack["CreditGrant.VoidGrantParams"]
+ id: str, **params: Unpack["CreditGrantVoidGrantParams"]
) -> "CreditGrant":
"""
Voids a credit grant.
@@ -601,7 +472,7 @@ async def void_grant_async(
@overload
async def void_grant_async(
- self, **params: Unpack["CreditGrant.VoidGrantParams"]
+ self, **params: Unpack["CreditGrantVoidGrantParams"]
) -> "CreditGrant":
"""
Voids a credit grant.
@@ -610,7 +481,7 @@ async def void_grant_async(
@class_method_variant("_cls_void_grant_async")
async def void_grant_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["CreditGrant.VoidGrantParams"]
+ self, **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 86b3b3ce8..e4e10239f 100644
--- a/stripe/billing/_credit_grant_service.py
+++ b/stripe/billing/_credit_grant_service.py
@@ -5,158 +5,34 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.billing._credit_grant import CreditGrant
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.billing._credit_grant_create_params import (
+ CreditGrantCreateParams,
+ )
+ from stripe.params.billing._credit_grant_expire_params import (
+ CreditGrantExpireParams,
+ )
+ from stripe.params.billing._credit_grant_list_params import (
+ CreditGrantListParams,
+ )
+ from stripe.params.billing._credit_grant_retrieve_params import (
+ CreditGrantRetrieveParams,
+ )
+ from stripe.params.billing._credit_grant_update_params import (
+ CreditGrantUpdateParams,
+ )
+ from stripe.params.billing._credit_grant_void_grant_params import (
+ CreditGrantVoidGrantParams,
+ )
-class CreditGrantService(StripeService):
- class CreateParams(TypedDict):
- amount: "CreditGrantService.CreateParamsAmount"
- """
- Amount of this credit grant.
- """
- applicability_config: (
- "CreditGrantService.CreateParamsApplicabilityConfig"
- )
- """
- Configuration specifying what this credit grant applies to. We currently only support `metered` prices that have a [Billing Meter](https://docs.stripe.com/api/billing/meter) attached to them.
- """
- category: Literal["paid", "promotional"]
- """
- The category of this credit grant.
- """
- customer: str
- """
- ID of the customer to receive the billing credits.
- """
- effective_at: NotRequired[int]
- """
- The time when the billing credits become effective-when they're eligible for use. It defaults to the current timestamp if not specified.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- The time when the billing credits expire. If not specified, the billing credits don't expire.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of key-value pairs that you can attach to an object. You can use this to store additional information about the object (for example, cost basis) in a structured format.
- """
- name: NotRequired[str]
- """
- A descriptive name shown in the Dashboard.
- """
- priority: NotRequired[int]
- """
- The desired priority for applying this credit grant. If not specified, it will be set to the default value of 50. The highest priority is 0 and the lowest is 100.
- """
-
- class CreateParamsAmount(TypedDict):
- monetary: NotRequired["CreditGrantService.CreateParamsAmountMonetary"]
- """
- The monetary amount.
- """
- type: Literal["monetary"]
- """
- The type of this amount. We currently only support `monetary` billing credits.
- """
-
- class CreateParamsAmountMonetary(TypedDict):
- currency: str
- """
- Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `value` parameter.
- """
- value: int
- """
- A positive integer representing the amount of the credit grant.
- """
-
- class CreateParamsApplicabilityConfig(TypedDict):
- scope: "CreditGrantService.CreateParamsApplicabilityConfigScope"
- """
- Specify the scope of this applicability config.
- """
-
- class CreateParamsApplicabilityConfigScope(TypedDict):
- price_type: NotRequired[Literal["metered"]]
- """
- The price type that credit grants can apply to. We currently only support the `metered` price type. Cannot be used in combination with `prices`.
- """
- prices: NotRequired[
- List[
- "CreditGrantService.CreateParamsApplicabilityConfigScopePrice"
- ]
- ]
- """
- A list of prices that the credit grant can apply to. We currently only support the `metered` prices. Cannot be used in combination with `price_type`.
- """
-
- class CreateParamsApplicabilityConfigScopePrice(TypedDict):
- id: str
- """
- The price ID this credit grant should apply to.
- """
-
- class ExpireParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(TypedDict):
- customer: NotRequired[str]
- """
- Only return credit grants for this customer.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired["Literal['']|int"]
- """
- The time when the billing credits created by this credit grant expire. If set to empty, the billing credits never expire.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of key-value pairs you can attach to an object. You can use this to store additional information about the object (for example, cost basis) in a structured format.
- """
-
- class VoidGrantParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class CreditGrantService(StripeService):
def list(
self,
- params: Optional["CreditGrantService.ListParams"] = None,
+ params: Optional["CreditGrantListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[CreditGrant]:
"""
@@ -175,7 +51,7 @@ def list(
async def list_async(
self,
- params: Optional["CreditGrantService.ListParams"] = None,
+ params: Optional["CreditGrantListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[CreditGrant]:
"""
@@ -194,7 +70,7 @@ async def list_async(
def create(
self,
- params: "CreditGrantService.CreateParams",
+ params: "CreditGrantCreateParams",
options: Optional[RequestOptions] = None,
) -> CreditGrant:
"""
@@ -213,7 +89,7 @@ def create(
async def create_async(
self,
- params: "CreditGrantService.CreateParams",
+ params: "CreditGrantCreateParams",
options: Optional[RequestOptions] = None,
) -> CreditGrant:
"""
@@ -233,7 +109,7 @@ async def create_async(
def retrieve(
self,
id: str,
- params: Optional["CreditGrantService.RetrieveParams"] = None,
+ params: Optional["CreditGrantRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditGrant:
"""
@@ -253,7 +129,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["CreditGrantService.RetrieveParams"] = None,
+ params: Optional["CreditGrantRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditGrant:
"""
@@ -273,7 +149,7 @@ async def retrieve_async(
def update(
self,
id: str,
- params: Optional["CreditGrantService.UpdateParams"] = None,
+ params: Optional["CreditGrantUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditGrant:
"""
@@ -293,7 +169,7 @@ def update(
async def update_async(
self,
id: str,
- params: Optional["CreditGrantService.UpdateParams"] = None,
+ params: Optional["CreditGrantUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditGrant:
"""
@@ -313,7 +189,7 @@ async def update_async(
def expire(
self,
id: str,
- params: Optional["CreditGrantService.ExpireParams"] = None,
+ params: Optional["CreditGrantExpireParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditGrant:
"""
@@ -335,7 +211,7 @@ def expire(
async def expire_async(
self,
id: str,
- params: Optional["CreditGrantService.ExpireParams"] = None,
+ params: Optional["CreditGrantExpireParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditGrant:
"""
@@ -357,7 +233,7 @@ async def expire_async(
def void_grant(
self,
id: str,
- params: Optional["CreditGrantService.VoidGrantParams"] = None,
+ params: Optional["CreditGrantVoidGrantParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditGrant:
"""
@@ -379,7 +255,7 @@ def void_grant(
async def void_grant_async(
self,
id: str,
- params: Optional["CreditGrantService.VoidGrantParams"] = None,
+ params: Optional["CreditGrantVoidGrantParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditGrant:
"""
diff --git a/stripe/billing/_meter.py b/stripe/billing/_meter.py
index a0ae2cf4a..5f7d7b114 100644
--- a/stripe/billing/_meter.py
+++ b/stripe/billing/_meter.py
@@ -4,21 +4,29 @@
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
from stripe._nested_resource_class_methods import nested_resource_class_methods
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe.billing._meter_event_summary import MeterEventSummary
+ from stripe.params.billing._meter_create_params import MeterCreateParams
+ from stripe.params.billing._meter_deactivate_params import (
+ MeterDeactivateParams,
+ )
+ from stripe.params.billing._meter_list_event_summaries_params import (
+ MeterListEventSummariesParams,
+ )
+ from stripe.params.billing._meter_list_params import MeterListParams
+ from stripe.params.billing._meter_modify_params import MeterModifyParams
+ from stripe.params.billing._meter_reactivate_params import (
+ MeterReactivateParams,
+ )
+ from stripe.params.billing._meter_retrieve_params import (
+ MeterRetrieveParams,
+ )
@nested_resource_class_methods("event_summary")
@@ -63,142 +71,6 @@ class ValueSettings(StripeObject):
The key in the meter event payload to use as the value for this meter.
"""
- class CreateParams(RequestOptions):
- customer_mapping: NotRequired["Meter.CreateParamsCustomerMapping"]
- """
- Fields that specify how to map a meter event to a customer.
- """
- default_aggregation: "Meter.CreateParamsDefaultAggregation"
- """
- The default settings to aggregate a meter's events with.
- """
- display_name: str
- """
- The meter's name. Not visible to the customer.
- """
- event_name: str
- """
- The name of the meter event to record usage for. Corresponds with the `event_name` field on meter events.
- """
- event_time_window: NotRequired[Literal["day", "hour"]]
- """
- The time window which meter events have been pre-aggregated for, if any.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- value_settings: NotRequired["Meter.CreateParamsValueSettings"]
- """
- Fields that specify how to calculate a meter event's value.
- """
-
- class CreateParamsCustomerMapping(TypedDict):
- event_payload_key: str
- """
- The key in the meter event payload to use for mapping the event to a customer.
- """
- type: Literal["by_id"]
- """
- The method for mapping a meter event to a customer. Must be `by_id`.
- """
-
- class CreateParamsDefaultAggregation(TypedDict):
- formula: Literal["count", "last", "sum"]
- """
- Specifies how events are aggregated. Allowed values are `count` to count the number of events, `sum` to sum each event's value and `last` to take the last event's value in the window.
- """
-
- class CreateParamsValueSettings(TypedDict):
- event_payload_key: str
- """
- The key in the usage event payload to use as the value for this meter. For example, if the event payload contains usage on a `bytes_used` field, then set the event_payload_key to "bytes_used".
- """
-
- class DeactivateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListEventSummariesParams(RequestOptions):
- customer: str
- """
- The customer for which to fetch event summaries.
- """
- end_time: int
- """
- The timestamp from when to stop aggregating meter events (exclusive). Must be aligned with minute boundaries.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- start_time: int
- """
- The timestamp from when to start aggregating meter events (inclusive). Must be aligned with minute boundaries.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- value_grouping_window: NotRequired[Literal["day", "hour"]]
- """
- Specifies what granularity to use when generating event summaries. If not specified, a single event summary would be returned for the specified time range. For hourly granularity, start and end times must align with hour boundaries (e.g., 00:00, 01:00, ..., 23:00). For daily granularity, start and end times must align with UTC day boundaries (00:00 UTC).
- """
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["active", "inactive"]]
- """
- Filter results to only include meters with the given status.
- """
-
- class ModifyParams(RequestOptions):
- display_name: NotRequired[str]
- """
- The meter's name. Not visible to the customer.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ReactivateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -241,7 +113,7 @@ class RetrieveParams(RequestOptions):
value_settings: ValueSettings
@classmethod
- def create(cls, **params: Unpack["Meter.CreateParams"]) -> "Meter":
+ def create(cls, **params: Unpack["MeterCreateParams"]) -> "Meter":
"""
Creates a billing meter.
"""
@@ -256,7 +128,7 @@ def create(cls, **params: Unpack["Meter.CreateParams"]) -> "Meter":
@classmethod
async def create_async(
- cls, **params: Unpack["Meter.CreateParams"]
+ cls, **params: Unpack["MeterCreateParams"]
) -> "Meter":
"""
Creates a billing meter.
@@ -272,7 +144,7 @@ async def create_async(
@classmethod
def _cls_deactivate(
- cls, id: str, **params: Unpack["Meter.DeactivateParams"]
+ 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.
@@ -291,7 +163,7 @@ def _cls_deactivate(
@overload
@staticmethod
def deactivate(
- id: str, **params: Unpack["Meter.DeactivateParams"]
+ 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.
@@ -299,9 +171,7 @@ def deactivate(
...
@overload
- def deactivate(
- self, **params: Unpack["Meter.DeactivateParams"]
- ) -> "Meter":
+ def deactivate(self, **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.
"""
@@ -309,7 +179,7 @@ def deactivate(
@class_method_variant("_cls_deactivate")
def deactivate( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Meter.DeactivateParams"]
+ self, **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.
@@ -327,7 +197,7 @@ def deactivate( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_deactivate_async(
- cls, id: str, **params: Unpack["Meter.DeactivateParams"]
+ 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.
@@ -346,7 +216,7 @@ async def _cls_deactivate_async(
@overload
@staticmethod
async def deactivate_async(
- id: str, **params: Unpack["Meter.DeactivateParams"]
+ 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.
@@ -355,7 +225,7 @@ async def deactivate_async(
@overload
async def deactivate_async(
- self, **params: Unpack["Meter.DeactivateParams"]
+ self, **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.
@@ -364,7 +234,7 @@ async def deactivate_async(
@class_method_variant("_cls_deactivate_async")
async def deactivate_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Meter.DeactivateParams"]
+ self, **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.
@@ -381,7 +251,7 @@ async def deactivate_async( # pyright: ignore[reportGeneralTypeIssues]
)
@classmethod
- def list(cls, **params: Unpack["Meter.ListParams"]) -> ListObject["Meter"]:
+ def list(cls, **params: Unpack["MeterListParams"]) -> ListObject["Meter"]:
"""
Retrieve a list of billing meters.
"""
@@ -400,7 +270,7 @@ def list(cls, **params: Unpack["Meter.ListParams"]) -> ListObject["Meter"]:
@classmethod
async def list_async(
- cls, **params: Unpack["Meter.ListParams"]
+ cls, **params: Unpack["MeterListParams"]
) -> ListObject["Meter"]:
"""
Retrieve a list of billing meters.
@@ -419,9 +289,7 @@ async def list_async(
return result
@classmethod
- def modify(
- cls, id: str, **params: Unpack["Meter.ModifyParams"]
- ) -> "Meter":
+ def modify(cls, id: str, **params: Unpack["MeterModifyParams"]) -> "Meter":
"""
Updates a billing meter.
"""
@@ -437,7 +305,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Meter.ModifyParams"]
+ cls, id: str, **params: Unpack["MeterModifyParams"]
) -> "Meter":
"""
Updates a billing meter.
@@ -454,7 +322,7 @@ async def modify_async(
@classmethod
def _cls_reactivate(
- cls, id: str, **params: Unpack["Meter.ReactivateParams"]
+ 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.
@@ -473,7 +341,7 @@ def _cls_reactivate(
@overload
@staticmethod
def reactivate(
- id: str, **params: Unpack["Meter.ReactivateParams"]
+ 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.
@@ -481,9 +349,7 @@ def reactivate(
...
@overload
- def reactivate(
- self, **params: Unpack["Meter.ReactivateParams"]
- ) -> "Meter":
+ def reactivate(self, **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.
"""
@@ -491,7 +357,7 @@ def reactivate(
@class_method_variant("_cls_reactivate")
def reactivate( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Meter.ReactivateParams"]
+ self, **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.
@@ -509,7 +375,7 @@ def reactivate( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_reactivate_async(
- cls, id: str, **params: Unpack["Meter.ReactivateParams"]
+ 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.
@@ -528,7 +394,7 @@ async def _cls_reactivate_async(
@overload
@staticmethod
async def reactivate_async(
- id: str, **params: Unpack["Meter.ReactivateParams"]
+ 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.
@@ -537,7 +403,7 @@ async def reactivate_async(
@overload
async def reactivate_async(
- self, **params: Unpack["Meter.ReactivateParams"]
+ self, **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.
@@ -546,7 +412,7 @@ async def reactivate_async(
@class_method_variant("_cls_reactivate_async")
async def reactivate_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Meter.ReactivateParams"]
+ self, **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.
@@ -564,7 +430,7 @@ async def reactivate_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Meter.RetrieveParams"]
+ cls, id: str, **params: Unpack["MeterRetrieveParams"]
) -> "Meter":
"""
Retrieves a billing meter given an ID.
@@ -575,7 +441,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Meter.RetrieveParams"]
+ cls, id: str, **params: Unpack["MeterRetrieveParams"]
) -> "Meter":
"""
Retrieves a billing meter given an ID.
@@ -586,7 +452,7 @@ async def retrieve_async(
@classmethod
def list_event_summaries(
- cls, id: str, **params: Unpack["Meter.ListEventSummariesParams"]
+ cls, id: str, **params: Unpack["MeterListEventSummariesParams"]
) -> ListObject["MeterEventSummary"]:
"""
Retrieve a list of billing meter event summaries.
@@ -604,7 +470,7 @@ def list_event_summaries(
@classmethod
async def list_event_summaries_async(
- cls, id: str, **params: Unpack["Meter.ListEventSummariesParams"]
+ cls, id: str, **params: Unpack["MeterListEventSummariesParams"]
) -> ListObject["MeterEventSummary"]:
"""
Retrieve a list of billing meter event summaries.
diff --git a/stripe/billing/_meter_event.py b/stripe/billing/_meter_event.py
index 428d66604..53dcfa569 100644
--- a/stripe/billing/_meter_event.py
+++ b/stripe/billing/_meter_event.py
@@ -1,9 +1,13 @@
# -*- coding: utf-8 -*-
# File generated from our OpenAPI spec
from stripe._createable_api_resource import CreateableAPIResource
-from stripe._request_options import RequestOptions
-from typing import ClassVar, Dict, List, cast
-from typing_extensions import Literal, NotRequired, Unpack
+from typing import ClassVar, Dict, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.billing._meter_event_create_params import (
+ MeterEventCreateParams,
+ )
class MeterEvent(CreateableAPIResource["MeterEvent"]):
@@ -14,29 +18,6 @@ class MeterEvent(CreateableAPIResource["MeterEvent"]):
OBJECT_NAME: ClassVar[Literal["billing.meter_event"]] = (
"billing.meter_event"
)
-
- class CreateParams(RequestOptions):
- event_name: str
- """
- The name of the meter event. Corresponds with the `event_name` field on a meter.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- identifier: NotRequired[str]
- """
- A unique identifier for the event. If not provided, one is generated. We recommend using UUID-like identifiers. We will enforce uniqueness within a rolling period of at least 24 hours. The enforcement of uniqueness primarily addresses issues arising from accidental retries or other problems occurring within extremely brief time intervals. This approach helps prevent duplicate entries and ensures data integrity in high-frequency operations.
- """
- payload: Dict[str, str]
- """
- The payload of the event. This must contain the fields corresponding to a meter's `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and `value_settings.event_payload_key` (default is `value`). Read more about the [payload](https://docs.stripe.com/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).
- """
- timestamp: NotRequired[int]
- """
- The time of the event. Measured in seconds since the Unix epoch. Must be within the past 35 calendar days or up to 5 minutes in the future. Defaults to current timestamp if not specified.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -68,7 +49,7 @@ class CreateParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["MeterEvent.CreateParams"]
+ cls, **params: Unpack["MeterEventCreateParams"]
) -> "MeterEvent":
"""
Creates a billing meter event.
@@ -84,7 +65,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["MeterEvent.CreateParams"]
+ cls, **params: Unpack["MeterEventCreateParams"]
) -> "MeterEvent":
"""
Creates a billing meter event.
diff --git a/stripe/billing/_meter_event_adjustment.py b/stripe/billing/_meter_event_adjustment.py
index 0304e7c7f..be7a0b935 100644
--- a/stripe/billing/_meter_event_adjustment.py
+++ b/stripe/billing/_meter_event_adjustment.py
@@ -1,10 +1,14 @@
# -*- coding: utf-8 -*-
# File generated from our OpenAPI spec
from stripe._createable_api_resource import CreateableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
-from typing import ClassVar, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing import ClassVar, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.billing._meter_event_adjustment_create_params import (
+ MeterEventAdjustmentCreateParams,
+ )
class MeterEventAdjustment(CreateableAPIResource["MeterEventAdjustment"]):
@@ -22,30 +26,6 @@ class Cancel(StripeObject):
Unique identifier for the event.
"""
- class CreateParams(RequestOptions):
- cancel: NotRequired["MeterEventAdjustment.CreateParamsCancel"]
- """
- Specifies which event to cancel.
- """
- event_name: str
- """
- The name of the meter event. Corresponds with the `event_name` field on a meter.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- type: Literal["cancel"]
- """
- Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet.
- """
-
- class CreateParamsCancel(TypedDict):
- identifier: NotRequired[str]
- """
- Unique identifier for the event. You can only cancel events within 24 hours of Stripe receiving them.
- """
-
cancel: Optional[Cancel]
"""
Specifies which event to cancel.
@@ -73,7 +53,7 @@ class CreateParamsCancel(TypedDict):
@classmethod
def create(
- cls, **params: Unpack["MeterEventAdjustment.CreateParams"]
+ cls, **params: Unpack["MeterEventAdjustmentCreateParams"]
) -> "MeterEventAdjustment":
"""
Creates a billing meter event adjustment.
@@ -89,7 +69,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["MeterEventAdjustment.CreateParams"]
+ cls, **params: Unpack["MeterEventAdjustmentCreateParams"]
) -> "MeterEventAdjustment":
"""
Creates a billing meter event adjustment.
diff --git a/stripe/billing/_meter_event_adjustment_service.py b/stripe/billing/_meter_event_adjustment_service.py
index c5f8cf7be..342d2bb50 100644
--- a/stripe/billing/_meter_event_adjustment_service.py
+++ b/stripe/billing/_meter_event_adjustment_service.py
@@ -3,38 +3,19 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe.billing._meter_event_adjustment import MeterEventAdjustment
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.billing._meter_event_adjustment_create_params import (
+ MeterEventAdjustmentCreateParams,
+ )
-class MeterEventAdjustmentService(StripeService):
- class CreateParams(TypedDict):
- cancel: NotRequired["MeterEventAdjustmentService.CreateParamsCancel"]
- """
- Specifies which event to cancel.
- """
- event_name: str
- """
- The name of the meter event. Corresponds with the `event_name` field on a meter.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- type: Literal["cancel"]
- """
- Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet.
- """
-
- class CreateParamsCancel(TypedDict):
- identifier: NotRequired[str]
- """
- Unique identifier for the event. You can only cancel events within 24 hours of Stripe receiving them.
- """
+class MeterEventAdjustmentService(StripeService):
def create(
self,
- params: "MeterEventAdjustmentService.CreateParams",
+ params: "MeterEventAdjustmentCreateParams",
options: Optional[RequestOptions] = None,
) -> MeterEventAdjustment:
"""
@@ -53,7 +34,7 @@ def create(
async def create_async(
self,
- params: "MeterEventAdjustmentService.CreateParams",
+ params: "MeterEventAdjustmentCreateParams",
options: Optional[RequestOptions] = None,
) -> MeterEventAdjustment:
"""
diff --git a/stripe/billing/_meter_event_service.py b/stripe/billing/_meter_event_service.py
index 2e43f3b71..208740055 100644
--- a/stripe/billing/_meter_event_service.py
+++ b/stripe/billing/_meter_event_service.py
@@ -3,36 +3,19 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe.billing._meter_event import MeterEvent
-from typing import Dict, List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.billing._meter_event_create_params import (
+ MeterEventCreateParams,
+ )
-class MeterEventService(StripeService):
- class CreateParams(TypedDict):
- event_name: str
- """
- The name of the meter event. Corresponds with the `event_name` field on a meter.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- identifier: NotRequired[str]
- """
- A unique identifier for the event. If not provided, one is generated. We recommend using UUID-like identifiers. We will enforce uniqueness within a rolling period of at least 24 hours. The enforcement of uniqueness primarily addresses issues arising from accidental retries or other problems occurring within extremely brief time intervals. This approach helps prevent duplicate entries and ensures data integrity in high-frequency operations.
- """
- payload: Dict[str, str]
- """
- The payload of the event. This must contain the fields corresponding to a meter's `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and `value_settings.event_payload_key` (default is `value`). Read more about the [payload](https://docs.stripe.com/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).
- """
- timestamp: NotRequired[int]
- """
- The time of the event. Measured in seconds since the Unix epoch. Must be within the past 35 calendar days or up to 5 minutes in the future. Defaults to current timestamp if not specified.
- """
+class MeterEventService(StripeService):
def create(
self,
- params: "MeterEventService.CreateParams",
+ params: "MeterEventCreateParams",
options: Optional[RequestOptions] = None,
) -> MeterEvent:
"""
@@ -51,7 +34,7 @@ def create(
async def create_async(
self,
- params: "MeterEventService.CreateParams",
+ params: "MeterEventCreateParams",
options: Optional[RequestOptions] = None,
) -> MeterEvent:
"""
diff --git a/stripe/billing/_meter_event_summary_service.py b/stripe/billing/_meter_event_summary_service.py
index a917a37c5..a603151c3 100644
--- a/stripe/billing/_meter_event_summary_service.py
+++ b/stripe/billing/_meter_event_summary_service.py
@@ -5,49 +5,20 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.billing._meter_event_summary import MeterEventSummary
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.billing._meter_event_summary_list_params import (
+ MeterEventSummaryListParams,
+ )
-class MeterEventSummaryService(StripeService):
- class ListParams(TypedDict):
- customer: str
- """
- The customer for which to fetch event summaries.
- """
- end_time: int
- """
- The timestamp from when to stop aggregating meter events (exclusive). Must be aligned with minute boundaries.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- start_time: int
- """
- The timestamp from when to start aggregating meter events (inclusive). Must be aligned with minute boundaries.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- value_grouping_window: NotRequired[Literal["day", "hour"]]
- """
- Specifies what granularity to use when generating event summaries. If not specified, a single event summary would be returned for the specified time range. For hourly granularity, start and end times must align with hour boundaries (e.g., 00:00, 01:00, ..., 23:00). For daily granularity, start and end times must align with UTC day boundaries (00:00 UTC).
- """
+class MeterEventSummaryService(StripeService):
def list(
self,
id: str,
- params: "MeterEventSummaryService.ListParams",
+ params: "MeterEventSummaryListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[MeterEventSummary]:
"""
@@ -69,7 +40,7 @@ def list(
async def list_async(
self,
id: str,
- params: "MeterEventSummaryService.ListParams",
+ params: "MeterEventSummaryListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[MeterEventSummary]:
"""
diff --git a/stripe/billing/_meter_service.py b/stripe/billing/_meter_service.py
index 53df2fb41..73dfbe97b 100644
--- a/stripe/billing/_meter_service.py
+++ b/stripe/billing/_meter_service.py
@@ -8,8 +8,22 @@
from stripe.billing._meter_event_summary_service import (
MeterEventSummaryService,
)
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.billing._meter_create_params import MeterCreateParams
+ from stripe.params.billing._meter_deactivate_params import (
+ MeterDeactivateParams,
+ )
+ from stripe.params.billing._meter_list_params import MeterListParams
+ from stripe.params.billing._meter_reactivate_params import (
+ MeterReactivateParams,
+ )
+ from stripe.params.billing._meter_retrieve_params import (
+ MeterRetrieveParams,
+ )
+ from stripe.params.billing._meter_update_params import MeterUpdateParams
class MeterService(StripeService):
@@ -17,113 +31,9 @@ def __init__(self, requestor):
super().__init__(requestor)
self.event_summaries = MeterEventSummaryService(self._requestor)
- class CreateParams(TypedDict):
- customer_mapping: NotRequired[
- "MeterService.CreateParamsCustomerMapping"
- ]
- """
- Fields that specify how to map a meter event to a customer.
- """
- default_aggregation: "MeterService.CreateParamsDefaultAggregation"
- """
- The default settings to aggregate a meter's events with.
- """
- display_name: str
- """
- The meter's name. Not visible to the customer.
- """
- event_name: str
- """
- The name of the meter event to record usage for. Corresponds with the `event_name` field on meter events.
- """
- event_time_window: NotRequired[Literal["day", "hour"]]
- """
- The time window which meter events have been pre-aggregated for, if any.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- value_settings: NotRequired["MeterService.CreateParamsValueSettings"]
- """
- Fields that specify how to calculate a meter event's value.
- """
-
- class CreateParamsCustomerMapping(TypedDict):
- event_payload_key: str
- """
- The key in the meter event payload to use for mapping the event to a customer.
- """
- type: Literal["by_id"]
- """
- The method for mapping a meter event to a customer. Must be `by_id`.
- """
-
- class CreateParamsDefaultAggregation(TypedDict):
- formula: Literal["count", "last", "sum"]
- """
- Specifies how events are aggregated. Allowed values are `count` to count the number of events, `sum` to sum each event's value and `last` to take the last event's value in the window.
- """
-
- class CreateParamsValueSettings(TypedDict):
- event_payload_key: str
- """
- The key in the usage event payload to use as the value for this meter. For example, if the event payload contains usage on a `bytes_used` field, then set the event_payload_key to "bytes_used".
- """
-
- class DeactivateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["active", "inactive"]]
- """
- Filter results to only include meters with the given status.
- """
-
- class ReactivateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- display_name: NotRequired[str]
- """
- The meter's name. Not visible to the customer.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
def list(
self,
- params: Optional["MeterService.ListParams"] = None,
+ params: Optional["MeterListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Meter]:
"""
@@ -142,7 +52,7 @@ def list(
async def list_async(
self,
- params: Optional["MeterService.ListParams"] = None,
+ params: Optional["MeterListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Meter]:
"""
@@ -161,7 +71,7 @@ async def list_async(
def create(
self,
- params: "MeterService.CreateParams",
+ params: "MeterCreateParams",
options: Optional[RequestOptions] = None,
) -> Meter:
"""
@@ -180,7 +90,7 @@ def create(
async def create_async(
self,
- params: "MeterService.CreateParams",
+ params: "MeterCreateParams",
options: Optional[RequestOptions] = None,
) -> Meter:
"""
@@ -200,7 +110,7 @@ async def create_async(
def retrieve(
self,
id: str,
- params: Optional["MeterService.RetrieveParams"] = None,
+ params: Optional["MeterRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Meter:
"""
@@ -220,7 +130,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["MeterService.RetrieveParams"] = None,
+ params: Optional["MeterRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Meter:
"""
@@ -240,7 +150,7 @@ async def retrieve_async(
def update(
self,
id: str,
- params: Optional["MeterService.UpdateParams"] = None,
+ params: Optional["MeterUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Meter:
"""
@@ -260,7 +170,7 @@ def update(
async def update_async(
self,
id: str,
- params: Optional["MeterService.UpdateParams"] = None,
+ params: Optional["MeterUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Meter:
"""
@@ -280,7 +190,7 @@ async def update_async(
def deactivate(
self,
id: str,
- params: Optional["MeterService.DeactivateParams"] = None,
+ params: Optional["MeterDeactivateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Meter:
"""
@@ -302,7 +212,7 @@ def deactivate(
async def deactivate_async(
self,
id: str,
- params: Optional["MeterService.DeactivateParams"] = None,
+ params: Optional["MeterDeactivateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Meter:
"""
@@ -324,7 +234,7 @@ async def deactivate_async(
def reactivate(
self,
id: str,
- params: Optional["MeterService.ReactivateParams"] = None,
+ params: Optional["MeterReactivateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Meter:
"""
@@ -346,7 +256,7 @@ def reactivate(
async def reactivate_async(
self,
id: str,
- params: Optional["MeterService.ReactivateParams"] = None,
+ params: Optional["MeterReactivateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Meter:
"""
diff --git a/stripe/billing_portal/_configuration.py b/stripe/billing_portal/_configuration.py
index a21a3c5d2..822a3acd7 100644
--- a/stripe/billing_portal/_configuration.py
+++ b/stripe/billing_portal/_configuration.py
@@ -4,21 +4,26 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import sanitize_id
-from typing import ClassVar, Dict, List, Optional, Union, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Dict, List, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._application import Application
+ from stripe.params.billing_portal._configuration_create_params import (
+ ConfigurationCreateParams,
+ )
+ from stripe.params.billing_portal._configuration_list_params import (
+ ConfigurationListParams,
+ )
+ from stripe.params.billing_portal._configuration_modify_params import (
+ ConfigurationModifyParams,
+ )
+ from stripe.params.billing_portal._configuration_retrieve_params import (
+ ConfigurationRetrieveParams,
+ )
class Configuration(
@@ -213,510 +218,6 @@ class LoginPage(StripeObject):
A shareable URL to the hosted portal login page. Your customers will be able to log in with their [email](https://stripe.com/docs/api/customers/object#customer_object-email) and receive a link to their customer portal.
"""
- class CreateParams(RequestOptions):
- business_profile: NotRequired[
- "Configuration.CreateParamsBusinessProfile"
- ]
- """
- The business information shown to customers in the portal.
- """
- default_return_url: NotRequired["Literal['']|str"]
- """
- The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- features: "Configuration.CreateParamsFeatures"
- """
- Information about the features available in the portal.
- """
- login_page: NotRequired["Configuration.CreateParamsLoginPage"]
- """
- The hosted login page for this configuration. Learn more about the portal login page in our [integration docs](https://stripe.com/docs/billing/subscriptions/integrating-customer-portal#share).
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired["Literal['']|str"]
- """
- The name of the configuration.
- """
-
- class CreateParamsBusinessProfile(TypedDict):
- headline: NotRequired["Literal['']|str"]
- """
- The messaging shown to customers in the portal.
- """
- privacy_policy_url: NotRequired[str]
- """
- A link to the business's publicly available privacy policy.
- """
- terms_of_service_url: NotRequired[str]
- """
- A link to the business's publicly available terms of service.
- """
-
- class CreateParamsFeatures(TypedDict):
- customer_update: NotRequired[
- "Configuration.CreateParamsFeaturesCustomerUpdate"
- ]
- """
- Information about updating the customer details in the portal.
- """
- invoice_history: NotRequired[
- "Configuration.CreateParamsFeaturesInvoiceHistory"
- ]
- """
- Information about showing the billing history in the portal.
- """
- payment_method_update: NotRequired[
- "Configuration.CreateParamsFeaturesPaymentMethodUpdate"
- ]
- """
- Information about updating payment methods in the portal.
- """
- subscription_cancel: NotRequired[
- "Configuration.CreateParamsFeaturesSubscriptionCancel"
- ]
- """
- Information about canceling subscriptions in the portal.
- """
- subscription_update: NotRequired[
- "Configuration.CreateParamsFeaturesSubscriptionUpdate"
- ]
- """
- Information about updating subscriptions in the portal.
- """
-
- class CreateParamsFeaturesCustomerUpdate(TypedDict):
- allowed_updates: NotRequired[
- "Literal['']|List[Literal['address', 'email', 'name', 'phone', 'shipping', 'tax_id']]"
- ]
- """
- The types of customer updates that are supported. When empty, customers are not updateable.
- """
- enabled: bool
- """
- Whether the feature is enabled.
- """
-
- class CreateParamsFeaturesInvoiceHistory(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled.
- """
-
- class CreateParamsFeaturesPaymentMethodUpdate(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled.
- """
-
- class CreateParamsFeaturesSubscriptionCancel(TypedDict):
- cancellation_reason: NotRequired[
- "Configuration.CreateParamsFeaturesSubscriptionCancelCancellationReason"
- ]
- """
- Whether the cancellation reasons will be collected in the portal and which options are exposed to the customer
- """
- enabled: bool
- """
- Whether the feature is enabled.
- """
- mode: NotRequired[Literal["at_period_end", "immediately"]]
- """
- Whether to cancel subscriptions immediately or at the end of the billing period.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Whether to create prorations when canceling subscriptions. Possible values are `none` and `create_prorations`, which is only compatible with `mode=immediately`. Passing `always_invoice` will result in an error. No prorations are generated when canceling a subscription at the end of its natural billing period.
- """
-
- class CreateParamsFeaturesSubscriptionCancelCancellationReason(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled.
- """
- options: Union[
- Literal[""],
- List[
- Literal[
- "customer_service",
- "low_quality",
- "missing_features",
- "other",
- "switched_service",
- "too_complex",
- "too_expensive",
- "unused",
- ]
- ],
- ]
- """
- Which cancellation reasons will be given as options to the customer.
- """
-
- class CreateParamsFeaturesSubscriptionUpdate(TypedDict):
- default_allowed_updates: NotRequired[
- "Literal['']|List[Literal['price', 'promotion_code', 'quantity']]"
- ]
- """
- The types of subscription updates that are supported. When empty, subscriptions are not updateable.
- """
- enabled: bool
- """
- Whether the feature is enabled.
- """
- products: NotRequired[
- "Literal['']|List[Configuration.CreateParamsFeaturesSubscriptionUpdateProduct]"
- ]
- """
- The list of up to 10 products that support subscription updates.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle prorations resulting from subscription updates. Valid values are `none`, `create_prorations`, and `always_invoice`.
- """
- schedule_at_period_end: NotRequired[
- "Configuration.CreateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEnd"
- ]
- """
- Setting to control when an update should be scheduled at the end of the period instead of applying immediately.
- """
- trial_update_behavior: NotRequired[
- Literal["continue_trial", "end_trial"]
- ]
- """
- The behavior when updating a subscription that is trialing.
- """
-
- class CreateParamsFeaturesSubscriptionUpdateProduct(TypedDict):
- adjustable_quantity: NotRequired[
- "Configuration.CreateParamsFeaturesSubscriptionUpdateProductAdjustableQuantity"
- ]
- """
- Control whether the quantity of the product can be adjusted.
- """
- prices: List[str]
- """
- The list of price IDs for the product that a subscription can be updated to.
- """
- product: str
- """
- The product id.
- """
-
- class CreateParamsFeaturesSubscriptionUpdateProductAdjustableQuantity(
- TypedDict,
- ):
- enabled: bool
- """
- Set to true if the quantity can be adjusted to any non-negative integer.
- """
- maximum: NotRequired[int]
- """
- The maximum quantity that can be set for the product.
- """
- minimum: NotRequired[int]
- """
- The minimum quantity that can be set for the product.
- """
-
- class CreateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEnd(TypedDict):
- conditions: NotRequired[
- List[
- "Configuration.CreateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEndCondition"
- ]
- ]
- """
- List of conditions. When any condition is true, the update will be scheduled at the end of the current period.
- """
-
- class CreateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEndCondition(
- TypedDict,
- ):
- type: Literal["decreasing_item_amount", "shortening_interval"]
- """
- The type of condition.
- """
-
- class CreateParamsLoginPage(TypedDict):
- enabled: bool
- """
- Set to `true` to generate a shareable URL [`login_page.url`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-login_page-url) that will take your customers to a hosted login page for the customer portal.
- """
-
- class ListParams(RequestOptions):
- active: NotRequired[bool]
- """
- Only return configurations that are active or inactive (e.g., pass `true` to only list active configurations).
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- is_default: NotRequired[bool]
- """
- Only return the default or non-default configurations (e.g., pass `true` to only list the default configuration).
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ModifyParams(RequestOptions):
- active: NotRequired[bool]
- """
- Whether the configuration is active and can be used to create portal sessions.
- """
- business_profile: NotRequired[
- "Configuration.ModifyParamsBusinessProfile"
- ]
- """
- The business information shown to customers in the portal.
- """
- default_return_url: NotRequired["Literal['']|str"]
- """
- The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- features: NotRequired["Configuration.ModifyParamsFeatures"]
- """
- Information about the features available in the portal.
- """
- login_page: NotRequired["Configuration.ModifyParamsLoginPage"]
- """
- The hosted login page for this configuration. Learn more about the portal login page in our [integration docs](https://stripe.com/docs/billing/subscriptions/integrating-customer-portal#share).
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired["Literal['']|str"]
- """
- The name of the configuration.
- """
-
- class ModifyParamsBusinessProfile(TypedDict):
- headline: NotRequired["Literal['']|str"]
- """
- The messaging shown to customers in the portal.
- """
- privacy_policy_url: NotRequired["Literal['']|str"]
- """
- A link to the business's publicly available privacy policy.
- """
- terms_of_service_url: NotRequired["Literal['']|str"]
- """
- A link to the business's publicly available terms of service.
- """
-
- class ModifyParamsFeatures(TypedDict):
- customer_update: NotRequired[
- "Configuration.ModifyParamsFeaturesCustomerUpdate"
- ]
- """
- Information about updating the customer details in the portal.
- """
- invoice_history: NotRequired[
- "Configuration.ModifyParamsFeaturesInvoiceHistory"
- ]
- """
- Information about showing the billing history in the portal.
- """
- payment_method_update: NotRequired[
- "Configuration.ModifyParamsFeaturesPaymentMethodUpdate"
- ]
- """
- Information about updating payment methods in the portal.
- """
- subscription_cancel: NotRequired[
- "Configuration.ModifyParamsFeaturesSubscriptionCancel"
- ]
- """
- Information about canceling subscriptions in the portal.
- """
- subscription_update: NotRequired[
- "Configuration.ModifyParamsFeaturesSubscriptionUpdate"
- ]
- """
- Information about updating subscriptions in the portal.
- """
-
- class ModifyParamsFeaturesCustomerUpdate(TypedDict):
- allowed_updates: NotRequired[
- "Literal['']|List[Literal['address', 'email', 'name', 'phone', 'shipping', 'tax_id']]"
- ]
- """
- The types of customer updates that are supported. When empty, customers are not updateable.
- """
- enabled: NotRequired[bool]
- """
- Whether the feature is enabled.
- """
-
- class ModifyParamsFeaturesInvoiceHistory(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled.
- """
-
- class ModifyParamsFeaturesPaymentMethodUpdate(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled.
- """
-
- class ModifyParamsFeaturesSubscriptionCancel(TypedDict):
- cancellation_reason: NotRequired[
- "Configuration.ModifyParamsFeaturesSubscriptionCancelCancellationReason"
- ]
- """
- Whether the cancellation reasons will be collected in the portal and which options are exposed to the customer
- """
- enabled: NotRequired[bool]
- """
- Whether the feature is enabled.
- """
- mode: NotRequired[Literal["at_period_end", "immediately"]]
- """
- Whether to cancel subscriptions immediately or at the end of the billing period.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Whether to create prorations when canceling subscriptions. Possible values are `none` and `create_prorations`, which is only compatible with `mode=immediately`. Passing `always_invoice` will result in an error. No prorations are generated when canceling a subscription at the end of its natural billing period.
- """
-
- class ModifyParamsFeaturesSubscriptionCancelCancellationReason(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled.
- """
- options: NotRequired[
- "Literal['']|List[Literal['customer_service', 'low_quality', 'missing_features', 'other', 'switched_service', 'too_complex', 'too_expensive', 'unused']]"
- ]
- """
- Which cancellation reasons will be given as options to the customer.
- """
-
- class ModifyParamsFeaturesSubscriptionUpdate(TypedDict):
- default_allowed_updates: NotRequired[
- "Literal['']|List[Literal['price', 'promotion_code', 'quantity']]"
- ]
- """
- The types of subscription updates that are supported. When empty, subscriptions are not updateable.
- """
- enabled: NotRequired[bool]
- """
- Whether the feature is enabled.
- """
- products: NotRequired[
- "Literal['']|List[Configuration.ModifyParamsFeaturesSubscriptionUpdateProduct]"
- ]
- """
- The list of up to 10 products that support subscription updates.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle prorations resulting from subscription updates. Valid values are `none`, `create_prorations`, and `always_invoice`.
- """
- schedule_at_period_end: NotRequired[
- "Configuration.ModifyParamsFeaturesSubscriptionUpdateScheduleAtPeriodEnd"
- ]
- """
- Setting to control when an update should be scheduled at the end of the period instead of applying immediately.
- """
- trial_update_behavior: NotRequired[
- Literal["continue_trial", "end_trial"]
- ]
- """
- The behavior when updating a subscription that is trialing.
- """
-
- class ModifyParamsFeaturesSubscriptionUpdateProduct(TypedDict):
- adjustable_quantity: NotRequired[
- "Configuration.ModifyParamsFeaturesSubscriptionUpdateProductAdjustableQuantity"
- ]
- """
- Control whether the quantity of the product can be adjusted.
- """
- prices: List[str]
- """
- The list of price IDs for the product that a subscription can be updated to.
- """
- product: str
- """
- The product id.
- """
-
- class ModifyParamsFeaturesSubscriptionUpdateProductAdjustableQuantity(
- TypedDict,
- ):
- enabled: bool
- """
- Set to true if the quantity can be adjusted to any non-negative integer.
- """
- maximum: NotRequired[int]
- """
- The maximum quantity that can be set for the product.
- """
- minimum: NotRequired[int]
- """
- The minimum quantity that can be set for the product.
- """
-
- class ModifyParamsFeaturesSubscriptionUpdateScheduleAtPeriodEnd(TypedDict):
- conditions: NotRequired[
- "Literal['']|List[Configuration.ModifyParamsFeaturesSubscriptionUpdateScheduleAtPeriodEndCondition]"
- ]
- """
- List of conditions. When any condition is true, the update will be scheduled at the end of the current period.
- """
-
- class ModifyParamsFeaturesSubscriptionUpdateScheduleAtPeriodEndCondition(
- TypedDict,
- ):
- type: Literal["decreasing_item_amount", "shortening_interval"]
- """
- The type of condition.
- """
-
- class ModifyParamsLoginPage(TypedDict):
- enabled: bool
- """
- Set to `true` to generate a shareable URL [`login_page.url`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-login_page-url) that will take your customers to a hosted login page for the customer portal.
-
- Set to `false` to deactivate the `login_page.url`.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
active: bool
"""
Whether the configuration is active and can be used to create portal sessions.
@@ -767,7 +268,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["Configuration.CreateParams"]
+ cls, **params: Unpack["ConfigurationCreateParams"]
) -> "Configuration":
"""
Creates a configuration that describes the functionality and behavior of a PortalSession
@@ -783,7 +284,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["Configuration.CreateParams"]
+ cls, **params: Unpack["ConfigurationCreateParams"]
) -> "Configuration":
"""
Creates a configuration that describes the functionality and behavior of a PortalSession
@@ -799,7 +300,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["Configuration.ListParams"]
+ cls, **params: Unpack["ConfigurationListParams"]
) -> ListObject["Configuration"]:
"""
Returns a list of configurations that describe the functionality of the customer portal.
@@ -819,7 +320,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Configuration.ListParams"]
+ cls, **params: Unpack["ConfigurationListParams"]
) -> ListObject["Configuration"]:
"""
Returns a list of configurations that describe the functionality of the customer portal.
@@ -839,7 +340,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Configuration.ModifyParams"]
+ cls, id: str, **params: Unpack["ConfigurationModifyParams"]
) -> "Configuration":
"""
Updates a configuration that describes the functionality of the customer portal.
@@ -856,7 +357,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Configuration.ModifyParams"]
+ cls, id: str, **params: Unpack["ConfigurationModifyParams"]
) -> "Configuration":
"""
Updates a configuration that describes the functionality of the customer portal.
@@ -873,7 +374,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Configuration.RetrieveParams"]
+ cls, id: str, **params: Unpack["ConfigurationRetrieveParams"]
) -> "Configuration":
"""
Retrieves a configuration that describes the functionality of the customer portal.
@@ -884,7 +385,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Configuration.RetrieveParams"]
+ cls, id: str, **params: Unpack["ConfigurationRetrieveParams"]
) -> "Configuration":
"""
Retrieves a configuration that describes the functionality of the customer portal.
diff --git a/stripe/billing_portal/_configuration_service.py b/stripe/billing_portal/_configuration_service.py
index b2836181a..bb48cc8e0 100644
--- a/stripe/billing_portal/_configuration_service.py
+++ b/stripe/billing_portal/_configuration_service.py
@@ -5,518 +5,28 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.billing_portal._configuration import Configuration
-from typing import Dict, List, Optional, Union, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.billing_portal._configuration_create_params import (
+ ConfigurationCreateParams,
+ )
+ from stripe.params.billing_portal._configuration_list_params import (
+ ConfigurationListParams,
+ )
+ from stripe.params.billing_portal._configuration_retrieve_params import (
+ ConfigurationRetrieveParams,
+ )
+ from stripe.params.billing_portal._configuration_update_params import (
+ ConfigurationUpdateParams,
+ )
class ConfigurationService(StripeService):
- class CreateParams(TypedDict):
- business_profile: NotRequired[
- "ConfigurationService.CreateParamsBusinessProfile"
- ]
- """
- The business information shown to customers in the portal.
- """
- default_return_url: NotRequired["Literal['']|str"]
- """
- The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- features: "ConfigurationService.CreateParamsFeatures"
- """
- Information about the features available in the portal.
- """
- login_page: NotRequired["ConfigurationService.CreateParamsLoginPage"]
- """
- The hosted login page for this configuration. Learn more about the portal login page in our [integration docs](https://stripe.com/docs/billing/subscriptions/integrating-customer-portal#share).
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired["Literal['']|str"]
- """
- The name of the configuration.
- """
-
- class CreateParamsBusinessProfile(TypedDict):
- headline: NotRequired["Literal['']|str"]
- """
- The messaging shown to customers in the portal.
- """
- privacy_policy_url: NotRequired[str]
- """
- A link to the business's publicly available privacy policy.
- """
- terms_of_service_url: NotRequired[str]
- """
- A link to the business's publicly available terms of service.
- """
-
- class CreateParamsFeatures(TypedDict):
- customer_update: NotRequired[
- "ConfigurationService.CreateParamsFeaturesCustomerUpdate"
- ]
- """
- Information about updating the customer details in the portal.
- """
- invoice_history: NotRequired[
- "ConfigurationService.CreateParamsFeaturesInvoiceHistory"
- ]
- """
- Information about showing the billing history in the portal.
- """
- payment_method_update: NotRequired[
- "ConfigurationService.CreateParamsFeaturesPaymentMethodUpdate"
- ]
- """
- Information about updating payment methods in the portal.
- """
- subscription_cancel: NotRequired[
- "ConfigurationService.CreateParamsFeaturesSubscriptionCancel"
- ]
- """
- Information about canceling subscriptions in the portal.
- """
- subscription_update: NotRequired[
- "ConfigurationService.CreateParamsFeaturesSubscriptionUpdate"
- ]
- """
- Information about updating subscriptions in the portal.
- """
-
- class CreateParamsFeaturesCustomerUpdate(TypedDict):
- allowed_updates: NotRequired[
- "Literal['']|List[Literal['address', 'email', 'name', 'phone', 'shipping', 'tax_id']]"
- ]
- """
- The types of customer updates that are supported. When empty, customers are not updateable.
- """
- enabled: bool
- """
- Whether the feature is enabled.
- """
-
- class CreateParamsFeaturesInvoiceHistory(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled.
- """
-
- class CreateParamsFeaturesPaymentMethodUpdate(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled.
- """
-
- class CreateParamsFeaturesSubscriptionCancel(TypedDict):
- cancellation_reason: NotRequired[
- "ConfigurationService.CreateParamsFeaturesSubscriptionCancelCancellationReason"
- ]
- """
- Whether the cancellation reasons will be collected in the portal and which options are exposed to the customer
- """
- enabled: bool
- """
- Whether the feature is enabled.
- """
- mode: NotRequired[Literal["at_period_end", "immediately"]]
- """
- Whether to cancel subscriptions immediately or at the end of the billing period.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Whether to create prorations when canceling subscriptions. Possible values are `none` and `create_prorations`, which is only compatible with `mode=immediately`. Passing `always_invoice` will result in an error. No prorations are generated when canceling a subscription at the end of its natural billing period.
- """
-
- class CreateParamsFeaturesSubscriptionCancelCancellationReason(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled.
- """
- options: Union[
- Literal[""],
- List[
- Literal[
- "customer_service",
- "low_quality",
- "missing_features",
- "other",
- "switched_service",
- "too_complex",
- "too_expensive",
- "unused",
- ]
- ],
- ]
- """
- Which cancellation reasons will be given as options to the customer.
- """
-
- class CreateParamsFeaturesSubscriptionUpdate(TypedDict):
- default_allowed_updates: NotRequired[
- "Literal['']|List[Literal['price', 'promotion_code', 'quantity']]"
- ]
- """
- The types of subscription updates that are supported. When empty, subscriptions are not updateable.
- """
- enabled: bool
- """
- Whether the feature is enabled.
- """
- products: NotRequired[
- "Literal['']|List[ConfigurationService.CreateParamsFeaturesSubscriptionUpdateProduct]"
- ]
- """
- The list of up to 10 products that support subscription updates.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle prorations resulting from subscription updates. Valid values are `none`, `create_prorations`, and `always_invoice`.
- """
- schedule_at_period_end: NotRequired[
- "ConfigurationService.CreateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEnd"
- ]
- """
- Setting to control when an update should be scheduled at the end of the period instead of applying immediately.
- """
- trial_update_behavior: NotRequired[
- Literal["continue_trial", "end_trial"]
- ]
- """
- The behavior when updating a subscription that is trialing.
- """
-
- class CreateParamsFeaturesSubscriptionUpdateProduct(TypedDict):
- adjustable_quantity: NotRequired[
- "ConfigurationService.CreateParamsFeaturesSubscriptionUpdateProductAdjustableQuantity"
- ]
- """
- Control whether the quantity of the product can be adjusted.
- """
- prices: List[str]
- """
- The list of price IDs for the product that a subscription can be updated to.
- """
- product: str
- """
- The product id.
- """
-
- class CreateParamsFeaturesSubscriptionUpdateProductAdjustableQuantity(
- TypedDict,
- ):
- enabled: bool
- """
- Set to true if the quantity can be adjusted to any non-negative integer.
- """
- maximum: NotRequired[int]
- """
- The maximum quantity that can be set for the product.
- """
- minimum: NotRequired[int]
- """
- The minimum quantity that can be set for the product.
- """
-
- class CreateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEnd(TypedDict):
- conditions: NotRequired[
- List[
- "ConfigurationService.CreateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEndCondition"
- ]
- ]
- """
- List of conditions. When any condition is true, the update will be scheduled at the end of the current period.
- """
-
- class CreateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEndCondition(
- TypedDict,
- ):
- type: Literal["decreasing_item_amount", "shortening_interval"]
- """
- The type of condition.
- """
-
- class CreateParamsLoginPage(TypedDict):
- enabled: bool
- """
- Set to `true` to generate a shareable URL [`login_page.url`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-login_page-url) that will take your customers to a hosted login page for the customer portal.
- """
-
- class ListParams(TypedDict):
- active: NotRequired[bool]
- """
- Only return configurations that are active or inactive (e.g., pass `true` to only list active configurations).
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- is_default: NotRequired[bool]
- """
- Only return the default or non-default configurations (e.g., pass `true` to only list the default configuration).
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- active: NotRequired[bool]
- """
- Whether the configuration is active and can be used to create portal sessions.
- """
- business_profile: NotRequired[
- "ConfigurationService.UpdateParamsBusinessProfile"
- ]
- """
- The business information shown to customers in the portal.
- """
- default_return_url: NotRequired["Literal['']|str"]
- """
- The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- features: NotRequired["ConfigurationService.UpdateParamsFeatures"]
- """
- Information about the features available in the portal.
- """
- login_page: NotRequired["ConfigurationService.UpdateParamsLoginPage"]
- """
- The hosted login page for this configuration. Learn more about the portal login page in our [integration docs](https://stripe.com/docs/billing/subscriptions/integrating-customer-portal#share).
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired["Literal['']|str"]
- """
- The name of the configuration.
- """
-
- class UpdateParamsBusinessProfile(TypedDict):
- headline: NotRequired["Literal['']|str"]
- """
- The messaging shown to customers in the portal.
- """
- privacy_policy_url: NotRequired["Literal['']|str"]
- """
- A link to the business's publicly available privacy policy.
- """
- terms_of_service_url: NotRequired["Literal['']|str"]
- """
- A link to the business's publicly available terms of service.
- """
-
- class UpdateParamsFeatures(TypedDict):
- customer_update: NotRequired[
- "ConfigurationService.UpdateParamsFeaturesCustomerUpdate"
- ]
- """
- Information about updating the customer details in the portal.
- """
- invoice_history: NotRequired[
- "ConfigurationService.UpdateParamsFeaturesInvoiceHistory"
- ]
- """
- Information about showing the billing history in the portal.
- """
- payment_method_update: NotRequired[
- "ConfigurationService.UpdateParamsFeaturesPaymentMethodUpdate"
- ]
- """
- Information about updating payment methods in the portal.
- """
- subscription_cancel: NotRequired[
- "ConfigurationService.UpdateParamsFeaturesSubscriptionCancel"
- ]
- """
- Information about canceling subscriptions in the portal.
- """
- subscription_update: NotRequired[
- "ConfigurationService.UpdateParamsFeaturesSubscriptionUpdate"
- ]
- """
- Information about updating subscriptions in the portal.
- """
-
- class UpdateParamsFeaturesCustomerUpdate(TypedDict):
- allowed_updates: NotRequired[
- "Literal['']|List[Literal['address', 'email', 'name', 'phone', 'shipping', 'tax_id']]"
- ]
- """
- The types of customer updates that are supported. When empty, customers are not updateable.
- """
- enabled: NotRequired[bool]
- """
- Whether the feature is enabled.
- """
-
- class UpdateParamsFeaturesInvoiceHistory(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled.
- """
-
- class UpdateParamsFeaturesPaymentMethodUpdate(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled.
- """
-
- class UpdateParamsFeaturesSubscriptionCancel(TypedDict):
- cancellation_reason: NotRequired[
- "ConfigurationService.UpdateParamsFeaturesSubscriptionCancelCancellationReason"
- ]
- """
- Whether the cancellation reasons will be collected in the portal and which options are exposed to the customer
- """
- enabled: NotRequired[bool]
- """
- Whether the feature is enabled.
- """
- mode: NotRequired[Literal["at_period_end", "immediately"]]
- """
- Whether to cancel subscriptions immediately or at the end of the billing period.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Whether to create prorations when canceling subscriptions. Possible values are `none` and `create_prorations`, which is only compatible with `mode=immediately`. Passing `always_invoice` will result in an error. No prorations are generated when canceling a subscription at the end of its natural billing period.
- """
-
- class UpdateParamsFeaturesSubscriptionCancelCancellationReason(TypedDict):
- enabled: bool
- """
- Whether the feature is enabled.
- """
- options: NotRequired[
- "Literal['']|List[Literal['customer_service', 'low_quality', 'missing_features', 'other', 'switched_service', 'too_complex', 'too_expensive', 'unused']]"
- ]
- """
- Which cancellation reasons will be given as options to the customer.
- """
-
- class UpdateParamsFeaturesSubscriptionUpdate(TypedDict):
- default_allowed_updates: NotRequired[
- "Literal['']|List[Literal['price', 'promotion_code', 'quantity']]"
- ]
- """
- The types of subscription updates that are supported. When empty, subscriptions are not updateable.
- """
- enabled: NotRequired[bool]
- """
- Whether the feature is enabled.
- """
- products: NotRequired[
- "Literal['']|List[ConfigurationService.UpdateParamsFeaturesSubscriptionUpdateProduct]"
- ]
- """
- The list of up to 10 products that support subscription updates.
- """
- proration_behavior: NotRequired[
- Literal["always_invoice", "create_prorations", "none"]
- ]
- """
- Determines how to handle prorations resulting from subscription updates. Valid values are `none`, `create_prorations`, and `always_invoice`.
- """
- schedule_at_period_end: NotRequired[
- "ConfigurationService.UpdateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEnd"
- ]
- """
- Setting to control when an update should be scheduled at the end of the period instead of applying immediately.
- """
- trial_update_behavior: NotRequired[
- Literal["continue_trial", "end_trial"]
- ]
- """
- The behavior when updating a subscription that is trialing.
- """
-
- class UpdateParamsFeaturesSubscriptionUpdateProduct(TypedDict):
- adjustable_quantity: NotRequired[
- "ConfigurationService.UpdateParamsFeaturesSubscriptionUpdateProductAdjustableQuantity"
- ]
- """
- Control whether the quantity of the product can be adjusted.
- """
- prices: List[str]
- """
- The list of price IDs for the product that a subscription can be updated to.
- """
- product: str
- """
- The product id.
- """
-
- class UpdateParamsFeaturesSubscriptionUpdateProductAdjustableQuantity(
- TypedDict,
- ):
- enabled: bool
- """
- Set to true if the quantity can be adjusted to any non-negative integer.
- """
- maximum: NotRequired[int]
- """
- The maximum quantity that can be set for the product.
- """
- minimum: NotRequired[int]
- """
- The minimum quantity that can be set for the product.
- """
-
- class UpdateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEnd(TypedDict):
- conditions: NotRequired[
- "Literal['']|List[ConfigurationService.UpdateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEndCondition]"
- ]
- """
- List of conditions. When any condition is true, the update will be scheduled at the end of the current period.
- """
-
- class UpdateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEndCondition(
- TypedDict,
- ):
- type: Literal["decreasing_item_amount", "shortening_interval"]
- """
- The type of condition.
- """
-
- class UpdateParamsLoginPage(TypedDict):
- enabled: bool
- """
- Set to `true` to generate a shareable URL [`login_page.url`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-login_page-url) that will take your customers to a hosted login page for the customer portal.
-
- Set to `false` to deactivate the `login_page.url`.
- """
-
def list(
self,
- params: Optional["ConfigurationService.ListParams"] = None,
+ params: Optional["ConfigurationListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Configuration]:
"""
@@ -535,7 +45,7 @@ def list(
async def list_async(
self,
- params: Optional["ConfigurationService.ListParams"] = None,
+ params: Optional["ConfigurationListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Configuration]:
"""
@@ -554,7 +64,7 @@ async def list_async(
def create(
self,
- params: "ConfigurationService.CreateParams",
+ params: "ConfigurationCreateParams",
options: Optional[RequestOptions] = None,
) -> Configuration:
"""
@@ -573,7 +83,7 @@ def create(
async def create_async(
self,
- params: "ConfigurationService.CreateParams",
+ params: "ConfigurationCreateParams",
options: Optional[RequestOptions] = None,
) -> Configuration:
"""
@@ -593,7 +103,7 @@ async def create_async(
def retrieve(
self,
configuration: str,
- params: Optional["ConfigurationService.RetrieveParams"] = None,
+ params: Optional["ConfigurationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Configuration:
"""
@@ -615,7 +125,7 @@ def retrieve(
async def retrieve_async(
self,
configuration: str,
- params: Optional["ConfigurationService.RetrieveParams"] = None,
+ params: Optional["ConfigurationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Configuration:
"""
@@ -637,7 +147,7 @@ async def retrieve_async(
def update(
self,
configuration: str,
- params: Optional["ConfigurationService.UpdateParams"] = None,
+ params: Optional["ConfigurationUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Configuration:
"""
@@ -659,7 +169,7 @@ def update(
async def update_async(
self,
configuration: str,
- params: Optional["ConfigurationService.UpdateParams"] = None,
+ params: Optional["ConfigurationUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Configuration:
"""
diff --git a/stripe/billing_portal/_session.py b/stripe/billing_portal/_session.py
index fabaabffa..c8d22f301 100644
--- a/stripe/billing_portal/_session.py
+++ b/stripe/billing_portal/_session.py
@@ -2,19 +2,15 @@
# File generated from our OpenAPI spec
from stripe._createable_api_resource import CreateableAPIResource
from stripe._expandable_field import ExpandableField
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from typing import ClassVar, List, Optional, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe.billing_portal._configuration import Configuration
+ from stripe.params.billing_portal._session_create_params import (
+ SessionCreateParams,
+ )
class Session(CreateableAPIResource["Session"]):
@@ -172,231 +168,6 @@ class Item(StripeObject):
"subscription_update_confirm": SubscriptionUpdateConfirm,
}
- class CreateParams(RequestOptions):
- configuration: NotRequired[str]
- """
- The ID of an existing [configuration](https://stripe.com/docs/api/customer_portal/configuration) to use for this session, describing its functionality and features. If not specified, the session uses the default configuration.
- """
- customer: str
- """
- The ID of an existing customer.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- flow_data: NotRequired["Session.CreateParamsFlowData"]
- """
- Information about a specific flow for the customer to go through. See the [docs](https://stripe.com/docs/customer-management/portal-deep-links) to learn more about using customer portal deep links and flows.
- """
- locale: NotRequired[
- Literal[
- "auto",
- "bg",
- "cs",
- "da",
- "de",
- "el",
- "en",
- "en-AU",
- "en-CA",
- "en-GB",
- "en-IE",
- "en-IN",
- "en-NZ",
- "en-SG",
- "es",
- "es-419",
- "et",
- "fi",
- "fil",
- "fr",
- "fr-CA",
- "hr",
- "hu",
- "id",
- "it",
- "ja",
- "ko",
- "lt",
- "lv",
- "ms",
- "mt",
- "nb",
- "nl",
- "pl",
- "pt",
- "pt-BR",
- "ro",
- "ru",
- "sk",
- "sl",
- "sv",
- "th",
- "tr",
- "vi",
- "zh",
- "zh-HK",
- "zh-TW",
- ]
- ]
- """
- The IETF language tag of the locale customer portal is displayed in. If blank or auto, the customer's `preferred_locales` or browser's locale is used.
- """
- on_behalf_of: NotRequired[str]
- """
- The `on_behalf_of` account to use for this session. When specified, only subscriptions and invoices with this `on_behalf_of` account appear in the portal. For more information, see the [docs](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant). Use the [Accounts API](https://stripe.com/docs/api/accounts/object#account_object-settings-branding) to modify the `on_behalf_of` account's branding settings, which the portal displays.
- """
- return_url: NotRequired[str]
- """
- The default URL to redirect customers to when they click on the portal's link to return to your website.
- """
-
- class CreateParamsFlowData(TypedDict):
- after_completion: NotRequired[
- "Session.CreateParamsFlowDataAfterCompletion"
- ]
- """
- Behavior after the flow is completed.
- """
- subscription_cancel: NotRequired[
- "Session.CreateParamsFlowDataSubscriptionCancel"
- ]
- """
- Configuration when `flow_data.type=subscription_cancel`.
- """
- subscription_update: NotRequired[
- "Session.CreateParamsFlowDataSubscriptionUpdate"
- ]
- """
- Configuration when `flow_data.type=subscription_update`.
- """
- subscription_update_confirm: NotRequired[
- "Session.CreateParamsFlowDataSubscriptionUpdateConfirm"
- ]
- """
- Configuration when `flow_data.type=subscription_update_confirm`.
- """
- type: Literal[
- "payment_method_update",
- "subscription_cancel",
- "subscription_update",
- "subscription_update_confirm",
- ]
- """
- Type of flow that the customer will go through.
- """
-
- class CreateParamsFlowDataAfterCompletion(TypedDict):
- hosted_confirmation: NotRequired[
- "Session.CreateParamsFlowDataAfterCompletionHostedConfirmation"
- ]
- """
- Configuration when `after_completion.type=hosted_confirmation`.
- """
- redirect: NotRequired[
- "Session.CreateParamsFlowDataAfterCompletionRedirect"
- ]
- """
- Configuration when `after_completion.type=redirect`.
- """
- type: Literal["hosted_confirmation", "portal_homepage", "redirect"]
- """
- The specified behavior after the flow is completed.
- """
-
- class CreateParamsFlowDataAfterCompletionHostedConfirmation(TypedDict):
- custom_message: NotRequired[str]
- """
- A custom message to display to the customer after the flow is completed.
- """
-
- class CreateParamsFlowDataAfterCompletionRedirect(TypedDict):
- return_url: str
- """
- The URL the customer will be redirected to after the flow is completed.
- """
-
- class CreateParamsFlowDataSubscriptionCancel(TypedDict):
- retention: NotRequired[
- "Session.CreateParamsFlowDataSubscriptionCancelRetention"
- ]
- """
- Specify a retention strategy to be used in the cancellation flow.
- """
- subscription: str
- """
- The ID of the subscription to be canceled.
- """
-
- class CreateParamsFlowDataSubscriptionCancelRetention(TypedDict):
- coupon_offer: "Session.CreateParamsFlowDataSubscriptionCancelRetentionCouponOffer"
- """
- Configuration when `retention.type=coupon_offer`.
- """
- type: Literal["coupon_offer"]
- """
- Type of retention strategy to use with the customer.
- """
-
- class CreateParamsFlowDataSubscriptionCancelRetentionCouponOffer(
- TypedDict
- ):
- coupon: str
- """
- The ID of the coupon to be offered.
- """
-
- class CreateParamsFlowDataSubscriptionUpdate(TypedDict):
- subscription: str
- """
- The ID of the subscription to be updated.
- """
-
- class CreateParamsFlowDataSubscriptionUpdateConfirm(TypedDict):
- discounts: NotRequired[
- List[
- "Session.CreateParamsFlowDataSubscriptionUpdateConfirmDiscount"
- ]
- ]
- """
- The coupon or promotion code to apply to this subscription update.
- """
- items: List[
- "Session.CreateParamsFlowDataSubscriptionUpdateConfirmItem"
- ]
- """
- The [subscription item](https://stripe.com/docs/api/subscription_items) to be updated through this flow. Currently, only up to one may be specified and subscriptions with multiple items are not updatable.
- """
- subscription: str
- """
- The ID of the subscription to be updated.
- """
-
- class CreateParamsFlowDataSubscriptionUpdateConfirmDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- The ID of the coupon to apply to this subscription update.
- """
- promotion_code: NotRequired[str]
- """
- The ID of a promotion code to apply to this subscription update.
- """
-
- class CreateParamsFlowDataSubscriptionUpdateConfirmItem(TypedDict):
- id: str
- """
- The ID of the [subscription item](https://stripe.com/docs/api/subscriptions/object#subscription_object-items-data-id) to be updated.
- """
- price: NotRequired[str]
- """
- The price the customer should subscribe to through this flow. The price must also be included in the configuration's [`features.subscription_update.products`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-features-subscription_update-products).
- """
- quantity: NotRequired[int]
- """
- [Quantity](https://stripe.com/docs/subscriptions/quantities) for this item that the customer should subscribe to through this flow.
- """
-
configuration: ExpandableField["Configuration"]
"""
The configuration used by this session, describing the features available.
@@ -493,7 +264,7 @@ class CreateParamsFlowDataSubscriptionUpdateConfirmItem(TypedDict):
"""
@classmethod
- def create(cls, **params: Unpack["Session.CreateParams"]) -> "Session":
+ def create(cls, **params: Unpack["SessionCreateParams"]) -> "Session":
"""
Creates a session of the customer portal.
"""
@@ -508,7 +279,7 @@ def create(cls, **params: Unpack["Session.CreateParams"]) -> "Session":
@classmethod
async def create_async(
- cls, **params: Unpack["Session.CreateParams"]
+ cls, **params: Unpack["SessionCreateParams"]
) -> "Session":
"""
Creates a session of the customer portal.
diff --git a/stripe/billing_portal/_session_service.py b/stripe/billing_portal/_session_service.py
index dd4338ec3..65430ae3a 100644
--- a/stripe/billing_portal/_session_service.py
+++ b/stripe/billing_portal/_session_service.py
@@ -3,239 +3,19 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe.billing_portal._session import Session
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.billing_portal._session_create_params import (
+ SessionCreateParams,
+ )
-class SessionService(StripeService):
- class CreateParams(TypedDict):
- configuration: NotRequired[str]
- """
- The ID of an existing [configuration](https://stripe.com/docs/api/customer_portal/configuration) to use for this session, describing its functionality and features. If not specified, the session uses the default configuration.
- """
- customer: str
- """
- The ID of an existing customer.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- flow_data: NotRequired["SessionService.CreateParamsFlowData"]
- """
- Information about a specific flow for the customer to go through. See the [docs](https://stripe.com/docs/customer-management/portal-deep-links) to learn more about using customer portal deep links and flows.
- """
- locale: NotRequired[
- Literal[
- "auto",
- "bg",
- "cs",
- "da",
- "de",
- "el",
- "en",
- "en-AU",
- "en-CA",
- "en-GB",
- "en-IE",
- "en-IN",
- "en-NZ",
- "en-SG",
- "es",
- "es-419",
- "et",
- "fi",
- "fil",
- "fr",
- "fr-CA",
- "hr",
- "hu",
- "id",
- "it",
- "ja",
- "ko",
- "lt",
- "lv",
- "ms",
- "mt",
- "nb",
- "nl",
- "pl",
- "pt",
- "pt-BR",
- "ro",
- "ru",
- "sk",
- "sl",
- "sv",
- "th",
- "tr",
- "vi",
- "zh",
- "zh-HK",
- "zh-TW",
- ]
- ]
- """
- The IETF language tag of the locale customer portal is displayed in. If blank or auto, the customer's `preferred_locales` or browser's locale is used.
- """
- on_behalf_of: NotRequired[str]
- """
- The `on_behalf_of` account to use for this session. When specified, only subscriptions and invoices with this `on_behalf_of` account appear in the portal. For more information, see the [docs](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant). Use the [Accounts API](https://stripe.com/docs/api/accounts/object#account_object-settings-branding) to modify the `on_behalf_of` account's branding settings, which the portal displays.
- """
- return_url: NotRequired[str]
- """
- The default URL to redirect customers to when they click on the portal's link to return to your website.
- """
-
- class CreateParamsFlowData(TypedDict):
- after_completion: NotRequired[
- "SessionService.CreateParamsFlowDataAfterCompletion"
- ]
- """
- Behavior after the flow is completed.
- """
- subscription_cancel: NotRequired[
- "SessionService.CreateParamsFlowDataSubscriptionCancel"
- ]
- """
- Configuration when `flow_data.type=subscription_cancel`.
- """
- subscription_update: NotRequired[
- "SessionService.CreateParamsFlowDataSubscriptionUpdate"
- ]
- """
- Configuration when `flow_data.type=subscription_update`.
- """
- subscription_update_confirm: NotRequired[
- "SessionService.CreateParamsFlowDataSubscriptionUpdateConfirm"
- ]
- """
- Configuration when `flow_data.type=subscription_update_confirm`.
- """
- type: Literal[
- "payment_method_update",
- "subscription_cancel",
- "subscription_update",
- "subscription_update_confirm",
- ]
- """
- Type of flow that the customer will go through.
- """
-
- class CreateParamsFlowDataAfterCompletion(TypedDict):
- hosted_confirmation: NotRequired[
- "SessionService.CreateParamsFlowDataAfterCompletionHostedConfirmation"
- ]
- """
- Configuration when `after_completion.type=hosted_confirmation`.
- """
- redirect: NotRequired[
- "SessionService.CreateParamsFlowDataAfterCompletionRedirect"
- ]
- """
- Configuration when `after_completion.type=redirect`.
- """
- type: Literal["hosted_confirmation", "portal_homepage", "redirect"]
- """
- The specified behavior after the flow is completed.
- """
-
- class CreateParamsFlowDataAfterCompletionHostedConfirmation(TypedDict):
- custom_message: NotRequired[str]
- """
- A custom message to display to the customer after the flow is completed.
- """
-
- class CreateParamsFlowDataAfterCompletionRedirect(TypedDict):
- return_url: str
- """
- The URL the customer will be redirected to after the flow is completed.
- """
-
- class CreateParamsFlowDataSubscriptionCancel(TypedDict):
- retention: NotRequired[
- "SessionService.CreateParamsFlowDataSubscriptionCancelRetention"
- ]
- """
- Specify a retention strategy to be used in the cancellation flow.
- """
- subscription: str
- """
- The ID of the subscription to be canceled.
- """
-
- class CreateParamsFlowDataSubscriptionCancelRetention(TypedDict):
- coupon_offer: "SessionService.CreateParamsFlowDataSubscriptionCancelRetentionCouponOffer"
- """
- Configuration when `retention.type=coupon_offer`.
- """
- type: Literal["coupon_offer"]
- """
- Type of retention strategy to use with the customer.
- """
-
- class CreateParamsFlowDataSubscriptionCancelRetentionCouponOffer(
- TypedDict
- ):
- coupon: str
- """
- The ID of the coupon to be offered.
- """
-
- class CreateParamsFlowDataSubscriptionUpdate(TypedDict):
- subscription: str
- """
- The ID of the subscription to be updated.
- """
-
- class CreateParamsFlowDataSubscriptionUpdateConfirm(TypedDict):
- discounts: NotRequired[
- List[
- "SessionService.CreateParamsFlowDataSubscriptionUpdateConfirmDiscount"
- ]
- ]
- """
- The coupon or promotion code to apply to this subscription update.
- """
- items: List[
- "SessionService.CreateParamsFlowDataSubscriptionUpdateConfirmItem"
- ]
- """
- The [subscription item](https://stripe.com/docs/api/subscription_items) to be updated through this flow. Currently, only up to one may be specified and subscriptions with multiple items are not updatable.
- """
- subscription: str
- """
- The ID of the subscription to be updated.
- """
-
- class CreateParamsFlowDataSubscriptionUpdateConfirmDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- The ID of the coupon to apply to this subscription update.
- """
- promotion_code: NotRequired[str]
- """
- The ID of a promotion code to apply to this subscription update.
- """
-
- class CreateParamsFlowDataSubscriptionUpdateConfirmItem(TypedDict):
- id: str
- """
- The ID of the [subscription item](https://stripe.com/docs/api/subscriptions/object#subscription_object-items-data-id) to be updated.
- """
- price: NotRequired[str]
- """
- The price the customer should subscribe to through this flow. The price must also be included in the configuration's [`features.subscription_update.products`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-features-subscription_update-products).
- """
- quantity: NotRequired[int]
- """
- [Quantity](https://stripe.com/docs/subscriptions/quantities) for this item that the customer should subscribe to through this flow.
- """
+class SessionService(StripeService):
def create(
self,
- params: "SessionService.CreateParams",
+ params: "SessionCreateParams",
options: Optional[RequestOptions] = None,
) -> Session:
"""
@@ -254,7 +34,7 @@ def create(
async def create_async(
self,
- params: "SessionService.CreateParams",
+ params: "SessionCreateParams",
options: Optional[RequestOptions] = None,
) -> Session:
"""
diff --git a/stripe/checkout/_session.py b/stripe/checkout/_session.py
index 6144b8256..4c9fd2df4 100644
--- a/stripe/checkout/_session.py
+++ b/stripe/checkout/_session.py
@@ -4,18 +4,11 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account
@@ -32,6 +25,22 @@
from stripe._subscription import Subscription
from stripe._tax_id import TaxId as TaxIdResource
from stripe._tax_rate import TaxRate
+ from stripe.params.checkout._session_create_params import (
+ SessionCreateParams,
+ )
+ from stripe.params.checkout._session_expire_params import (
+ SessionExpireParams,
+ )
+ from stripe.params.checkout._session_list_line_items_params import (
+ SessionListLineItemsParams,
+ )
+ from stripe.params.checkout._session_list_params import SessionListParams
+ from stripe.params.checkout._session_modify_params import (
+ SessionModifyParams,
+ )
+ from stripe.params.checkout._session_retrieve_params import (
+ SessionRetrieveParams,
+ )
class Session(
@@ -2054,3090 +2063,6 @@ class Link(StripeObject):
link: Optional[Link]
_inner_class_types = {"link": Link}
- class CreateParams(RequestOptions):
- adaptive_pricing: NotRequired["Session.CreateParamsAdaptivePricing"]
- """
- Settings for price localization with [Adaptive Pricing](https://docs.stripe.com/payments/checkout/adaptive-pricing).
- """
- after_expiration: NotRequired["Session.CreateParamsAfterExpiration"]
- """
- Configure actions after a Checkout Session has expired.
- """
- allow_promotion_codes: NotRequired[bool]
- """
- Enables user redeemable promotion codes.
- """
- automatic_tax: NotRequired["Session.CreateParamsAutomaticTax"]
- """
- Settings for automatic tax lookup for this session and resulting payments, invoices, and subscriptions.
- """
- billing_address_collection: NotRequired[Literal["auto", "required"]]
- """
- Specify whether Checkout should collect the customer's billing address. Defaults to `auto`.
- """
- branding_settings: NotRequired["Session.CreateParamsBrandingSettings"]
- """
- The branding settings for the Checkout Session. This parameter is not allowed if ui_mode is `custom`.
- """
- cancel_url: NotRequired[str]
- """
- If set, Checkout displays a back button and customers will be directed to this URL if they decide to cancel payment and return to your website. This parameter is not allowed if ui_mode is `embedded` or `custom`.
- """
- client_reference_id: NotRequired[str]
- """
- A unique string to reference the Checkout Session. This can be a
- customer ID, a cart ID, or similar, and can be used to reconcile the
- session with your internal systems.
- """
- consent_collection: NotRequired[
- "Session.CreateParamsConsentCollection"
- ]
- """
- Configure fields for the Checkout Session to gather active consent from customers.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Required in `setup` mode when `payment_method_types` is not set.
- """
- custom_fields: NotRequired[List["Session.CreateParamsCustomField"]]
- """
- Collect additional information from your customer using custom fields. Up to 3 fields are supported.
- """
- custom_text: NotRequired["Session.CreateParamsCustomText"]
- """
- Display additional text for your customers using custom text.
- """
- customer: NotRequired[str]
- """
- ID of an existing Customer, if one exists. In `payment` mode, the customer's most recently saved card
- payment method will be used to prefill the email, name, card details, and billing address
- on the Checkout page. In `subscription` mode, the customer's [default payment method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method)
- will be used if it's a card, otherwise the most recently saved card will be used. A valid billing address, billing name and billing email are required on the payment method for Checkout to prefill the customer's card details.
-
- If the Customer already has a valid [email](https://stripe.com/docs/api/customers/object#customer_object-email) set, the email will be prefilled and not editable in Checkout.
- If the Customer does not have a valid `email`, Checkout will set the email entered during the session on the Customer.
-
- If blank for Checkout Sessions in `subscription` mode or with `customer_creation` set as `always` in `payment` mode, Checkout will create a new Customer object based on information provided during the payment flow.
-
- You can set [`payment_intent_data.setup_future_usage`](https://stripe.com/docs/api/checkout/sessions/create#create_checkout_session-payment_intent_data-setup_future_usage) to have Checkout automatically attach the payment method to the Customer you pass in for future reuse.
- """
- customer_creation: NotRequired[Literal["always", "if_required"]]
- """
- Configure whether a Checkout Session creates a [Customer](https://stripe.com/docs/api/customers) during Session confirmation.
-
- When a Customer is not created, you can still retrieve email, address, and other customer data entered in Checkout
- with [customer_details](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-customer_details).
-
- Sessions that don't create Customers instead are grouped by [guest customers](https://stripe.com/docs/payments/checkout/guest-customers)
- in the Dashboard. Promotion codes limited to first time customers will return invalid for these Sessions.
-
- Can only be set in `payment` and `setup` mode.
- """
- customer_email: NotRequired[str]
- """
- If provided, this value will be used when the Customer object is created.
- If not provided, customers will be asked to enter their email address.
- Use this parameter to prefill customer data if you already have an email
- on file. To access information about the customer once a session is
- complete, use the `customer` field.
- """
- customer_update: NotRequired["Session.CreateParamsCustomerUpdate"]
- """
- Controls what fields on Customer can be updated by the Checkout Session. Can only be provided when `customer` is provided.
- """
- discounts: NotRequired[List["Session.CreateParamsDiscount"]]
- """
- The coupon or promotion code to apply to this Session. Currently, only up to one may be specified.
- """
- excluded_payment_method_types: NotRequired[
- List[
- Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "card",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- ]
- ]
- """
- A list of the types of payment methods (e.g., `card`) that should be excluded from this Checkout Session. This should only be used when payment methods for this Checkout Session are managed through the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- The Epoch time in seconds at which the Checkout Session will expire. It can be anywhere from 30 minutes to 24 hours after Checkout Session creation. By default, this value is 24 hours from creation.
- """
- invoice_creation: NotRequired["Session.CreateParamsInvoiceCreation"]
- """
- Generate a post-purchase Invoice for one-time payments.
- """
- line_items: NotRequired[List["Session.CreateParamsLineItem"]]
- """
- A list of items the customer is purchasing. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices). The parameter is required for `payment` and `subscription` mode.
-
- For `payment` mode, there is a maximum of 100 line items, however it is recommended to consolidate line items if there are more than a few dozen.
-
- For `subscription` mode, there is a maximum of 20 line items with recurring Prices and 20 line items with one-time Prices. Line items with one-time Prices will be on the initial invoice only.
- """
- locale: NotRequired[
- Literal[
- "auto",
- "bg",
- "cs",
- "da",
- "de",
- "el",
- "en",
- "en-GB",
- "es",
- "es-419",
- "et",
- "fi",
- "fil",
- "fr",
- "fr-CA",
- "hr",
- "hu",
- "id",
- "it",
- "ja",
- "ko",
- "lt",
- "lv",
- "ms",
- "mt",
- "nb",
- "nl",
- "pl",
- "pt",
- "pt-BR",
- "ro",
- "ru",
- "sk",
- "sl",
- "sv",
- "th",
- "tr",
- "vi",
- "zh",
- "zh-HK",
- "zh-TW",
- ]
- ]
- """
- The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mode: NotRequired[Literal["payment", "setup", "subscription"]]
- """
- The mode of the Checkout Session. Pass `subscription` if the Checkout Session includes at least one recurring item.
- """
- name_collection: NotRequired["Session.CreateParamsNameCollection"]
- """
- Controls name collection settings for the session.
-
- You can configure Checkout to collect your customers' business names, individual names, or both. Each name field can be either required or optional.
-
- If a [Customer](https://stripe.com/docs/api/customers) is created or provided, the names can be saved to the Customer object as well.
- """
- optional_items: NotRequired[List["Session.CreateParamsOptionalItem"]]
- """
- A list of optional items the customer can add to their order at checkout. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices).
-
- There is a maximum of 10 optional items allowed on a Checkout Session, and the existing limits on the number of line items allowed on a Checkout Session apply to the combined number of line items and optional items.
-
- For `payment` mode, there is a maximum of 100 combined line items and optional items, however it is recommended to consolidate items if there are more than a few dozen.
-
- For `subscription` mode, there is a maximum of 20 line items and optional items with recurring Prices and 20 line items and optional items with one-time Prices.
- """
- origin_context: NotRequired[Literal["mobile_app", "web"]]
- """
- Where the user is coming from. This informs the optimizations that are applied to the session.
- """
- payment_intent_data: NotRequired[
- "Session.CreateParamsPaymentIntentData"
- ]
- """
- A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
- """
- payment_method_collection: NotRequired[
- Literal["always", "if_required"]
- ]
- """
- Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.
- This may occur if the Checkout Session includes a free trial or a discount.
-
- Can only be set in `subscription` mode. Defaults to `always`.
-
- 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_configuration: NotRequired[str]
- """
- The ID of the payment method configuration to use with this Checkout session.
- """
- payment_method_data: NotRequired[
- "Session.CreateParamsPaymentMethodData"
- ]
- """
- This parameter allows you to set some attributes on the payment method created during a Checkout session.
- """
- payment_method_options: NotRequired[
- "Session.CreateParamsPaymentMethodOptions"
- ]
- """
- Payment-method-specific configuration.
- """
- payment_method_types: NotRequired[
- List[
- Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "card",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- ]
- ]
- """
- A list of the types of payment methods (e.g., `card`) this Checkout Session can accept.
-
- You can omit this attribute to manage your payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
- See [Dynamic Payment Methods](https://stripe.com/docs/payments/payment-methods/integration-options#using-dynamic-payment-methods) for more details.
-
- Read more about the supported payment methods and their requirements in our [payment
- method details guide](https://docs.stripe.com/docs/payments/checkout/payment-methods).
-
- If multiple payment methods are passed, Checkout will dynamically reorder them to
- prioritize the most relevant payment methods based on the customer's location and
- other characteristics.
- """
- permissions: NotRequired["Session.CreateParamsPermissions"]
- """
- This property is used to set up permissions for various actions (e.g., update) on the CheckoutSession object. Can only be set when creating `embedded` or `custom` sessions.
-
- For specific permissions, please refer to their dedicated subsections, such as `permissions.update_shipping_details`.
- """
- phone_number_collection: NotRequired[
- "Session.CreateParamsPhoneNumberCollection"
- ]
- """
- Controls phone number collection settings for the session.
-
- We recommend that you review your privacy policy and check with your legal contacts
- before using this feature. Learn more about [collecting phone numbers with Checkout](https://stripe.com/docs/payments/checkout/phone-numbers).
- """
- redirect_on_completion: NotRequired[
- Literal["always", "if_required", "never"]
- ]
- """
- This parameter applies to `ui_mode: embedded`. Learn more about the [redirect behavior](https://stripe.com/docs/payments/checkout/custom-success-page?payment-ui=embedded-form) of embedded sessions. Defaults to `always`.
- """
- return_url: NotRequired[str]
- """
- The URL to redirect your customer back to after they authenticate or cancel their payment on the
- payment method's app or site. This parameter is required if `ui_mode` is `embedded` or `custom`
- and redirect-based payment methods are enabled on the session.
- """
- saved_payment_method_options: NotRequired[
- "Session.CreateParamsSavedPaymentMethodOptions"
- ]
- """
- Controls saved payment method settings for the session. Only available in `payment` and `subscription` mode.
- """
- setup_intent_data: NotRequired["Session.CreateParamsSetupIntentData"]
- """
- A subset of parameters to be passed to SetupIntent creation for Checkout Sessions in `setup` mode.
- """
- shipping_address_collection: NotRequired[
- "Session.CreateParamsShippingAddressCollection"
- ]
- """
- When set, provides configuration for Checkout to collect a shipping address from a customer.
- """
- shipping_options: NotRequired[
- List["Session.CreateParamsShippingOption"]
- ]
- """
- The shipping rate options to apply to this Session. Up to a maximum of 5.
- """
- submit_type: NotRequired[
- Literal["auto", "book", "donate", "pay", "subscribe"]
- ]
- """
- Describes the type of transaction being performed by Checkout in order
- to customize relevant text on the page, such as the submit button.
- `submit_type` can only be specified on Checkout Sessions in
- `payment` or `subscription` mode. If blank or `auto`, `pay` is used.
- """
- subscription_data: NotRequired["Session.CreateParamsSubscriptionData"]
- """
- A subset of parameters to be passed to subscription creation for Checkout Sessions in `subscription` mode.
- """
- success_url: NotRequired[str]
- """
- The URL to which Stripe should send customers when payment or setup
- is complete.
- This parameter is not allowed if ui_mode is `embedded` or `custom`. If you'd like to use
- information from the successful Checkout Session on your page, read the
- guide on [customizing your success page](https://stripe.com/docs/payments/checkout/custom-success-page).
- """
- tax_id_collection: NotRequired["Session.CreateParamsTaxIdCollection"]
- """
- Controls tax ID collection during checkout.
- """
- ui_mode: NotRequired[Literal["custom", "embedded", "hosted"]]
- """
- The UI mode of the Session. Defaults to `hosted`.
- """
- wallet_options: NotRequired["Session.CreateParamsWalletOptions"]
- """
- Wallet-specific configuration.
- """
-
- class CreateParamsAdaptivePricing(TypedDict):
- enabled: NotRequired[bool]
- """
- If set to `true`, Adaptive Pricing is available on [eligible sessions](https://docs.stripe.com/payments/currencies/localize-prices/adaptive-pricing?payment-ui=stripe-hosted#restrictions). Defaults to your [dashboard setting](https://dashboard.stripe.com/settings/adaptive-pricing).
- """
-
- class CreateParamsAfterExpiration(TypedDict):
- recovery: NotRequired["Session.CreateParamsAfterExpirationRecovery"]
- """
- Configure a Checkout Session that can be used to recover an expired session.
- """
-
- class CreateParamsAfterExpirationRecovery(TypedDict):
- allow_promotion_codes: NotRequired[bool]
- """
- Enables user redeemable promotion codes on the recovered Checkout Sessions. Defaults to `false`
- """
- enabled: bool
- """
- If `true`, a recovery URL will be generated to recover this Checkout Session if it
- expires before a successful transaction is completed. It will be attached to the
- Checkout Session object upon expiration.
- """
-
- class CreateParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
-
- Enabling this parameter causes Checkout to collect any billing address information necessary for tax calculation.
- """
- liability: NotRequired["Session.CreateParamsAutomaticTaxLiability"]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreateParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsBrandingSettings(TypedDict):
- background_color: NotRequired["Literal['']|str"]
- """
- A hex color value starting with `#` representing the background color for the Checkout Session.
- """
- border_style: NotRequired[
- "Literal['']|Literal['pill', 'rectangular', 'rounded']"
- ]
- """
- The border style for the Checkout Session.
- """
- button_color: NotRequired["Literal['']|str"]
- """
- A hex color value starting with `#` representing the button color for the Checkout Session.
- """
- display_name: NotRequired[str]
- """
- A string to override the business name shown on the Checkout Session.
- """
- font_family: NotRequired[
- "Literal['']|Literal['be_vietnam_pro', 'bitter', 'chakra_petch', 'default', 'hahmlet', 'inconsolata', 'inter', 'lato', 'lora', 'm_plus_1_code', 'montserrat', 'noto_sans', 'noto_sans_jp', 'noto_serif', 'nunito', 'open_sans', 'pridi', 'pt_sans', 'pt_serif', 'raleway', 'roboto', 'roboto_slab', 'source_sans_pro', 'titillium_web', 'ubuntu_mono', 'zen_maru_gothic']"
- ]
- """
- The font family for the Checkout Session corresponding to one of the [supported font families](https://docs.stripe.com/payments/checkout/customization/appearance?payment-ui=stripe-hosted#font-compatibility).
- """
- icon: NotRequired["Session.CreateParamsBrandingSettingsIcon"]
- """
- The icon for the Checkout Session. You cannot set both `logo` and `icon`.
- """
- logo: NotRequired["Session.CreateParamsBrandingSettingsLogo"]
- """
- The logo for the Checkout Session. You cannot set both `logo` and `icon`.
- """
-
- class CreateParamsBrandingSettingsIcon(TypedDict):
- file: NotRequired[str]
- """
- The ID of a [File upload](https://stripe.com/docs/api/files) representing the icon. Purpose must be `business_icon`. Required if `type` is `file` and disallowed otherwise.
- """
- type: Literal["file", "url"]
- """
- The type of image for the icon. Must be one of `file` or `url`.
- """
- url: NotRequired[str]
- """
- The URL of the image. Required if `type` is `url` and disallowed otherwise.
- """
-
- class CreateParamsBrandingSettingsLogo(TypedDict):
- file: NotRequired[str]
- """
- The ID of a [File upload](https://stripe.com/docs/api/files) representing the logo. Purpose must be `business_logo`. Required if `type` is `file` and disallowed otherwise.
- """
- type: Literal["file", "url"]
- """
- The type of image for the logo. Must be one of `file` or `url`.
- """
- url: NotRequired[str]
- """
- The URL of the image. Required if `type` is `url` and disallowed otherwise.
- """
-
- class CreateParamsConsentCollection(TypedDict):
- payment_method_reuse_agreement: NotRequired[
- "Session.CreateParamsConsentCollectionPaymentMethodReuseAgreement"
- ]
- """
- Determines the display of payment method reuse agreement text in the UI. If set to `hidden`, it will hide legal text related to the reuse of a payment method.
- """
- promotions: NotRequired[Literal["auto", "none"]]
- """
- If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
- Session will determine whether to display an option to opt into promotional communication
- from the merchant depending on the customer's locale. Only available to US merchants.
- """
- terms_of_service: NotRequired[Literal["none", "required"]]
- """
- If set to `required`, it requires customers to check a terms of service checkbox before being able to pay.
- There must be a valid terms of service URL set in your [Dashboard settings](https://dashboard.stripe.com/settings/public).
- """
-
- class CreateParamsConsentCollectionPaymentMethodReuseAgreement(TypedDict):
- position: Literal["auto", "hidden"]
- """
- Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's
- defaults will be used. When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
- """
-
- class CreateParamsCustomField(TypedDict):
- dropdown: NotRequired["Session.CreateParamsCustomFieldDropdown"]
- """
- Configuration for `type=dropdown` fields.
- """
- key: str
- """
- String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
- """
- label: "Session.CreateParamsCustomFieldLabel"
- """
- The label for the field, displayed to the customer.
- """
- numeric: NotRequired["Session.CreateParamsCustomFieldNumeric"]
- """
- Configuration for `type=numeric` fields.
- """
- optional: NotRequired[bool]
- """
- Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
- """
- text: NotRequired["Session.CreateParamsCustomFieldText"]
- """
- Configuration for `type=text` fields.
- """
- type: Literal["dropdown", "numeric", "text"]
- """
- The type of the field.
- """
-
- class CreateParamsCustomFieldDropdown(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
- """
- options: List["Session.CreateParamsCustomFieldDropdownOption"]
- """
- The options available for the customer to select. Up to 200 options allowed.
- """
-
- class CreateParamsCustomFieldDropdownOption(TypedDict):
- label: str
- """
- The label for the option, displayed to the customer. Up to 100 characters.
- """
- value: str
- """
- The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
- """
-
- class CreateParamsCustomFieldLabel(TypedDict):
- custom: str
- """
- Custom text for the label, displayed to the customer. Up to 50 characters.
- """
- type: Literal["custom"]
- """
- The type of the label.
- """
-
- class CreateParamsCustomFieldNumeric(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.
- """
- maximum_length: NotRequired[int]
- """
- The maximum character length constraint for the customer's input.
- """
- minimum_length: NotRequired[int]
- """
- The minimum character length requirement for the customer's input.
- """
-
- class CreateParamsCustomFieldText(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.
- """
- maximum_length: NotRequired[int]
- """
- The maximum character length constraint for the customer's input.
- """
- minimum_length: NotRequired[int]
- """
- The minimum character length requirement for the customer's input.
- """
-
- class CreateParamsCustomText(TypedDict):
- after_submit: NotRequired[
- "Literal['']|Session.CreateParamsCustomTextAfterSubmit"
- ]
- """
- Custom text that should be displayed after the payment confirmation button.
- """
- shipping_address: NotRequired[
- "Literal['']|Session.CreateParamsCustomTextShippingAddress"
- ]
- """
- Custom text that should be displayed alongside shipping address collection.
- """
- submit: NotRequired["Literal['']|Session.CreateParamsCustomTextSubmit"]
- """
- Custom text that should be displayed alongside the payment confirmation button.
- """
- terms_of_service_acceptance: NotRequired[
- "Literal['']|Session.CreateParamsCustomTextTermsOfServiceAcceptance"
- ]
- """
- Custom text that should be displayed in place of the default terms of service agreement text.
- """
-
- class CreateParamsCustomTextAfterSubmit(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsCustomTextShippingAddress(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsCustomTextSubmit(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsCustomTextTermsOfServiceAcceptance(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsCustomerUpdate(TypedDict):
- address: NotRequired[Literal["auto", "never"]]
- """
- Describes whether Checkout saves the billing address onto `customer.address`.
- To always collect a full billing address, use `billing_address_collection`. Defaults to `never`.
- """
- name: NotRequired[Literal["auto", "never"]]
- """
- Describes whether Checkout saves the name onto `customer.name`. Defaults to `never`.
- """
- shipping: NotRequired[Literal["auto", "never"]]
- """
- Describes whether Checkout saves shipping information onto `customer.shipping`.
- To collect shipping information, use `shipping_address_collection`. Defaults to `never`.
- """
-
- class CreateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- The ID of the coupon to apply to this Session.
- """
- promotion_code: NotRequired[str]
- """
- The ID of a promotion code to apply to this Session.
- """
-
- class CreateParamsInvoiceCreation(TypedDict):
- enabled: bool
- """
- Set to `true` to enable invoice creation.
- """
- invoice_data: NotRequired[
- "Session.CreateParamsInvoiceCreationInvoiceData"
- ]
- """
- Parameters passed when creating invoices for payment-mode Checkout Sessions.
- """
-
- class CreateParamsInvoiceCreationInvoiceData(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the invoice.
- """
- custom_fields: NotRequired[
- "Literal['']|List[Session.CreateParamsInvoiceCreationInvoiceDataCustomField]"
- ]
- """
- Default custom fields to be displayed on invoices for this customer.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- footer: NotRequired[str]
- """
- Default footer to be displayed on invoices for this customer.
- """
- issuer: NotRequired[
- "Session.CreateParamsInvoiceCreationInvoiceDataIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- rendering_options: NotRequired[
- "Literal['']|Session.CreateParamsInvoiceCreationInvoiceDataRenderingOptions"
- ]
- """
- Default options for invoice PDF rendering for this customer.
- """
-
- class CreateParamsInvoiceCreationInvoiceDataCustomField(TypedDict):
- name: str
- """
- The name of the custom field. This may be up to 40 characters.
- """
- value: str
- """
- The value of the custom field. This may be up to 140 characters.
- """
-
- class CreateParamsInvoiceCreationInvoiceDataIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsInvoiceCreationInvoiceDataRenderingOptions(TypedDict):
- amount_tax_display: NotRequired[
- "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
- ]
- """
- How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
- """
- template: NotRequired[str]
- """
- ID of the invoice rendering template to use for this invoice.
- """
-
- class CreateParamsLineItem(TypedDict):
- adjustable_quantity: NotRequired[
- "Session.CreateParamsLineItemAdjustableQuantity"
- ]
- """
- When set, provides configuration for this item's quantity to be adjusted by the customer during Checkout.
- """
- dynamic_tax_rates: NotRequired[List[str]]
- """
- The [tax rates](https://stripe.com/docs/api/tax_rates) that will be applied to this line item depending on the customer's billing/shipping address. We currently support the following countries: US, GB, AU, and all countries in the EU.
- """
- price: NotRequired[str]
- """
- The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired["Session.CreateParamsLineItemPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- The quantity of the line item being purchased. Quantity should not be defined when `recurring.usage_type=metered`.
- """
- tax_rates: NotRequired[List[str]]
- """
- The [tax rates](https://stripe.com/docs/api/tax_rates) which apply to this line item.
- """
-
- class CreateParamsLineItemAdjustableQuantity(TypedDict):
- enabled: bool
- """
- Set to true if the quantity can be adjusted to any non-negative integer.
- """
- maximum: NotRequired[int]
- """
- The maximum quantity the customer can purchase for the Checkout Session. By default this value is 99. You can specify a value up to 999999.
- """
- minimum: NotRequired[int]
- """
- The minimum quantity the customer must purchase for the Checkout Session. By default this value is 0.
- """
-
- class CreateParamsLineItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: NotRequired[str]
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
- """
- product_data: NotRequired[
- "Session.CreateParamsLineItemPriceDataProductData"
- ]
- """
- Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
- """
- recurring: NotRequired[
- "Session.CreateParamsLineItemPriceDataRecurring"
- ]
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsLineItemPriceDataProductData(TypedDict):
- description: NotRequired[str]
- """
- The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
- """
- images: NotRequired[List[str]]
- """
- A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The product's name, meant to be displayable to the customer.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- unit_label: NotRequired[str]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
- """
-
- class CreateParamsLineItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class CreateParamsNameCollection(TypedDict):
- business: NotRequired["Session.CreateParamsNameCollectionBusiness"]
- """
- Controls settings applied for collecting the customer's business name on the session.
- """
- individual: NotRequired["Session.CreateParamsNameCollectionIndividual"]
- """
- Controls settings applied for collecting the customer's individual name on the session.
- """
-
- class CreateParamsNameCollectionBusiness(TypedDict):
- enabled: bool
- """
- Enable business name collection on the Checkout Session. Defaults to `false`.
- """
- optional: NotRequired[bool]
- """
- Whether the customer is required to provide a business name before completing the Checkout Session. Defaults to `false`.
- """
-
- class CreateParamsNameCollectionIndividual(TypedDict):
- enabled: bool
- """
- Enable individual name collection on the Checkout Session. Defaults to `false`.
- """
- optional: NotRequired[bool]
- """
- Whether the customer is required to provide their name before completing the Checkout Session. Defaults to `false`.
- """
-
- class CreateParamsOptionalItem(TypedDict):
- adjustable_quantity: NotRequired[
- "Session.CreateParamsOptionalItemAdjustableQuantity"
- ]
- """
- When set, provides configuration for the customer to adjust the quantity of the line item created when a customer chooses to add this optional item to their order.
- """
- price: str
- """
- The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object.
- """
- quantity: int
- """
- The initial quantity of the line item created when a customer chooses to add this optional item to their order.
- """
-
- class CreateParamsOptionalItemAdjustableQuantity(TypedDict):
- enabled: bool
- """
- Set to true if the quantity can be adjusted to any non-negative integer.
- """
- maximum: NotRequired[int]
- """
- The maximum quantity of this item the customer can purchase. By default this value is 99. You can specify a value up to 999999.
- """
- minimum: NotRequired[int]
- """
- The minimum quantity of this item the customer must purchase, if they choose to purchase it. Because this item is optional, the customer will always be able to remove it from their order, even if the `minimum` configured here is greater than 0. By default this value is 0.
- """
-
- class CreateParamsPaymentIntentData(TypedDict):
- application_fee_amount: NotRequired[int]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- capture_method: NotRequired[
- Literal["automatic", "automatic_async", "manual"]
- ]
- """
- Controls when the funds will be captured from the customer's account.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The Stripe account ID for which these funds are intended. For details,
- see the PaymentIntents [use case for connected
- accounts](https://docs.stripe.com/docs/payments/connected-accounts).
- """
- receipt_email: NotRequired[str]
- """
- Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
- """
- setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
- """
- Indicates that you intend to [make future payments](https://stripe.com/docs/payments/payment-intents#future-usage) with the payment
- method collected by this Checkout Session.
-
- When setting this to `on_session`, Checkout will show a notice to the
- customer that their payment details will be saved.
-
- When setting this to `off_session`, Checkout will show a notice to the
- customer that their payment details will be saved and used for future
- payments.
-
- If a Customer has been provided or Checkout creates a new Customer,
- Checkout will attach the payment method to the Customer.
-
- If Checkout does not create a Customer, the payment method is not attached
- to a Customer. To reuse the payment method, you can retrieve it from the
- Checkout Session's PaymentIntent.
-
- When processing card payments, Checkout also uses `setup_future_usage`
- to dynamically optimize your payment flow and comply with regional
- legislation and network rules, such as SCA.
- """
- shipping: NotRequired["Session.CreateParamsPaymentIntentDataShipping"]
- """
- Shipping information for this payment.
- """
- statement_descriptor: NotRequired[str]
- """
- Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
-
- Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
- """
- statement_descriptor_suffix: NotRequired[str]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
- """
- transfer_data: NotRequired[
- "Session.CreateParamsPaymentIntentDataTransferData"
- ]
- """
- The parameters used to automatically create a Transfer when the payment succeeds.
- For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
- """
-
- class CreateParamsPaymentIntentDataShipping(TypedDict):
- address: "Session.CreateParamsPaymentIntentDataShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class CreateParamsPaymentIntentDataShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsPaymentIntentDataTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when a charge succeeds.
- """
- destination: str
- """
- If specified, successful charges will be attributed to the destination
- account for tax reporting, and the funds from charges will be transferred
- to the destination account. The ID of the resulting transfer will be
- returned on the successful charge's `transfer` field.
- """
-
- class CreateParamsPaymentMethodData(TypedDict):
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- Allow redisplay will be set on the payment method on confirmation and indicates whether this payment method can be shown again to the customer in a checkout flow. Only set this field if you wish to override the allow_redisplay value determined by Checkout.
- """
-
- class CreateParamsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsAcssDebit"
- ]
- """
- contains details about the ACSS Debit payment method options.
- """
- affirm: NotRequired["Session.CreateParamsPaymentMethodOptionsAffirm"]
- """
- contains details about the Affirm payment method options.
- """
- afterpay_clearpay: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsAfterpayClearpay"
- ]
- """
- contains details about the Afterpay Clearpay payment method options.
- """
- alipay: NotRequired["Session.CreateParamsPaymentMethodOptionsAlipay"]
- """
- contains details about the Alipay payment method options.
- """
- alma: NotRequired["Session.CreateParamsPaymentMethodOptionsAlma"]
- """
- contains details about the Alma payment method options.
- """
- amazon_pay: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsAmazonPay"
- ]
- """
- contains details about the AmazonPay payment method options.
- """
- au_becs_debit: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsAuBecsDebit"
- ]
- """
- contains details about the AU Becs Debit payment method options.
- """
- bacs_debit: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsBacsDebit"
- ]
- """
- contains details about the Bacs Debit payment method options.
- """
- bancontact: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsBancontact"
- ]
- """
- contains details about the Bancontact payment method options.
- """
- billie: NotRequired["Session.CreateParamsPaymentMethodOptionsBillie"]
- """
- contains details about the Billie payment method options.
- """
- boleto: NotRequired["Session.CreateParamsPaymentMethodOptionsBoleto"]
- """
- contains details about the Boleto payment method options.
- """
- card: NotRequired["Session.CreateParamsPaymentMethodOptionsCard"]
- """
- contains details about the Card payment method options.
- """
- cashapp: NotRequired["Session.CreateParamsPaymentMethodOptionsCashapp"]
- """
- contains details about the Cashapp Pay payment method options.
- """
- customer_balance: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsCustomerBalance"
- ]
- """
- contains details about the Customer Balance payment method options.
- """
- demo_pay: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsDemoPay"
- ]
- """
- contains details about the DemoPay payment method options.
- """
- eps: NotRequired["Session.CreateParamsPaymentMethodOptionsEps"]
- """
- contains details about the EPS payment method options.
- """
- fpx: NotRequired["Session.CreateParamsPaymentMethodOptionsFpx"]
- """
- contains details about the FPX payment method options.
- """
- giropay: NotRequired["Session.CreateParamsPaymentMethodOptionsGiropay"]
- """
- contains details about the Giropay payment method options.
- """
- grabpay: NotRequired["Session.CreateParamsPaymentMethodOptionsGrabpay"]
- """
- contains details about the Grabpay payment method options.
- """
- ideal: NotRequired["Session.CreateParamsPaymentMethodOptionsIdeal"]
- """
- contains details about the Ideal payment method options.
- """
- kakao_pay: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsKakaoPay"
- ]
- """
- contains details about the Kakao Pay payment method options.
- """
- klarna: NotRequired["Session.CreateParamsPaymentMethodOptionsKlarna"]
- """
- contains details about the Klarna payment method options.
- """
- konbini: NotRequired["Session.CreateParamsPaymentMethodOptionsKonbini"]
- """
- contains details about the Konbini payment method options.
- """
- kr_card: NotRequired["Session.CreateParamsPaymentMethodOptionsKrCard"]
- """
- contains details about the Korean card payment method options.
- """
- link: NotRequired["Session.CreateParamsPaymentMethodOptionsLink"]
- """
- contains details about the Link payment method options.
- """
- mobilepay: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsMobilepay"
- ]
- """
- contains details about the Mobilepay payment method options.
- """
- multibanco: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsMultibanco"
- ]
- """
- contains details about the Multibanco payment method options.
- """
- naver_pay: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsNaverPay"
- ]
- """
- contains details about the Naver Pay payment method options.
- """
- oxxo: NotRequired["Session.CreateParamsPaymentMethodOptionsOxxo"]
- """
- contains details about the OXXO payment method options.
- """
- p24: NotRequired["Session.CreateParamsPaymentMethodOptionsP24"]
- """
- contains details about the P24 payment method options.
- """
- pay_by_bank: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsPayByBank"
- ]
- """
- contains details about the Pay By Bank payment method options.
- """
- payco: NotRequired["Session.CreateParamsPaymentMethodOptionsPayco"]
- """
- contains details about the PAYCO payment method options.
- """
- paynow: NotRequired["Session.CreateParamsPaymentMethodOptionsPaynow"]
- """
- contains details about the PayNow payment method options.
- """
- paypal: NotRequired["Session.CreateParamsPaymentMethodOptionsPaypal"]
- """
- contains details about the PayPal payment method options.
- """
- pix: NotRequired["Session.CreateParamsPaymentMethodOptionsPix"]
- """
- contains details about the Pix payment method options.
- """
- revolut_pay: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsRevolutPay"
- ]
- """
- contains details about the RevolutPay payment method options.
- """
- samsung_pay: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsSamsungPay"
- ]
- """
- contains details about the Samsung Pay payment method options.
- """
- satispay: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsSatispay"
- ]
- """
- contains details about the Satispay payment method options.
- """
- sepa_debit: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsSepaDebit"
- ]
- """
- contains details about the Sepa Debit payment method options.
- """
- sofort: NotRequired["Session.CreateParamsPaymentMethodOptionsSofort"]
- """
- contains details about the Sofort payment method options.
- """
- swish: NotRequired["Session.CreateParamsPaymentMethodOptionsSwish"]
- """
- contains details about the Swish payment method options.
- """
- us_bank_account: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsUsBankAccount"
- ]
- """
- contains details about the Us Bank Account payment method options.
- """
- wechat_pay: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsWechatPay"
- ]
- """
- contains details about the WeChat Pay payment method options.
- """
-
- class CreateParamsPaymentMethodOptionsAcssDebit(TypedDict):
- currency: NotRequired[Literal["cad", "usd"]]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). This is only accepted for Checkout Sessions in `setup` mode.
- """
- mandate_options: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class CreateParamsPaymentMethodOptionsAcssDebitMandateOptions(TypedDict):
- custom_mandate_url: NotRequired["Literal['']|str"]
- """
- A URL for custom mandate text to render during confirmation step.
- The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
- or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
- """
- default_for: NotRequired[List[Literal["invoice", "subscription"]]]
- """
- List of Stripe products where this mandate can be selected automatically. Only usable in `setup` mode.
- """
- interval_description: NotRequired[str]
- """
- Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
- """
- payment_schedule: NotRequired[
- Literal["combined", "interval", "sporadic"]
- ]
- """
- Payment schedule for the mandate.
- """
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class CreateParamsPaymentMethodOptionsAffirm(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsAfterpayClearpay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsAlipay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsAlma(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
-
- class CreateParamsPaymentMethodOptionsAmazonPay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none", "off_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsAuBecsDebit(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class CreateParamsPaymentMethodOptionsBacsDebit(TypedDict):
- mandate_options: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsBacsDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class CreateParamsPaymentMethodOptionsBacsDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
- """
-
- class CreateParamsPaymentMethodOptionsBancontact(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsBillie(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
-
- class CreateParamsPaymentMethodOptionsBoleto(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsCard(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- installments: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsCardInstallments"
- ]
- """
- Installment options for card payments
- """
- request_extended_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [capture beyond the standard authorization validity window](https://docs.stripe.com/payments/extended-authorization) for this CheckoutSession.
- """
- request_incremental_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [increment the authorization](https://docs.stripe.com/payments/incremental-authorization) for this CheckoutSession.
- """
- request_multicapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to make [multiple captures](https://docs.stripe.com/payments/multicapture) for this CheckoutSession.
- """
- request_overcapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to [overcapture](https://docs.stripe.com/payments/overcapture) for this CheckoutSession.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
- restrictions: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsCardRestrictions"
- ]
- """
- Restrictions to apply to the card payment method. For example, you can block specific card brands.
- """
- setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- statement_descriptor_suffix_kana: NotRequired[str]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that's set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
- """
- statement_descriptor_suffix_kanji: NotRequired[str]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that's set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
- """
-
- class CreateParamsPaymentMethodOptionsCardInstallments(TypedDict):
- enabled: NotRequired[bool]
- """
- Setting to true enables installments for this Checkout Session.
- Setting to false will prevent any installment plan from applying to a payment.
- """
-
- class CreateParamsPaymentMethodOptionsCardRestrictions(TypedDict):
- brands_blocked: NotRequired[
- List[
- Literal[
- "american_express",
- "discover_global_network",
- "mastercard",
- "visa",
- ]
- ]
- ]
- """
- Specify the card brands to block in the Checkout Session. If a customer enters or selects a card belonging to a blocked brand, they can't complete the Session.
- """
-
- class CreateParamsPaymentMethodOptionsCashapp(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsCustomerBalance(TypedDict):
- bank_transfer: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[Literal["bank_transfer"]]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for eu_bank_transfer funding type.
- """
- requested_address_types: NotRequired[
- List[
- Literal[
- "aba",
- "iban",
- "sepa",
- "sort_code",
- "spei",
- "swift",
- "zengin",
- ]
- ]
- ]
- """
- List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
-
- Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
- """
- type: Literal[
- "eu_bank_transfer",
- "gb_bank_transfer",
- "jp_bank_transfer",
- "mx_bank_transfer",
- "us_bank_transfer",
- ]
- """
- The list of bank transfer types that this PaymentIntent is allowed to use for funding.
- """
-
- class CreateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class CreateParamsPaymentMethodOptionsDemoPay(TypedDict):
- setup_future_usage: NotRequired[Literal["none", "off_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsEps(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsFpx(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsGiropay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsGrabpay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsIdeal(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsKakaoPay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none", "off_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsKlarna(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- subscriptions: NotRequired[
- "Literal['']|List[Session.CreateParamsPaymentMethodOptionsKlarnaSubscription]"
- ]
- """
- Subscription details if the Checkout Session sets up a future subscription.
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Unit of time between subscription charges.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
- """
- name: NotRequired[str]
- """
- Name for subscription.
- """
- next_billing: "Session.CreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
- """
- Describes the upcoming charge for this subscription.
- """
- reference: str
- """
- A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
- TypedDict,
- ):
- amount: int
- """
- The amount of the next charge for the subscription.
- """
- date: str
- """
- The date of the next charge for the subscription in YYYY-MM-DD format.
- """
-
- class CreateParamsPaymentMethodOptionsKonbini(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsKrCard(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none", "off_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsLink(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none", "off_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsMobilepay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsMultibanco(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsNaverPay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none", "off_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsOxxo(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsP24(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- tos_shown_and_accepted: NotRequired[bool]
- """
- Confirm that the payer has accepted the P24 terms and conditions.
- """
-
- class CreateParamsPaymentMethodOptionsPayByBank(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptionsPayco(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
-
- class CreateParamsPaymentMethodOptionsPaynow(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsPaypal(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds will be captured from the customer's account.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-DE",
- "de-LU",
- "el-GR",
- "en-GB",
- "en-US",
- "es-ES",
- "fi-FI",
- "fr-BE",
- "fr-FR",
- "fr-LU",
- "hu-HU",
- "it-IT",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "sk-SK",
- "sv-SE",
- ]
- ]
- """
- [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
- """
- reference: NotRequired[str]
- """
- A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
- """
- risk_correlation_id: NotRequired[str]
- """
- The risk correlation ID for an on-session payment using a saved PayPal payment method.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsPix(TypedDict):
- amount_includes_iof: NotRequired[Literal["always", "never"]]
- """
- Determines if the amount includes the IOF tax. Defaults to `never`.
- """
- expires_after_seconds: NotRequired[int]
- """
- The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsRevolutPay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none", "off_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsSamsungPay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
-
- class CreateParamsPaymentMethodOptionsSatispay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
-
- class CreateParamsPaymentMethodOptionsSepaDebit(TypedDict):
- mandate_options: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsSepaDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class CreateParamsPaymentMethodOptionsSepaDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
- """
-
- class CreateParamsPaymentMethodOptionsSofort(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsSwish(TypedDict):
- reference: NotRequired[str]
- """
- The order reference that will be displayed to customers in the Swish application. Defaults to the `id` of the Payment Intent.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccount(TypedDict):
- financial_connections: NotRequired[
- "Session.CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[Literal["automatic", "instant"]]
- """
- Verification method for the intent
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
-
- class CreateParamsPaymentMethodOptionsWechatPay(TypedDict):
- app_id: NotRequired[str]
- """
- The app ID registered with WeChat Pay. Only required when client is ios or android.
- """
- client: Literal["android", "ios", "web"]
- """
- The client type that the end customer will pay from
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPermissions(TypedDict):
- update_shipping_details: NotRequired[
- Literal["client_only", "server_only"]
- ]
- """
- Determines which entity is allowed to update the shipping details.
-
- Default is `client_only`. Stripe Checkout client will automatically update the shipping details. If set to `server_only`, only your server is allowed to update the shipping details.
-
- When set to `server_only`, you must add the onShippingDetailsChange event handler when initializing the Stripe Checkout client and manually update the shipping details from your server using the Stripe API.
- """
-
- class CreateParamsPhoneNumberCollection(TypedDict):
- enabled: bool
- """
- Set to `true` to enable phone number collection.
-
- Can only be set in `payment` and `subscription` mode.
- """
-
- class CreateParamsSavedPaymentMethodOptions(TypedDict):
- allow_redisplay_filters: NotRequired[
- List[Literal["always", "limited", "unspecified"]]
- ]
- """
- Uses the `allow_redisplay` value of each saved payment method to filter the set presented to a returning customer. By default, only saved payment methods with 'allow_redisplay: ‘always' are shown in Checkout.
- """
- payment_method_remove: NotRequired[Literal["disabled", "enabled"]]
- """
- Enable customers to choose if they wish to remove their saved payment methods. Disabled by default.
- """
- payment_method_save: NotRequired[Literal["disabled", "enabled"]]
- """
- Enable customers to choose if they wish to save their payment method for future use. Disabled by default.
- """
-
- class CreateParamsSetupIntentData(TypedDict):
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The Stripe account for which the setup is intended.
- """
-
- class CreateParamsShippingAddressCollection(TypedDict):
- allowed_countries: List[
- Literal[
- "AC",
- "AD",
- "AE",
- "AF",
- "AG",
- "AI",
- "AL",
- "AM",
- "AO",
- "AQ",
- "AR",
- "AT",
- "AU",
- "AW",
- "AX",
- "AZ",
- "BA",
- "BB",
- "BD",
- "BE",
- "BF",
- "BG",
- "BH",
- "BI",
- "BJ",
- "BL",
- "BM",
- "BN",
- "BO",
- "BQ",
- "BR",
- "BS",
- "BT",
- "BV",
- "BW",
- "BY",
- "BZ",
- "CA",
- "CD",
- "CF",
- "CG",
- "CH",
- "CI",
- "CK",
- "CL",
- "CM",
- "CN",
- "CO",
- "CR",
- "CV",
- "CW",
- "CY",
- "CZ",
- "DE",
- "DJ",
- "DK",
- "DM",
- "DO",
- "DZ",
- "EC",
- "EE",
- "EG",
- "EH",
- "ER",
- "ES",
- "ET",
- "FI",
- "FJ",
- "FK",
- "FO",
- "FR",
- "GA",
- "GB",
- "GD",
- "GE",
- "GF",
- "GG",
- "GH",
- "GI",
- "GL",
- "GM",
- "GN",
- "GP",
- "GQ",
- "GR",
- "GS",
- "GT",
- "GU",
- "GW",
- "GY",
- "HK",
- "HN",
- "HR",
- "HT",
- "HU",
- "ID",
- "IE",
- "IL",
- "IM",
- "IN",
- "IO",
- "IQ",
- "IS",
- "IT",
- "JE",
- "JM",
- "JO",
- "JP",
- "KE",
- "KG",
- "KH",
- "KI",
- "KM",
- "KN",
- "KR",
- "KW",
- "KY",
- "KZ",
- "LA",
- "LB",
- "LC",
- "LI",
- "LK",
- "LR",
- "LS",
- "LT",
- "LU",
- "LV",
- "LY",
- "MA",
- "MC",
- "MD",
- "ME",
- "MF",
- "MG",
- "MK",
- "ML",
- "MM",
- "MN",
- "MO",
- "MQ",
- "MR",
- "MS",
- "MT",
- "MU",
- "MV",
- "MW",
- "MX",
- "MY",
- "MZ",
- "NA",
- "NC",
- "NE",
- "NG",
- "NI",
- "NL",
- "NO",
- "NP",
- "NR",
- "NU",
- "NZ",
- "OM",
- "PA",
- "PE",
- "PF",
- "PG",
- "PH",
- "PK",
- "PL",
- "PM",
- "PN",
- "PR",
- "PS",
- "PT",
- "PY",
- "QA",
- "RE",
- "RO",
- "RS",
- "RU",
- "RW",
- "SA",
- "SB",
- "SC",
- "SD",
- "SE",
- "SG",
- "SH",
- "SI",
- "SJ",
- "SK",
- "SL",
- "SM",
- "SN",
- "SO",
- "SR",
- "SS",
- "ST",
- "SV",
- "SX",
- "SZ",
- "TA",
- "TC",
- "TD",
- "TF",
- "TG",
- "TH",
- "TJ",
- "TK",
- "TL",
- "TM",
- "TN",
- "TO",
- "TR",
- "TT",
- "TV",
- "TW",
- "TZ",
- "UA",
- "UG",
- "US",
- "UY",
- "UZ",
- "VA",
- "VC",
- "VE",
- "VG",
- "VN",
- "VU",
- "WF",
- "WS",
- "XK",
- "YE",
- "YT",
- "ZA",
- "ZM",
- "ZW",
- "ZZ",
- ]
- ]
- """
- An array of two-letter ISO country codes representing which countries Checkout should provide as options for
- shipping locations.
- """
-
- class CreateParamsShippingOption(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the Shipping Rate to use for this shipping option.
- """
- shipping_rate_data: NotRequired[
- "Session.CreateParamsShippingOptionShippingRateData"
- ]
- """
- Parameters to be passed to Shipping Rate creation for this shipping option.
- """
-
- class CreateParamsShippingOptionShippingRateData(TypedDict):
- delivery_estimate: NotRequired[
- "Session.CreateParamsShippingOptionShippingRateDataDeliveryEstimate"
- ]
- """
- The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- display_name: str
- """
- The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- fixed_amount: NotRequired[
- "Session.CreateParamsShippingOptionShippingRateDataFixedAmount"
- ]
- """
- Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
- """
- type: NotRequired[Literal["fixed_amount"]]
- """
- The type of calculation to use on the shipping rate.
- """
-
- class CreateParamsShippingOptionShippingRateDataDeliveryEstimate(
- TypedDict
- ):
- maximum: NotRequired[
- "Session.CreateParamsShippingOptionShippingRateDataDeliveryEstimateMaximum"
- ]
- """
- The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
- """
- minimum: NotRequired[
- "Session.CreateParamsShippingOptionShippingRateDataDeliveryEstimateMinimum"
- ]
- """
- The lower bound of the estimated range. If empty, represents no lower bound.
- """
-
- class CreateParamsShippingOptionShippingRateDataDeliveryEstimateMaximum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class CreateParamsShippingOptionShippingRateDataDeliveryEstimateMinimum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class CreateParamsShippingOptionShippingRateDataFixedAmount(TypedDict):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- currency_options: NotRequired[
- Dict[
- str,
- "Session.CreateParamsShippingOptionShippingRateDataFixedAmountCurrencyOptions",
- ]
- ]
- """
- Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class CreateParamsShippingOptionShippingRateDataFixedAmountCurrencyOptions(
- TypedDict,
- ):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
-
- class CreateParamsSubscriptionData(TypedDict):
- application_fee_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. To use an application fee percent, the request must be made on behalf of another account, using the `Stripe-Account` header or an OAuth key. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- billing_cycle_anchor: NotRequired[int]
- """
- A future timestamp to anchor the subscription's billing cycle for new subscriptions.
- """
- billing_mode: NotRequired[
- "Session.CreateParamsSubscriptionDataBillingMode"
- ]
- """
- Controls how prorations and invoices for subscriptions are calculated and orchestrated.
- """
- default_tax_rates: NotRequired[List[str]]
- """
- The tax rates that will apply to any subscription item that does not have
- `tax_rates` set. Invoices created will have their `default_tax_rates` populated
- from the subscription.
- """
- description: NotRequired[str]
- """
- The subscription's description, meant to be displayable to the customer.
- Use this field to optionally store an explanation of the subscription
- for rendering in the [customer portal](https://stripe.com/docs/customer-management).
- """
- invoice_settings: NotRequired[
- "Session.CreateParamsSubscriptionDataInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The account on behalf of which to charge, for each of the subscription's invoices.
- """
- proration_behavior: NotRequired[Literal["create_prorations", "none"]]
- """
- Determines how to handle prorations resulting from the `billing_cycle_anchor`. If no value is passed, the default is `create_prorations`.
- """
- transfer_data: NotRequired[
- "Session.CreateParamsSubscriptionDataTransferData"
- ]
- """
- If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges.
- """
- trial_end: NotRequired[int]
- """
- Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. Has to be at least 48 hours in the future.
- """
- trial_period_days: NotRequired[int]
- """
- Integer representing the number of trial period days before the customer is charged for the first time. Has to be at least 1.
- """
- trial_settings: NotRequired[
- "Session.CreateParamsSubscriptionDataTrialSettings"
- ]
- """
- Settings related to subscription trials.
- """
-
- class CreateParamsSubscriptionDataBillingMode(TypedDict):
- flexible: NotRequired[
- "Session.CreateParamsSubscriptionDataBillingModeFlexible"
- ]
- """
- Configure behavior for flexible billing mode.
- """
- type: Literal["classic", "flexible"]
- """
- Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
- """
-
- class CreateParamsSubscriptionDataBillingModeFlexible(TypedDict):
- proration_discounts: NotRequired[Literal["included", "itemized"]]
- """
- Controls how invoices and invoice items display proration amounts and discount amounts.
- """
-
- class CreateParamsSubscriptionDataInvoiceSettings(TypedDict):
- issuer: NotRequired[
- "Session.CreateParamsSubscriptionDataInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class CreateParamsSubscriptionDataInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsSubscriptionDataTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class CreateParamsSubscriptionDataTrialSettings(TypedDict):
- end_behavior: (
- "Session.CreateParamsSubscriptionDataTrialSettingsEndBehavior"
- )
- """
- Defines how the subscription should behave when the user's free trial ends.
- """
-
- class CreateParamsSubscriptionDataTrialSettingsEndBehavior(TypedDict):
- missing_payment_method: Literal["cancel", "create_invoice", "pause"]
- """
- Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
- """
-
- class CreateParamsTaxIdCollection(TypedDict):
- enabled: bool
- """
- Enable tax ID collection during checkout. Defaults to `false`.
- """
- required: NotRequired[Literal["if_supported", "never"]]
- """
- Describes whether a tax ID is required during checkout. Defaults to `never`.
- """
-
- class CreateParamsWalletOptions(TypedDict):
- link: NotRequired["Session.CreateParamsWalletOptionsLink"]
- """
- contains details about the Link wallet options.
- """
-
- class CreateParamsWalletOptionsLink(TypedDict):
- display: NotRequired[Literal["auto", "never"]]
- """
- Specifies whether Checkout should display Link as a payment option. By default, Checkout will display all the supported wallets that the Checkout Session was created with. This is the `auto` behavior, and it is the default choice.
- """
-
- class ExpireParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListLineItemsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["Session.ListParamsCreated|int"]
- """
- Only return Checkout Sessions that were created during the given date interval.
- """
- customer: NotRequired[str]
- """
- Only return the Checkout Sessions for the Customer specified.
- """
- customer_details: NotRequired["Session.ListParamsCustomerDetails"]
- """
- Only return the Checkout Sessions for the Customer details specified.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payment_intent: NotRequired[str]
- """
- Only return the Checkout Session for the PaymentIntent specified.
- """
- payment_link: NotRequired[str]
- """
- Only return the Checkout Sessions for the Payment Link specified.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["complete", "expired", "open"]]
- """
- Only return the Checkout Sessions matching the given status.
- """
- subscription: NotRequired[str]
- """
- Only return the Checkout Session for the subscription specified.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsCustomerDetails(TypedDict):
- email: str
- """
- Customer's email address.
- """
-
- class ModifyParams(RequestOptions):
- collected_information: NotRequired[
- "Session.ModifyParamsCollectedInformation"
- ]
- """
- Information about the customer collected within the Checkout Session. Can only be set when updating `embedded` or `custom` sessions.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- shipping_options: NotRequired[
- "Literal['']|List[Session.ModifyParamsShippingOption]"
- ]
- """
- The shipping rate options to apply to this Session. Up to a maximum of 5.
- """
-
- class ModifyParamsCollectedInformation(TypedDict):
- shipping_details: NotRequired[
- "Session.ModifyParamsCollectedInformationShippingDetails"
- ]
- """
- The shipping details to apply to this Session.
- """
-
- class ModifyParamsCollectedInformationShippingDetails(TypedDict):
- address: (
- "Session.ModifyParamsCollectedInformationShippingDetailsAddress"
- )
- """
- The address of the customer
- """
- name: str
- """
- The name of customer
- """
-
- class ModifyParamsCollectedInformationShippingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ModifyParamsShippingOption(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the Shipping Rate to use for this shipping option.
- """
- shipping_rate_data: NotRequired[
- "Session.ModifyParamsShippingOptionShippingRateData"
- ]
- """
- Parameters to be passed to Shipping Rate creation for this shipping option.
- """
-
- class ModifyParamsShippingOptionShippingRateData(TypedDict):
- delivery_estimate: NotRequired[
- "Session.ModifyParamsShippingOptionShippingRateDataDeliveryEstimate"
- ]
- """
- The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- display_name: str
- """
- The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- fixed_amount: NotRequired[
- "Session.ModifyParamsShippingOptionShippingRateDataFixedAmount"
- ]
- """
- Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
- """
- type: NotRequired[Literal["fixed_amount"]]
- """
- The type of calculation to use on the shipping rate.
- """
-
- class ModifyParamsShippingOptionShippingRateDataDeliveryEstimate(
- TypedDict
- ):
- maximum: NotRequired[
- "Session.ModifyParamsShippingOptionShippingRateDataDeliveryEstimateMaximum"
- ]
- """
- The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
- """
- minimum: NotRequired[
- "Session.ModifyParamsShippingOptionShippingRateDataDeliveryEstimateMinimum"
- ]
- """
- The lower bound of the estimated range. If empty, represents no lower bound.
- """
-
- class ModifyParamsShippingOptionShippingRateDataDeliveryEstimateMaximum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class ModifyParamsShippingOptionShippingRateDataDeliveryEstimateMinimum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class ModifyParamsShippingOptionShippingRateDataFixedAmount(TypedDict):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- currency_options: NotRequired[
- Dict[
- str,
- "Session.ModifyParamsShippingOptionShippingRateDataFixedAmountCurrencyOptions",
- ]
- ]
- """
- Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class ModifyParamsShippingOptionShippingRateDataFixedAmountCurrencyOptions(
- TypedDict,
- ):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
adaptive_pricing: Optional[AdaptivePricing]
"""
Settings for price localization with [Adaptive Pricing](https://docs.stripe.com/payments/checkout/adaptive-pricing).
@@ -5446,7 +2371,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["Session.CreateParams"]) -> "Session":
+ def create(cls, **params: Unpack["SessionCreateParams"]) -> "Session":
"""
Creates a Checkout Session object.
"""
@@ -5461,7 +2386,7 @@ def create(cls, **params: Unpack["Session.CreateParams"]) -> "Session":
@classmethod
async def create_async(
- cls, **params: Unpack["Session.CreateParams"]
+ cls, **params: Unpack["SessionCreateParams"]
) -> "Session":
"""
Creates a Checkout Session object.
@@ -5477,7 +2402,7 @@ async def create_async(
@classmethod
def _cls_expire(
- cls, session: str, **params: Unpack["Session.ExpireParams"]
+ cls, session: str, **params: Unpack["SessionExpireParams"]
) -> "Session":
"""
A Checkout Session can be expired when it is in one of these statuses: open
@@ -5498,7 +2423,7 @@ def _cls_expire(
@overload
@staticmethod
def expire(
- session: str, **params: Unpack["Session.ExpireParams"]
+ session: str, **params: Unpack["SessionExpireParams"]
) -> "Session":
"""
A Checkout Session can be expired when it is in one of these statuses: open
@@ -5508,7 +2433,7 @@ def expire(
...
@overload
- def expire(self, **params: Unpack["Session.ExpireParams"]) -> "Session":
+ def expire(self, **params: Unpack["SessionExpireParams"]) -> "Session":
"""
A Checkout Session can be expired when it is in one of these statuses: open
@@ -5518,7 +2443,7 @@ def expire(self, **params: Unpack["Session.ExpireParams"]) -> "Session":
@class_method_variant("_cls_expire")
def expire( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Session.ExpireParams"]
+ self, **params: Unpack["SessionExpireParams"]
) -> "Session":
"""
A Checkout Session can be expired when it is in one of these statuses: open
@@ -5538,7 +2463,7 @@ def expire( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_expire_async(
- cls, session: str, **params: Unpack["Session.ExpireParams"]
+ cls, session: str, **params: Unpack["SessionExpireParams"]
) -> "Session":
"""
A Checkout Session can be expired when it is in one of these statuses: open
@@ -5559,7 +2484,7 @@ async def _cls_expire_async(
@overload
@staticmethod
async def expire_async(
- session: str, **params: Unpack["Session.ExpireParams"]
+ session: str, **params: Unpack["SessionExpireParams"]
) -> "Session":
"""
A Checkout Session can be expired when it is in one of these statuses: open
@@ -5570,7 +2495,7 @@ async def expire_async(
@overload
async def expire_async(
- self, **params: Unpack["Session.ExpireParams"]
+ self, **params: Unpack["SessionExpireParams"]
) -> "Session":
"""
A Checkout Session can be expired when it is in one of these statuses: open
@@ -5581,7 +2506,7 @@ async def expire_async(
@class_method_variant("_cls_expire_async")
async def expire_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Session.ExpireParams"]
+ self, **params: Unpack["SessionExpireParams"]
) -> "Session":
"""
A Checkout Session can be expired when it is in one of these statuses: open
@@ -5601,7 +2526,7 @@ async def expire_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["Session.ListParams"]
+ cls, **params: Unpack["SessionListParams"]
) -> ListObject["Session"]:
"""
Returns a list of Checkout Sessions.
@@ -5621,7 +2546,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Session.ListParams"]
+ cls, **params: Unpack["SessionListParams"]
) -> ListObject["Session"]:
"""
Returns a list of Checkout Sessions.
@@ -5641,7 +2566,7 @@ async def list_async(
@classmethod
def _cls_list_line_items(
- cls, session: str, **params: Unpack["Session.ListLineItemsParams"]
+ 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.
@@ -5660,7 +2585,7 @@ def _cls_list_line_items(
@overload
@staticmethod
def list_line_items(
- session: str, **params: Unpack["Session.ListLineItemsParams"]
+ 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.
@@ -5669,7 +2594,7 @@ def list_line_items(
@overload
def list_line_items(
- self, **params: Unpack["Session.ListLineItemsParams"]
+ self, **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.
@@ -5678,7 +2603,7 @@ def list_line_items(
@class_method_variant("_cls_list_line_items")
def list_line_items( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Session.ListLineItemsParams"]
+ self, **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.
@@ -5696,7 +2621,7 @@ def list_line_items( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_list_line_items_async(
- cls, session: str, **params: Unpack["Session.ListLineItemsParams"]
+ 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.
@@ -5715,7 +2640,7 @@ async def _cls_list_line_items_async(
@overload
@staticmethod
async def list_line_items_async(
- session: str, **params: Unpack["Session.ListLineItemsParams"]
+ 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.
@@ -5724,7 +2649,7 @@ async def list_line_items_async(
@overload
async def list_line_items_async(
- self, **params: Unpack["Session.ListLineItemsParams"]
+ self, **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.
@@ -5733,7 +2658,7 @@ async def list_line_items_async(
@class_method_variant("_cls_list_line_items_async")
async def list_line_items_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Session.ListLineItemsParams"]
+ self, **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.
@@ -5751,7 +2676,7 @@ async def list_line_items_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def modify(
- cls, id: str, **params: Unpack["Session.ModifyParams"]
+ cls, id: str, **params: Unpack["SessionModifyParams"]
) -> "Session":
"""
Updates a Checkout Session object.
@@ -5770,7 +2695,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Session.ModifyParams"]
+ cls, id: str, **params: Unpack["SessionModifyParams"]
) -> "Session":
"""
Updates a Checkout Session object.
@@ -5789,7 +2714,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Session.RetrieveParams"]
+ cls, id: str, **params: Unpack["SessionRetrieveParams"]
) -> "Session":
"""
Retrieves a Checkout Session object.
@@ -5800,7 +2725,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Session.RetrieveParams"]
+ cls, id: str, **params: Unpack["SessionRetrieveParams"]
) -> "Session":
"""
Retrieves a Checkout Session object.
diff --git a/stripe/checkout/_session_line_item_service.py b/stripe/checkout/_session_line_item_service.py
index c4187f35f..25862b64b 100644
--- a/stripe/checkout/_session_line_item_service.py
+++ b/stripe/checkout/_session_line_item_service.py
@@ -5,33 +5,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.checkout._session_line_item_list_params import (
+ SessionLineItemListParams,
+ )
-class SessionLineItemService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
+class SessionLineItemService(StripeService):
def list(
self,
session: str,
- params: Optional["SessionLineItemService.ListParams"] = None,
+ params: Optional["SessionLineItemListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[LineItem]:
"""
@@ -53,7 +40,7 @@ def list(
async def list_async(
self,
session: str,
- params: Optional["SessionLineItemService.ListParams"] = None,
+ 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 0abc0f8f3..844022bbc 100644
--- a/stripe/checkout/_session_service.py
+++ b/stripe/checkout/_session_service.py
@@ -6,8 +6,23 @@
from stripe._util import sanitize_id
from stripe.checkout._session import Session
from stripe.checkout._session_line_item_service import SessionLineItemService
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.checkout._session_create_params import (
+ SessionCreateParams,
+ )
+ from stripe.params.checkout._session_expire_params import (
+ SessionExpireParams,
+ )
+ from stripe.params.checkout._session_list_params import SessionListParams
+ from stripe.params.checkout._session_retrieve_params import (
+ SessionRetrieveParams,
+ )
+ from stripe.params.checkout._session_update_params import (
+ SessionUpdateParams,
+ )
class SessionService(StripeService):
@@ -15,3147 +30,9 @@ def __init__(self, requestor):
super().__init__(requestor)
self.line_items = SessionLineItemService(self._requestor)
- class CreateParams(TypedDict):
- adaptive_pricing: NotRequired[
- "SessionService.CreateParamsAdaptivePricing"
- ]
- """
- Settings for price localization with [Adaptive Pricing](https://docs.stripe.com/payments/checkout/adaptive-pricing).
- """
- after_expiration: NotRequired[
- "SessionService.CreateParamsAfterExpiration"
- ]
- """
- Configure actions after a Checkout Session has expired.
- """
- allow_promotion_codes: NotRequired[bool]
- """
- Enables user redeemable promotion codes.
- """
- automatic_tax: NotRequired["SessionService.CreateParamsAutomaticTax"]
- """
- Settings for automatic tax lookup for this session and resulting payments, invoices, and subscriptions.
- """
- billing_address_collection: NotRequired[Literal["auto", "required"]]
- """
- Specify whether Checkout should collect the customer's billing address. Defaults to `auto`.
- """
- branding_settings: NotRequired[
- "SessionService.CreateParamsBrandingSettings"
- ]
- """
- The branding settings for the Checkout Session. This parameter is not allowed if ui_mode is `custom`.
- """
- cancel_url: NotRequired[str]
- """
- If set, Checkout displays a back button and customers will be directed to this URL if they decide to cancel payment and return to your website. This parameter is not allowed if ui_mode is `embedded` or `custom`.
- """
- client_reference_id: NotRequired[str]
- """
- A unique string to reference the Checkout Session. This can be a
- customer ID, a cart ID, or similar, and can be used to reconcile the
- session with your internal systems.
- """
- consent_collection: NotRequired[
- "SessionService.CreateParamsConsentCollection"
- ]
- """
- Configure fields for the Checkout Session to gather active consent from customers.
- """
- currency: NotRequired[str]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Required in `setup` mode when `payment_method_types` is not set.
- """
- custom_fields: NotRequired[
- List["SessionService.CreateParamsCustomField"]
- ]
- """
- Collect additional information from your customer using custom fields. Up to 3 fields are supported.
- """
- custom_text: NotRequired["SessionService.CreateParamsCustomText"]
- """
- Display additional text for your customers using custom text.
- """
- customer: NotRequired[str]
- """
- ID of an existing Customer, if one exists. In `payment` mode, the customer's most recently saved card
- payment method will be used to prefill the email, name, card details, and billing address
- on the Checkout page. In `subscription` mode, the customer's [default payment method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method)
- will be used if it's a card, otherwise the most recently saved card will be used. A valid billing address, billing name and billing email are required on the payment method for Checkout to prefill the customer's card details.
-
- If the Customer already has a valid [email](https://stripe.com/docs/api/customers/object#customer_object-email) set, the email will be prefilled and not editable in Checkout.
- If the Customer does not have a valid `email`, Checkout will set the email entered during the session on the Customer.
-
- If blank for Checkout Sessions in `subscription` mode or with `customer_creation` set as `always` in `payment` mode, Checkout will create a new Customer object based on information provided during the payment flow.
-
- You can set [`payment_intent_data.setup_future_usage`](https://stripe.com/docs/api/checkout/sessions/create#create_checkout_session-payment_intent_data-setup_future_usage) to have Checkout automatically attach the payment method to the Customer you pass in for future reuse.
- """
- customer_creation: NotRequired[Literal["always", "if_required"]]
- """
- Configure whether a Checkout Session creates a [Customer](https://stripe.com/docs/api/customers) during Session confirmation.
-
- When a Customer is not created, you can still retrieve email, address, and other customer data entered in Checkout
- with [customer_details](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-customer_details).
-
- Sessions that don't create Customers instead are grouped by [guest customers](https://stripe.com/docs/payments/checkout/guest-customers)
- in the Dashboard. Promotion codes limited to first time customers will return invalid for these Sessions.
-
- Can only be set in `payment` and `setup` mode.
- """
- customer_email: NotRequired[str]
- """
- If provided, this value will be used when the Customer object is created.
- If not provided, customers will be asked to enter their email address.
- Use this parameter to prefill customer data if you already have an email
- on file. To access information about the customer once a session is
- complete, use the `customer` field.
- """
- customer_update: NotRequired[
- "SessionService.CreateParamsCustomerUpdate"
- ]
- """
- Controls what fields on Customer can be updated by the Checkout Session. Can only be provided when `customer` is provided.
- """
- discounts: NotRequired[List["SessionService.CreateParamsDiscount"]]
- """
- The coupon or promotion code to apply to this Session. Currently, only up to one may be specified.
- """
- excluded_payment_method_types: NotRequired[
- List[
- Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "card",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- ]
- ]
- """
- A list of the types of payment methods (e.g., `card`) that should be excluded from this Checkout Session. This should only be used when payment methods for this Checkout Session are managed through the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- The Epoch time in seconds at which the Checkout Session will expire. It can be anywhere from 30 minutes to 24 hours after Checkout Session creation. By default, this value is 24 hours from creation.
- """
- invoice_creation: NotRequired[
- "SessionService.CreateParamsInvoiceCreation"
- ]
- """
- Generate a post-purchase Invoice for one-time payments.
- """
- line_items: NotRequired[List["SessionService.CreateParamsLineItem"]]
- """
- A list of items the customer is purchasing. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices). The parameter is required for `payment` and `subscription` mode.
-
- For `payment` mode, there is a maximum of 100 line items, however it is recommended to consolidate line items if there are more than a few dozen.
-
- For `subscription` mode, there is a maximum of 20 line items with recurring Prices and 20 line items with one-time Prices. Line items with one-time Prices will be on the initial invoice only.
- """
- locale: NotRequired[
- Literal[
- "auto",
- "bg",
- "cs",
- "da",
- "de",
- "el",
- "en",
- "en-GB",
- "es",
- "es-419",
- "et",
- "fi",
- "fil",
- "fr",
- "fr-CA",
- "hr",
- "hu",
- "id",
- "it",
- "ja",
- "ko",
- "lt",
- "lv",
- "ms",
- "mt",
- "nb",
- "nl",
- "pl",
- "pt",
- "pt-BR",
- "ro",
- "ru",
- "sk",
- "sl",
- "sv",
- "th",
- "tr",
- "vi",
- "zh",
- "zh-HK",
- "zh-TW",
- ]
- ]
- """
- The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mode: NotRequired[Literal["payment", "setup", "subscription"]]
- """
- The mode of the Checkout Session. Pass `subscription` if the Checkout Session includes at least one recurring item.
- """
- name_collection: NotRequired[
- "SessionService.CreateParamsNameCollection"
- ]
- """
- Controls name collection settings for the session.
-
- You can configure Checkout to collect your customers' business names, individual names, or both. Each name field can be either required or optional.
-
- If a [Customer](https://stripe.com/docs/api/customers) is created or provided, the names can be saved to the Customer object as well.
- """
- optional_items: NotRequired[
- List["SessionService.CreateParamsOptionalItem"]
- ]
- """
- A list of optional items the customer can add to their order at checkout. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices).
-
- There is a maximum of 10 optional items allowed on a Checkout Session, and the existing limits on the number of line items allowed on a Checkout Session apply to the combined number of line items and optional items.
-
- For `payment` mode, there is a maximum of 100 combined line items and optional items, however it is recommended to consolidate items if there are more than a few dozen.
-
- For `subscription` mode, there is a maximum of 20 line items and optional items with recurring Prices and 20 line items and optional items with one-time Prices.
- """
- origin_context: NotRequired[Literal["mobile_app", "web"]]
- """
- Where the user is coming from. This informs the optimizations that are applied to the session.
- """
- payment_intent_data: NotRequired[
- "SessionService.CreateParamsPaymentIntentData"
- ]
- """
- A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
- """
- payment_method_collection: NotRequired[
- Literal["always", "if_required"]
- ]
- """
- Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.
- This may occur if the Checkout Session includes a free trial or a discount.
-
- Can only be set in `subscription` mode. Defaults to `always`.
-
- 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_configuration: NotRequired[str]
- """
- The ID of the payment method configuration to use with this Checkout session.
- """
- payment_method_data: NotRequired[
- "SessionService.CreateParamsPaymentMethodData"
- ]
- """
- This parameter allows you to set some attributes on the payment method created during a Checkout session.
- """
- payment_method_options: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptions"
- ]
- """
- Payment-method-specific configuration.
- """
- payment_method_types: NotRequired[
- List[
- Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "card",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- ]
- ]
- """
- A list of the types of payment methods (e.g., `card`) this Checkout Session can accept.
-
- You can omit this attribute to manage your payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
- See [Dynamic Payment Methods](https://stripe.com/docs/payments/payment-methods/integration-options#using-dynamic-payment-methods) for more details.
-
- Read more about the supported payment methods and their requirements in our [payment
- method details guide](https://docs.stripe.com/docs/payments/checkout/payment-methods).
-
- If multiple payment methods are passed, Checkout will dynamically reorder them to
- prioritize the most relevant payment methods based on the customer's location and
- other characteristics.
- """
- permissions: NotRequired["SessionService.CreateParamsPermissions"]
- """
- This property is used to set up permissions for various actions (e.g., update) on the CheckoutSession object. Can only be set when creating `embedded` or `custom` sessions.
-
- For specific permissions, please refer to their dedicated subsections, such as `permissions.update_shipping_details`.
- """
- phone_number_collection: NotRequired[
- "SessionService.CreateParamsPhoneNumberCollection"
- ]
- """
- Controls phone number collection settings for the session.
-
- We recommend that you review your privacy policy and check with your legal contacts
- before using this feature. Learn more about [collecting phone numbers with Checkout](https://stripe.com/docs/payments/checkout/phone-numbers).
- """
- redirect_on_completion: NotRequired[
- Literal["always", "if_required", "never"]
- ]
- """
- This parameter applies to `ui_mode: embedded`. Learn more about the [redirect behavior](https://stripe.com/docs/payments/checkout/custom-success-page?payment-ui=embedded-form) of embedded sessions. Defaults to `always`.
- """
- return_url: NotRequired[str]
- """
- The URL to redirect your customer back to after they authenticate or cancel their payment on the
- payment method's app or site. This parameter is required if `ui_mode` is `embedded` or `custom`
- and redirect-based payment methods are enabled on the session.
- """
- saved_payment_method_options: NotRequired[
- "SessionService.CreateParamsSavedPaymentMethodOptions"
- ]
- """
- Controls saved payment method settings for the session. Only available in `payment` and `subscription` mode.
- """
- setup_intent_data: NotRequired[
- "SessionService.CreateParamsSetupIntentData"
- ]
- """
- A subset of parameters to be passed to SetupIntent creation for Checkout Sessions in `setup` mode.
- """
- shipping_address_collection: NotRequired[
- "SessionService.CreateParamsShippingAddressCollection"
- ]
- """
- When set, provides configuration for Checkout to collect a shipping address from a customer.
- """
- shipping_options: NotRequired[
- List["SessionService.CreateParamsShippingOption"]
- ]
- """
- The shipping rate options to apply to this Session. Up to a maximum of 5.
- """
- submit_type: NotRequired[
- Literal["auto", "book", "donate", "pay", "subscribe"]
- ]
- """
- Describes the type of transaction being performed by Checkout in order
- to customize relevant text on the page, such as the submit button.
- `submit_type` can only be specified on Checkout Sessions in
- `payment` or `subscription` mode. If blank or `auto`, `pay` is used.
- """
- subscription_data: NotRequired[
- "SessionService.CreateParamsSubscriptionData"
- ]
- """
- A subset of parameters to be passed to subscription creation for Checkout Sessions in `subscription` mode.
- """
- success_url: NotRequired[str]
- """
- The URL to which Stripe should send customers when payment or setup
- is complete.
- This parameter is not allowed if ui_mode is `embedded` or `custom`. If you'd like to use
- information from the successful Checkout Session on your page, read the
- guide on [customizing your success page](https://stripe.com/docs/payments/checkout/custom-success-page).
- """
- tax_id_collection: NotRequired[
- "SessionService.CreateParamsTaxIdCollection"
- ]
- """
- Controls tax ID collection during checkout.
- """
- ui_mode: NotRequired[Literal["custom", "embedded", "hosted"]]
- """
- The UI mode of the Session. Defaults to `hosted`.
- """
- wallet_options: NotRequired["SessionService.CreateParamsWalletOptions"]
- """
- Wallet-specific configuration.
- """
-
- class CreateParamsAdaptivePricing(TypedDict):
- enabled: NotRequired[bool]
- """
- If set to `true`, Adaptive Pricing is available on [eligible sessions](https://docs.stripe.com/payments/currencies/localize-prices/adaptive-pricing?payment-ui=stripe-hosted#restrictions). Defaults to your [dashboard setting](https://dashboard.stripe.com/settings/adaptive-pricing).
- """
-
- class CreateParamsAfterExpiration(TypedDict):
- recovery: NotRequired[
- "SessionService.CreateParamsAfterExpirationRecovery"
- ]
- """
- Configure a Checkout Session that can be used to recover an expired session.
- """
-
- class CreateParamsAfterExpirationRecovery(TypedDict):
- allow_promotion_codes: NotRequired[bool]
- """
- Enables user redeemable promotion codes on the recovered Checkout Sessions. Defaults to `false`
- """
- enabled: bool
- """
- If `true`, a recovery URL will be generated to recover this Checkout Session if it
- expires before a successful transaction is completed. It will be attached to the
- Checkout Session object upon expiration.
- """
-
- class CreateParamsAutomaticTax(TypedDict):
- enabled: bool
- """
- Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
-
- Enabling this parameter causes Checkout to collect any billing address information necessary for tax calculation.
- """
- liability: NotRequired[
- "SessionService.CreateParamsAutomaticTaxLiability"
- ]
- """
- The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
- """
-
- class CreateParamsAutomaticTaxLiability(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsBrandingSettings(TypedDict):
- background_color: NotRequired["Literal['']|str"]
- """
- A hex color value starting with `#` representing the background color for the Checkout Session.
- """
- border_style: NotRequired[
- "Literal['']|Literal['pill', 'rectangular', 'rounded']"
- ]
- """
- The border style for the Checkout Session.
- """
- button_color: NotRequired["Literal['']|str"]
- """
- A hex color value starting with `#` representing the button color for the Checkout Session.
- """
- display_name: NotRequired[str]
- """
- A string to override the business name shown on the Checkout Session.
- """
- font_family: NotRequired[
- "Literal['']|Literal['be_vietnam_pro', 'bitter', 'chakra_petch', 'default', 'hahmlet', 'inconsolata', 'inter', 'lato', 'lora', 'm_plus_1_code', 'montserrat', 'noto_sans', 'noto_sans_jp', 'noto_serif', 'nunito', 'open_sans', 'pridi', 'pt_sans', 'pt_serif', 'raleway', 'roboto', 'roboto_slab', 'source_sans_pro', 'titillium_web', 'ubuntu_mono', 'zen_maru_gothic']"
- ]
- """
- The font family for the Checkout Session corresponding to one of the [supported font families](https://docs.stripe.com/payments/checkout/customization/appearance?payment-ui=stripe-hosted#font-compatibility).
- """
- icon: NotRequired["SessionService.CreateParamsBrandingSettingsIcon"]
- """
- The icon for the Checkout Session. You cannot set both `logo` and `icon`.
- """
- logo: NotRequired["SessionService.CreateParamsBrandingSettingsLogo"]
- """
- The logo for the Checkout Session. You cannot set both `logo` and `icon`.
- """
-
- class CreateParamsBrandingSettingsIcon(TypedDict):
- file: NotRequired[str]
- """
- The ID of a [File upload](https://stripe.com/docs/api/files) representing the icon. Purpose must be `business_icon`. Required if `type` is `file` and disallowed otherwise.
- """
- type: Literal["file", "url"]
- """
- The type of image for the icon. Must be one of `file` or `url`.
- """
- url: NotRequired[str]
- """
- The URL of the image. Required if `type` is `url` and disallowed otherwise.
- """
-
- class CreateParamsBrandingSettingsLogo(TypedDict):
- file: NotRequired[str]
- """
- The ID of a [File upload](https://stripe.com/docs/api/files) representing the logo. Purpose must be `business_logo`. Required if `type` is `file` and disallowed otherwise.
- """
- type: Literal["file", "url"]
- """
- The type of image for the logo. Must be one of `file` or `url`.
- """
- url: NotRequired[str]
- """
- The URL of the image. Required if `type` is `url` and disallowed otherwise.
- """
-
- class CreateParamsConsentCollection(TypedDict):
- payment_method_reuse_agreement: NotRequired[
- "SessionService.CreateParamsConsentCollectionPaymentMethodReuseAgreement"
- ]
- """
- Determines the display of payment method reuse agreement text in the UI. If set to `hidden`, it will hide legal text related to the reuse of a payment method.
- """
- promotions: NotRequired[Literal["auto", "none"]]
- """
- If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
- Session will determine whether to display an option to opt into promotional communication
- from the merchant depending on the customer's locale. Only available to US merchants.
- """
- terms_of_service: NotRequired[Literal["none", "required"]]
- """
- If set to `required`, it requires customers to check a terms of service checkbox before being able to pay.
- There must be a valid terms of service URL set in your [Dashboard settings](https://dashboard.stripe.com/settings/public).
- """
-
- class CreateParamsConsentCollectionPaymentMethodReuseAgreement(TypedDict):
- position: Literal["auto", "hidden"]
- """
- Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's
- defaults will be used. When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
- """
-
- class CreateParamsCustomField(TypedDict):
- dropdown: NotRequired["SessionService.CreateParamsCustomFieldDropdown"]
- """
- Configuration for `type=dropdown` fields.
- """
- key: str
- """
- String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
- """
- label: "SessionService.CreateParamsCustomFieldLabel"
- """
- The label for the field, displayed to the customer.
- """
- numeric: NotRequired["SessionService.CreateParamsCustomFieldNumeric"]
- """
- Configuration for `type=numeric` fields.
- """
- optional: NotRequired[bool]
- """
- Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
- """
- text: NotRequired["SessionService.CreateParamsCustomFieldText"]
- """
- Configuration for `type=text` fields.
- """
- type: Literal["dropdown", "numeric", "text"]
- """
- The type of the field.
- """
-
- class CreateParamsCustomFieldDropdown(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
- """
- options: List["SessionService.CreateParamsCustomFieldDropdownOption"]
- """
- The options available for the customer to select. Up to 200 options allowed.
- """
-
- class CreateParamsCustomFieldDropdownOption(TypedDict):
- label: str
- """
- The label for the option, displayed to the customer. Up to 100 characters.
- """
- value: str
- """
- The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
- """
-
- class CreateParamsCustomFieldLabel(TypedDict):
- custom: str
- """
- Custom text for the label, displayed to the customer. Up to 50 characters.
- """
- type: Literal["custom"]
- """
- The type of the label.
- """
-
- class CreateParamsCustomFieldNumeric(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.
- """
- maximum_length: NotRequired[int]
- """
- The maximum character length constraint for the customer's input.
- """
- minimum_length: NotRequired[int]
- """
- The minimum character length requirement for the customer's input.
- """
-
- class CreateParamsCustomFieldText(TypedDict):
- default_value: NotRequired[str]
- """
- The value that will pre-fill the field on the payment page.
- """
- maximum_length: NotRequired[int]
- """
- The maximum character length constraint for the customer's input.
- """
- minimum_length: NotRequired[int]
- """
- The minimum character length requirement for the customer's input.
- """
-
- class CreateParamsCustomText(TypedDict):
- after_submit: NotRequired[
- "Literal['']|SessionService.CreateParamsCustomTextAfterSubmit"
- ]
- """
- Custom text that should be displayed after the payment confirmation button.
- """
- shipping_address: NotRequired[
- "Literal['']|SessionService.CreateParamsCustomTextShippingAddress"
- ]
- """
- Custom text that should be displayed alongside shipping address collection.
- """
- submit: NotRequired[
- "Literal['']|SessionService.CreateParamsCustomTextSubmit"
- ]
- """
- Custom text that should be displayed alongside the payment confirmation button.
- """
- terms_of_service_acceptance: NotRequired[
- "Literal['']|SessionService.CreateParamsCustomTextTermsOfServiceAcceptance"
- ]
- """
- Custom text that should be displayed in place of the default terms of service agreement text.
- """
-
- class CreateParamsCustomTextAfterSubmit(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsCustomTextShippingAddress(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsCustomTextSubmit(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsCustomTextTermsOfServiceAcceptance(TypedDict):
- message: str
- """
- Text may be up to 1200 characters in length.
- """
-
- class CreateParamsCustomerUpdate(TypedDict):
- address: NotRequired[Literal["auto", "never"]]
- """
- Describes whether Checkout saves the billing address onto `customer.address`.
- To always collect a full billing address, use `billing_address_collection`. Defaults to `never`.
- """
- name: NotRequired[Literal["auto", "never"]]
- """
- Describes whether Checkout saves the name onto `customer.name`. Defaults to `never`.
- """
- shipping: NotRequired[Literal["auto", "never"]]
- """
- Describes whether Checkout saves shipping information onto `customer.shipping`.
- To collect shipping information, use `shipping_address_collection`. Defaults to `never`.
- """
-
- class CreateParamsDiscount(TypedDict):
- coupon: NotRequired[str]
- """
- The ID of the coupon to apply to this Session.
- """
- promotion_code: NotRequired[str]
- """
- The ID of a promotion code to apply to this Session.
- """
-
- class CreateParamsInvoiceCreation(TypedDict):
- enabled: bool
- """
- Set to `true` to enable invoice creation.
- """
- invoice_data: NotRequired[
- "SessionService.CreateParamsInvoiceCreationInvoiceData"
- ]
- """
- Parameters passed when creating invoices for payment-mode Checkout Sessions.
- """
-
- class CreateParamsInvoiceCreationInvoiceData(TypedDict):
- account_tax_ids: NotRequired["Literal['']|List[str]"]
- """
- The account tax IDs associated with the invoice.
- """
- custom_fields: NotRequired[
- "Literal['']|List[SessionService.CreateParamsInvoiceCreationInvoiceDataCustomField]"
- ]
- """
- Default custom fields to be displayed on invoices for this customer.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- footer: NotRequired[str]
- """
- Default footer to be displayed on invoices for this customer.
- """
- issuer: NotRequired[
- "SessionService.CreateParamsInvoiceCreationInvoiceDataIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- rendering_options: NotRequired[
- "Literal['']|SessionService.CreateParamsInvoiceCreationInvoiceDataRenderingOptions"
- ]
- """
- Default options for invoice PDF rendering for this customer.
- """
-
- class CreateParamsInvoiceCreationInvoiceDataCustomField(TypedDict):
- name: str
- """
- The name of the custom field. This may be up to 40 characters.
- """
- value: str
- """
- The value of the custom field. This may be up to 140 characters.
- """
-
- class CreateParamsInvoiceCreationInvoiceDataIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsInvoiceCreationInvoiceDataRenderingOptions(TypedDict):
- amount_tax_display: NotRequired[
- "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
- ]
- """
- How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
- """
- template: NotRequired[str]
- """
- ID of the invoice rendering template to use for this invoice.
- """
-
- class CreateParamsLineItem(TypedDict):
- adjustable_quantity: NotRequired[
- "SessionService.CreateParamsLineItemAdjustableQuantity"
- ]
- """
- When set, provides configuration for this item's quantity to be adjusted by the customer during Checkout.
- """
- dynamic_tax_rates: NotRequired[List[str]]
- """
- The [tax rates](https://stripe.com/docs/api/tax_rates) that will be applied to this line item depending on the customer's billing/shipping address. We currently support the following countries: US, GB, AU, and all countries in the EU.
- """
- price: NotRequired[str]
- """
- The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object. One of `price` or `price_data` is required.
- """
- price_data: NotRequired["SessionService.CreateParamsLineItemPriceData"]
- """
- Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
- """
- quantity: NotRequired[int]
- """
- The quantity of the line item being purchased. Quantity should not be defined when `recurring.usage_type=metered`.
- """
- tax_rates: NotRequired[List[str]]
- """
- The [tax rates](https://stripe.com/docs/api/tax_rates) which apply to this line item.
- """
-
- class CreateParamsLineItemAdjustableQuantity(TypedDict):
- enabled: bool
- """
- Set to true if the quantity can be adjusted to any non-negative integer.
- """
- maximum: NotRequired[int]
- """
- The maximum quantity the customer can purchase for the Checkout Session. By default this value is 99. You can specify a value up to 999999.
- """
- minimum: NotRequired[int]
- """
- The minimum quantity the customer must purchase for the Checkout Session. By default this value is 0.
- """
-
- class CreateParamsLineItemPriceData(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- product: NotRequired[str]
- """
- The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
- """
- product_data: NotRequired[
- "SessionService.CreateParamsLineItemPriceDataProductData"
- ]
- """
- Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
- """
- recurring: NotRequired[
- "SessionService.CreateParamsLineItemPriceDataRecurring"
- ]
- """
- The recurring components of a price such as `interval` and `interval_count`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
- """
- unit_amount: NotRequired[int]
- """
- A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
- """
- unit_amount_decimal: NotRequired[str]
- """
- Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
- """
-
- class CreateParamsLineItemPriceDataProductData(TypedDict):
- description: NotRequired[str]
- """
- The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
- """
- images: NotRequired[List[str]]
- """
- A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The product's name, meant to be displayable to the customer.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
- unit_label: NotRequired[str]
- """
- A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
- """
-
- class CreateParamsLineItemPriceDataRecurring(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Specifies billing frequency. Either `day`, `week`, `month` or `year`.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
- """
-
- class CreateParamsNameCollection(TypedDict):
- business: NotRequired[
- "SessionService.CreateParamsNameCollectionBusiness"
- ]
- """
- Controls settings applied for collecting the customer's business name on the session.
- """
- individual: NotRequired[
- "SessionService.CreateParamsNameCollectionIndividual"
- ]
- """
- Controls settings applied for collecting the customer's individual name on the session.
- """
-
- class CreateParamsNameCollectionBusiness(TypedDict):
- enabled: bool
- """
- Enable business name collection on the Checkout Session. Defaults to `false`.
- """
- optional: NotRequired[bool]
- """
- Whether the customer is required to provide a business name before completing the Checkout Session. Defaults to `false`.
- """
-
- class CreateParamsNameCollectionIndividual(TypedDict):
- enabled: bool
- """
- Enable individual name collection on the Checkout Session. Defaults to `false`.
- """
- optional: NotRequired[bool]
- """
- Whether the customer is required to provide their name before completing the Checkout Session. Defaults to `false`.
- """
-
- class CreateParamsOptionalItem(TypedDict):
- adjustable_quantity: NotRequired[
- "SessionService.CreateParamsOptionalItemAdjustableQuantity"
- ]
- """
- When set, provides configuration for the customer to adjust the quantity of the line item created when a customer chooses to add this optional item to their order.
- """
- price: str
- """
- The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object.
- """
- quantity: int
- """
- The initial quantity of the line item created when a customer chooses to add this optional item to their order.
- """
-
- class CreateParamsOptionalItemAdjustableQuantity(TypedDict):
- enabled: bool
- """
- Set to true if the quantity can be adjusted to any non-negative integer.
- """
- maximum: NotRequired[int]
- """
- The maximum quantity of this item the customer can purchase. By default this value is 99. You can specify a value up to 999999.
- """
- minimum: NotRequired[int]
- """
- The minimum quantity of this item the customer must purchase, if they choose to purchase it. Because this item is optional, the customer will always be able to remove it from their order, even if the `minimum` configured here is greater than 0. By default this value is 0.
- """
-
- class CreateParamsPaymentIntentData(TypedDict):
- application_fee_amount: NotRequired[int]
- """
- The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- capture_method: NotRequired[
- Literal["automatic", "automatic_async", "manual"]
- ]
- """
- Controls when the funds will be captured from the customer's account.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The Stripe account ID for which these funds are intended. For details,
- see the PaymentIntents [use case for connected
- accounts](https://docs.stripe.com/docs/payments/connected-accounts).
- """
- receipt_email: NotRequired[str]
- """
- Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
- """
- setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
- """
- Indicates that you intend to [make future payments](https://stripe.com/docs/payments/payment-intents#future-usage) with the payment
- method collected by this Checkout Session.
-
- When setting this to `on_session`, Checkout will show a notice to the
- customer that their payment details will be saved.
-
- When setting this to `off_session`, Checkout will show a notice to the
- customer that their payment details will be saved and used for future
- payments.
-
- If a Customer has been provided or Checkout creates a new Customer,
- Checkout will attach the payment method to the Customer.
-
- If Checkout does not create a Customer, the payment method is not attached
- to a Customer. To reuse the payment method, you can retrieve it from the
- Checkout Session's PaymentIntent.
-
- When processing card payments, Checkout also uses `setup_future_usage`
- to dynamically optimize your payment flow and comply with regional
- legislation and network rules, such as SCA.
- """
- shipping: NotRequired[
- "SessionService.CreateParamsPaymentIntentDataShipping"
- ]
- """
- Shipping information for this payment.
- """
- statement_descriptor: NotRequired[str]
- """
- Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
-
- Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
- """
- statement_descriptor_suffix: NotRequired[str]
- """
- Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
- """
- transfer_data: NotRequired[
- "SessionService.CreateParamsPaymentIntentDataTransferData"
- ]
- """
- The parameters used to automatically create a Transfer when the payment succeeds.
- For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
- """
- transfer_group: NotRequired[str]
- """
- A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
- """
-
- class CreateParamsPaymentIntentDataShipping(TypedDict):
- address: "SessionService.CreateParamsPaymentIntentDataShippingAddress"
- """
- Shipping address.
- """
- carrier: NotRequired[str]
- """
- The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired[str]
- """
- Recipient phone (including extension).
- """
- tracking_number: NotRequired[str]
- """
- The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
- """
-
- class CreateParamsPaymentIntentDataShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsPaymentIntentDataTransferData(TypedDict):
- amount: NotRequired[int]
- """
- The amount that will be transferred automatically when a charge succeeds.
- """
- destination: str
- """
- If specified, successful charges will be attributed to the destination
- account for tax reporting, and the funds from charges will be transferred
- to the destination account. The ID of the resulting transfer will be
- returned on the successful charge's `transfer` field.
- """
-
- class CreateParamsPaymentMethodData(TypedDict):
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- Allow redisplay will be set on the payment method on confirmation and indicates whether this payment method can be shown again to the customer in a checkout flow. Only set this field if you wish to override the allow_redisplay value determined by Checkout.
- """
-
- class CreateParamsPaymentMethodOptions(TypedDict):
- acss_debit: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsAcssDebit"
- ]
- """
- contains details about the ACSS Debit payment method options.
- """
- affirm: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsAffirm"
- ]
- """
- contains details about the Affirm payment method options.
- """
- afterpay_clearpay: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsAfterpayClearpay"
- ]
- """
- contains details about the Afterpay Clearpay payment method options.
- """
- alipay: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsAlipay"
- ]
- """
- contains details about the Alipay payment method options.
- """
- alma: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsAlma"
- ]
- """
- contains details about the Alma payment method options.
- """
- amazon_pay: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsAmazonPay"
- ]
- """
- contains details about the AmazonPay payment method options.
- """
- au_becs_debit: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsAuBecsDebit"
- ]
- """
- contains details about the AU Becs Debit payment method options.
- """
- bacs_debit: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsBacsDebit"
- ]
- """
- contains details about the Bacs Debit payment method options.
- """
- bancontact: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsBancontact"
- ]
- """
- contains details about the Bancontact payment method options.
- """
- billie: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsBillie"
- ]
- """
- contains details about the Billie payment method options.
- """
- boleto: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsBoleto"
- ]
- """
- contains details about the Boleto payment method options.
- """
- card: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsCard"
- ]
- """
- contains details about the Card payment method options.
- """
- cashapp: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsCashapp"
- ]
- """
- contains details about the Cashapp Pay payment method options.
- """
- customer_balance: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsCustomerBalance"
- ]
- """
- contains details about the Customer Balance payment method options.
- """
- demo_pay: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsDemoPay"
- ]
- """
- contains details about the DemoPay payment method options.
- """
- eps: NotRequired["SessionService.CreateParamsPaymentMethodOptionsEps"]
- """
- contains details about the EPS payment method options.
- """
- fpx: NotRequired["SessionService.CreateParamsPaymentMethodOptionsFpx"]
- """
- contains details about the FPX payment method options.
- """
- giropay: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsGiropay"
- ]
- """
- contains details about the Giropay payment method options.
- """
- grabpay: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsGrabpay"
- ]
- """
- contains details about the Grabpay payment method options.
- """
- ideal: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsIdeal"
- ]
- """
- contains details about the Ideal payment method options.
- """
- kakao_pay: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsKakaoPay"
- ]
- """
- contains details about the Kakao Pay payment method options.
- """
- klarna: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsKlarna"
- ]
- """
- contains details about the Klarna payment method options.
- """
- konbini: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsKonbini"
- ]
- """
- contains details about the Konbini payment method options.
- """
- kr_card: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsKrCard"
- ]
- """
- contains details about the Korean card payment method options.
- """
- link: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsLink"
- ]
- """
- contains details about the Link payment method options.
- """
- mobilepay: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsMobilepay"
- ]
- """
- contains details about the Mobilepay payment method options.
- """
- multibanco: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsMultibanco"
- ]
- """
- contains details about the Multibanco payment method options.
- """
- naver_pay: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsNaverPay"
- ]
- """
- contains details about the Naver Pay payment method options.
- """
- oxxo: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsOxxo"
- ]
- """
- contains details about the OXXO payment method options.
- """
- p24: NotRequired["SessionService.CreateParamsPaymentMethodOptionsP24"]
- """
- contains details about the P24 payment method options.
- """
- pay_by_bank: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsPayByBank"
- ]
- """
- contains details about the Pay By Bank payment method options.
- """
- payco: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsPayco"
- ]
- """
- contains details about the PAYCO payment method options.
- """
- paynow: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsPaynow"
- ]
- """
- contains details about the PayNow payment method options.
- """
- paypal: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsPaypal"
- ]
- """
- contains details about the PayPal payment method options.
- """
- pix: NotRequired["SessionService.CreateParamsPaymentMethodOptionsPix"]
- """
- contains details about the Pix payment method options.
- """
- revolut_pay: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsRevolutPay"
- ]
- """
- contains details about the RevolutPay payment method options.
- """
- samsung_pay: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsSamsungPay"
- ]
- """
- contains details about the Samsung Pay payment method options.
- """
- satispay: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsSatispay"
- ]
- """
- contains details about the Satispay payment method options.
- """
- sepa_debit: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsSepaDebit"
- ]
- """
- contains details about the Sepa Debit payment method options.
- """
- sofort: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsSofort"
- ]
- """
- contains details about the Sofort payment method options.
- """
- swish: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsSwish"
- ]
- """
- contains details about the Swish payment method options.
- """
- us_bank_account: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsUsBankAccount"
- ]
- """
- contains details about the Us Bank Account payment method options.
- """
- wechat_pay: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsWechatPay"
- ]
- """
- contains details about the WeChat Pay payment method options.
- """
-
- class CreateParamsPaymentMethodOptionsAcssDebit(TypedDict):
- currency: NotRequired[Literal["cad", "usd"]]
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). This is only accepted for Checkout Sessions in `setup` mode.
- """
- mandate_options: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsAcssDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[
- Literal["automatic", "instant", "microdeposits"]
- ]
- """
- Verification method for the intent
- """
-
- class CreateParamsPaymentMethodOptionsAcssDebitMandateOptions(TypedDict):
- custom_mandate_url: NotRequired["Literal['']|str"]
- """
- A URL for custom mandate text to render during confirmation step.
- The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
- or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
- """
- default_for: NotRequired[List[Literal["invoice", "subscription"]]]
- """
- List of Stripe products where this mandate can be selected automatically. Only usable in `setup` mode.
- """
- interval_description: NotRequired[str]
- """
- Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
- """
- payment_schedule: NotRequired[
- Literal["combined", "interval", "sporadic"]
- ]
- """
- Payment schedule for the mandate.
- """
- transaction_type: NotRequired[Literal["business", "personal"]]
- """
- Transaction type of the mandate.
- """
-
- class CreateParamsPaymentMethodOptionsAffirm(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsAfterpayClearpay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsAlipay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsAlma(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
-
- class CreateParamsPaymentMethodOptionsAmazonPay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none", "off_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsAuBecsDebit(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class CreateParamsPaymentMethodOptionsBacsDebit(TypedDict):
- mandate_options: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsBacsDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class CreateParamsPaymentMethodOptionsBacsDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
- """
-
- class CreateParamsPaymentMethodOptionsBancontact(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsBillie(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
-
- class CreateParamsPaymentMethodOptionsBoleto(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsCard(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- installments: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsCardInstallments"
- ]
- """
- Installment options for card payments
- """
- request_extended_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [capture beyond the standard authorization validity window](https://docs.stripe.com/payments/extended-authorization) for this CheckoutSession.
- """
- request_incremental_authorization: NotRequired[
- Literal["if_available", "never"]
- ]
- """
- Request ability to [increment the authorization](https://docs.stripe.com/payments/incremental-authorization) for this CheckoutSession.
- """
- request_multicapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to make [multiple captures](https://docs.stripe.com/payments/multicapture) for this CheckoutSession.
- """
- request_overcapture: NotRequired[Literal["if_available", "never"]]
- """
- Request ability to [overcapture](https://docs.stripe.com/payments/overcapture) for this CheckoutSession.
- """
- request_three_d_secure: NotRequired[
- Literal["any", "automatic", "challenge"]
- ]
- """
- We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
- """
- restrictions: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsCardRestrictions"
- ]
- """
- Restrictions to apply to the card payment method. For example, you can block specific card brands.
- """
- setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- statement_descriptor_suffix_kana: NotRequired[str]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that's set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
- """
- statement_descriptor_suffix_kanji: NotRequired[str]
- """
- Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that's set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
- """
-
- class CreateParamsPaymentMethodOptionsCardInstallments(TypedDict):
- enabled: NotRequired[bool]
- """
- Setting to true enables installments for this Checkout Session.
- Setting to false will prevent any installment plan from applying to a payment.
- """
-
- class CreateParamsPaymentMethodOptionsCardRestrictions(TypedDict):
- brands_blocked: NotRequired[
- List[
- Literal[
- "american_express",
- "discover_global_network",
- "mastercard",
- "visa",
- ]
- ]
- ]
- """
- Specify the card brands to block in the Checkout Session. If a customer enters or selects a card belonging to a blocked brand, they can't complete the Session.
- """
-
- class CreateParamsPaymentMethodOptionsCashapp(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsCustomerBalance(TypedDict):
- bank_transfer: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsCustomerBalanceBankTransfer"
- ]
- """
- Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
- """
- funding_type: NotRequired[Literal["bank_transfer"]]
- """
- The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsCustomerBalanceBankTransfer(
- TypedDict,
- ):
- eu_bank_transfer: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
- ]
- """
- Configuration for eu_bank_transfer funding type.
- """
- requested_address_types: NotRequired[
- List[
- Literal[
- "aba",
- "iban",
- "sepa",
- "sort_code",
- "spei",
- "swift",
- "zengin",
- ]
- ]
- ]
- """
- List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
-
- Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
- """
- type: Literal[
- "eu_bank_transfer",
- "gb_bank_transfer",
- "jp_bank_transfer",
- "mx_bank_transfer",
- "us_bank_transfer",
- ]
- """
- The list of bank transfer types that this PaymentIntent is allowed to use for funding.
- """
-
- class CreateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
- TypedDict,
- ):
- country: str
- """
- The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
- """
-
- class CreateParamsPaymentMethodOptionsDemoPay(TypedDict):
- setup_future_usage: NotRequired[Literal["none", "off_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsEps(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsFpx(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsGiropay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsGrabpay(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsIdeal(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsKakaoPay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none", "off_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsKlarna(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- subscriptions: NotRequired[
- "Literal['']|List[SessionService.CreateParamsPaymentMethodOptionsKlarnaSubscription]"
- ]
- """
- Subscription details if the Checkout Session sets up a future subscription.
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
- interval: Literal["day", "month", "week", "year"]
- """
- Unit of time between subscription charges.
- """
- interval_count: NotRequired[int]
- """
- The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
- """
- name: NotRequired[str]
- """
- Name for subscription.
- """
- next_billing: "SessionService.CreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
- """
- Describes the upcoming charge for this subscription.
- """
- reference: str
- """
- A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
- """
-
- class CreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
- TypedDict,
- ):
- amount: int
- """
- The amount of the next charge for the subscription.
- """
- date: str
- """
- The date of the next charge for the subscription in YYYY-MM-DD format.
- """
-
- class CreateParamsPaymentMethodOptionsKonbini(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsKrCard(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none", "off_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsLink(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none", "off_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsMobilepay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsMultibanco(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsNaverPay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none", "off_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsOxxo(TypedDict):
- expires_after_days: NotRequired[int]
- """
- The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsP24(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- tos_shown_and_accepted: NotRequired[bool]
- """
- Confirm that the payer has accepted the P24 terms and conditions.
- """
-
- class CreateParamsPaymentMethodOptionsPayByBank(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptionsPayco(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
-
- class CreateParamsPaymentMethodOptionsPaynow(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsPaypal(TypedDict):
- capture_method: NotRequired["Literal['']|Literal['manual']"]
- """
- Controls when the funds will be captured from the customer's account.
- """
- preferred_locale: NotRequired[
- Literal[
- "cs-CZ",
- "da-DK",
- "de-AT",
- "de-DE",
- "de-LU",
- "el-GR",
- "en-GB",
- "en-US",
- "es-ES",
- "fi-FI",
- "fr-BE",
- "fr-FR",
- "fr-LU",
- "hu-HU",
- "it-IT",
- "nl-BE",
- "nl-NL",
- "pl-PL",
- "pt-PT",
- "sk-SK",
- "sv-SE",
- ]
- ]
- """
- [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
- """
- reference: NotRequired[str]
- """
- A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
- """
- risk_correlation_id: NotRequired[str]
- """
- The risk correlation ID for an on-session payment using a saved PayPal payment method.
- """
- setup_future_usage: NotRequired[
- "Literal['']|Literal['none', 'off_session']"
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
-
- If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
- """
-
- class CreateParamsPaymentMethodOptionsPix(TypedDict):
- amount_includes_iof: NotRequired[Literal["always", "never"]]
- """
- Determines if the amount includes the IOF tax. Defaults to `never`.
- """
- expires_after_seconds: NotRequired[int]
- """
- The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsRevolutPay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
- setup_future_usage: NotRequired[Literal["none", "off_session"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsSamsungPay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
-
- class CreateParamsPaymentMethodOptionsSatispay(TypedDict):
- capture_method: NotRequired[Literal["manual"]]
- """
- Controls when the funds will be captured from the customer's account.
- """
-
- class CreateParamsPaymentMethodOptionsSepaDebit(TypedDict):
- mandate_options: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsSepaDebitMandateOptions"
- ]
- """
- Additional fields for Mandate creation
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
-
- class CreateParamsPaymentMethodOptionsSepaDebitMandateOptions(TypedDict):
- reference_prefix: NotRequired["Literal['']|str"]
- """
- Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
- """
-
- class CreateParamsPaymentMethodOptionsSofort(TypedDict):
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPaymentMethodOptionsSwish(TypedDict):
- reference: NotRequired[str]
- """
- The order reference that will be displayed to customers in the Swish application. Defaults to the `id` of the Payment Intent.
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccount(TypedDict):
- financial_connections: NotRequired[
- "SessionService.CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
- ]
- """
- Additional fields for Financial Connections Session creation
- """
- setup_future_usage: NotRequired[
- Literal["none", "off_session", "on_session"]
- ]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
- target_date: NotRequired[str]
- """
- Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
- """
- verification_method: NotRequired[Literal["automatic", "instant"]]
- """
- Verification method for the intent
- """
-
- class CreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
- TypedDict,
- ):
- permissions: NotRequired[
- List[
- Literal[
- "balances", "ownership", "payment_method", "transactions"
- ]
- ]
- ]
- """
- The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
-
- class CreateParamsPaymentMethodOptionsWechatPay(TypedDict):
- app_id: NotRequired[str]
- """
- The app ID registered with WeChat Pay. Only required when client is ios or android.
- """
- client: Literal["android", "ios", "web"]
- """
- The client type that the end customer will pay from
- """
- setup_future_usage: NotRequired[Literal["none"]]
- """
- Indicates that you intend to make future payments with this PaymentIntent's payment method.
-
- If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
-
- If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
-
- When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
- """
-
- class CreateParamsPermissions(TypedDict):
- update_shipping_details: NotRequired[
- Literal["client_only", "server_only"]
- ]
- """
- Determines which entity is allowed to update the shipping details.
-
- Default is `client_only`. Stripe Checkout client will automatically update the shipping details. If set to `server_only`, only your server is allowed to update the shipping details.
-
- When set to `server_only`, you must add the onShippingDetailsChange event handler when initializing the Stripe Checkout client and manually update the shipping details from your server using the Stripe API.
- """
-
- class CreateParamsPhoneNumberCollection(TypedDict):
- enabled: bool
- """
- Set to `true` to enable phone number collection.
-
- Can only be set in `payment` and `subscription` mode.
- """
-
- class CreateParamsSavedPaymentMethodOptions(TypedDict):
- allow_redisplay_filters: NotRequired[
- List[Literal["always", "limited", "unspecified"]]
- ]
- """
- Uses the `allow_redisplay` value of each saved payment method to filter the set presented to a returning customer. By default, only saved payment methods with 'allow_redisplay: ‘always' are shown in Checkout.
- """
- payment_method_remove: NotRequired[Literal["disabled", "enabled"]]
- """
- Enable customers to choose if they wish to remove their saved payment methods. Disabled by default.
- """
- payment_method_save: NotRequired[Literal["disabled", "enabled"]]
- """
- Enable customers to choose if they wish to save their payment method for future use. Disabled by default.
- """
-
- class CreateParamsSetupIntentData(TypedDict):
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The Stripe account for which the setup is intended.
- """
-
- class CreateParamsShippingAddressCollection(TypedDict):
- allowed_countries: List[
- Literal[
- "AC",
- "AD",
- "AE",
- "AF",
- "AG",
- "AI",
- "AL",
- "AM",
- "AO",
- "AQ",
- "AR",
- "AT",
- "AU",
- "AW",
- "AX",
- "AZ",
- "BA",
- "BB",
- "BD",
- "BE",
- "BF",
- "BG",
- "BH",
- "BI",
- "BJ",
- "BL",
- "BM",
- "BN",
- "BO",
- "BQ",
- "BR",
- "BS",
- "BT",
- "BV",
- "BW",
- "BY",
- "BZ",
- "CA",
- "CD",
- "CF",
- "CG",
- "CH",
- "CI",
- "CK",
- "CL",
- "CM",
- "CN",
- "CO",
- "CR",
- "CV",
- "CW",
- "CY",
- "CZ",
- "DE",
- "DJ",
- "DK",
- "DM",
- "DO",
- "DZ",
- "EC",
- "EE",
- "EG",
- "EH",
- "ER",
- "ES",
- "ET",
- "FI",
- "FJ",
- "FK",
- "FO",
- "FR",
- "GA",
- "GB",
- "GD",
- "GE",
- "GF",
- "GG",
- "GH",
- "GI",
- "GL",
- "GM",
- "GN",
- "GP",
- "GQ",
- "GR",
- "GS",
- "GT",
- "GU",
- "GW",
- "GY",
- "HK",
- "HN",
- "HR",
- "HT",
- "HU",
- "ID",
- "IE",
- "IL",
- "IM",
- "IN",
- "IO",
- "IQ",
- "IS",
- "IT",
- "JE",
- "JM",
- "JO",
- "JP",
- "KE",
- "KG",
- "KH",
- "KI",
- "KM",
- "KN",
- "KR",
- "KW",
- "KY",
- "KZ",
- "LA",
- "LB",
- "LC",
- "LI",
- "LK",
- "LR",
- "LS",
- "LT",
- "LU",
- "LV",
- "LY",
- "MA",
- "MC",
- "MD",
- "ME",
- "MF",
- "MG",
- "MK",
- "ML",
- "MM",
- "MN",
- "MO",
- "MQ",
- "MR",
- "MS",
- "MT",
- "MU",
- "MV",
- "MW",
- "MX",
- "MY",
- "MZ",
- "NA",
- "NC",
- "NE",
- "NG",
- "NI",
- "NL",
- "NO",
- "NP",
- "NR",
- "NU",
- "NZ",
- "OM",
- "PA",
- "PE",
- "PF",
- "PG",
- "PH",
- "PK",
- "PL",
- "PM",
- "PN",
- "PR",
- "PS",
- "PT",
- "PY",
- "QA",
- "RE",
- "RO",
- "RS",
- "RU",
- "RW",
- "SA",
- "SB",
- "SC",
- "SD",
- "SE",
- "SG",
- "SH",
- "SI",
- "SJ",
- "SK",
- "SL",
- "SM",
- "SN",
- "SO",
- "SR",
- "SS",
- "ST",
- "SV",
- "SX",
- "SZ",
- "TA",
- "TC",
- "TD",
- "TF",
- "TG",
- "TH",
- "TJ",
- "TK",
- "TL",
- "TM",
- "TN",
- "TO",
- "TR",
- "TT",
- "TV",
- "TW",
- "TZ",
- "UA",
- "UG",
- "US",
- "UY",
- "UZ",
- "VA",
- "VC",
- "VE",
- "VG",
- "VN",
- "VU",
- "WF",
- "WS",
- "XK",
- "YE",
- "YT",
- "ZA",
- "ZM",
- "ZW",
- "ZZ",
- ]
- ]
- """
- An array of two-letter ISO country codes representing which countries Checkout should provide as options for
- shipping locations.
- """
-
- class CreateParamsShippingOption(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the Shipping Rate to use for this shipping option.
- """
- shipping_rate_data: NotRequired[
- "SessionService.CreateParamsShippingOptionShippingRateData"
- ]
- """
- Parameters to be passed to Shipping Rate creation for this shipping option.
- """
-
- class CreateParamsShippingOptionShippingRateData(TypedDict):
- delivery_estimate: NotRequired[
- "SessionService.CreateParamsShippingOptionShippingRateDataDeliveryEstimate"
- ]
- """
- The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- display_name: str
- """
- The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- fixed_amount: NotRequired[
- "SessionService.CreateParamsShippingOptionShippingRateDataFixedAmount"
- ]
- """
- Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
- """
- type: NotRequired[Literal["fixed_amount"]]
- """
- The type of calculation to use on the shipping rate.
- """
-
- class CreateParamsShippingOptionShippingRateDataDeliveryEstimate(
- TypedDict
- ):
- maximum: NotRequired[
- "SessionService.CreateParamsShippingOptionShippingRateDataDeliveryEstimateMaximum"
- ]
- """
- The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
- """
- minimum: NotRequired[
- "SessionService.CreateParamsShippingOptionShippingRateDataDeliveryEstimateMinimum"
- ]
- """
- The lower bound of the estimated range. If empty, represents no lower bound.
- """
-
- class CreateParamsShippingOptionShippingRateDataDeliveryEstimateMaximum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class CreateParamsShippingOptionShippingRateDataDeliveryEstimateMinimum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class CreateParamsShippingOptionShippingRateDataFixedAmount(TypedDict):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- currency_options: NotRequired[
- Dict[
- str,
- "SessionService.CreateParamsShippingOptionShippingRateDataFixedAmountCurrencyOptions",
- ]
- ]
- """
- Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class CreateParamsShippingOptionShippingRateDataFixedAmountCurrencyOptions(
- TypedDict,
- ):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
-
- class CreateParamsSubscriptionData(TypedDict):
- application_fee_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. To use an application fee percent, the request must be made on behalf of another account, using the `Stripe-Account` header or an OAuth key. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
- """
- billing_cycle_anchor: NotRequired[int]
- """
- A future timestamp to anchor the subscription's billing cycle for new subscriptions.
- """
- billing_mode: NotRequired[
- "SessionService.CreateParamsSubscriptionDataBillingMode"
- ]
- """
- Controls how prorations and invoices for subscriptions are calculated and orchestrated.
- """
- default_tax_rates: NotRequired[List[str]]
- """
- The tax rates that will apply to any subscription item that does not have
- `tax_rates` set. Invoices created will have their `default_tax_rates` populated
- from the subscription.
- """
- description: NotRequired[str]
- """
- The subscription's description, meant to be displayable to the customer.
- Use this field to optionally store an explanation of the subscription
- for rendering in the [customer portal](https://stripe.com/docs/customer-management).
- """
- invoice_settings: NotRequired[
- "SessionService.CreateParamsSubscriptionDataInvoiceSettings"
- ]
- """
- All invoices will be billed using the specified settings.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- on_behalf_of: NotRequired[str]
- """
- The account on behalf of which to charge, for each of the subscription's invoices.
- """
- proration_behavior: NotRequired[Literal["create_prorations", "none"]]
- """
- Determines how to handle prorations resulting from the `billing_cycle_anchor`. If no value is passed, the default is `create_prorations`.
- """
- transfer_data: NotRequired[
- "SessionService.CreateParamsSubscriptionDataTransferData"
- ]
- """
- If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges.
- """
- trial_end: NotRequired[int]
- """
- Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. Has to be at least 48 hours in the future.
- """
- trial_period_days: NotRequired[int]
- """
- Integer representing the number of trial period days before the customer is charged for the first time. Has to be at least 1.
- """
- trial_settings: NotRequired[
- "SessionService.CreateParamsSubscriptionDataTrialSettings"
- ]
- """
- Settings related to subscription trials.
- """
-
- class CreateParamsSubscriptionDataBillingMode(TypedDict):
- flexible: NotRequired[
- "SessionService.CreateParamsSubscriptionDataBillingModeFlexible"
- ]
- """
- Configure behavior for flexible billing mode.
- """
- type: Literal["classic", "flexible"]
- """
- Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
- """
-
- class CreateParamsSubscriptionDataBillingModeFlexible(TypedDict):
- proration_discounts: NotRequired[Literal["included", "itemized"]]
- """
- Controls how invoices and invoice items display proration amounts and discount amounts.
- """
-
- class CreateParamsSubscriptionDataInvoiceSettings(TypedDict):
- issuer: NotRequired[
- "SessionService.CreateParamsSubscriptionDataInvoiceSettingsIssuer"
- ]
- """
- The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
- """
-
- class CreateParamsSubscriptionDataInvoiceSettingsIssuer(TypedDict):
- account: NotRequired[str]
- """
- The connected account being referenced when `type` is `account`.
- """
- type: Literal["account", "self"]
- """
- Type of the account referenced in the request.
- """
-
- class CreateParamsSubscriptionDataTransferData(TypedDict):
- amount_percent: NotRequired[float]
- """
- A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
- """
- destination: str
- """
- ID of an existing, connected Stripe account.
- """
-
- class CreateParamsSubscriptionDataTrialSettings(TypedDict):
- end_behavior: "SessionService.CreateParamsSubscriptionDataTrialSettingsEndBehavior"
- """
- Defines how the subscription should behave when the user's free trial ends.
- """
-
- class CreateParamsSubscriptionDataTrialSettingsEndBehavior(TypedDict):
- missing_payment_method: Literal["cancel", "create_invoice", "pause"]
- """
- Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
- """
-
- class CreateParamsTaxIdCollection(TypedDict):
- enabled: bool
- """
- Enable tax ID collection during checkout. Defaults to `false`.
- """
- required: NotRequired[Literal["if_supported", "never"]]
- """
- Describes whether a tax ID is required during checkout. Defaults to `never`.
- """
-
- class CreateParamsWalletOptions(TypedDict):
- link: NotRequired["SessionService.CreateParamsWalletOptionsLink"]
- """
- contains details about the Link wallet options.
- """
-
- class CreateParamsWalletOptionsLink(TypedDict):
- display: NotRequired[Literal["auto", "never"]]
- """
- Specifies whether Checkout should display Link as a payment option. By default, Checkout will display all the supported wallets that the Checkout Session was created with. This is the `auto` behavior, and it is the default choice.
- """
-
- class ExpireParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(TypedDict):
- created: NotRequired["SessionService.ListParamsCreated|int"]
- """
- Only return Checkout Sessions that were created during the given date interval.
- """
- customer: NotRequired[str]
- """
- Only return the Checkout Sessions for the Customer specified.
- """
- customer_details: NotRequired[
- "SessionService.ListParamsCustomerDetails"
- ]
- """
- Only return the Checkout Sessions for the Customer details specified.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payment_intent: NotRequired[str]
- """
- Only return the Checkout Session for the PaymentIntent specified.
- """
- payment_link: NotRequired[str]
- """
- Only return the Checkout Sessions for the Payment Link specified.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["complete", "expired", "open"]]
- """
- Only return the Checkout Sessions matching the given status.
- """
- subscription: NotRequired[str]
- """
- Only return the Checkout Session for the subscription specified.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsCustomerDetails(TypedDict):
- email: str
- """
- Customer's email address.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- collected_information: NotRequired[
- "SessionService.UpdateParamsCollectedInformation"
- ]
- """
- Information about the customer collected within the Checkout Session. Can only be set when updating `embedded` or `custom` sessions.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- shipping_options: NotRequired[
- "Literal['']|List[SessionService.UpdateParamsShippingOption]"
- ]
- """
- The shipping rate options to apply to this Session. Up to a maximum of 5.
- """
-
- class UpdateParamsCollectedInformation(TypedDict):
- shipping_details: NotRequired[
- "SessionService.UpdateParamsCollectedInformationShippingDetails"
- ]
- """
- The shipping details to apply to this Session.
- """
-
- class UpdateParamsCollectedInformationShippingDetails(TypedDict):
- address: "SessionService.UpdateParamsCollectedInformationShippingDetailsAddress"
- """
- The address of the customer
- """
- name: str
- """
- The name of customer
- """
-
- class UpdateParamsCollectedInformationShippingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsShippingOption(TypedDict):
- shipping_rate: NotRequired[str]
- """
- The ID of the Shipping Rate to use for this shipping option.
- """
- shipping_rate_data: NotRequired[
- "SessionService.UpdateParamsShippingOptionShippingRateData"
- ]
- """
- Parameters to be passed to Shipping Rate creation for this shipping option.
- """
-
- class UpdateParamsShippingOptionShippingRateData(TypedDict):
- delivery_estimate: NotRequired[
- "SessionService.UpdateParamsShippingOptionShippingRateDataDeliveryEstimate"
- ]
- """
- The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- display_name: str
- """
- The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
- """
- fixed_amount: NotRequired[
- "SessionService.UpdateParamsShippingOptionShippingRateDataFixedAmount"
- ]
- """
- Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
- """
- type: NotRequired[Literal["fixed_amount"]]
- """
- The type of calculation to use on the shipping rate.
- """
-
- class UpdateParamsShippingOptionShippingRateDataDeliveryEstimate(
- TypedDict
- ):
- maximum: NotRequired[
- "SessionService.UpdateParamsShippingOptionShippingRateDataDeliveryEstimateMaximum"
- ]
- """
- The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
- """
- minimum: NotRequired[
- "SessionService.UpdateParamsShippingOptionShippingRateDataDeliveryEstimateMinimum"
- ]
- """
- The lower bound of the estimated range. If empty, represents no lower bound.
- """
-
- class UpdateParamsShippingOptionShippingRateDataDeliveryEstimateMaximum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class UpdateParamsShippingOptionShippingRateDataDeliveryEstimateMinimum(
- TypedDict,
- ):
- unit: Literal["business_day", "day", "hour", "month", "week"]
- """
- A unit of time.
- """
- value: int
- """
- Must be greater than 0.
- """
-
- class UpdateParamsShippingOptionShippingRateDataFixedAmount(TypedDict):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- currency_options: NotRequired[
- Dict[
- str,
- "SessionService.UpdateParamsShippingOptionShippingRateDataFixedAmountCurrencyOptions",
- ]
- ]
- """
- Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
- """
-
- class UpdateParamsShippingOptionShippingRateDataFixedAmountCurrencyOptions(
- TypedDict,
- ):
- amount: int
- """
- A non-negative integer in cents representing how much to charge.
- """
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "unspecified"]
- ]
- """
- Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
- """
-
def list(
self,
- params: Optional["SessionService.ListParams"] = None,
+ params: Optional["SessionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Session]:
"""
@@ -3174,7 +51,7 @@ def list(
async def list_async(
self,
- params: Optional["SessionService.ListParams"] = None,
+ params: Optional["SessionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Session]:
"""
@@ -3193,7 +70,7 @@ async def list_async(
def create(
self,
- params: Optional["SessionService.CreateParams"] = None,
+ params: Optional["SessionCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Session:
"""
@@ -3212,7 +89,7 @@ def create(
async def create_async(
self,
- params: Optional["SessionService.CreateParams"] = None,
+ params: Optional["SessionCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Session:
"""
@@ -3232,7 +109,7 @@ async def create_async(
def retrieve(
self,
session: str,
- params: Optional["SessionService.RetrieveParams"] = None,
+ params: Optional["SessionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Session:
"""
@@ -3254,7 +131,7 @@ def retrieve(
async def retrieve_async(
self,
session: str,
- params: Optional["SessionService.RetrieveParams"] = None,
+ params: Optional["SessionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Session:
"""
@@ -3276,7 +153,7 @@ async def retrieve_async(
def update(
self,
session: str,
- params: Optional["SessionService.UpdateParams"] = None,
+ params: Optional["SessionUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Session:
"""
@@ -3300,7 +177,7 @@ def update(
async def update_async(
self,
session: str,
- params: Optional["SessionService.UpdateParams"] = None,
+ params: Optional["SessionUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Session:
"""
@@ -3324,7 +201,7 @@ async def update_async(
def expire(
self,
session: str,
- params: Optional["SessionService.ExpireParams"] = None,
+ params: Optional["SessionExpireParams"] = None,
options: Optional[RequestOptions] = None,
) -> Session:
"""
@@ -3348,7 +225,7 @@ def expire(
async def expire_async(
self,
session: str,
- params: Optional["SessionService.ExpireParams"] = None,
+ params: Optional["SessionExpireParams"] = None,
options: Optional[RequestOptions] = None,
) -> Session:
"""
diff --git a/stripe/climate/_order.py b/stripe/climate/_order.py
index 354821c46..477690ee9 100644
--- a/stripe/climate/_order.py
+++ b/stripe/climate/_order.py
@@ -4,22 +4,22 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, Dict, List, Optional, Union, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Dict, List, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe.climate._product import Product
from stripe.climate._supplier import Supplier
+ from stripe.params.climate._order_cancel_params import OrderCancelParams
+ from stripe.params.climate._order_create_params import OrderCreateParams
+ from stripe.params.climate._order_list_params import OrderListParams
+ from stripe.params.climate._order_modify_params import OrderModifyParams
+ from stripe.params.climate._order_retrieve_params import (
+ OrderRetrieveParams,
+ )
class Order(
@@ -85,92 +85,6 @@ class Location(StripeObject):
"""
_inner_class_types = {"location": Location}
- class CancelParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(RequestOptions):
- amount: NotRequired[int]
- """
- Requested amount of carbon removal units. Either this or `metric_tons` must be specified.
- """
- beneficiary: NotRequired["Order.CreateParamsBeneficiary"]
- """
- Publicly sharable reference for the end beneficiary of carbon removal. Assumed to be the Stripe account if not set.
- """
- currency: NotRequired[str]
- """
- Request currency for the order as a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a supported [settlement currency for your account](https://stripe.com/docs/currencies). If omitted, the account's default currency will be used.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- metric_tons: NotRequired[str]
- """
- Requested number of tons for the order. Either this or `amount` must be specified.
- """
- product: str
- """
- Unique identifier of the Climate product.
- """
-
- class CreateParamsBeneficiary(TypedDict):
- public_name: str
- """
- Publicly displayable name for the end beneficiary of carbon removal.
- """
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ModifyParams(RequestOptions):
- beneficiary: NotRequired["Literal['']|Order.ModifyParamsBeneficiary"]
- """
- Publicly sharable reference for the end beneficiary of carbon removal. Assumed to be the Stripe account if not set.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class ModifyParamsBeneficiary(TypedDict):
- public_name: Union[Literal[""], str]
- """
- Publicly displayable name for the end beneficiary of carbon removal.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount_fees: int
"""
Total amount of [Frontier](https://frontierclimate.com/)'s service fees in the currency's smallest unit.
@@ -263,7 +177,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def _cls_cancel(
- cls, order: str, **params: Unpack["Order.CancelParams"]
+ cls, order: str, **params: Unpack["OrderCancelParams"]
) -> "Order":
"""
Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the
@@ -284,7 +198,7 @@ def _cls_cancel(
@overload
@staticmethod
- def cancel(order: str, **params: Unpack["Order.CancelParams"]) -> "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
@@ -294,7 +208,7 @@ def cancel(order: str, **params: Unpack["Order.CancelParams"]) -> "Order":
...
@overload
- def cancel(self, **params: Unpack["Order.CancelParams"]) -> "Order":
+ def cancel(self, **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
@@ -305,7 +219,7 @@ def cancel(self, **params: Unpack["Order.CancelParams"]) -> "Order":
@class_method_variant("_cls_cancel")
def cancel( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Order.CancelParams"]
+ self, **params: Unpack["OrderCancelParams"]
) -> "Order":
"""
Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the
@@ -326,7 +240,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_cancel_async(
- cls, order: str, **params: Unpack["Order.CancelParams"]
+ cls, order: str, **params: Unpack["OrderCancelParams"]
) -> "Order":
"""
Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the
@@ -348,7 +262,7 @@ async def _cls_cancel_async(
@overload
@staticmethod
async def cancel_async(
- order: str, **params: Unpack["Order.CancelParams"]
+ order: str, **params: Unpack["OrderCancelParams"]
) -> "Order":
"""
Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the
@@ -360,7 +274,7 @@ async def cancel_async(
@overload
async def cancel_async(
- self, **params: Unpack["Order.CancelParams"]
+ self, **params: Unpack["OrderCancelParams"]
) -> "Order":
"""
Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the
@@ -372,7 +286,7 @@ async def cancel_async(
@class_method_variant("_cls_cancel_async")
async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Order.CancelParams"]
+ self, **params: Unpack["OrderCancelParams"]
) -> "Order":
"""
Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the
@@ -392,7 +306,7 @@ async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
)
@classmethod
- def create(cls, **params: Unpack["Order.CreateParams"]) -> "Order":
+ def create(cls, **params: Unpack["OrderCreateParams"]) -> "Order":
"""
Creates a Climate order object for a given Climate product. The order will be processed immediately
after creation and payment will be deducted your Stripe balance.
@@ -408,7 +322,7 @@ def create(cls, **params: Unpack["Order.CreateParams"]) -> "Order":
@classmethod
async def create_async(
- cls, **params: Unpack["Order.CreateParams"]
+ cls, **params: Unpack["OrderCreateParams"]
) -> "Order":
"""
Creates a Climate order object for a given Climate product. The order will be processed immediately
@@ -424,7 +338,7 @@ async def create_async(
)
@classmethod
- def list(cls, **params: Unpack["Order.ListParams"]) -> ListObject["Order"]:
+ def list(cls, **params: Unpack["OrderListParams"]) -> ListObject["Order"]:
"""
Lists all Climate order objects. The orders are returned sorted by creation date, with the
most recently created orders appearing first.
@@ -444,7 +358,7 @@ def list(cls, **params: Unpack["Order.ListParams"]) -> ListObject["Order"]:
@classmethod
async def list_async(
- cls, **params: Unpack["Order.ListParams"]
+ cls, **params: Unpack["OrderListParams"]
) -> ListObject["Order"]:
"""
Lists all Climate order objects. The orders are returned sorted by creation date, with the
@@ -464,9 +378,7 @@ async def list_async(
return result
@classmethod
- def modify(
- cls, id: str, **params: Unpack["Order.ModifyParams"]
- ) -> "Order":
+ def modify(cls, id: str, **params: Unpack["OrderModifyParams"]) -> "Order":
"""
Updates the specified order by setting the values of the parameters passed.
"""
@@ -482,7 +394,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Order.ModifyParams"]
+ cls, id: str, **params: Unpack["OrderModifyParams"]
) -> "Order":
"""
Updates the specified order by setting the values of the parameters passed.
@@ -499,7 +411,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Order.RetrieveParams"]
+ cls, id: str, **params: Unpack["OrderRetrieveParams"]
) -> "Order":
"""
Retrieves the details of a Climate order object with the given ID.
@@ -510,7 +422,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Order.RetrieveParams"]
+ cls, id: str, **params: Unpack["OrderRetrieveParams"]
) -> "Order":
"""
Retrieves the details of a Climate order object with the given ID.
diff --git a/stripe/climate/_order_service.py b/stripe/climate/_order_service.py
index 4ea9e33f8..7865e1000 100644
--- a/stripe/climate/_order_service.py
+++ b/stripe/climate/_order_service.py
@@ -5,102 +5,23 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.climate._order import Order
-from typing import Dict, List, Optional, Union, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.climate._order_cancel_params import OrderCancelParams
+ from stripe.params.climate._order_create_params import OrderCreateParams
+ from stripe.params.climate._order_list_params import OrderListParams
+ from stripe.params.climate._order_retrieve_params import (
+ OrderRetrieveParams,
+ )
+ from stripe.params.climate._order_update_params import OrderUpdateParams
-class OrderService(StripeService):
- class CancelParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(TypedDict):
- amount: NotRequired[int]
- """
- Requested amount of carbon removal units. Either this or `metric_tons` must be specified.
- """
- beneficiary: NotRequired["OrderService.CreateParamsBeneficiary"]
- """
- Publicly sharable reference for the end beneficiary of carbon removal. Assumed to be the Stripe account if not set.
- """
- currency: NotRequired[str]
- """
- Request currency for the order as a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a supported [settlement currency for your account](https://stripe.com/docs/currencies). If omitted, the account's default currency will be used.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- metric_tons: NotRequired[str]
- """
- Requested number of tons for the order. Either this or `amount` must be specified.
- """
- product: str
- """
- Unique identifier of the Climate product.
- """
-
- class CreateParamsBeneficiary(TypedDict):
- public_name: str
- """
- Publicly displayable name for the end beneficiary of carbon removal.
- """
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- beneficiary: NotRequired[
- "Literal['']|OrderService.UpdateParamsBeneficiary"
- ]
- """
- Publicly sharable reference for the end beneficiary of carbon removal. Assumed to be the Stripe account if not set.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class UpdateParamsBeneficiary(TypedDict):
- public_name: Union[Literal[""], str]
- """
- Publicly displayable name for the end beneficiary of carbon removal.
- """
+class OrderService(StripeService):
def list(
self,
- params: Optional["OrderService.ListParams"] = None,
+ params: Optional["OrderListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Order]:
"""
@@ -120,7 +41,7 @@ def list(
async def list_async(
self,
- params: Optional["OrderService.ListParams"] = None,
+ params: Optional["OrderListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Order]:
"""
@@ -140,7 +61,7 @@ async def list_async(
def create(
self,
- params: "OrderService.CreateParams",
+ params: "OrderCreateParams",
options: Optional[RequestOptions] = None,
) -> Order:
"""
@@ -160,7 +81,7 @@ def create(
async def create_async(
self,
- params: "OrderService.CreateParams",
+ params: "OrderCreateParams",
options: Optional[RequestOptions] = None,
) -> Order:
"""
@@ -181,7 +102,7 @@ async def create_async(
def retrieve(
self,
order: str,
- params: Optional["OrderService.RetrieveParams"] = None,
+ params: Optional["OrderRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Order:
"""
@@ -201,7 +122,7 @@ def retrieve(
async def retrieve_async(
self,
order: str,
- params: Optional["OrderService.RetrieveParams"] = None,
+ params: Optional["OrderRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Order:
"""
@@ -221,7 +142,7 @@ async def retrieve_async(
def update(
self,
order: str,
- params: Optional["OrderService.UpdateParams"] = None,
+ params: Optional["OrderUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Order:
"""
@@ -241,7 +162,7 @@ def update(
async def update_async(
self,
order: str,
- params: Optional["OrderService.UpdateParams"] = None,
+ params: Optional["OrderUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Order:
"""
@@ -261,7 +182,7 @@ async def update_async(
def cancel(
self,
order: str,
- params: Optional["OrderService.CancelParams"] = None,
+ params: Optional["OrderCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> Order:
"""
@@ -286,7 +207,7 @@ def cancel(
async def cancel_async(
self,
order: str,
- params: Optional["OrderService.CancelParams"] = None,
+ params: Optional["OrderCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> Order:
"""
diff --git a/stripe/climate/_product.py b/stripe/climate/_product.py
index fbe5c4d16..613352ec9 100644
--- a/stripe/climate/_product.py
+++ b/stripe/climate/_product.py
@@ -2,13 +2,16 @@
# File generated from our OpenAPI spec
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from typing import ClassVar, Dict, List, Optional
-from typing_extensions import Literal, NotRequired, Unpack, TYPE_CHECKING
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe.climate._supplier import Supplier
+ from stripe.params.climate._product_list_params import ProductListParams
+ from stripe.params.climate._product_retrieve_params import (
+ ProductRetrieveParams,
+ )
class Product(ListableAPIResource["Product"]):
@@ -33,30 +36,6 @@ class CurrentPricesPerMetricTon(StripeObject):
Total for one metric ton of carbon removal (including fees) in the currency's smallest unit.
"""
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -98,7 +77,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["Product.ListParams"]
+ cls, **params: Unpack["ProductListParams"]
) -> ListObject["Product"]:
"""
Lists all available Climate product objects.
@@ -118,7 +97,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Product.ListParams"]
+ cls, **params: Unpack["ProductListParams"]
) -> ListObject["Product"]:
"""
Lists all available Climate product objects.
@@ -138,7 +117,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Product.RetrieveParams"]
+ cls, id: str, **params: Unpack["ProductRetrieveParams"]
) -> "Product":
"""
Retrieves the details of a Climate product with the given ID.
@@ -149,7 +128,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Product.RetrieveParams"]
+ cls, id: str, **params: Unpack["ProductRetrieveParams"]
) -> "Product":
"""
Retrieves the details of a Climate product with the given ID.
diff --git a/stripe/climate/_product_service.py b/stripe/climate/_product_service.py
index 5b8108272..d9bc88796 100644
--- a/stripe/climate/_product_service.py
+++ b/stripe/climate/_product_service.py
@@ -5,38 +5,20 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.climate._product import Product
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.climate._product_list_params import ProductListParams
+ from stripe.params.climate._product_retrieve_params import (
+ ProductRetrieveParams,
+ )
-class ProductService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class ProductService(StripeService):
def list(
self,
- params: Optional["ProductService.ListParams"] = None,
+ params: Optional["ProductListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Product]:
"""
@@ -55,7 +37,7 @@ def list(
async def list_async(
self,
- params: Optional["ProductService.ListParams"] = None,
+ params: Optional["ProductListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Product]:
"""
@@ -75,7 +57,7 @@ async def list_async(
def retrieve(
self,
product: str,
- params: Optional["ProductService.RetrieveParams"] = None,
+ params: Optional["ProductRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Product:
"""
@@ -97,7 +79,7 @@ def retrieve(
async def retrieve_async(
self,
product: str,
- params: Optional["ProductService.RetrieveParams"] = None,
+ params: Optional["ProductRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Product:
"""
diff --git a/stripe/climate/_supplier.py b/stripe/climate/_supplier.py
index 78b76bbc0..d65e2100d 100644
--- a/stripe/climate/_supplier.py
+++ b/stripe/climate/_supplier.py
@@ -2,10 +2,15 @@
# File generated from our OpenAPI spec
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from typing import ClassVar, List, Optional
-from typing_extensions import Literal, NotRequired, Unpack
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.climate._supplier_list_params import SupplierListParams
+ from stripe.params.climate._supplier_retrieve_params import (
+ SupplierRetrieveParams,
+ )
class Supplier(ListableAPIResource["Supplier"]):
@@ -37,30 +42,6 @@ class Location(StripeObject):
The state/county/province/region where the supplier is located.
"""
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
id: str
"""
Unique identifier for the object.
@@ -96,7 +77,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["Supplier.ListParams"]
+ cls, **params: Unpack["SupplierListParams"]
) -> ListObject["Supplier"]:
"""
Lists all available Climate supplier objects.
@@ -116,7 +97,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Supplier.ListParams"]
+ cls, **params: Unpack["SupplierListParams"]
) -> ListObject["Supplier"]:
"""
Lists all available Climate supplier objects.
@@ -136,7 +117,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Supplier.RetrieveParams"]
+ cls, id: str, **params: Unpack["SupplierRetrieveParams"]
) -> "Supplier":
"""
Retrieves a Climate supplier object.
@@ -147,7 +128,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Supplier.RetrieveParams"]
+ cls, id: str, **params: Unpack["SupplierRetrieveParams"]
) -> "Supplier":
"""
Retrieves a Climate supplier object.
diff --git a/stripe/climate/_supplier_service.py b/stripe/climate/_supplier_service.py
index a2333170f..5cb5ed496 100644
--- a/stripe/climate/_supplier_service.py
+++ b/stripe/climate/_supplier_service.py
@@ -5,38 +5,20 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.climate._supplier import Supplier
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.climate._supplier_list_params import SupplierListParams
+ from stripe.params.climate._supplier_retrieve_params import (
+ SupplierRetrieveParams,
+ )
-class SupplierService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class SupplierService(StripeService):
def list(
self,
- params: Optional["SupplierService.ListParams"] = None,
+ params: Optional["SupplierListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Supplier]:
"""
@@ -55,7 +37,7 @@ def list(
async def list_async(
self,
- params: Optional["SupplierService.ListParams"] = None,
+ params: Optional["SupplierListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Supplier]:
"""
@@ -75,7 +57,7 @@ async def list_async(
def retrieve(
self,
supplier: str,
- params: Optional["SupplierService.RetrieveParams"] = None,
+ params: Optional["SupplierRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Supplier:
"""
@@ -97,7 +79,7 @@ def retrieve(
async def retrieve_async(
self,
supplier: str,
- params: Optional["SupplierService.RetrieveParams"] = None,
+ params: Optional["SupplierRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Supplier:
"""
diff --git a/stripe/entitlements/_active_entitlement.py b/stripe/entitlements/_active_entitlement.py
index 51d324d5c..9e95b282d 100644
--- a/stripe/entitlements/_active_entitlement.py
+++ b/stripe/entitlements/_active_entitlement.py
@@ -3,12 +3,17 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
-from typing import ClassVar, List
-from typing_extensions import Literal, NotRequired, Unpack, TYPE_CHECKING
+from typing import ClassVar
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe.entitlements._feature import Feature
+ from stripe.params.entitlements._active_entitlement_list_params import (
+ ActiveEntitlementListParams,
+ )
+ from stripe.params.entitlements._active_entitlement_retrieve_params import (
+ ActiveEntitlementRetrieveParams,
+ )
class ActiveEntitlement(ListableAPIResource["ActiveEntitlement"]):
@@ -19,35 +24,6 @@ class ActiveEntitlement(ListableAPIResource["ActiveEntitlement"]):
OBJECT_NAME: ClassVar[Literal["entitlements.active_entitlement"]] = (
"entitlements.active_entitlement"
)
-
- class ListParams(RequestOptions):
- customer: str
- """
- The ID of the customer.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
feature: ExpandableField["Feature"]
"""
The [Feature](https://stripe.com/docs/api/entitlements/feature) that the customer is entitled to.
@@ -71,7 +47,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["ActiveEntitlement.ListParams"]
+ cls, **params: Unpack["ActiveEntitlementListParams"]
) -> ListObject["ActiveEntitlement"]:
"""
Retrieve a list of active entitlements for a customer
@@ -91,7 +67,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["ActiveEntitlement.ListParams"]
+ cls, **params: Unpack["ActiveEntitlementListParams"]
) -> ListObject["ActiveEntitlement"]:
"""
Retrieve a list of active entitlements for a customer
@@ -111,7 +87,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["ActiveEntitlement.RetrieveParams"]
+ cls, id: str, **params: Unpack["ActiveEntitlementRetrieveParams"]
) -> "ActiveEntitlement":
"""
Retrieve an active entitlement
@@ -122,7 +98,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["ActiveEntitlement.RetrieveParams"]
+ cls, id: str, **params: Unpack["ActiveEntitlementRetrieveParams"]
) -> "ActiveEntitlement":
"""
Retrieve an active entitlement
diff --git a/stripe/entitlements/_active_entitlement_service.py b/stripe/entitlements/_active_entitlement_service.py
index 892584c6e..607258bde 100644
--- a/stripe/entitlements/_active_entitlement_service.py
+++ b/stripe/entitlements/_active_entitlement_service.py
@@ -5,42 +5,22 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.entitlements._active_entitlement import ActiveEntitlement
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.entitlements._active_entitlement_list_params import (
+ ActiveEntitlementListParams,
+ )
+ from stripe.params.entitlements._active_entitlement_retrieve_params import (
+ ActiveEntitlementRetrieveParams,
+ )
-class ActiveEntitlementService(StripeService):
- class ListParams(TypedDict):
- customer: str
- """
- The ID of the customer.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class ActiveEntitlementService(StripeService):
def list(
self,
- params: "ActiveEntitlementService.ListParams",
+ params: "ActiveEntitlementListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[ActiveEntitlement]:
"""
@@ -59,7 +39,7 @@ def list(
async def list_async(
self,
- params: "ActiveEntitlementService.ListParams",
+ params: "ActiveEntitlementListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[ActiveEntitlement]:
"""
@@ -79,7 +59,7 @@ async def list_async(
def retrieve(
self,
id: str,
- params: Optional["ActiveEntitlementService.RetrieveParams"] = None,
+ params: Optional["ActiveEntitlementRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ActiveEntitlement:
"""
@@ -101,7 +81,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["ActiveEntitlementService.RetrieveParams"] = None,
+ params: Optional["ActiveEntitlementRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ActiveEntitlement:
"""
diff --git a/stripe/entitlements/_feature.py b/stripe/entitlements/_feature.py
index 85bca6f8f..c9954ef1e 100644
--- a/stripe/entitlements/_feature.py
+++ b/stripe/entitlements/_feature.py
@@ -3,11 +3,24 @@
from stripe._createable_api_resource import CreateableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import sanitize_id
-from typing import ClassVar, Dict, List, cast
-from typing_extensions import Literal, NotRequired, Unpack
+from typing import ClassVar, Dict, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.entitlements._feature_create_params import (
+ FeatureCreateParams,
+ )
+ from stripe.params.entitlements._feature_list_params import (
+ FeatureListParams,
+ )
+ from stripe.params.entitlements._feature_modify_params import (
+ FeatureModifyParams,
+ )
+ from stripe.params.entitlements._feature_retrieve_params import (
+ FeatureRetrieveParams,
+ )
class Feature(
@@ -23,75 +36,6 @@ class Feature(
OBJECT_NAME: ClassVar[Literal["entitlements.feature"]] = (
"entitlements.feature"
)
-
- class CreateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- lookup_key: str
- """
- A unique key you provide as your own system identifier. This may be up to 80 characters.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- """
- name: str
- """
- The feature's name, for your own purpose, not meant to be displayable to the customer.
- """
-
- class ListParams(RequestOptions):
- archived: NotRequired[bool]
- """
- If set, filter results to only include features with the given archive status.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- lookup_key: NotRequired[str]
- """
- If set, filter results to only include features with the given lookup_key.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ModifyParams(RequestOptions):
- active: NotRequired[bool]
- """
- Inactive features cannot be attached to new products and will not be returned from the features list endpoint.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- """
- name: NotRequired[str]
- """
- The feature's name, for your own purpose, not meant to be displayable to the customer.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
active: bool
"""
Inactive features cannot be attached to new products and will not be returned from the features list endpoint.
@@ -122,7 +66,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["Feature.CreateParams"]) -> "Feature":
+ def create(cls, **params: Unpack["FeatureCreateParams"]) -> "Feature":
"""
Creates a feature
"""
@@ -137,7 +81,7 @@ def create(cls, **params: Unpack["Feature.CreateParams"]) -> "Feature":
@classmethod
async def create_async(
- cls, **params: Unpack["Feature.CreateParams"]
+ cls, **params: Unpack["FeatureCreateParams"]
) -> "Feature":
"""
Creates a feature
@@ -153,7 +97,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["Feature.ListParams"]
+ cls, **params: Unpack["FeatureListParams"]
) -> ListObject["Feature"]:
"""
Retrieve a list of features
@@ -173,7 +117,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Feature.ListParams"]
+ cls, **params: Unpack["FeatureListParams"]
) -> ListObject["Feature"]:
"""
Retrieve a list of features
@@ -193,7 +137,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Feature.ModifyParams"]
+ cls, id: str, **params: Unpack["FeatureModifyParams"]
) -> "Feature":
"""
Update a feature's metadata or permanently deactivate it.
@@ -210,7 +154,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Feature.ModifyParams"]
+ cls, id: str, **params: Unpack["FeatureModifyParams"]
) -> "Feature":
"""
Update a feature's metadata or permanently deactivate it.
@@ -227,7 +171,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Feature.RetrieveParams"]
+ cls, id: str, **params: Unpack["FeatureRetrieveParams"]
) -> "Feature":
"""
Retrieves a feature
@@ -238,7 +182,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Feature.RetrieveParams"]
+ cls, id: str, **params: Unpack["FeatureRetrieveParams"]
) -> "Feature":
"""
Retrieves a feature
diff --git a/stripe/entitlements/_feature_service.py b/stripe/entitlements/_feature_service.py
index d1841b36b..4f50b652b 100644
--- a/stripe/entitlements/_feature_service.py
+++ b/stripe/entitlements/_feature_service.py
@@ -5,82 +5,28 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.entitlements._feature import Feature
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.entitlements._feature_create_params import (
+ FeatureCreateParams,
+ )
+ from stripe.params.entitlements._feature_list_params import (
+ FeatureListParams,
+ )
+ from stripe.params.entitlements._feature_retrieve_params import (
+ FeatureRetrieveParams,
+ )
+ from stripe.params.entitlements._feature_update_params import (
+ FeatureUpdateParams,
+ )
-class FeatureService(StripeService):
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- lookup_key: str
- """
- A unique key you provide as your own system identifier. This may be up to 80 characters.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- """
- name: str
- """
- The feature's name, for your own purpose, not meant to be displayable to the customer.
- """
-
- class ListParams(TypedDict):
- archived: NotRequired[bool]
- """
- If set, filter results to only include features with the given archive status.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- lookup_key: NotRequired[str]
- """
- If set, filter results to only include features with the given lookup_key.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- active: NotRequired[bool]
- """
- Inactive features cannot be attached to new products and will not be returned from the features list endpoint.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- """
- name: NotRequired[str]
- """
- The feature's name, for your own purpose, not meant to be displayable to the customer.
- """
+class FeatureService(StripeService):
def list(
self,
- params: Optional["FeatureService.ListParams"] = None,
+ params: Optional["FeatureListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Feature]:
"""
@@ -99,7 +45,7 @@ def list(
async def list_async(
self,
- params: Optional["FeatureService.ListParams"] = None,
+ params: Optional["FeatureListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Feature]:
"""
@@ -118,7 +64,7 @@ async def list_async(
def create(
self,
- params: "FeatureService.CreateParams",
+ params: "FeatureCreateParams",
options: Optional[RequestOptions] = None,
) -> Feature:
"""
@@ -137,7 +83,7 @@ def create(
async def create_async(
self,
- params: "FeatureService.CreateParams",
+ params: "FeatureCreateParams",
options: Optional[RequestOptions] = None,
) -> Feature:
"""
@@ -157,7 +103,7 @@ async def create_async(
def retrieve(
self,
id: str,
- params: Optional["FeatureService.RetrieveParams"] = None,
+ params: Optional["FeatureRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Feature:
"""
@@ -177,7 +123,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["FeatureService.RetrieveParams"] = None,
+ params: Optional["FeatureRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Feature:
"""
@@ -197,7 +143,7 @@ async def retrieve_async(
def update(
self,
id: str,
- params: Optional["FeatureService.UpdateParams"] = None,
+ params: Optional["FeatureUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Feature:
"""
@@ -217,7 +163,7 @@ def update(
async def update_async(
self,
id: str,
- params: Optional["FeatureService.UpdateParams"] = None,
+ params: Optional["FeatureUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Feature:
"""
diff --git a/stripe/financial_connections/_account.py b/stripe/financial_connections/_account.py
index 5760bc3b8..6c86a3993 100644
--- a/stripe/financial_connections/_account.py
+++ b/stripe/financial_connections/_account.py
@@ -3,17 +3,10 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account as AccountResource
@@ -22,6 +15,27 @@
from stripe.financial_connections._account_ownership import (
AccountOwnership,
)
+ from stripe.params.financial_connections._account_disconnect_params import (
+ AccountDisconnectParams,
+ )
+ from stripe.params.financial_connections._account_list_owners_params import (
+ AccountListOwnersParams,
+ )
+ from stripe.params.financial_connections._account_list_params import (
+ AccountListParams,
+ )
+ from stripe.params.financial_connections._account_refresh_account_params import (
+ AccountRefreshAccountParams,
+ )
+ from stripe.params.financial_connections._account_retrieve_params import (
+ AccountRetrieveParams,
+ )
+ from stripe.params.financial_connections._account_subscribe_params import (
+ AccountSubscribeParams,
+ )
+ from stripe.params.financial_connections._account_unsubscribe_params import (
+ AccountUnsubscribeParams,
+ )
class Account(ListableAPIResource["Account"]):
@@ -134,106 +148,6 @@ class TransactionRefresh(StripeObject):
The status of the last refresh attempt.
"""
- class DisconnectParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListOwnersParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- ownership: str
- """
- The ID of the ownership object to fetch owners from.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParams(RequestOptions):
- account_holder: NotRequired["Account.ListParamsAccountHolder"]
- """
- If present, only return accounts that belong to the specified account holder. `account_holder[customer]` and `account_holder[account]` are mutually exclusive.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- session: NotRequired[str]
- """
- If present, only return accounts that were collected as part of the given session.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsAccountHolder(TypedDict):
- account: NotRequired[str]
- """
- The ID of the Stripe account whose accounts will be retrieved.
- """
- customer: NotRequired[str]
- """
- The ID of the Stripe customer whose accounts will be retrieved.
- """
-
- class RefreshAccountParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- features: List[Literal["balance", "ownership", "transactions"]]
- """
- The list of account features that you would like to refresh.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SubscribeParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- features: List[Literal["transactions"]]
- """
- The list of account features to which you would like to subscribe.
- """
-
- class UnsubscribeParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- features: List[Literal["transactions"]]
- """
- The list of account features from which you would like to unsubscribe.
- """
-
account_holder: Optional[AccountHolder]
"""
The account holder that this account belongs to.
@@ -337,7 +251,7 @@ class UnsubscribeParams(RequestOptions):
@classmethod
def _cls_disconnect(
- cls, account: str, **params: Unpack["Account.DisconnectParams"]
+ 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).
@@ -356,7 +270,7 @@ def _cls_disconnect(
@overload
@staticmethod
def disconnect(
- account: str, **params: Unpack["Account.DisconnectParams"]
+ 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 +279,7 @@ def disconnect(
@overload
def disconnect(
- self, **params: Unpack["Account.DisconnectParams"]
+ self, **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).
@@ -374,7 +288,7 @@ def disconnect(
@class_method_variant("_cls_disconnect")
def disconnect( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.DisconnectParams"]
+ self, **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).
@@ -392,7 +306,7 @@ def disconnect( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_disconnect_async(
- cls, account: str, **params: Unpack["Account.DisconnectParams"]
+ 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).
@@ -411,7 +325,7 @@ async def _cls_disconnect_async(
@overload
@staticmethod
async def disconnect_async(
- account: str, **params: Unpack["Account.DisconnectParams"]
+ 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).
@@ -420,7 +334,7 @@ async def disconnect_async(
@overload
async def disconnect_async(
- self, **params: Unpack["Account.DisconnectParams"]
+ self, **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).
@@ -429,7 +343,7 @@ async def disconnect_async(
@class_method_variant("_cls_disconnect_async")
async def disconnect_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.DisconnectParams"]
+ self, **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).
@@ -447,7 +361,7 @@ async def disconnect_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["Account.ListParams"]
+ cls, **params: Unpack["AccountListParams"]
) -> ListObject["Account"]:
"""
Returns a list of Financial Connections Account objects.
@@ -467,7 +381,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Account.ListParams"]
+ cls, **params: Unpack["AccountListParams"]
) -> ListObject["Account"]:
"""
Returns a list of Financial Connections Account objects.
@@ -487,7 +401,7 @@ async def list_async(
@classmethod
def _cls_list_owners(
- cls, account: str, **params: Unpack["Account.ListOwnersParams"]
+ cls, account: str, **params: Unpack["AccountListOwnersParams"]
) -> ListObject["AccountOwner"]:
"""
Lists all owners for a given Account
@@ -506,7 +420,7 @@ def _cls_list_owners(
@overload
@staticmethod
def list_owners(
- account: str, **params: Unpack["Account.ListOwnersParams"]
+ account: str, **params: Unpack["AccountListOwnersParams"]
) -> ListObject["AccountOwner"]:
"""
Lists all owners for a given Account
@@ -515,7 +429,7 @@ def list_owners(
@overload
def list_owners(
- self, **params: Unpack["Account.ListOwnersParams"]
+ self, **params: Unpack["AccountListOwnersParams"]
) -> ListObject["AccountOwner"]:
"""
Lists all owners for a given Account
@@ -524,7 +438,7 @@ def list_owners(
@class_method_variant("_cls_list_owners")
def list_owners( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.ListOwnersParams"]
+ self, **params: Unpack["AccountListOwnersParams"]
) -> ListObject["AccountOwner"]:
"""
Lists all owners for a given Account
@@ -542,7 +456,7 @@ def list_owners( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_list_owners_async(
- cls, account: str, **params: Unpack["Account.ListOwnersParams"]
+ cls, account: str, **params: Unpack["AccountListOwnersParams"]
) -> ListObject["AccountOwner"]:
"""
Lists all owners for a given Account
@@ -561,7 +475,7 @@ async def _cls_list_owners_async(
@overload
@staticmethod
async def list_owners_async(
- account: str, **params: Unpack["Account.ListOwnersParams"]
+ account: str, **params: Unpack["AccountListOwnersParams"]
) -> ListObject["AccountOwner"]:
"""
Lists all owners for a given Account
@@ -570,7 +484,7 @@ async def list_owners_async(
@overload
async def list_owners_async(
- self, **params: Unpack["Account.ListOwnersParams"]
+ self, **params: Unpack["AccountListOwnersParams"]
) -> ListObject["AccountOwner"]:
"""
Lists all owners for a given Account
@@ -579,7 +493,7 @@ async def list_owners_async(
@class_method_variant("_cls_list_owners_async")
async def list_owners_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.ListOwnersParams"]
+ self, **params: Unpack["AccountListOwnersParams"]
) -> ListObject["AccountOwner"]:
"""
Lists all owners for a given Account
@@ -597,7 +511,7 @@ async def list_owners_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_refresh_account(
- cls, account: str, **params: Unpack["Account.RefreshAccountParams"]
+ cls, account: str, **params: Unpack["AccountRefreshAccountParams"]
) -> "Account":
"""
Refreshes the data associated with a Financial Connections Account.
@@ -616,7 +530,7 @@ def _cls_refresh_account(
@overload
@staticmethod
def refresh_account(
- account: str, **params: Unpack["Account.RefreshAccountParams"]
+ account: str, **params: Unpack["AccountRefreshAccountParams"]
) -> "Account":
"""
Refreshes the data associated with a Financial Connections Account.
@@ -625,7 +539,7 @@ def refresh_account(
@overload
def refresh_account(
- self, **params: Unpack["Account.RefreshAccountParams"]
+ self, **params: Unpack["AccountRefreshAccountParams"]
) -> "Account":
"""
Refreshes the data associated with a Financial Connections Account.
@@ -634,7 +548,7 @@ def refresh_account(
@class_method_variant("_cls_refresh_account")
def refresh_account( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.RefreshAccountParams"]
+ self, **params: Unpack["AccountRefreshAccountParams"]
) -> "Account":
"""
Refreshes the data associated with a Financial Connections Account.
@@ -652,7 +566,7 @@ def refresh_account( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_refresh_account_async(
- cls, account: str, **params: Unpack["Account.RefreshAccountParams"]
+ cls, account: str, **params: Unpack["AccountRefreshAccountParams"]
) -> "Account":
"""
Refreshes the data associated with a Financial Connections Account.
@@ -671,7 +585,7 @@ async def _cls_refresh_account_async(
@overload
@staticmethod
async def refresh_account_async(
- account: str, **params: Unpack["Account.RefreshAccountParams"]
+ account: str, **params: Unpack["AccountRefreshAccountParams"]
) -> "Account":
"""
Refreshes the data associated with a Financial Connections Account.
@@ -680,7 +594,7 @@ async def refresh_account_async(
@overload
async def refresh_account_async(
- self, **params: Unpack["Account.RefreshAccountParams"]
+ self, **params: Unpack["AccountRefreshAccountParams"]
) -> "Account":
"""
Refreshes the data associated with a Financial Connections Account.
@@ -689,7 +603,7 @@ async def refresh_account_async(
@class_method_variant("_cls_refresh_account_async")
async def refresh_account_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.RefreshAccountParams"]
+ self, **params: Unpack["AccountRefreshAccountParams"]
) -> "Account":
"""
Refreshes the data associated with a Financial Connections Account.
@@ -707,7 +621,7 @@ async def refresh_account_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Account.RetrieveParams"]
+ cls, id: str, **params: Unpack["AccountRetrieveParams"]
) -> "Account":
"""
Retrieves the details of an Financial Connections Account.
@@ -718,7 +632,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Account.RetrieveParams"]
+ cls, id: str, **params: Unpack["AccountRetrieveParams"]
) -> "Account":
"""
Retrieves the details of an Financial Connections Account.
@@ -729,7 +643,7 @@ async def retrieve_async(
@classmethod
def _cls_subscribe(
- cls, account: str, **params: Unpack["Account.SubscribeParams"]
+ cls, account: str, **params: Unpack["AccountSubscribeParams"]
) -> "Account":
"""
Subscribes to periodic refreshes of data associated with a Financial Connections Account.
@@ -748,7 +662,7 @@ def _cls_subscribe(
@overload
@staticmethod
def subscribe(
- account: str, **params: Unpack["Account.SubscribeParams"]
+ account: str, **params: Unpack["AccountSubscribeParams"]
) -> "Account":
"""
Subscribes to periodic refreshes of data associated with a Financial Connections Account.
@@ -757,7 +671,7 @@ def subscribe(
@overload
def subscribe(
- self, **params: Unpack["Account.SubscribeParams"]
+ self, **params: Unpack["AccountSubscribeParams"]
) -> "Account":
"""
Subscribes to periodic refreshes of data associated with a Financial Connections Account.
@@ -766,7 +680,7 @@ def subscribe(
@class_method_variant("_cls_subscribe")
def subscribe( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.SubscribeParams"]
+ self, **params: Unpack["AccountSubscribeParams"]
) -> "Account":
"""
Subscribes to periodic refreshes of data associated with a Financial Connections Account.
@@ -784,7 +698,7 @@ def subscribe( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_subscribe_async(
- cls, account: str, **params: Unpack["Account.SubscribeParams"]
+ cls, account: str, **params: Unpack["AccountSubscribeParams"]
) -> "Account":
"""
Subscribes to periodic refreshes of data associated with a Financial Connections Account.
@@ -803,7 +717,7 @@ async def _cls_subscribe_async(
@overload
@staticmethod
async def subscribe_async(
- account: str, **params: Unpack["Account.SubscribeParams"]
+ account: str, **params: Unpack["AccountSubscribeParams"]
) -> "Account":
"""
Subscribes to periodic refreshes of data associated with a Financial Connections Account.
@@ -812,7 +726,7 @@ async def subscribe_async(
@overload
async def subscribe_async(
- self, **params: Unpack["Account.SubscribeParams"]
+ self, **params: Unpack["AccountSubscribeParams"]
) -> "Account":
"""
Subscribes to periodic refreshes of data associated with a Financial Connections Account.
@@ -821,7 +735,7 @@ async def subscribe_async(
@class_method_variant("_cls_subscribe_async")
async def subscribe_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.SubscribeParams"]
+ self, **params: Unpack["AccountSubscribeParams"]
) -> "Account":
"""
Subscribes to periodic refreshes of data associated with a Financial Connections Account.
@@ -839,7 +753,7 @@ async def subscribe_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_unsubscribe(
- cls, account: str, **params: Unpack["Account.UnsubscribeParams"]
+ cls, account: str, **params: Unpack["AccountUnsubscribeParams"]
) -> "Account":
"""
Unsubscribes from periodic refreshes of data associated with a Financial Connections Account.
@@ -858,7 +772,7 @@ def _cls_unsubscribe(
@overload
@staticmethod
def unsubscribe(
- account: str, **params: Unpack["Account.UnsubscribeParams"]
+ account: str, **params: Unpack["AccountUnsubscribeParams"]
) -> "Account":
"""
Unsubscribes from periodic refreshes of data associated with a Financial Connections Account.
@@ -867,7 +781,7 @@ def unsubscribe(
@overload
def unsubscribe(
- self, **params: Unpack["Account.UnsubscribeParams"]
+ self, **params: Unpack["AccountUnsubscribeParams"]
) -> "Account":
"""
Unsubscribes from periodic refreshes of data associated with a Financial Connections Account.
@@ -876,7 +790,7 @@ def unsubscribe(
@class_method_variant("_cls_unsubscribe")
def unsubscribe( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.UnsubscribeParams"]
+ self, **params: Unpack["AccountUnsubscribeParams"]
) -> "Account":
"""
Unsubscribes from periodic refreshes of data associated with a Financial Connections Account.
@@ -894,7 +808,7 @@ def unsubscribe( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_unsubscribe_async(
- cls, account: str, **params: Unpack["Account.UnsubscribeParams"]
+ cls, account: str, **params: Unpack["AccountUnsubscribeParams"]
) -> "Account":
"""
Unsubscribes from periodic refreshes of data associated with a Financial Connections Account.
@@ -913,7 +827,7 @@ async def _cls_unsubscribe_async(
@overload
@staticmethod
async def unsubscribe_async(
- account: str, **params: Unpack["Account.UnsubscribeParams"]
+ account: str, **params: Unpack["AccountUnsubscribeParams"]
) -> "Account":
"""
Unsubscribes from periodic refreshes of data associated with a Financial Connections Account.
@@ -922,7 +836,7 @@ async def unsubscribe_async(
@overload
async def unsubscribe_async(
- self, **params: Unpack["Account.UnsubscribeParams"]
+ self, **params: Unpack["AccountUnsubscribeParams"]
) -> "Account":
"""
Unsubscribes from periodic refreshes of data associated with a Financial Connections Account.
@@ -931,7 +845,7 @@ async def unsubscribe_async(
@class_method_variant("_cls_unsubscribe_async")
async def unsubscribe_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Account.UnsubscribeParams"]
+ self, **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 9b1263f52..17f591238 100644
--- a/stripe/financial_connections/_account_owner_service.py
+++ b/stripe/financial_connections/_account_owner_service.py
@@ -5,37 +5,20 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.financial_connections._account_owner import AccountOwner
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.financial_connections._account_owner_list_params import (
+ AccountOwnerListParams,
+ )
-class AccountOwnerService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- ownership: str
- """
- The ID of the ownership object to fetch owners from.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
+class AccountOwnerService(StripeService):
def list(
self,
account: str,
- params: "AccountOwnerService.ListParams",
+ params: "AccountOwnerListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[AccountOwner]:
"""
@@ -57,7 +40,7 @@ def list(
async def list_async(
self,
account: str,
- params: "AccountOwnerService.ListParams",
+ 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 7d9e02376..2bae18e46 100644
--- a/stripe/financial_connections/_account_service.py
+++ b/stripe/financial_connections/_account_service.py
@@ -8,8 +8,28 @@
from stripe.financial_connections._account_owner_service import (
AccountOwnerService,
)
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.financial_connections._account_disconnect_params import (
+ AccountDisconnectParams,
+ )
+ from stripe.params.financial_connections._account_list_params import (
+ AccountListParams,
+ )
+ from stripe.params.financial_connections._account_refresh_params import (
+ AccountRefreshParams,
+ )
+ from stripe.params.financial_connections._account_retrieve_params import (
+ AccountRetrieveParams,
+ )
+ from stripe.params.financial_connections._account_subscribe_params import (
+ AccountSubscribeParams,
+ )
+ from stripe.params.financial_connections._account_unsubscribe_params import (
+ AccountUnsubscribeParams,
+ )
class AccountService(StripeService):
@@ -17,87 +37,9 @@ def __init__(self, requestor):
super().__init__(requestor)
self.owners = AccountOwnerService(self._requestor)
- class DisconnectParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(TypedDict):
- account_holder: NotRequired["AccountService.ListParamsAccountHolder"]
- """
- If present, only return accounts that belong to the specified account holder. `account_holder[customer]` and `account_holder[account]` are mutually exclusive.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- session: NotRequired[str]
- """
- If present, only return accounts that were collected as part of the given session.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsAccountHolder(TypedDict):
- account: NotRequired[str]
- """
- The ID of the Stripe account whose accounts will be retrieved.
- """
- customer: NotRequired[str]
- """
- The ID of the Stripe customer whose accounts will be retrieved.
- """
-
- class RefreshParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- features: List[Literal["balance", "ownership", "transactions"]]
- """
- The list of account features that you would like to refresh.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SubscribeParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- features: List[Literal["transactions"]]
- """
- The list of account features to which you would like to subscribe.
- """
-
- class UnsubscribeParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- features: List[Literal["transactions"]]
- """
- The list of account features from which you would like to unsubscribe.
- """
-
def list(
self,
- params: Optional["AccountService.ListParams"] = None,
+ params: Optional["AccountListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Account]:
"""
@@ -116,7 +58,7 @@ def list(
async def list_async(
self,
- params: Optional["AccountService.ListParams"] = None,
+ params: Optional["AccountListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Account]:
"""
@@ -136,7 +78,7 @@ async def list_async(
def retrieve(
self,
account: str,
- params: Optional["AccountService.RetrieveParams"] = None,
+ params: Optional["AccountRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -158,7 +100,7 @@ def retrieve(
async def retrieve_async(
self,
account: str,
- params: Optional["AccountService.RetrieveParams"] = None,
+ params: Optional["AccountRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -180,7 +122,7 @@ async def retrieve_async(
def disconnect(
self,
account: str,
- params: Optional["AccountService.DisconnectParams"] = None,
+ params: Optional["AccountDisconnectParams"] = None,
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -202,7 +144,7 @@ def disconnect(
async def disconnect_async(
self,
account: str,
- params: Optional["AccountService.DisconnectParams"] = None,
+ params: Optional["AccountDisconnectParams"] = None,
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -224,7 +166,7 @@ async def disconnect_async(
def refresh(
self,
account: str,
- params: "AccountService.RefreshParams",
+ params: "AccountRefreshParams",
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -246,7 +188,7 @@ def refresh(
async def refresh_async(
self,
account: str,
- params: "AccountService.RefreshParams",
+ params: "AccountRefreshParams",
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -268,7 +210,7 @@ async def refresh_async(
def subscribe(
self,
account: str,
- params: "AccountService.SubscribeParams",
+ params: "AccountSubscribeParams",
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -290,7 +232,7 @@ def subscribe(
async def subscribe_async(
self,
account: str,
- params: "AccountService.SubscribeParams",
+ params: "AccountSubscribeParams",
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -312,7 +254,7 @@ async def subscribe_async(
def unsubscribe(
self,
account: str,
- params: "AccountService.UnsubscribeParams",
+ params: "AccountUnsubscribeParams",
options: Optional[RequestOptions] = None,
) -> Account:
"""
@@ -334,7 +276,7 @@ def unsubscribe(
async def unsubscribe_async(
self,
account: str,
- params: "AccountService.UnsubscribeParams",
+ params: "AccountUnsubscribeParams",
options: Optional[RequestOptions] = None,
) -> Account:
"""
diff --git a/stripe/financial_connections/_session.py b/stripe/financial_connections/_session.py
index 1109ccda9..bbd15a827 100644
--- a/stripe/financial_connections/_session.py
+++ b/stripe/financial_connections/_session.py
@@ -3,16 +3,9 @@
from stripe._createable_api_resource import CreateableAPIResource
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from typing import ClassVar, List, Optional, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._account import Account as AccountResource
@@ -20,6 +13,12 @@
from stripe.financial_connections._account import (
Account as FinancialConnectionsAccountResource,
)
+ from stripe.params.financial_connections._session_create_params import (
+ SessionCreateParams,
+ )
+ from stripe.params.financial_connections._session_retrieve_params import (
+ SessionRetrieveParams,
+ )
class Session(CreateableAPIResource["Session"]):
@@ -65,78 +64,6 @@ class Filters(StripeObject):
List of countries from which to filter accounts.
"""
- class CreateParams(RequestOptions):
- account_holder: "Session.CreateParamsAccountHolder"
- """
- The account holder to link accounts for.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- filters: NotRequired["Session.CreateParamsFilters"]
- """
- Filters to restrict the kinds of accounts to collect.
- """
- permissions: List[
- Literal["balances", "ownership", "payment_method", "transactions"]
- ]
- """
- List of data features that you would like to request access to.
-
- Possible values are `balances`, `transactions`, `ownership`, and `payment_method`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
- return_url: NotRequired[str]
- """
- For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
- """
-
- class CreateParamsAccountHolder(TypedDict):
- account: NotRequired[str]
- """
- The ID of the Stripe account whose accounts will be retrieved. Should only be present if `type` is `account`.
- """
- customer: NotRequired[str]
- """
- The ID of the Stripe customer whose accounts will be retrieved. Should only be present if `type` is `customer`.
- """
- type: Literal["account", "customer"]
- """
- Type of account holder to collect accounts for.
- """
-
- class CreateParamsFilters(TypedDict):
- account_subcategories: NotRequired[
- List[
- Literal[
- "checking",
- "credit_card",
- "line_of_credit",
- "mortgage",
- "savings",
- ]
- ]
- ]
- """
- Restricts the Session to subcategories of accounts that can be linked. Valid subcategories are: `checking`, `savings`, `mortgage`, `line_of_credit`, `credit_card`.
- """
- countries: NotRequired[List[str]]
- """
- List of countries from which to collect accounts.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
account_holder: Optional[AccountHolder]
"""
The account holder for whom accounts are collected in this session.
@@ -178,7 +105,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["Session.CreateParams"]) -> "Session":
+ def create(cls, **params: Unpack["SessionCreateParams"]) -> "Session":
"""
To launch the Financial Connections authorization flow, create a Session. The session's client_secret can be used to launch the flow using Stripe.js.
"""
@@ -193,7 +120,7 @@ def create(cls, **params: Unpack["Session.CreateParams"]) -> "Session":
@classmethod
async def create_async(
- cls, **params: Unpack["Session.CreateParams"]
+ cls, **params: Unpack["SessionCreateParams"]
) -> "Session":
"""
To launch the Financial Connections authorization flow, create a Session. The session's client_secret can be used to launch the flow using Stripe.js.
@@ -209,7 +136,7 @@ async def create_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Session.RetrieveParams"]
+ cls, id: str, **params: Unpack["SessionRetrieveParams"]
) -> "Session":
"""
Retrieves the details of a Financial Connections Session
@@ -220,7 +147,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Session.RetrieveParams"]
+ cls, id: str, **params: Unpack["SessionRetrieveParams"]
) -> "Session":
"""
Retrieves the details of a Financial Connections Session
diff --git a/stripe/financial_connections/_session_service.py b/stripe/financial_connections/_session_service.py
index 8703feb0b..ad8a34782 100644
--- a/stripe/financial_connections/_session_service.py
+++ b/stripe/financial_connections/_session_service.py
@@ -4,87 +4,23 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.financial_connections._session import Session
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.financial_connections._session_create_params import (
+ SessionCreateParams,
+ )
+ from stripe.params.financial_connections._session_retrieve_params import (
+ SessionRetrieveParams,
+ )
-class SessionService(StripeService):
- class CreateParams(TypedDict):
- account_holder: "SessionService.CreateParamsAccountHolder"
- """
- The account holder to link accounts for.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- filters: NotRequired["SessionService.CreateParamsFilters"]
- """
- Filters to restrict the kinds of accounts to collect.
- """
- permissions: List[
- Literal["balances", "ownership", "payment_method", "transactions"]
- ]
- """
- List of data features that you would like to request access to.
-
- Possible values are `balances`, `transactions`, `ownership`, and `payment_method`.
- """
- prefetch: NotRequired[
- List[Literal["balances", "ownership", "transactions"]]
- ]
- """
- List of data features that you would like to retrieve upon account creation.
- """
- return_url: NotRequired[str]
- """
- For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
- """
-
- class CreateParamsAccountHolder(TypedDict):
- account: NotRequired[str]
- """
- The ID of the Stripe account whose accounts will be retrieved. Should only be present if `type` is `account`.
- """
- customer: NotRequired[str]
- """
- The ID of the Stripe customer whose accounts will be retrieved. Should only be present if `type` is `customer`.
- """
- type: Literal["account", "customer"]
- """
- Type of account holder to collect accounts for.
- """
-
- class CreateParamsFilters(TypedDict):
- account_subcategories: NotRequired[
- List[
- Literal[
- "checking",
- "credit_card",
- "line_of_credit",
- "mortgage",
- "savings",
- ]
- ]
- ]
- """
- Restricts the Session to subcategories of accounts that can be linked. Valid subcategories are: `checking`, `savings`, `mortgage`, `line_of_credit`, `credit_card`.
- """
- countries: NotRequired[List[str]]
- """
- List of countries from which to collect accounts.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class SessionService(StripeService):
def retrieve(
self,
session: str,
- params: Optional["SessionService.RetrieveParams"] = None,
+ params: Optional["SessionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Session:
"""
@@ -106,7 +42,7 @@ def retrieve(
async def retrieve_async(
self,
session: str,
- params: Optional["SessionService.RetrieveParams"] = None,
+ params: Optional["SessionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Session:
"""
@@ -127,7 +63,7 @@ async def retrieve_async(
def create(
self,
- params: "SessionService.CreateParams",
+ params: "SessionCreateParams",
options: Optional[RequestOptions] = None,
) -> Session:
"""
@@ -146,7 +82,7 @@ def create(
async def create_async(
self,
- params: "SessionService.CreateParams",
+ params: "SessionCreateParams",
options: Optional[RequestOptions] = None,
) -> Session:
"""
diff --git a/stripe/financial_connections/_transaction.py b/stripe/financial_connections/_transaction.py
index 47188a1cb..9a5369584 100644
--- a/stripe/financial_connections/_transaction.py
+++ b/stripe/financial_connections/_transaction.py
@@ -2,10 +2,17 @@
# File generated from our OpenAPI spec
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
-from typing import ClassVar, List, Optional
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing import ClassVar, Optional
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.financial_connections._transaction_list_params import (
+ TransactionListParams,
+ )
+ from stripe.params.financial_connections._transaction_retrieve_params import (
+ TransactionRetrieveParams,
+ )
class Transaction(ListableAPIResource["Transaction"]):
@@ -27,68 +34,6 @@ class StatusTransitions(StripeObject):
Time at which this transaction was voided. Measured in seconds since the Unix epoch.
"""
- class ListParams(RequestOptions):
- account: str
- """
- The ID of the Financial Connections Account whose transactions will be retrieved.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- transacted_at: NotRequired["Transaction.ListParamsTransactedAt|int"]
- """
- A filter on the list based on the object `transacted_at` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with the following options:
- """
- transaction_refresh: NotRequired[
- "Transaction.ListParamsTransactionRefresh"
- ]
- """
- A filter on the list based on the object `transaction_refresh` field. The value can be a dictionary with the following options:
- """
-
- class ListParamsTransactedAt(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsTransactionRefresh(TypedDict):
- after: str
- """
- Return results where the transactions were created or updated by a refresh that took place after this refresh (non-inclusive).
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
account: str
"""
The ID of the Financial Connections Account this transaction belongs to.
@@ -137,7 +82,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["Transaction.ListParams"]
+ cls, **params: Unpack["TransactionListParams"]
) -> ListObject["Transaction"]:
"""
Returns a list of Financial Connections Transaction objects.
@@ -157,7 +102,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Transaction.ListParams"]
+ cls, **params: Unpack["TransactionListParams"]
) -> ListObject["Transaction"]:
"""
Returns a list of Financial Connections Transaction objects.
@@ -177,7 +122,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Transaction.RetrieveParams"]
+ cls, id: str, **params: Unpack["TransactionRetrieveParams"]
) -> "Transaction":
"""
Retrieves the details of a Financial Connections Transaction
@@ -188,7 +133,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Transaction.RetrieveParams"]
+ cls, id: str, **params: Unpack["TransactionRetrieveParams"]
) -> "Transaction":
"""
Retrieves the details of a Financial Connections Transaction
diff --git a/stripe/financial_connections/_transaction_service.py b/stripe/financial_connections/_transaction_service.py
index 9bcc53a68..58dceb483 100644
--- a/stripe/financial_connections/_transaction_service.py
+++ b/stripe/financial_connections/_transaction_service.py
@@ -5,78 +5,22 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.financial_connections._transaction import Transaction
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.financial_connections._transaction_list_params import (
+ TransactionListParams,
+ )
+ from stripe.params.financial_connections._transaction_retrieve_params import (
+ TransactionRetrieveParams,
+ )
-class TransactionService(StripeService):
- class ListParams(TypedDict):
- account: str
- """
- The ID of the Financial Connections Account whose transactions will be retrieved.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- transacted_at: NotRequired[
- "TransactionService.ListParamsTransactedAt|int"
- ]
- """
- A filter on the list based on the object `transacted_at` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with the following options:
- """
- transaction_refresh: NotRequired[
- "TransactionService.ListParamsTransactionRefresh"
- ]
- """
- A filter on the list based on the object `transaction_refresh` field. The value can be a dictionary with the following options:
- """
-
- class ListParamsTransactedAt(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsTransactionRefresh(TypedDict):
- after: str
- """
- Return results where the transactions were created or updated by a refresh that took place after this refresh (non-inclusive).
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class TransactionService(StripeService):
def list(
self,
- params: "TransactionService.ListParams",
+ params: "TransactionListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[Transaction]:
"""
@@ -95,7 +39,7 @@ def list(
async def list_async(
self,
- params: "TransactionService.ListParams",
+ params: "TransactionListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[Transaction]:
"""
@@ -115,7 +59,7 @@ async def list_async(
def retrieve(
self,
transaction: str,
- params: Optional["TransactionService.RetrieveParams"] = None,
+ params: Optional["TransactionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
@@ -137,7 +81,7 @@ def retrieve(
async def retrieve_async(
self,
transaction: str,
- params: Optional["TransactionService.RetrieveParams"] = None,
+ params: Optional["TransactionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
diff --git a/stripe/forwarding/_request.py b/stripe/forwarding/_request.py
index 787704049..cd1bd7016 100644
--- a/stripe/forwarding/_request.py
+++ b/stripe/forwarding/_request.py
@@ -3,10 +3,18 @@
from stripe._createable_api_resource import CreateableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from typing import ClassVar, Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.forwarding._request_create_params import (
+ RequestCreateParams,
+ )
+ from stripe.params.forwarding._request_list_params import RequestListParams
+ from stripe.params.forwarding._request_retrieve_params import (
+ RequestRetrieveParams,
+ )
class Request(
@@ -93,106 +101,6 @@ class Header(StripeObject):
"""
_inner_class_types = {"headers": Header}
- class CreateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- payment_method: str
- """
- The PaymentMethod to insert into the forwarded request. Forwarding previously consumed PaymentMethods is allowed.
- """
- replacements: List[
- Literal[
- "card_cvc",
- "card_expiry",
- "card_number",
- "cardholder_name",
- "request_signature",
- ]
- ]
- """
- The field kinds to be replaced in the forwarded request.
- """
- request: "Request.CreateParamsRequest"
- """
- The request body and headers to be sent to the destination endpoint.
- """
- url: str
- """
- The destination URL for the forwarded request. Must be supported by the config.
- """
-
- class CreateParamsRequest(TypedDict):
- body: NotRequired[str]
- """
- The body payload to send to the destination endpoint.
- """
- headers: NotRequired[List["Request.CreateParamsRequestHeader"]]
- """
- The headers to include in the forwarded request. Can be omitted if no additional headers (excluding Stripe-generated ones such as the Content-Type header) should be included.
- """
-
- class CreateParamsRequestHeader(TypedDict):
- name: str
- """
- The header name.
- """
- value: str
- """
- The header value.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["Request.ListParamsCreated"]
- """
- Similar to other List endpoints, filters results based on created timestamp. You can pass gt, gte, lt, and lte timestamp values.
- """
- ending_before: NotRequired[str]
- """
- A pagination cursor to fetch the previous page of the list. The value must be a ForwardingRequest ID.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A pagination cursor to fetch the next page of the list. The value must be a ForwardingRequest ID.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Return results where the `created` field is greater than this value.
- """
- gte: NotRequired[int]
- """
- Return results where the `created` field is greater than or equal to this value.
- """
- lt: NotRequired[int]
- """
- Return results where the `created` field is less than this value.
- """
- lte: NotRequired[int]
- """
- Return results where the `created` field is less than or equal to this value.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -247,7 +155,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["Request.CreateParams"]) -> "Request":
+ def create(cls, **params: Unpack["RequestCreateParams"]) -> "Request":
"""
Creates a ForwardingRequest object.
"""
@@ -262,7 +170,7 @@ def create(cls, **params: Unpack["Request.CreateParams"]) -> "Request":
@classmethod
async def create_async(
- cls, **params: Unpack["Request.CreateParams"]
+ cls, **params: Unpack["RequestCreateParams"]
) -> "Request":
"""
Creates a ForwardingRequest object.
@@ -278,7 +186,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["Request.ListParams"]
+ cls, **params: Unpack["RequestListParams"]
) -> ListObject["Request"]:
"""
Lists all ForwardingRequest objects.
@@ -298,7 +206,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Request.ListParams"]
+ cls, **params: Unpack["RequestListParams"]
) -> ListObject["Request"]:
"""
Lists all ForwardingRequest objects.
@@ -318,7 +226,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Request.RetrieveParams"]
+ cls, id: str, **params: Unpack["RequestRetrieveParams"]
) -> "Request":
"""
Retrieves a ForwardingRequest object.
@@ -329,7 +237,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Request.RetrieveParams"]
+ cls, id: str, **params: Unpack["RequestRetrieveParams"]
) -> "Request":
"""
Retrieves a ForwardingRequest object.
diff --git a/stripe/forwarding/_request_service.py b/stripe/forwarding/_request_service.py
index 378b9372a..cf6e9bc84 100644
--- a/stripe/forwarding/_request_service.py
+++ b/stripe/forwarding/_request_service.py
@@ -5,114 +5,23 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.forwarding._request import Request
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.forwarding._request_create_params import (
+ RequestCreateParams,
+ )
+ from stripe.params.forwarding._request_list_params import RequestListParams
+ from stripe.params.forwarding._request_retrieve_params import (
+ RequestRetrieveParams,
+ )
-class RequestService(StripeService):
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- payment_method: str
- """
- The PaymentMethod to insert into the forwarded request. Forwarding previously consumed PaymentMethods is allowed.
- """
- replacements: List[
- Literal[
- "card_cvc",
- "card_expiry",
- "card_number",
- "cardholder_name",
- "request_signature",
- ]
- ]
- """
- The field kinds to be replaced in the forwarded request.
- """
- request: "RequestService.CreateParamsRequest"
- """
- The request body and headers to be sent to the destination endpoint.
- """
- url: str
- """
- The destination URL for the forwarded request. Must be supported by the config.
- """
-
- class CreateParamsRequest(TypedDict):
- body: NotRequired[str]
- """
- The body payload to send to the destination endpoint.
- """
- headers: NotRequired[List["RequestService.CreateParamsRequestHeader"]]
- """
- The headers to include in the forwarded request. Can be omitted if no additional headers (excluding Stripe-generated ones such as the Content-Type header) should be included.
- """
-
- class CreateParamsRequestHeader(TypedDict):
- name: str
- """
- The header name.
- """
- value: str
- """
- The header value.
- """
-
- class ListParams(TypedDict):
- created: NotRequired["RequestService.ListParamsCreated"]
- """
- Similar to other List endpoints, filters results based on created timestamp. You can pass gt, gte, lt, and lte timestamp values.
- """
- ending_before: NotRequired[str]
- """
- A pagination cursor to fetch the previous page of the list. The value must be a ForwardingRequest ID.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A pagination cursor to fetch the next page of the list. The value must be a ForwardingRequest ID.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Return results where the `created` field is greater than this value.
- """
- gte: NotRequired[int]
- """
- Return results where the `created` field is greater than or equal to this value.
- """
- lt: NotRequired[int]
- """
- Return results where the `created` field is less than this value.
- """
- lte: NotRequired[int]
- """
- Return results where the `created` field is less than or equal to this value.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class RequestService(StripeService):
def list(
self,
- params: Optional["RequestService.ListParams"] = None,
+ params: Optional["RequestListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Request]:
"""
@@ -131,7 +40,7 @@ def list(
async def list_async(
self,
- params: Optional["RequestService.ListParams"] = None,
+ params: Optional["RequestListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Request]:
"""
@@ -150,7 +59,7 @@ async def list_async(
def create(
self,
- params: "RequestService.CreateParams",
+ params: "RequestCreateParams",
options: Optional[RequestOptions] = None,
) -> Request:
"""
@@ -169,7 +78,7 @@ def create(
async def create_async(
self,
- params: "RequestService.CreateParams",
+ params: "RequestCreateParams",
options: Optional[RequestOptions] = None,
) -> Request:
"""
@@ -189,7 +98,7 @@ async def create_async(
def retrieve(
self,
id: str,
- params: Optional["RequestService.RetrieveParams"] = None,
+ params: Optional["RequestRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Request:
"""
@@ -209,7 +118,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["RequestService.RetrieveParams"] = None,
+ params: Optional["RequestRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Request:
"""
diff --git a/stripe/identity/_verification_report.py b/stripe/identity/_verification_report.py
index 50f215251..335851502 100644
--- a/stripe/identity/_verification_report.py
+++ b/stripe/identity/_verification_report.py
@@ -2,10 +2,17 @@
# File generated from our OpenAPI spec
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from typing import ClassVar, List, Optional
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.identity._verification_report_list_params import (
+ VerificationReportListParams,
+ )
+ from stripe.params.identity._verification_report_retrieve_params import (
+ VerificationReportRetrieveParams,
+ )
class VerificationReport(ListableAPIResource["VerificationReport"]):
@@ -363,64 +370,6 @@ class Error(StripeObject):
"""
_inner_class_types = {"error": Error}
- class ListParams(RequestOptions):
- client_reference_id: NotRequired[str]
- """
- A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
- """
- created: NotRequired["VerificationReport.ListParamsCreated|int"]
- """
- Only return VerificationReports that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[Literal["document", "id_number"]]
- """
- Only return VerificationReports of this type
- """
- verification_session: NotRequired[str]
- """
- Only return VerificationReports created by this VerificationSession ID. It is allowed to provide a VerificationIntent ID.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
client_reference_id: Optional[str]
"""
A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
@@ -477,7 +426,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["VerificationReport.ListParams"]
+ cls, **params: Unpack["VerificationReportListParams"]
) -> ListObject["VerificationReport"]:
"""
List all verification reports.
@@ -497,7 +446,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["VerificationReport.ListParams"]
+ cls, **params: Unpack["VerificationReportListParams"]
) -> ListObject["VerificationReport"]:
"""
List all verification reports.
@@ -517,7 +466,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["VerificationReport.RetrieveParams"]
+ cls, id: str, **params: Unpack["VerificationReportRetrieveParams"]
) -> "VerificationReport":
"""
Retrieves an existing VerificationReport
@@ -528,7 +477,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["VerificationReport.RetrieveParams"]
+ cls, id: str, **params: Unpack["VerificationReportRetrieveParams"]
) -> "VerificationReport":
"""
Retrieves an existing VerificationReport
diff --git a/stripe/identity/_verification_report_service.py b/stripe/identity/_verification_report_service.py
index f9f5940b7..8ea97bfb2 100644
--- a/stripe/identity/_verification_report_service.py
+++ b/stripe/identity/_verification_report_service.py
@@ -5,72 +5,22 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.identity._verification_report import VerificationReport
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.identity._verification_report_list_params import (
+ VerificationReportListParams,
+ )
+ from stripe.params.identity._verification_report_retrieve_params import (
+ VerificationReportRetrieveParams,
+ )
-class VerificationReportService(StripeService):
- class ListParams(TypedDict):
- client_reference_id: NotRequired[str]
- """
- A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
- """
- created: NotRequired["VerificationReportService.ListParamsCreated|int"]
- """
- Only return VerificationReports that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[Literal["document", "id_number"]]
- """
- Only return VerificationReports of this type
- """
- verification_session: NotRequired[str]
- """
- Only return VerificationReports created by this VerificationSession ID. It is allowed to provide a VerificationIntent ID.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class VerificationReportService(StripeService):
def list(
self,
- params: Optional["VerificationReportService.ListParams"] = None,
+ params: Optional["VerificationReportListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[VerificationReport]:
"""
@@ -89,7 +39,7 @@ def list(
async def list_async(
self,
- params: Optional["VerificationReportService.ListParams"] = None,
+ params: Optional["VerificationReportListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[VerificationReport]:
"""
@@ -109,7 +59,7 @@ async def list_async(
def retrieve(
self,
report: str,
- params: Optional["VerificationReportService.RetrieveParams"] = None,
+ params: Optional["VerificationReportRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> VerificationReport:
"""
@@ -131,7 +81,7 @@ def retrieve(
async def retrieve_async(
self,
report: str,
- params: Optional["VerificationReportService.RetrieveParams"] = None,
+ params: Optional["VerificationReportRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> VerificationReport:
"""
diff --git a/stripe/identity/_verification_session.py b/stripe/identity/_verification_session.py
index 4e68f74c2..7c7fe4982 100644
--- a/stripe/identity/_verification_session.py
+++ b/stripe/identity/_verification_session.py
@@ -4,21 +4,32 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe.identity._verification_report import VerificationReport
+ from stripe.params.identity._verification_session_cancel_params import (
+ VerificationSessionCancelParams,
+ )
+ from stripe.params.identity._verification_session_create_params import (
+ VerificationSessionCreateParams,
+ )
+ from stripe.params.identity._verification_session_list_params import (
+ VerificationSessionListParams,
+ )
+ from stripe.params.identity._verification_session_modify_params import (
+ VerificationSessionModifyParams,
+ )
+ from stripe.params.identity._verification_session_redact_params import (
+ VerificationSessionRedactParams,
+ )
+ from stripe.params.identity._verification_session_retrieve_params import (
+ VerificationSessionRetrieveParams,
+ )
class VerificationSession(
@@ -248,231 +259,6 @@ class Dob(StripeObject):
"""
_inner_class_types = {"address": Address, "dob": Dob}
- class CancelParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(RequestOptions):
- client_reference_id: NotRequired[str]
- """
- A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- options: NotRequired["VerificationSession.CreateParamsOptions"]
- """
- A set of options for the session's verification checks.
- """
- provided_details: NotRequired[
- "VerificationSession.CreateParamsProvidedDetails"
- ]
- """
- Details provided about the user being verified. These details may be shown to the user.
- """
- related_customer: NotRequired[str]
- """
- Customer ID
- """
- related_person: NotRequired[
- "VerificationSession.CreateParamsRelatedPerson"
- ]
- """
- Tokens referencing a Person resource and it's associated account.
- """
- return_url: NotRequired[str]
- """
- The URL that the user will be redirected to upon completing the verification flow.
- """
- type: NotRequired[Literal["document", "id_number"]]
- """
- The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed. You must provide a `type` if not passing `verification_flow`.
- """
- verification_flow: NotRequired[str]
- """
- The ID of a verification flow from the Dashboard. See https://docs.stripe.com/identity/verification-flows.
- """
-
- class CreateParamsOptions(TypedDict):
- document: NotRequired[
- "Literal['']|VerificationSession.CreateParamsOptionsDocument"
- ]
- """
- Options that apply to the [document check](https://stripe.com/docs/identity/verification-checks?type=document).
- """
-
- class CreateParamsOptionsDocument(TypedDict):
- allowed_types: NotRequired[
- List[Literal["driving_license", "id_card", "passport"]]
- ]
- """
- Array of strings of allowed identity document types. If the provided identity document isn't one of the allowed types, the verification check will fail with a document_type_not_allowed error code.
- """
- require_id_number: NotRequired[bool]
- """
- Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document's extracted name and date of birth.
- """
- require_live_capture: NotRequired[bool]
- """
- Disable image uploads, identity document images have to be captured using the device's camera.
- """
- require_matching_selfie: NotRequired[bool]
- """
- Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user's face. [Learn more](https://stripe.com/docs/identity/selfie).
- """
-
- class CreateParamsProvidedDetails(TypedDict):
- email: NotRequired[str]
- """
- Email of user being verified
- """
- phone: NotRequired[str]
- """
- Phone number of user being verified
- """
-
- class CreateParamsRelatedPerson(TypedDict):
- account: str
- """
- A token representing a connected account. If provided, the person parameter is also required and must be associated with the account.
- """
- person: str
- """
- A token referencing a Person resource that this verification is being used to verify.
- """
-
- class ListParams(RequestOptions):
- client_reference_id: NotRequired[str]
- """
- A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
- """
- created: NotRequired["VerificationSession.ListParamsCreated|int"]
- """
- Only return VerificationSessions that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- related_customer: NotRequired[str]
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["canceled", "processing", "requires_input", "verified"]
- ]
- """
- Only return VerificationSessions with this status. [Learn more about the lifecycle of sessions](https://stripe.com/docs/identity/how-sessions-work).
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- options: NotRequired["VerificationSession.ModifyParamsOptions"]
- """
- A set of options for the session's verification checks.
- """
- provided_details: NotRequired[
- "VerificationSession.ModifyParamsProvidedDetails"
- ]
- """
- Details provided about the user being verified. These details may be shown to the user.
- """
- type: NotRequired[Literal["document", "id_number"]]
- """
- The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed.
- """
-
- class ModifyParamsOptions(TypedDict):
- document: NotRequired[
- "Literal['']|VerificationSession.ModifyParamsOptionsDocument"
- ]
- """
- Options that apply to the [document check](https://stripe.com/docs/identity/verification-checks?type=document).
- """
-
- class ModifyParamsOptionsDocument(TypedDict):
- allowed_types: NotRequired[
- List[Literal["driving_license", "id_card", "passport"]]
- ]
- """
- Array of strings of allowed identity document types. If the provided identity document isn't one of the allowed types, the verification check will fail with a document_type_not_allowed error code.
- """
- require_id_number: NotRequired[bool]
- """
- Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document's extracted name and date of birth.
- """
- require_live_capture: NotRequired[bool]
- """
- Disable image uploads, identity document images have to be captured using the device's camera.
- """
- require_matching_selfie: NotRequired[bool]
- """
- Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user's face. [Learn more](https://stripe.com/docs/identity/selfie).
- """
-
- class ModifyParamsProvidedDetails(TypedDict):
- email: NotRequired[str]
- """
- Email of user being verified
- """
- phone: NotRequired[str]
- """
- Phone number of user being verified
- """
-
- class RedactParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
client_reference_id: Optional[str]
"""
A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
@@ -549,7 +335,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def _cls_cancel(
- cls, session: str, **params: Unpack["VerificationSession.CancelParams"]
+ 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).
@@ -570,7 +356,7 @@ def _cls_cancel(
@overload
@staticmethod
def cancel(
- session: str, **params: Unpack["VerificationSession.CancelParams"]
+ 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).
@@ -581,7 +367,7 @@ def cancel(
@overload
def cancel(
- self, **params: Unpack["VerificationSession.CancelParams"]
+ self, **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).
@@ -592,7 +378,7 @@ def cancel(
@class_method_variant("_cls_cancel")
def cancel( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["VerificationSession.CancelParams"]
+ self, **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).
@@ -612,7 +398,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_cancel_async(
- cls, session: str, **params: Unpack["VerificationSession.CancelParams"]
+ 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).
@@ -633,7 +419,7 @@ async def _cls_cancel_async(
@overload
@staticmethod
async def cancel_async(
- session: str, **params: Unpack["VerificationSession.CancelParams"]
+ 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).
@@ -644,7 +430,7 @@ async def cancel_async(
@overload
async def cancel_async(
- self, **params: Unpack["VerificationSession.CancelParams"]
+ self, **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).
@@ -655,7 +441,7 @@ async def cancel_async(
@class_method_variant("_cls_cancel_async")
async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["VerificationSession.CancelParams"]
+ self, **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).
@@ -675,7 +461,7 @@ async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def create(
- cls, **params: Unpack["VerificationSession.CreateParams"]
+ cls, **params: Unpack["VerificationSessionCreateParams"]
) -> "VerificationSession":
"""
Creates a VerificationSession object.
@@ -697,7 +483,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["VerificationSession.CreateParams"]
+ cls, **params: Unpack["VerificationSessionCreateParams"]
) -> "VerificationSession":
"""
Creates a VerificationSession object.
@@ -719,7 +505,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["VerificationSession.ListParams"]
+ cls, **params: Unpack["VerificationSessionListParams"]
) -> ListObject["VerificationSession"]:
"""
Returns a list of VerificationSessions
@@ -739,7 +525,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["VerificationSession.ListParams"]
+ cls, **params: Unpack["VerificationSessionListParams"]
) -> ListObject["VerificationSession"]:
"""
Returns a list of VerificationSessions
@@ -759,7 +545,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["VerificationSession.ModifyParams"]
+ cls, id: str, **params: Unpack["VerificationSessionModifyParams"]
) -> "VerificationSession":
"""
Updates a VerificationSession object.
@@ -779,7 +565,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["VerificationSession.ModifyParams"]
+ cls, id: str, **params: Unpack["VerificationSessionModifyParams"]
) -> "VerificationSession":
"""
Updates a VerificationSession object.
@@ -799,7 +585,7 @@ async def modify_async(
@classmethod
def _cls_redact(
- cls, session: str, **params: Unpack["VerificationSession.RedactParams"]
+ cls, session: str, **params: Unpack["VerificationSessionRedactParams"]
) -> "VerificationSession":
"""
Redact a VerificationSession to remove all collected information from Stripe. This will redact
@@ -836,7 +622,7 @@ def _cls_redact(
@overload
@staticmethod
def redact(
- session: str, **params: Unpack["VerificationSession.RedactParams"]
+ session: str, **params: Unpack["VerificationSessionRedactParams"]
) -> "VerificationSession":
"""
Redact a VerificationSession to remove all collected information from Stripe. This will redact
@@ -863,7 +649,7 @@ def redact(
@overload
def redact(
- self, **params: Unpack["VerificationSession.RedactParams"]
+ self, **params: Unpack["VerificationSessionRedactParams"]
) -> "VerificationSession":
"""
Redact a VerificationSession to remove all collected information from Stripe. This will redact
@@ -890,7 +676,7 @@ def redact(
@class_method_variant("_cls_redact")
def redact( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["VerificationSession.RedactParams"]
+ self, **params: Unpack["VerificationSessionRedactParams"]
) -> "VerificationSession":
"""
Redact a VerificationSession to remove all collected information from Stripe. This will redact
@@ -926,7 +712,7 @@ def redact( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_redact_async(
- cls, session: str, **params: Unpack["VerificationSession.RedactParams"]
+ cls, session: str, **params: Unpack["VerificationSessionRedactParams"]
) -> "VerificationSession":
"""
Redact a VerificationSession to remove all collected information from Stripe. This will redact
@@ -963,7 +749,7 @@ async def _cls_redact_async(
@overload
@staticmethod
async def redact_async(
- session: str, **params: Unpack["VerificationSession.RedactParams"]
+ session: str, **params: Unpack["VerificationSessionRedactParams"]
) -> "VerificationSession":
"""
Redact a VerificationSession to remove all collected information from Stripe. This will redact
@@ -990,7 +776,7 @@ async def redact_async(
@overload
async def redact_async(
- self, **params: Unpack["VerificationSession.RedactParams"]
+ self, **params: Unpack["VerificationSessionRedactParams"]
) -> "VerificationSession":
"""
Redact a VerificationSession to remove all collected information from Stripe. This will redact
@@ -1017,7 +803,7 @@ async def redact_async(
@class_method_variant("_cls_redact_async")
async def redact_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["VerificationSession.RedactParams"]
+ self, **params: Unpack["VerificationSessionRedactParams"]
) -> "VerificationSession":
"""
Redact a VerificationSession to remove all collected information from Stripe. This will redact
@@ -1053,7 +839,7 @@ async def redact_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["VerificationSession.RetrieveParams"]
+ cls, id: str, **params: Unpack["VerificationSessionRetrieveParams"]
) -> "VerificationSession":
"""
Retrieves the details of a VerificationSession that was previously created.
@@ -1067,7 +853,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["VerificationSession.RetrieveParams"]
+ cls, id: str, **params: Unpack["VerificationSessionRetrieveParams"]
) -> "VerificationSession":
"""
Retrieves the details of a VerificationSession that was previously created.
diff --git a/stripe/identity/_verification_session_service.py b/stripe/identity/_verification_session_service.py
index 7e6d1574b..aa48f91fa 100644
--- a/stripe/identity/_verification_session_service.py
+++ b/stripe/identity/_verification_session_service.py
@@ -5,241 +5,34 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.identity._verification_session import VerificationSession
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.identity._verification_session_cancel_params import (
+ VerificationSessionCancelParams,
+ )
+ from stripe.params.identity._verification_session_create_params import (
+ VerificationSessionCreateParams,
+ )
+ from stripe.params.identity._verification_session_list_params import (
+ VerificationSessionListParams,
+ )
+ from stripe.params.identity._verification_session_redact_params import (
+ VerificationSessionRedactParams,
+ )
+ from stripe.params.identity._verification_session_retrieve_params import (
+ VerificationSessionRetrieveParams,
+ )
+ from stripe.params.identity._verification_session_update_params import (
+ VerificationSessionUpdateParams,
+ )
class VerificationSessionService(StripeService):
- class CancelParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(TypedDict):
- client_reference_id: NotRequired[str]
- """
- A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- options: NotRequired["VerificationSessionService.CreateParamsOptions"]
- """
- A set of options for the session's verification checks.
- """
- provided_details: NotRequired[
- "VerificationSessionService.CreateParamsProvidedDetails"
- ]
- """
- Details provided about the user being verified. These details may be shown to the user.
- """
- related_customer: NotRequired[str]
- """
- Customer ID
- """
- related_person: NotRequired[
- "VerificationSessionService.CreateParamsRelatedPerson"
- ]
- """
- Tokens referencing a Person resource and it's associated account.
- """
- return_url: NotRequired[str]
- """
- The URL that the user will be redirected to upon completing the verification flow.
- """
- type: NotRequired[Literal["document", "id_number"]]
- """
- The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed. You must provide a `type` if not passing `verification_flow`.
- """
- verification_flow: NotRequired[str]
- """
- The ID of a verification flow from the Dashboard. See https://docs.stripe.com/identity/verification-flows.
- """
-
- class CreateParamsOptions(TypedDict):
- document: NotRequired[
- "Literal['']|VerificationSessionService.CreateParamsOptionsDocument"
- ]
- """
- Options that apply to the [document check](https://stripe.com/docs/identity/verification-checks?type=document).
- """
-
- class CreateParamsOptionsDocument(TypedDict):
- allowed_types: NotRequired[
- List[Literal["driving_license", "id_card", "passport"]]
- ]
- """
- Array of strings of allowed identity document types. If the provided identity document isn't one of the allowed types, the verification check will fail with a document_type_not_allowed error code.
- """
- require_id_number: NotRequired[bool]
- """
- Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document's extracted name and date of birth.
- """
- require_live_capture: NotRequired[bool]
- """
- Disable image uploads, identity document images have to be captured using the device's camera.
- """
- require_matching_selfie: NotRequired[bool]
- """
- Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user's face. [Learn more](https://stripe.com/docs/identity/selfie).
- """
-
- class CreateParamsProvidedDetails(TypedDict):
- email: NotRequired[str]
- """
- Email of user being verified
- """
- phone: NotRequired[str]
- """
- Phone number of user being verified
- """
-
- class CreateParamsRelatedPerson(TypedDict):
- account: str
- """
- A token representing a connected account. If provided, the person parameter is also required and must be associated with the account.
- """
- person: str
- """
- A token referencing a Person resource that this verification is being used to verify.
- """
-
- class ListParams(TypedDict):
- client_reference_id: NotRequired[str]
- """
- A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
- """
- created: NotRequired[
- "VerificationSessionService.ListParamsCreated|int"
- ]
- """
- Only return VerificationSessions that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- related_customer: NotRequired[str]
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["canceled", "processing", "requires_input", "verified"]
- ]
- """
- Only return VerificationSessions with this status. [Learn more about the lifecycle of sessions](https://stripe.com/docs/identity/how-sessions-work).
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RedactParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- options: NotRequired["VerificationSessionService.UpdateParamsOptions"]
- """
- A set of options for the session's verification checks.
- """
- provided_details: NotRequired[
- "VerificationSessionService.UpdateParamsProvidedDetails"
- ]
- """
- Details provided about the user being verified. These details may be shown to the user.
- """
- type: NotRequired[Literal["document", "id_number"]]
- """
- The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed.
- """
-
- class UpdateParamsOptions(TypedDict):
- document: NotRequired[
- "Literal['']|VerificationSessionService.UpdateParamsOptionsDocument"
- ]
- """
- Options that apply to the [document check](https://stripe.com/docs/identity/verification-checks?type=document).
- """
-
- class UpdateParamsOptionsDocument(TypedDict):
- allowed_types: NotRequired[
- List[Literal["driving_license", "id_card", "passport"]]
- ]
- """
- Array of strings of allowed identity document types. If the provided identity document isn't one of the allowed types, the verification check will fail with a document_type_not_allowed error code.
- """
- require_id_number: NotRequired[bool]
- """
- Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document's extracted name and date of birth.
- """
- require_live_capture: NotRequired[bool]
- """
- Disable image uploads, identity document images have to be captured using the device's camera.
- """
- require_matching_selfie: NotRequired[bool]
- """
- Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user's face. [Learn more](https://stripe.com/docs/identity/selfie).
- """
-
- class UpdateParamsProvidedDetails(TypedDict):
- email: NotRequired[str]
- """
- Email of user being verified
- """
- phone: NotRequired[str]
- """
- Phone number of user being verified
- """
-
def list(
self,
- params: Optional["VerificationSessionService.ListParams"] = None,
+ params: Optional["VerificationSessionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[VerificationSession]:
"""
@@ -258,7 +51,7 @@ def list(
async def list_async(
self,
- params: Optional["VerificationSessionService.ListParams"] = None,
+ params: Optional["VerificationSessionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[VerificationSession]:
"""
@@ -277,7 +70,7 @@ async def list_async(
def create(
self,
- params: Optional["VerificationSessionService.CreateParams"] = None,
+ params: Optional["VerificationSessionCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> VerificationSession:
"""
@@ -302,7 +95,7 @@ def create(
async def create_async(
self,
- params: Optional["VerificationSessionService.CreateParams"] = None,
+ params: Optional["VerificationSessionCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> VerificationSession:
"""
@@ -328,7 +121,7 @@ async def create_async(
def retrieve(
self,
session: str,
- params: Optional["VerificationSessionService.RetrieveParams"] = None,
+ params: Optional["VerificationSessionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> VerificationSession:
"""
@@ -353,7 +146,7 @@ def retrieve(
async def retrieve_async(
self,
session: str,
- params: Optional["VerificationSessionService.RetrieveParams"] = None,
+ params: Optional["VerificationSessionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> VerificationSession:
"""
@@ -378,7 +171,7 @@ async def retrieve_async(
def update(
self,
session: str,
- params: Optional["VerificationSessionService.UpdateParams"] = None,
+ params: Optional["VerificationSessionUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> VerificationSession:
"""
@@ -403,7 +196,7 @@ def update(
async def update_async(
self,
session: str,
- params: Optional["VerificationSessionService.UpdateParams"] = None,
+ params: Optional["VerificationSessionUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> VerificationSession:
"""
@@ -428,7 +221,7 @@ async def update_async(
def cancel(
self,
session: str,
- params: Optional["VerificationSessionService.CancelParams"] = None,
+ params: Optional["VerificationSessionCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> VerificationSession:
"""
@@ -452,7 +245,7 @@ def cancel(
async def cancel_async(
self,
session: str,
- params: Optional["VerificationSessionService.CancelParams"] = None,
+ params: Optional["VerificationSessionCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> VerificationSession:
"""
@@ -476,7 +269,7 @@ async def cancel_async(
def redact(
self,
session: str,
- params: Optional["VerificationSessionService.RedactParams"] = None,
+ params: Optional["VerificationSessionRedactParams"] = None,
options: Optional[RequestOptions] = None,
) -> VerificationSession:
"""
@@ -516,7 +309,7 @@ def redact(
async def redact_async(
self,
session: str,
- params: Optional["VerificationSessionService.RedactParams"] = None,
+ params: Optional["VerificationSessionRedactParams"] = None,
options: Optional[RequestOptions] = None,
) -> VerificationSession:
"""
diff --git a/stripe/issuing/_authorization.py b/stripe/issuing/_authorization.py
index 304715bc7..60e775d02 100644
--- a/stripe/issuing/_authorization.py
+++ b/stripe/issuing/_authorization.py
@@ -3,20 +3,12 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._test_helpers import APIResourceTestHelpers
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- Type,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Type, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._balance_transaction import BalanceTransaction
@@ -24,6 +16,42 @@
from stripe.issuing._cardholder import Cardholder
from stripe.issuing._token import Token
from stripe.issuing._transaction import Transaction
+ from stripe.params.issuing._authorization_approve_params import (
+ AuthorizationApproveParams,
+ )
+ from stripe.params.issuing._authorization_capture_params import (
+ AuthorizationCaptureParams,
+ )
+ from stripe.params.issuing._authorization_create_params import (
+ AuthorizationCreateParams,
+ )
+ from stripe.params.issuing._authorization_decline_params import (
+ AuthorizationDeclineParams,
+ )
+ from stripe.params.issuing._authorization_expire_params import (
+ AuthorizationExpireParams,
+ )
+ from stripe.params.issuing._authorization_finalize_amount_params import (
+ AuthorizationFinalizeAmountParams,
+ )
+ from stripe.params.issuing._authorization_increment_params import (
+ AuthorizationIncrementParams,
+ )
+ from stripe.params.issuing._authorization_list_params import (
+ AuthorizationListParams,
+ )
+ from stripe.params.issuing._authorization_modify_params import (
+ AuthorizationModifyParams,
+ )
+ from stripe.params.issuing._authorization_respond_params import (
+ AuthorizationRespondParams,
+ )
+ from stripe.params.issuing._authorization_retrieve_params import (
+ AuthorizationRetrieveParams,
+ )
+ from stripe.params.issuing._authorization_reverse_params import (
+ AuthorizationReverseParams,
+ )
class Authorization(
@@ -459,1202 +487,6 @@ class ThreeDSecure(StripeObject):
"three_d_secure": ThreeDSecure,
}
- class ApproveParams(RequestOptions):
- amount: NotRequired[int]
- """
- If the authorization's `pending_request.is_amount_controllable` property is `true`, you may provide this value to control how much to hold for the authorization. Must be positive (use [`decline`](https://stripe.com/docs/api/issuing/authorizations/decline) to decline an authorization request).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class CaptureParams(RequestOptions):
- capture_amount: NotRequired[int]
- """
- The amount to capture from the authorization. If not provided, the full amount of the authorization will be captured. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- close_authorization: NotRequired[bool]
- """
- Whether to close the authorization after capture. Defaults to true. Set to false to enable multi-capture flows.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- purchase_details: NotRequired[
- "Authorization.CaptureParamsPurchaseDetails"
- ]
- """
- Additional purchase information that is optionally provided by the merchant.
- """
-
- class CaptureParamsPurchaseDetails(TypedDict):
- fleet: NotRequired["Authorization.CaptureParamsPurchaseDetailsFleet"]
- """
- Fleet-specific information for transactions using Fleet cards.
- """
- flight: NotRequired["Authorization.CaptureParamsPurchaseDetailsFlight"]
- """
- Information about the flight that was purchased with this transaction.
- """
- fuel: NotRequired["Authorization.CaptureParamsPurchaseDetailsFuel"]
- """
- Information about fuel that was purchased with this transaction.
- """
- lodging: NotRequired[
- "Authorization.CaptureParamsPurchaseDetailsLodging"
- ]
- """
- Information about lodging that was purchased with this transaction.
- """
- receipt: NotRequired[
- List["Authorization.CaptureParamsPurchaseDetailsReceipt"]
- ]
- """
- The line items in the purchase.
- """
- reference: NotRequired[str]
- """
- A merchant-specific order number.
- """
-
- class CaptureParamsPurchaseDetailsFleet(TypedDict):
- cardholder_prompt_data: NotRequired[
- "Authorization.CaptureParamsPurchaseDetailsFleetCardholderPromptData"
- ]
- """
- Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
- """
- purchase_type: NotRequired[
- Literal[
- "fuel_and_non_fuel_purchase",
- "fuel_purchase",
- "non_fuel_purchase",
- ]
- ]
- """
- The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
- """
- reported_breakdown: NotRequired[
- "Authorization.CaptureParamsPurchaseDetailsFleetReportedBreakdown"
- ]
- """
- More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
- """
- service_type: NotRequired[
- Literal["full_service", "non_fuel_transaction", "self_service"]
- ]
- """
- The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
- """
-
- class CaptureParamsPurchaseDetailsFleetCardholderPromptData(TypedDict):
- driver_id: NotRequired[str]
- """
- Driver ID.
- """
- odometer: NotRequired[int]
- """
- Odometer reading.
- """
- unspecified_id: NotRequired[str]
- """
- An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
- """
- user_id: NotRequired[str]
- """
- User ID.
- """
- vehicle_number: NotRequired[str]
- """
- Vehicle number.
- """
-
- class CaptureParamsPurchaseDetailsFleetReportedBreakdown(TypedDict):
- fuel: NotRequired[
- "Authorization.CaptureParamsPurchaseDetailsFleetReportedBreakdownFuel"
- ]
- """
- Breakdown of fuel portion of the purchase.
- """
- non_fuel: NotRequired[
- "Authorization.CaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel"
- ]
- """
- Breakdown of non-fuel portion of the purchase.
- """
- tax: NotRequired[
- "Authorization.CaptureParamsPurchaseDetailsFleetReportedBreakdownTax"
- ]
- """
- Information about tax included in this transaction.
- """
-
- class CaptureParamsPurchaseDetailsFleetReportedBreakdownFuel(TypedDict):
- gross_amount_decimal: NotRequired[str]
- """
- Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
- """
-
- class CaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel(TypedDict):
- gross_amount_decimal: NotRequired[str]
- """
- Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
- """
-
- class CaptureParamsPurchaseDetailsFleetReportedBreakdownTax(TypedDict):
- local_amount_decimal: NotRequired[str]
- """
- Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
- national_amount_decimal: NotRequired[str]
- """
- Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
-
- class CaptureParamsPurchaseDetailsFlight(TypedDict):
- departure_at: NotRequired[int]
- """
- The time that the flight departed.
- """
- passenger_name: NotRequired[str]
- """
- The name of the passenger.
- """
- refundable: NotRequired[bool]
- """
- Whether the ticket is refundable.
- """
- segments: NotRequired[
- List["Authorization.CaptureParamsPurchaseDetailsFlightSegment"]
- ]
- """
- The legs of the trip.
- """
- travel_agency: NotRequired[str]
- """
- The travel agency that issued the ticket.
- """
-
- class CaptureParamsPurchaseDetailsFlightSegment(TypedDict):
- arrival_airport_code: NotRequired[str]
- """
- The three-letter IATA airport code of the flight's destination.
- """
- carrier: NotRequired[str]
- """
- The airline carrier code.
- """
- departure_airport_code: NotRequired[str]
- """
- The three-letter IATA airport code that the flight departed from.
- """
- flight_number: NotRequired[str]
- """
- The flight number.
- """
- service_class: NotRequired[str]
- """
- The flight's service class.
- """
- stopover_allowed: NotRequired[bool]
- """
- Whether a stopover is allowed on this flight.
- """
-
- class CaptureParamsPurchaseDetailsFuel(TypedDict):
- industry_product_code: NotRequired[str]
- """
- [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
- """
- quantity_decimal: NotRequired[str]
- """
- The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
- """
- type: NotRequired[
- Literal[
- "diesel",
- "other",
- "unleaded_plus",
- "unleaded_regular",
- "unleaded_super",
- ]
- ]
- """
- The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
- """
- unit: NotRequired[
- Literal[
- "charging_minute",
- "imperial_gallon",
- "kilogram",
- "kilowatt_hour",
- "liter",
- "other",
- "pound",
- "us_gallon",
- ]
- ]
- """
- The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
- """
- unit_cost_decimal: NotRequired[str]
- """
- The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
- """
-
- class CaptureParamsPurchaseDetailsLodging(TypedDict):
- check_in_at: NotRequired[int]
- """
- The time of checking into the lodging.
- """
- nights: NotRequired[int]
- """
- The number of nights stayed at the lodging.
- """
-
- class CaptureParamsPurchaseDetailsReceipt(TypedDict):
- description: NotRequired[str]
- quantity: NotRequired[str]
- total: NotRequired[int]
- unit_cost: NotRequired[int]
-
- class CreateParams(RequestOptions):
- amount: NotRequired[int]
- """
- The total amount to attempt to authorize. This amount is in the provided currency, or defaults to the card's currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- amount_details: NotRequired["Authorization.CreateParamsAmountDetails"]
- """
- Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- authorization_method: NotRequired[
- Literal["chip", "contactless", "keyed_in", "online", "swipe"]
- ]
- """
- How the card details were provided. Defaults to online.
- """
- card: str
- """
- Card associated with this authorization.
- """
- currency: NotRequired[str]
- """
- The currency of the authorization. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- fleet: NotRequired["Authorization.CreateParamsFleet"]
- """
- Fleet-specific information for authorizations using Fleet cards.
- """
- fraud_disputability_likelihood: NotRequired[
- Literal["neutral", "unknown", "very_likely", "very_unlikely"]
- ]
- """
- Probability that this transaction can be disputed in the event of fraud. Assessed by comparing the characteristics of the authorization to card network rules.
- """
- fuel: NotRequired["Authorization.CreateParamsFuel"]
- """
- Information about fuel that was purchased with this transaction.
- """
- is_amount_controllable: NotRequired[bool]
- """
- If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.
- """
- merchant_amount: NotRequired[int]
- """
- The total amount to attempt to authorize. This amount is in the provided merchant currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- merchant_currency: NotRequired[str]
- """
- The currency of the authorization. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- merchant_data: NotRequired["Authorization.CreateParamsMerchantData"]
- """
- Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
- """
- network_data: NotRequired["Authorization.CreateParamsNetworkData"]
- """
- Details about the authorization, such as identifiers, set by the card network.
- """
- risk_assessment: NotRequired[
- "Authorization.CreateParamsRiskAssessment"
- ]
- """
- Stripe's assessment of the fraud risk for this authorization.
- """
- verification_data: NotRequired[
- "Authorization.CreateParamsVerificationData"
- ]
- """
- Verifications that Stripe performed on information that the cardholder provided to the merchant.
- """
- wallet: NotRequired[Literal["apple_pay", "google_pay", "samsung_pay"]]
- """
- The digital wallet used for this transaction. One of `apple_pay`, `google_pay`, or `samsung_pay`. Will populate as `null` when no digital wallet was utilized.
- """
-
- class CreateParamsAmountDetails(TypedDict):
- atm_fee: NotRequired[int]
- """
- The ATM withdrawal fee.
- """
- cashback_amount: NotRequired[int]
- """
- The amount of cash requested by the cardholder.
- """
-
- class CreateParamsFleet(TypedDict):
- cardholder_prompt_data: NotRequired[
- "Authorization.CreateParamsFleetCardholderPromptData"
- ]
- """
- Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
- """
- purchase_type: NotRequired[
- Literal[
- "fuel_and_non_fuel_purchase",
- "fuel_purchase",
- "non_fuel_purchase",
- ]
- ]
- """
- The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
- """
- reported_breakdown: NotRequired[
- "Authorization.CreateParamsFleetReportedBreakdown"
- ]
- """
- More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
- """
- service_type: NotRequired[
- Literal["full_service", "non_fuel_transaction", "self_service"]
- ]
- """
- The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
- """
-
- class CreateParamsFleetCardholderPromptData(TypedDict):
- driver_id: NotRequired[str]
- """
- Driver ID.
- """
- odometer: NotRequired[int]
- """
- Odometer reading.
- """
- unspecified_id: NotRequired[str]
- """
- An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
- """
- user_id: NotRequired[str]
- """
- User ID.
- """
- vehicle_number: NotRequired[str]
- """
- Vehicle number.
- """
-
- class CreateParamsFleetReportedBreakdown(TypedDict):
- fuel: NotRequired[
- "Authorization.CreateParamsFleetReportedBreakdownFuel"
- ]
- """
- Breakdown of fuel portion of the purchase.
- """
- non_fuel: NotRequired[
- "Authorization.CreateParamsFleetReportedBreakdownNonFuel"
- ]
- """
- Breakdown of non-fuel portion of the purchase.
- """
- tax: NotRequired["Authorization.CreateParamsFleetReportedBreakdownTax"]
- """
- Information about tax included in this transaction.
- """
-
- class CreateParamsFleetReportedBreakdownFuel(TypedDict):
- gross_amount_decimal: NotRequired[str]
- """
- Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
- """
-
- class CreateParamsFleetReportedBreakdownNonFuel(TypedDict):
- gross_amount_decimal: NotRequired[str]
- """
- Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
- """
-
- class CreateParamsFleetReportedBreakdownTax(TypedDict):
- local_amount_decimal: NotRequired[str]
- """
- Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
- national_amount_decimal: NotRequired[str]
- """
- Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
-
- class CreateParamsFuel(TypedDict):
- industry_product_code: NotRequired[str]
- """
- [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
- """
- quantity_decimal: NotRequired[str]
- """
- The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
- """
- type: NotRequired[
- Literal[
- "diesel",
- "other",
- "unleaded_plus",
- "unleaded_regular",
- "unleaded_super",
- ]
- ]
- """
- The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
- """
- unit: NotRequired[
- Literal[
- "charging_minute",
- "imperial_gallon",
- "kilogram",
- "kilowatt_hour",
- "liter",
- "other",
- "pound",
- "us_gallon",
- ]
- ]
- """
- The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
- """
- unit_cost_decimal: NotRequired[str]
- """
- The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
- """
-
- class CreateParamsMerchantData(TypedDict):
- category: NotRequired[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- """
- A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
- """
- city: NotRequired[str]
- """
- City where the seller is located
- """
- country: NotRequired[str]
- """
- Country where the seller is located
- """
- name: NotRequired[str]
- """
- Name of the seller
- """
- network_id: NotRequired[str]
- """
- Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
- """
- postal_code: NotRequired[str]
- """
- Postal code where the seller is located
- """
- state: NotRequired[str]
- """
- State where the seller is located
- """
- terminal_id: NotRequired[str]
- """
- An ID assigned by the seller to the location of the sale.
- """
- url: NotRequired[str]
- """
- URL provided by the merchant on a 3DS request
- """
-
- class CreateParamsNetworkData(TypedDict):
- acquiring_institution_id: NotRequired[str]
- """
- Identifier assigned to the acquirer by the card network.
- """
-
- class CreateParamsRiskAssessment(TypedDict):
- card_testing_risk: NotRequired[
- "Authorization.CreateParamsRiskAssessmentCardTestingRisk"
- ]
- """
- Stripe's assessment of this authorization's likelihood of being card testing activity.
- """
- merchant_dispute_risk: NotRequired[
- "Authorization.CreateParamsRiskAssessmentMerchantDisputeRisk"
- ]
- """
- The dispute risk of the merchant (the seller on a purchase) on an authorization based on all Stripe Issuing activity.
- """
-
- class CreateParamsRiskAssessmentCardTestingRisk(TypedDict):
- invalid_account_number_decline_rate_past_hour: NotRequired[int]
- """
- The % of declines due to a card number not existing in the past hour, taking place at the same merchant. Higher rates correspond to a greater probability of card testing activity, meaning bad actors may be attempting different card number combinations to guess a correct one. Takes on values between 0 and 100.
- """
- invalid_credentials_decline_rate_past_hour: NotRequired[int]
- """
- The % of declines due to incorrect verification data (like CVV or expiry) in the past hour, taking place at the same merchant. Higher rates correspond to a greater probability of bad actors attempting to utilize valid card credentials at merchants with verification requirements. Takes on values between 0 and 100.
- """
- risk_level: Literal[
- "elevated", "highest", "low", "normal", "not_assessed", "unknown"
- ]
- """
- The likelihood that this authorization is associated with card testing activity. This is assessed by evaluating decline activity over the last hour.
- """
-
- class CreateParamsRiskAssessmentMerchantDisputeRisk(TypedDict):
- dispute_rate: NotRequired[int]
- """
- The dispute rate observed across all Stripe Issuing authorizations for this merchant. For example, a value of 50 means 50% of authorizations from this merchant on Stripe Issuing have resulted in a dispute. Higher values mean a higher likelihood the authorization is disputed. Takes on values between 0 and 100.
- """
- risk_level: Literal[
- "elevated", "highest", "low", "normal", "not_assessed", "unknown"
- ]
- """
- The likelihood that authorizations from this merchant will result in a dispute based on their history on Stripe Issuing.
- """
-
- class CreateParamsVerificationData(TypedDict):
- address_line1_check: NotRequired[
- Literal["match", "mismatch", "not_provided"]
- ]
- """
- Whether the cardholder provided an address first line and if it matched the cardholder's `billing.address.line1`.
- """
- address_postal_code_check: NotRequired[
- Literal["match", "mismatch", "not_provided"]
- ]
- """
- Whether the cardholder provided a postal code and if it matched the cardholder's `billing.address.postal_code`.
- """
- authentication_exemption: NotRequired[
- "Authorization.CreateParamsVerificationDataAuthenticationExemption"
- ]
- """
- The exemption applied to this authorization.
- """
- cvc_check: NotRequired[Literal["match", "mismatch", "not_provided"]]
- """
- Whether the cardholder provided a CVC and if it matched Stripe's record.
- """
- expiry_check: NotRequired[Literal["match", "mismatch", "not_provided"]]
- """
- Whether the cardholder provided an expiry date and if it matched Stripe's record.
- """
- three_d_secure: NotRequired[
- "Authorization.CreateParamsVerificationDataThreeDSecure"
- ]
- """
- 3D Secure details.
- """
-
- class CreateParamsVerificationDataAuthenticationExemption(TypedDict):
- claimed_by: Literal["acquirer", "issuer"]
- """
- The entity that requested the exemption, either the acquiring merchant or the Issuing user.
- """
- type: Literal[
- "low_value_transaction", "transaction_risk_analysis", "unknown"
- ]
- """
- The specific exemption claimed for this authorization.
- """
-
- class CreateParamsVerificationDataThreeDSecure(TypedDict):
- result: Literal[
- "attempt_acknowledged", "authenticated", "failed", "required"
- ]
- """
- The outcome of the 3D Secure authentication request.
- """
-
- class DeclineParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class ExpireParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class FinalizeAmountParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- final_amount: int
- """
- The final authorization amount that will be captured by the merchant. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- fleet: NotRequired["Authorization.FinalizeAmountParamsFleet"]
- """
- Fleet-specific information for authorizations using Fleet cards.
- """
- fuel: NotRequired["Authorization.FinalizeAmountParamsFuel"]
- """
- Information about fuel that was purchased with this transaction.
- """
-
- class FinalizeAmountParamsFleet(TypedDict):
- cardholder_prompt_data: NotRequired[
- "Authorization.FinalizeAmountParamsFleetCardholderPromptData"
- ]
- """
- Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
- """
- purchase_type: NotRequired[
- Literal[
- "fuel_and_non_fuel_purchase",
- "fuel_purchase",
- "non_fuel_purchase",
- ]
- ]
- """
- The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
- """
- reported_breakdown: NotRequired[
- "Authorization.FinalizeAmountParamsFleetReportedBreakdown"
- ]
- """
- More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
- """
- service_type: NotRequired[
- Literal["full_service", "non_fuel_transaction", "self_service"]
- ]
- """
- The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
- """
-
- class FinalizeAmountParamsFleetCardholderPromptData(TypedDict):
- driver_id: NotRequired[str]
- """
- Driver ID.
- """
- odometer: NotRequired[int]
- """
- Odometer reading.
- """
- unspecified_id: NotRequired[str]
- """
- An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
- """
- user_id: NotRequired[str]
- """
- User ID.
- """
- vehicle_number: NotRequired[str]
- """
- Vehicle number.
- """
-
- class FinalizeAmountParamsFleetReportedBreakdown(TypedDict):
- fuel: NotRequired[
- "Authorization.FinalizeAmountParamsFleetReportedBreakdownFuel"
- ]
- """
- Breakdown of fuel portion of the purchase.
- """
- non_fuel: NotRequired[
- "Authorization.FinalizeAmountParamsFleetReportedBreakdownNonFuel"
- ]
- """
- Breakdown of non-fuel portion of the purchase.
- """
- tax: NotRequired[
- "Authorization.FinalizeAmountParamsFleetReportedBreakdownTax"
- ]
- """
- Information about tax included in this transaction.
- """
-
- class FinalizeAmountParamsFleetReportedBreakdownFuel(TypedDict):
- gross_amount_decimal: NotRequired[str]
- """
- Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
- """
-
- class FinalizeAmountParamsFleetReportedBreakdownNonFuel(TypedDict):
- gross_amount_decimal: NotRequired[str]
- """
- Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
- """
-
- class FinalizeAmountParamsFleetReportedBreakdownTax(TypedDict):
- local_amount_decimal: NotRequired[str]
- """
- Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
- national_amount_decimal: NotRequired[str]
- """
- Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
-
- class FinalizeAmountParamsFuel(TypedDict):
- industry_product_code: NotRequired[str]
- """
- [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
- """
- quantity_decimal: NotRequired[str]
- """
- The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
- """
- type: NotRequired[
- Literal[
- "diesel",
- "other",
- "unleaded_plus",
- "unleaded_regular",
- "unleaded_super",
- ]
- ]
- """
- The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
- """
- unit: NotRequired[
- Literal[
- "charging_minute",
- "imperial_gallon",
- "kilogram",
- "kilowatt_hour",
- "liter",
- "other",
- "pound",
- "us_gallon",
- ]
- ]
- """
- The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
- """
- unit_cost_decimal: NotRequired[str]
- """
- The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
- """
-
- class IncrementParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- increment_amount: int
- """
- The amount to increment the authorization by. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- is_amount_controllable: NotRequired[bool]
- """
- If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.
- """
-
- class ListParams(RequestOptions):
- card: NotRequired[str]
- """
- Only return authorizations that belong to the given card.
- """
- cardholder: NotRequired[str]
- """
- Only return authorizations that belong to the given cardholder.
- """
- created: NotRequired["Authorization.ListParamsCreated|int"]
- """
- Only return authorizations that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["closed", "expired", "pending", "reversed"]
- ]
- """
- Only return authorizations with the given status. One of `pending`, `closed`, or `reversed`.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class RespondParams(RequestOptions):
- confirmed: bool
- """
- Whether to simulate the user confirming that the transaction was legitimate (true) or telling Stripe that it was fraudulent (false).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ReverseParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- reverse_amount: NotRequired[int]
- """
- The amount to reverse from the authorization. If not provided, the full amount of the authorization will be reversed. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
-
amount: int
"""
The total amount that was authorized or rejected. This amount is in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). `amount` should be the same as `merchant_amount`, unless `currency` and `merchant_currency` are different.
@@ -1770,9 +602,7 @@ class ReverseParams(RequestOptions):
@classmethod
def _cls_approve(
- cls,
- authorization: str,
- **params: Unpack["Authorization.ApproveParams"],
+ 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.
@@ -1792,7 +622,7 @@ def _cls_approve(
@overload
@staticmethod
def approve(
- authorization: str, **params: Unpack["Authorization.ApproveParams"]
+ 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.
@@ -1802,7 +632,7 @@ def approve(
@overload
def approve(
- self, **params: Unpack["Authorization.ApproveParams"]
+ self, **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.
@@ -1812,7 +642,7 @@ def approve(
@class_method_variant("_cls_approve")
def approve( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.ApproveParams"]
+ self, **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.
@@ -1831,9 +661,7 @@ def approve( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_approve_async(
- cls,
- authorization: str,
- **params: Unpack["Authorization.ApproveParams"],
+ 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.
@@ -1853,7 +681,7 @@ async def _cls_approve_async(
@overload
@staticmethod
async def approve_async(
- authorization: str, **params: Unpack["Authorization.ApproveParams"]
+ 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.
@@ -1863,7 +691,7 @@ async def approve_async(
@overload
async def approve_async(
- self, **params: Unpack["Authorization.ApproveParams"]
+ self, **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.
@@ -1873,7 +701,7 @@ async def approve_async(
@class_method_variant("_cls_approve_async")
async def approve_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.ApproveParams"]
+ self, **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.
@@ -1892,9 +720,7 @@ async def approve_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_decline(
- cls,
- authorization: str,
- **params: Unpack["Authorization.DeclineParams"],
+ 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.
@@ -1914,7 +740,7 @@ def _cls_decline(
@overload
@staticmethod
def decline(
- authorization: str, **params: Unpack["Authorization.DeclineParams"]
+ 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.
@@ -1924,7 +750,7 @@ def decline(
@overload
def decline(
- self, **params: Unpack["Authorization.DeclineParams"]
+ self, **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.
@@ -1934,7 +760,7 @@ def decline(
@class_method_variant("_cls_decline")
def decline( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.DeclineParams"]
+ self, **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.
@@ -1953,9 +779,7 @@ def decline( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_decline_async(
- cls,
- authorization: str,
- **params: Unpack["Authorization.DeclineParams"],
+ 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.
@@ -1975,7 +799,7 @@ async def _cls_decline_async(
@overload
@staticmethod
async def decline_async(
- authorization: str, **params: Unpack["Authorization.DeclineParams"]
+ 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.
@@ -1985,7 +809,7 @@ async def decline_async(
@overload
async def decline_async(
- self, **params: Unpack["Authorization.DeclineParams"]
+ self, **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.
@@ -1995,7 +819,7 @@ async def decline_async(
@class_method_variant("_cls_decline_async")
async def decline_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.DeclineParams"]
+ self, **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.
@@ -2014,7 +838,7 @@ async def decline_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["Authorization.ListParams"]
+ cls, **params: Unpack["AuthorizationListParams"]
) -> ListObject["Authorization"]:
"""
Returns a list of Issuing Authorization objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -2034,7 +858,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Authorization.ListParams"]
+ cls, **params: Unpack["AuthorizationListParams"]
) -> ListObject["Authorization"]:
"""
Returns a list of Issuing Authorization objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -2054,7 +878,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Authorization.ModifyParams"]
+ cls, id: str, **params: Unpack["AuthorizationModifyParams"]
) -> "Authorization":
"""
Updates the specified Issuing Authorization object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -2071,7 +895,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Authorization.ModifyParams"]
+ cls, id: str, **params: Unpack["AuthorizationModifyParams"]
) -> "Authorization":
"""
Updates the specified Issuing Authorization object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -2088,7 +912,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Authorization.RetrieveParams"]
+ cls, id: str, **params: Unpack["AuthorizationRetrieveParams"]
) -> "Authorization":
"""
Retrieves an Issuing Authorization object.
@@ -2099,7 +923,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Authorization.RetrieveParams"]
+ cls, id: str, **params: Unpack["AuthorizationRetrieveParams"]
) -> "Authorization":
"""
Retrieves an Issuing Authorization object.
@@ -2115,7 +939,7 @@ class TestHelpers(APIResourceTestHelpers["Authorization"]):
def _cls_capture(
cls,
authorization: str,
- **params: Unpack["Authorization.CaptureParams"],
+ **params: Unpack["AuthorizationCaptureParams"],
) -> "Authorization":
"""
Capture a test-mode authorization.
@@ -2134,7 +958,7 @@ def _cls_capture(
@overload
@staticmethod
def capture(
- authorization: str, **params: Unpack["Authorization.CaptureParams"]
+ authorization: str, **params: Unpack["AuthorizationCaptureParams"]
) -> "Authorization":
"""
Capture a test-mode authorization.
@@ -2143,7 +967,7 @@ def capture(
@overload
def capture(
- self, **params: Unpack["Authorization.CaptureParams"]
+ self, **params: Unpack["AuthorizationCaptureParams"]
) -> "Authorization":
"""
Capture a test-mode authorization.
@@ -2152,7 +976,7 @@ def capture(
@class_method_variant("_cls_capture")
def capture( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.CaptureParams"]
+ self, **params: Unpack["AuthorizationCaptureParams"]
) -> "Authorization":
"""
Capture a test-mode authorization.
@@ -2172,7 +996,7 @@ def capture( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_capture_async(
cls,
authorization: str,
- **params: Unpack["Authorization.CaptureParams"],
+ **params: Unpack["AuthorizationCaptureParams"],
) -> "Authorization":
"""
Capture a test-mode authorization.
@@ -2191,7 +1015,7 @@ async def _cls_capture_async(
@overload
@staticmethod
async def capture_async(
- authorization: str, **params: Unpack["Authorization.CaptureParams"]
+ authorization: str, **params: Unpack["AuthorizationCaptureParams"]
) -> "Authorization":
"""
Capture a test-mode authorization.
@@ -2200,7 +1024,7 @@ async def capture_async(
@overload
async def capture_async(
- self, **params: Unpack["Authorization.CaptureParams"]
+ self, **params: Unpack["AuthorizationCaptureParams"]
) -> "Authorization":
"""
Capture a test-mode authorization.
@@ -2209,7 +1033,7 @@ async def capture_async(
@class_method_variant("_cls_capture_async")
async def capture_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.CaptureParams"]
+ self, **params: Unpack["AuthorizationCaptureParams"]
) -> "Authorization":
"""
Capture a test-mode authorization.
@@ -2227,7 +1051,7 @@ async def capture_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def create(
- cls, **params: Unpack["Authorization.CreateParams"]
+ cls, **params: Unpack["AuthorizationCreateParams"]
) -> "Authorization":
"""
Create a test-mode authorization.
@@ -2243,7 +1067,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["Authorization.CreateParams"]
+ cls, **params: Unpack["AuthorizationCreateParams"]
) -> "Authorization":
"""
Create a test-mode authorization.
@@ -2261,7 +1085,7 @@ async def create_async(
def _cls_expire(
cls,
authorization: str,
- **params: Unpack["Authorization.ExpireParams"],
+ **params: Unpack["AuthorizationExpireParams"],
) -> "Authorization":
"""
Expire a test-mode Authorization.
@@ -2280,7 +1104,7 @@ def _cls_expire(
@overload
@staticmethod
def expire(
- authorization: str, **params: Unpack["Authorization.ExpireParams"]
+ authorization: str, **params: Unpack["AuthorizationExpireParams"]
) -> "Authorization":
"""
Expire a test-mode Authorization.
@@ -2289,7 +1113,7 @@ def expire(
@overload
def expire(
- self, **params: Unpack["Authorization.ExpireParams"]
+ self, **params: Unpack["AuthorizationExpireParams"]
) -> "Authorization":
"""
Expire a test-mode Authorization.
@@ -2298,7 +1122,7 @@ def expire(
@class_method_variant("_cls_expire")
def expire( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.ExpireParams"]
+ self, **params: Unpack["AuthorizationExpireParams"]
) -> "Authorization":
"""
Expire a test-mode Authorization.
@@ -2318,7 +1142,7 @@ def expire( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_expire_async(
cls,
authorization: str,
- **params: Unpack["Authorization.ExpireParams"],
+ **params: Unpack["AuthorizationExpireParams"],
) -> "Authorization":
"""
Expire a test-mode Authorization.
@@ -2337,7 +1161,7 @@ async def _cls_expire_async(
@overload
@staticmethod
async def expire_async(
- authorization: str, **params: Unpack["Authorization.ExpireParams"]
+ authorization: str, **params: Unpack["AuthorizationExpireParams"]
) -> "Authorization":
"""
Expire a test-mode Authorization.
@@ -2346,7 +1170,7 @@ async def expire_async(
@overload
async def expire_async(
- self, **params: Unpack["Authorization.ExpireParams"]
+ self, **params: Unpack["AuthorizationExpireParams"]
) -> "Authorization":
"""
Expire a test-mode Authorization.
@@ -2355,7 +1179,7 @@ async def expire_async(
@class_method_variant("_cls_expire_async")
async def expire_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.ExpireParams"]
+ self, **params: Unpack["AuthorizationExpireParams"]
) -> "Authorization":
"""
Expire a test-mode Authorization.
@@ -2375,7 +1199,7 @@ async def expire_async( # pyright: ignore[reportGeneralTypeIssues]
def _cls_finalize_amount(
cls,
authorization: str,
- **params: Unpack["Authorization.FinalizeAmountParams"],
+ **params: Unpack["AuthorizationFinalizeAmountParams"],
) -> "Authorization":
"""
Finalize the amount on an Authorization prior to capture, when the initial authorization was for an estimated amount.
@@ -2395,7 +1219,7 @@ def _cls_finalize_amount(
@staticmethod
def finalize_amount(
authorization: str,
- **params: Unpack["Authorization.FinalizeAmountParams"],
+ **params: Unpack["AuthorizationFinalizeAmountParams"],
) -> "Authorization":
"""
Finalize the amount on an Authorization prior to capture, when the initial authorization was for an estimated amount.
@@ -2404,7 +1228,7 @@ def finalize_amount(
@overload
def finalize_amount(
- self, **params: Unpack["Authorization.FinalizeAmountParams"]
+ self, **params: Unpack["AuthorizationFinalizeAmountParams"]
) -> "Authorization":
"""
Finalize the amount on an Authorization prior to capture, when the initial authorization was for an estimated amount.
@@ -2413,7 +1237,7 @@ def finalize_amount(
@class_method_variant("_cls_finalize_amount")
def finalize_amount( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.FinalizeAmountParams"]
+ self, **params: Unpack["AuthorizationFinalizeAmountParams"]
) -> "Authorization":
"""
Finalize the amount on an Authorization prior to capture, when the initial authorization was for an estimated amount.
@@ -2433,7 +1257,7 @@ def finalize_amount( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_finalize_amount_async(
cls,
authorization: str,
- **params: Unpack["Authorization.FinalizeAmountParams"],
+ **params: Unpack["AuthorizationFinalizeAmountParams"],
) -> "Authorization":
"""
Finalize the amount on an Authorization prior to capture, when the initial authorization was for an estimated amount.
@@ -2453,7 +1277,7 @@ async def _cls_finalize_amount_async(
@staticmethod
async def finalize_amount_async(
authorization: str,
- **params: Unpack["Authorization.FinalizeAmountParams"],
+ **params: Unpack["AuthorizationFinalizeAmountParams"],
) -> "Authorization":
"""
Finalize the amount on an Authorization prior to capture, when the initial authorization was for an estimated amount.
@@ -2462,7 +1286,7 @@ async def finalize_amount_async(
@overload
async def finalize_amount_async(
- self, **params: Unpack["Authorization.FinalizeAmountParams"]
+ self, **params: Unpack["AuthorizationFinalizeAmountParams"]
) -> "Authorization":
"""
Finalize the amount on an Authorization prior to capture, when the initial authorization was for an estimated amount.
@@ -2471,7 +1295,7 @@ async def finalize_amount_async(
@class_method_variant("_cls_finalize_amount_async")
async def finalize_amount_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.FinalizeAmountParams"]
+ self, **params: Unpack["AuthorizationFinalizeAmountParams"]
) -> "Authorization":
"""
Finalize the amount on an Authorization prior to capture, when the initial authorization was for an estimated amount.
@@ -2491,7 +1315,7 @@ async def finalize_amount_async( # pyright: ignore[reportGeneralTypeIssues]
def _cls_increment(
cls,
authorization: str,
- **params: Unpack["Authorization.IncrementParams"],
+ **params: Unpack["AuthorizationIncrementParams"],
) -> "Authorization":
"""
Increment a test-mode Authorization.
@@ -2511,7 +1335,7 @@ def _cls_increment(
@staticmethod
def increment(
authorization: str,
- **params: Unpack["Authorization.IncrementParams"],
+ **params: Unpack["AuthorizationIncrementParams"],
) -> "Authorization":
"""
Increment a test-mode Authorization.
@@ -2520,7 +1344,7 @@ def increment(
@overload
def increment(
- self, **params: Unpack["Authorization.IncrementParams"]
+ self, **params: Unpack["AuthorizationIncrementParams"]
) -> "Authorization":
"""
Increment a test-mode Authorization.
@@ -2529,7 +1353,7 @@ def increment(
@class_method_variant("_cls_increment")
def increment( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.IncrementParams"]
+ self, **params: Unpack["AuthorizationIncrementParams"]
) -> "Authorization":
"""
Increment a test-mode Authorization.
@@ -2549,7 +1373,7 @@ def increment( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_increment_async(
cls,
authorization: str,
- **params: Unpack["Authorization.IncrementParams"],
+ **params: Unpack["AuthorizationIncrementParams"],
) -> "Authorization":
"""
Increment a test-mode Authorization.
@@ -2569,7 +1393,7 @@ async def _cls_increment_async(
@staticmethod
async def increment_async(
authorization: str,
- **params: Unpack["Authorization.IncrementParams"],
+ **params: Unpack["AuthorizationIncrementParams"],
) -> "Authorization":
"""
Increment a test-mode Authorization.
@@ -2578,7 +1402,7 @@ async def increment_async(
@overload
async def increment_async(
- self, **params: Unpack["Authorization.IncrementParams"]
+ self, **params: Unpack["AuthorizationIncrementParams"]
) -> "Authorization":
"""
Increment a test-mode Authorization.
@@ -2587,7 +1411,7 @@ async def increment_async(
@class_method_variant("_cls_increment_async")
async def increment_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.IncrementParams"]
+ self, **params: Unpack["AuthorizationIncrementParams"]
) -> "Authorization":
"""
Increment a test-mode Authorization.
@@ -2607,7 +1431,7 @@ async def increment_async( # pyright: ignore[reportGeneralTypeIssues]
def _cls_respond(
cls,
authorization: str,
- **params: Unpack["Authorization.RespondParams"],
+ **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.
@@ -2626,7 +1450,7 @@ def _cls_respond(
@overload
@staticmethod
def respond(
- authorization: str, **params: Unpack["Authorization.RespondParams"]
+ 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.
@@ -2635,7 +1459,7 @@ def respond(
@overload
def respond(
- self, **params: Unpack["Authorization.RespondParams"]
+ self, **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.
@@ -2644,7 +1468,7 @@ def respond(
@class_method_variant("_cls_respond")
def respond( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.RespondParams"]
+ self, **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.
@@ -2664,7 +1488,7 @@ def respond( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_respond_async(
cls,
authorization: str,
- **params: Unpack["Authorization.RespondParams"],
+ **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.
@@ -2683,7 +1507,7 @@ async def _cls_respond_async(
@overload
@staticmethod
async def respond_async(
- authorization: str, **params: Unpack["Authorization.RespondParams"]
+ 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.
@@ -2692,7 +1516,7 @@ async def respond_async(
@overload
async def respond_async(
- self, **params: Unpack["Authorization.RespondParams"]
+ self, **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.
@@ -2701,7 +1525,7 @@ async def respond_async(
@class_method_variant("_cls_respond_async")
async def respond_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.RespondParams"]
+ self, **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.
@@ -2721,7 +1545,7 @@ async def respond_async( # pyright: ignore[reportGeneralTypeIssues]
def _cls_reverse(
cls,
authorization: str,
- **params: Unpack["Authorization.ReverseParams"],
+ **params: Unpack["AuthorizationReverseParams"],
) -> "Authorization":
"""
Reverse a test-mode Authorization.
@@ -2740,7 +1564,7 @@ def _cls_reverse(
@overload
@staticmethod
def reverse(
- authorization: str, **params: Unpack["Authorization.ReverseParams"]
+ authorization: str, **params: Unpack["AuthorizationReverseParams"]
) -> "Authorization":
"""
Reverse a test-mode Authorization.
@@ -2749,7 +1573,7 @@ def reverse(
@overload
def reverse(
- self, **params: Unpack["Authorization.ReverseParams"]
+ self, **params: Unpack["AuthorizationReverseParams"]
) -> "Authorization":
"""
Reverse a test-mode Authorization.
@@ -2758,7 +1582,7 @@ def reverse(
@class_method_variant("_cls_reverse")
def reverse( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.ReverseParams"]
+ self, **params: Unpack["AuthorizationReverseParams"]
) -> "Authorization":
"""
Reverse a test-mode Authorization.
@@ -2778,7 +1602,7 @@ def reverse( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_reverse_async(
cls,
authorization: str,
- **params: Unpack["Authorization.ReverseParams"],
+ **params: Unpack["AuthorizationReverseParams"],
) -> "Authorization":
"""
Reverse a test-mode Authorization.
@@ -2797,7 +1621,7 @@ async def _cls_reverse_async(
@overload
@staticmethod
async def reverse_async(
- authorization: str, **params: Unpack["Authorization.ReverseParams"]
+ authorization: str, **params: Unpack["AuthorizationReverseParams"]
) -> "Authorization":
"""
Reverse a test-mode Authorization.
@@ -2806,7 +1630,7 @@ async def reverse_async(
@overload
async def reverse_async(
- self, **params: Unpack["Authorization.ReverseParams"]
+ self, **params: Unpack["AuthorizationReverseParams"]
) -> "Authorization":
"""
Reverse a test-mode Authorization.
@@ -2815,7 +1639,7 @@ async def reverse_async(
@class_method_variant("_cls_reverse_async")
async def reverse_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Authorization.ReverseParams"]
+ self, **params: Unpack["AuthorizationReverseParams"]
) -> "Authorization":
"""
Reverse a test-mode Authorization.
diff --git a/stripe/issuing/_authorization_service.py b/stripe/issuing/_authorization_service.py
index d7e6f08ec..d85ebfee4 100644
--- a/stripe/issuing/_authorization_service.py
+++ b/stripe/issuing/_authorization_service.py
@@ -5,108 +5,31 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.issuing._authorization import Authorization
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.issuing._authorization_approve_params import (
+ AuthorizationApproveParams,
+ )
+ from stripe.params.issuing._authorization_decline_params import (
+ AuthorizationDeclineParams,
+ )
+ from stripe.params.issuing._authorization_list_params import (
+ AuthorizationListParams,
+ )
+ from stripe.params.issuing._authorization_retrieve_params import (
+ AuthorizationRetrieveParams,
+ )
+ from stripe.params.issuing._authorization_update_params import (
+ AuthorizationUpdateParams,
+ )
class AuthorizationService(StripeService):
- class ApproveParams(TypedDict):
- amount: NotRequired[int]
- """
- If the authorization's `pending_request.is_amount_controllable` property is `true`, you may provide this value to control how much to hold for the authorization. Must be positive (use [`decline`](https://stripe.com/docs/api/issuing/authorizations/decline) to decline an authorization request).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class DeclineParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class ListParams(TypedDict):
- card: NotRequired[str]
- """
- Only return authorizations that belong to the given card.
- """
- cardholder: NotRequired[str]
- """
- Only return authorizations that belong to the given cardholder.
- """
- created: NotRequired["AuthorizationService.ListParamsCreated|int"]
- """
- Only return authorizations that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["closed", "expired", "pending", "reversed"]
- ]
- """
- Only return authorizations with the given status. One of `pending`, `closed`, or `reversed`.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
def list(
self,
- params: Optional["AuthorizationService.ListParams"] = None,
+ params: Optional["AuthorizationListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Authorization]:
"""
@@ -125,7 +48,7 @@ def list(
async def list_async(
self,
- params: Optional["AuthorizationService.ListParams"] = None,
+ params: Optional["AuthorizationListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Authorization]:
"""
@@ -145,7 +68,7 @@ async def list_async(
def retrieve(
self,
authorization: str,
- params: Optional["AuthorizationService.RetrieveParams"] = None,
+ params: Optional["AuthorizationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -167,7 +90,7 @@ def retrieve(
async def retrieve_async(
self,
authorization: str,
- params: Optional["AuthorizationService.RetrieveParams"] = None,
+ params: Optional["AuthorizationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -189,7 +112,7 @@ async def retrieve_async(
def update(
self,
authorization: str,
- params: Optional["AuthorizationService.UpdateParams"] = None,
+ params: Optional["AuthorizationUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -211,7 +134,7 @@ def update(
async def update_async(
self,
authorization: str,
- params: Optional["AuthorizationService.UpdateParams"] = None,
+ params: Optional["AuthorizationUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -233,7 +156,7 @@ async def update_async(
def approve(
self,
authorization: str,
- params: Optional["AuthorizationService.ApproveParams"] = None,
+ params: Optional["AuthorizationApproveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -256,7 +179,7 @@ def approve(
async def approve_async(
self,
authorization: str,
- params: Optional["AuthorizationService.ApproveParams"] = None,
+ params: Optional["AuthorizationApproveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -279,7 +202,7 @@ async def approve_async(
def decline(
self,
authorization: str,
- params: Optional["AuthorizationService.DeclineParams"] = None,
+ params: Optional["AuthorizationDeclineParams"] = None,
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -302,7 +225,7 @@ def decline(
async def decline_async(
self,
authorization: str,
- params: Optional["AuthorizationService.DeclineParams"] = None,
+ params: Optional["AuthorizationDeclineParams"] = None,
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
diff --git a/stripe/issuing/_card.py b/stripe/issuing/_card.py
index 10fcd38b3..ebce1fe2b 100644
--- a/stripe/issuing/_card.py
+++ b/stripe/issuing/_card.py
@@ -4,24 +4,31 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._test_helpers import APIResourceTestHelpers
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- Type,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Type, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe.issuing._cardholder import Cardholder
from stripe.issuing._personalization_design import PersonalizationDesign
+ from stripe.params.issuing._card_create_params import CardCreateParams
+ from stripe.params.issuing._card_deliver_card_params import (
+ CardDeliverCardParams,
+ )
+ from stripe.params.issuing._card_fail_card_params import CardFailCardParams
+ from stripe.params.issuing._card_list_params import CardListParams
+ from stripe.params.issuing._card_modify_params import CardModifyParams
+ from stripe.params.issuing._card_retrieve_params import CardRetrieveParams
+ from stripe.params.issuing._card_return_card_params import (
+ CardReturnCardParams,
+ )
+ from stripe.params.issuing._card_ship_card_params import CardShipCardParams
+ from stripe.params.issuing._card_submit_card_params import (
+ CardSubmitCardParams,
+ )
class Card(
@@ -1173,2260 +1180,6 @@ class GooglePay(StripeObject):
"""
_inner_class_types = {"apple_pay": ApplePay, "google_pay": GooglePay}
- class CreateParams(RequestOptions):
- cardholder: NotRequired[str]
- """
- The [Cardholder](https://stripe.com/docs/api#issuing_cardholder_object) object with which the card will be associated.
- """
- currency: str
- """
- The currency for the card.
- """
- exp_month: NotRequired[int]
- """
- The desired expiration month (1-12) for this card if [specifying a custom expiration date](https://docs.stripe.com/issuing/cards/virtual/issue-cards?testing-method=with-code#exp-dates).
- """
- exp_year: NotRequired[int]
- """
- The desired 4-digit expiration year for this card if [specifying a custom expiration date](https://docs.stripe.com/issuing/cards/virtual/issue-cards?testing-method=with-code#exp-dates).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: NotRequired[str]
- """
- The new financial account ID the card will be associated with. This field allows a card to be reassigned to a different financial account.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- personalization_design: NotRequired[str]
- """
- The personalization design object belonging to this card.
- """
- pin: NotRequired["Card.CreateParamsPin"]
- """
- The desired PIN for this card.
- """
- replacement_for: NotRequired[str]
- """
- The card this is meant to be a replacement for (if any).
- """
- replacement_reason: NotRequired[
- Literal["damaged", "expired", "lost", "stolen"]
- ]
- """
- If `replacement_for` is specified, this should indicate why that card is being replaced.
- """
- second_line: NotRequired["Literal['']|str"]
- """
- The second line to print on the card. Max length: 24 characters.
- """
- shipping: NotRequired["Card.CreateParamsShipping"]
- """
- The address where the card will be shipped.
- """
- spending_controls: NotRequired["Card.CreateParamsSpendingControls"]
- """
- Rules that control spending for this card. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
- """
- status: NotRequired[Literal["active", "inactive"]]
- """
- Whether authorizations can be approved on this card. May be blocked from activating cards depending on past-due Cardholder requirements. Defaults to `inactive`.
- """
- type: Literal["physical", "virtual"]
- """
- The type of card to issue. Possible values are `physical` or `virtual`.
- """
-
- class CreateParamsPin(TypedDict):
- encrypted_number: NotRequired[str]
- """
- The card's desired new PIN, encrypted under Stripe's public key.
- """
-
- class CreateParamsShipping(TypedDict):
- address: "Card.CreateParamsShippingAddress"
- """
- The address that the card is shipped to.
- """
- address_validation: NotRequired[
- "Card.CreateParamsShippingAddressValidation"
- ]
- """
- Address validation settings.
- """
- customs: NotRequired["Card.CreateParamsShippingCustoms"]
- """
- Customs information for the shipment.
- """
- name: str
- """
- The name printed on the shipping label when shipping the card.
- """
- phone_number: NotRequired[str]
- """
- Phone number of the recipient of the shipment.
- """
- require_signature: NotRequired[bool]
- """
- Whether a signature is required for card delivery.
- """
- service: NotRequired[Literal["express", "priority", "standard"]]
- """
- Shipment service.
- """
- type: NotRequired[Literal["bulk", "individual"]]
- """
- Packaging options.
- """
-
- class CreateParamsShippingAddress(TypedDict):
- city: str
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: str
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsShippingAddressValidation(TypedDict):
- mode: Literal[
- "disabled", "normalization_only", "validation_and_normalization"
- ]
- """
- The address validation capabilities to use.
- """
-
- class CreateParamsShippingCustoms(TypedDict):
- eori_number: NotRequired[str]
- """
- The Economic Operators Registration and Identification (EORI) number to use for Customs. Required for bulk shipments to Europe.
- """
-
- class CreateParamsSpendingControls(TypedDict):
- allowed_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
- """
- allowed_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
- """
- blocked_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
- """
- blocked_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
- """
- spending_limits: NotRequired[
- List["Card.CreateParamsSpendingControlsSpendingLimit"]
- ]
- """
- Limit spending with amount-based rules that apply across any cards this card replaced (i.e., its `replacement_for` card and _that_ card's `replacement_for` card, up the chain).
- """
-
- class CreateParamsSpendingControlsSpendingLimit(TypedDict):
- amount: int
- """
- Maximum amount allowed to spend per interval.
- """
- categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
- """
- interval: Literal[
- "all_time",
- "daily",
- "monthly",
- "per_authorization",
- "weekly",
- "yearly",
- ]
- """
- Interval (or event) to which the amount applies.
- """
-
- class DeliverCardParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class FailCardParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(RequestOptions):
- cardholder: NotRequired[str]
- """
- Only return cards belonging to the Cardholder with the provided ID.
- """
- created: NotRequired["Card.ListParamsCreated|int"]
- """
- Only return cards that were issued during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- exp_month: NotRequired[int]
- """
- Only return cards that have the given expiration month.
- """
- exp_year: NotRequired[int]
- """
- Only return cards that have the given expiration year.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- last4: NotRequired[str]
- """
- Only return cards that have the given last four digits.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- personalization_design: NotRequired[str]
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["active", "canceled", "inactive"]]
- """
- Only return cards that have the given status. One of `active`, `inactive`, or `canceled`.
- """
- type: NotRequired[Literal["physical", "virtual"]]
- """
- Only return cards that have the given type. One of `virtual` or `physical`.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- cancellation_reason: NotRequired[Literal["lost", "stolen"]]
- """
- Reason why the `status` of this card is `canceled`.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- personalization_design: NotRequired[str]
- pin: NotRequired["Card.ModifyParamsPin"]
- """
- The desired new PIN for this card.
- """
- shipping: NotRequired["Card.ModifyParamsShipping"]
- """
- Updated shipping information for the card.
- """
- spending_controls: NotRequired["Card.ModifyParamsSpendingControls"]
- """
- Rules that control spending for this card. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
- """
- status: NotRequired[Literal["active", "canceled", "inactive"]]
- """
- Dictates whether authorizations can be approved on this card. May be blocked from activating cards depending on past-due Cardholder requirements. Defaults to `inactive`. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`.
- """
-
- class ModifyParamsPin(TypedDict):
- encrypted_number: NotRequired[str]
- """
- The card's desired new PIN, encrypted under Stripe's public key.
- """
-
- class ModifyParamsShipping(TypedDict):
- address: "Card.ModifyParamsShippingAddress"
- """
- The address that the card is shipped to.
- """
- address_validation: NotRequired[
- "Card.ModifyParamsShippingAddressValidation"
- ]
- """
- Address validation settings.
- """
- customs: NotRequired["Card.ModifyParamsShippingCustoms"]
- """
- Customs information for the shipment.
- """
- name: str
- """
- The name printed on the shipping label when shipping the card.
- """
- phone_number: NotRequired[str]
- """
- Phone number of the recipient of the shipment.
- """
- require_signature: NotRequired[bool]
- """
- Whether a signature is required for card delivery.
- """
- service: NotRequired[Literal["express", "priority", "standard"]]
- """
- Shipment service.
- """
- type: NotRequired[Literal["bulk", "individual"]]
- """
- Packaging options.
- """
-
- class ModifyParamsShippingAddress(TypedDict):
- city: str
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: str
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ModifyParamsShippingAddressValidation(TypedDict):
- mode: Literal[
- "disabled", "normalization_only", "validation_and_normalization"
- ]
- """
- The address validation capabilities to use.
- """
-
- class ModifyParamsShippingCustoms(TypedDict):
- eori_number: NotRequired[str]
- """
- The Economic Operators Registration and Identification (EORI) number to use for Customs. Required for bulk shipments to Europe.
- """
-
- class ModifyParamsSpendingControls(TypedDict):
- allowed_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
- """
- allowed_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
- """
- blocked_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
- """
- blocked_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
- """
- spending_limits: NotRequired[
- List["Card.ModifyParamsSpendingControlsSpendingLimit"]
- ]
- """
- Limit spending with amount-based rules that apply across any cards this card replaced (i.e., its `replacement_for` card and _that_ card's `replacement_for` card, up the chain).
- """
-
- class ModifyParamsSpendingControlsSpendingLimit(TypedDict):
- amount: int
- """
- Maximum amount allowed to spend per interval.
- """
- categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
- """
- interval: Literal[
- "all_time",
- "daily",
- "monthly",
- "per_authorization",
- "weekly",
- "yearly",
- ]
- """
- Interval (or event) to which the amount applies.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ReturnCardParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ShipCardParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SubmitCardParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
brand: str
"""
The brand of the card.
@@ -3530,7 +1283,7 @@ class SubmitCardParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["Card.CreateParams"]) -> "Card":
+ def create(cls, **params: Unpack["CardCreateParams"]) -> "Card":
"""
Creates an Issuing Card object.
"""
@@ -3545,7 +1298,7 @@ def create(cls, **params: Unpack["Card.CreateParams"]) -> "Card":
@classmethod
async def create_async(
- cls, **params: Unpack["Card.CreateParams"]
+ cls, **params: Unpack["CardCreateParams"]
) -> "Card":
"""
Creates an Issuing Card object.
@@ -3560,7 +1313,7 @@ async def create_async(
)
@classmethod
- def list(cls, **params: Unpack["Card.ListParams"]) -> ListObject["Card"]:
+ def list(cls, **params: Unpack["CardListParams"]) -> ListObject["Card"]:
"""
Returns a list of Issuing Card objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
"""
@@ -3579,7 +1332,7 @@ def list(cls, **params: Unpack["Card.ListParams"]) -> ListObject["Card"]:
@classmethod
async def list_async(
- cls, **params: Unpack["Card.ListParams"]
+ cls, **params: Unpack["CardListParams"]
) -> ListObject["Card"]:
"""
Returns a list of Issuing Card objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -3598,7 +1351,7 @@ async def list_async(
return result
@classmethod
- def modify(cls, id: str, **params: Unpack["Card.ModifyParams"]) -> "Card":
+ def modify(cls, id: str, **params: Unpack["CardModifyParams"]) -> "Card":
"""
Updates the specified Issuing Card object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
"""
@@ -3614,7 +1367,7 @@ def modify(cls, id: str, **params: Unpack["Card.ModifyParams"]) -> "Card":
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Card.ModifyParams"]
+ cls, id: str, **params: Unpack["CardModifyParams"]
) -> "Card":
"""
Updates the specified Issuing Card object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -3631,7 +1384,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Card.RetrieveParams"]
+ cls, id: str, **params: Unpack["CardRetrieveParams"]
) -> "Card":
"""
Retrieves an Issuing Card object.
@@ -3642,7 +1395,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Card.RetrieveParams"]
+ cls, id: str, **params: Unpack["CardRetrieveParams"]
) -> "Card":
"""
Retrieves an Issuing Card object.
@@ -3656,7 +1409,7 @@ class TestHelpers(APIResourceTestHelpers["Card"]):
@classmethod
def _cls_deliver_card(
- cls, card: str, **params: Unpack["Card.DeliverCardParams"]
+ cls, card: str, **params: Unpack["CardDeliverCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to delivered.
@@ -3675,7 +1428,7 @@ def _cls_deliver_card(
@overload
@staticmethod
def deliver_card(
- card: str, **params: Unpack["Card.DeliverCardParams"]
+ card: str, **params: Unpack["CardDeliverCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to delivered.
@@ -3684,7 +1437,7 @@ def deliver_card(
@overload
def deliver_card(
- self, **params: Unpack["Card.DeliverCardParams"]
+ self, **params: Unpack["CardDeliverCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to delivered.
@@ -3693,7 +1446,7 @@ def deliver_card(
@class_method_variant("_cls_deliver_card")
def deliver_card( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Card.DeliverCardParams"]
+ self, **params: Unpack["CardDeliverCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to delivered.
@@ -3711,7 +1464,7 @@ def deliver_card( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_deliver_card_async(
- cls, card: str, **params: Unpack["Card.DeliverCardParams"]
+ cls, card: str, **params: Unpack["CardDeliverCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to delivered.
@@ -3730,7 +1483,7 @@ async def _cls_deliver_card_async(
@overload
@staticmethod
async def deliver_card_async(
- card: str, **params: Unpack["Card.DeliverCardParams"]
+ card: str, **params: Unpack["CardDeliverCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to delivered.
@@ -3739,7 +1492,7 @@ async def deliver_card_async(
@overload
async def deliver_card_async(
- self, **params: Unpack["Card.DeliverCardParams"]
+ self, **params: Unpack["CardDeliverCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to delivered.
@@ -3748,7 +1501,7 @@ async def deliver_card_async(
@class_method_variant("_cls_deliver_card_async")
async def deliver_card_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Card.DeliverCardParams"]
+ self, **params: Unpack["CardDeliverCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to delivered.
@@ -3766,7 +1519,7 @@ async def deliver_card_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_fail_card(
- cls, card: str, **params: Unpack["Card.FailCardParams"]
+ cls, card: str, **params: Unpack["CardFailCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to failure.
@@ -3785,7 +1538,7 @@ def _cls_fail_card(
@overload
@staticmethod
def fail_card(
- card: str, **params: Unpack["Card.FailCardParams"]
+ card: str, **params: Unpack["CardFailCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to failure.
@@ -3793,7 +1546,7 @@ def fail_card(
...
@overload
- def fail_card(self, **params: Unpack["Card.FailCardParams"]) -> "Card":
+ def fail_card(self, **params: Unpack["CardFailCardParams"]) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to failure.
"""
@@ -3801,7 +1554,7 @@ def fail_card(self, **params: Unpack["Card.FailCardParams"]) -> "Card":
@class_method_variant("_cls_fail_card")
def fail_card( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Card.FailCardParams"]
+ self, **params: Unpack["CardFailCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to failure.
@@ -3819,7 +1572,7 @@ def fail_card( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_fail_card_async(
- cls, card: str, **params: Unpack["Card.FailCardParams"]
+ cls, card: str, **params: Unpack["CardFailCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to failure.
@@ -3838,7 +1591,7 @@ async def _cls_fail_card_async(
@overload
@staticmethod
async def fail_card_async(
- card: str, **params: Unpack["Card.FailCardParams"]
+ card: str, **params: Unpack["CardFailCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to failure.
@@ -3847,7 +1600,7 @@ async def fail_card_async(
@overload
async def fail_card_async(
- self, **params: Unpack["Card.FailCardParams"]
+ self, **params: Unpack["CardFailCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to failure.
@@ -3856,7 +1609,7 @@ async def fail_card_async(
@class_method_variant("_cls_fail_card_async")
async def fail_card_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Card.FailCardParams"]
+ self, **params: Unpack["CardFailCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to failure.
@@ -3874,7 +1627,7 @@ async def fail_card_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_return_card(
- cls, card: str, **params: Unpack["Card.ReturnCardParams"]
+ cls, card: str, **params: Unpack["CardReturnCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to returned.
@@ -3893,7 +1646,7 @@ def _cls_return_card(
@overload
@staticmethod
def return_card(
- card: str, **params: Unpack["Card.ReturnCardParams"]
+ card: str, **params: Unpack["CardReturnCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to returned.
@@ -3902,7 +1655,7 @@ def return_card(
@overload
def return_card(
- self, **params: Unpack["Card.ReturnCardParams"]
+ self, **params: Unpack["CardReturnCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to returned.
@@ -3911,7 +1664,7 @@ def return_card(
@class_method_variant("_cls_return_card")
def return_card( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Card.ReturnCardParams"]
+ self, **params: Unpack["CardReturnCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to returned.
@@ -3929,7 +1682,7 @@ def return_card( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_return_card_async(
- cls, card: str, **params: Unpack["Card.ReturnCardParams"]
+ cls, card: str, **params: Unpack["CardReturnCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to returned.
@@ -3948,7 +1701,7 @@ async def _cls_return_card_async(
@overload
@staticmethod
async def return_card_async(
- card: str, **params: Unpack["Card.ReturnCardParams"]
+ card: str, **params: Unpack["CardReturnCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to returned.
@@ -3957,7 +1710,7 @@ async def return_card_async(
@overload
async def return_card_async(
- self, **params: Unpack["Card.ReturnCardParams"]
+ self, **params: Unpack["CardReturnCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to returned.
@@ -3966,7 +1719,7 @@ async def return_card_async(
@class_method_variant("_cls_return_card_async")
async def return_card_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Card.ReturnCardParams"]
+ self, **params: Unpack["CardReturnCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to returned.
@@ -3984,7 +1737,7 @@ async def return_card_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_ship_card(
- cls, card: str, **params: Unpack["Card.ShipCardParams"]
+ cls, card: str, **params: Unpack["CardShipCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to shipped.
@@ -4003,7 +1756,7 @@ def _cls_ship_card(
@overload
@staticmethod
def ship_card(
- card: str, **params: Unpack["Card.ShipCardParams"]
+ card: str, **params: Unpack["CardShipCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to shipped.
@@ -4011,7 +1764,7 @@ def ship_card(
...
@overload
- def ship_card(self, **params: Unpack["Card.ShipCardParams"]) -> "Card":
+ def ship_card(self, **params: Unpack["CardShipCardParams"]) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to shipped.
"""
@@ -4019,7 +1772,7 @@ def ship_card(self, **params: Unpack["Card.ShipCardParams"]) -> "Card":
@class_method_variant("_cls_ship_card")
def ship_card( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Card.ShipCardParams"]
+ self, **params: Unpack["CardShipCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to shipped.
@@ -4037,7 +1790,7 @@ def ship_card( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_ship_card_async(
- cls, card: str, **params: Unpack["Card.ShipCardParams"]
+ cls, card: str, **params: Unpack["CardShipCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to shipped.
@@ -4056,7 +1809,7 @@ async def _cls_ship_card_async(
@overload
@staticmethod
async def ship_card_async(
- card: str, **params: Unpack["Card.ShipCardParams"]
+ card: str, **params: Unpack["CardShipCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to shipped.
@@ -4065,7 +1818,7 @@ async def ship_card_async(
@overload
async def ship_card_async(
- self, **params: Unpack["Card.ShipCardParams"]
+ self, **params: Unpack["CardShipCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to shipped.
@@ -4074,7 +1827,7 @@ async def ship_card_async(
@class_method_variant("_cls_ship_card_async")
async def ship_card_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Card.ShipCardParams"]
+ self, **params: Unpack["CardShipCardParams"]
) -> "Card":
"""
Updates the shipping status of the specified Issuing Card object to shipped.
@@ -4092,7 +1845,7 @@ async def ship_card_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_submit_card(
- cls, card: str, **params: Unpack["Card.SubmitCardParams"]
+ 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.
@@ -4111,7 +1864,7 @@ def _cls_submit_card(
@overload
@staticmethod
def submit_card(
- card: str, **params: Unpack["Card.SubmitCardParams"]
+ 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.
@@ -4120,7 +1873,7 @@ def submit_card(
@overload
def submit_card(
- self, **params: Unpack["Card.SubmitCardParams"]
+ self, **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.
@@ -4129,7 +1882,7 @@ def submit_card(
@class_method_variant("_cls_submit_card")
def submit_card( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Card.SubmitCardParams"]
+ self, **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.
@@ -4147,7 +1900,7 @@ def submit_card( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_submit_card_async(
- cls, card: str, **params: Unpack["Card.SubmitCardParams"]
+ 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.
@@ -4166,7 +1919,7 @@ async def _cls_submit_card_async(
@overload
@staticmethod
async def submit_card_async(
- card: str, **params: Unpack["Card.SubmitCardParams"]
+ 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.
@@ -4175,7 +1928,7 @@ async def submit_card_async(
@overload
async def submit_card_async(
- self, **params: Unpack["Card.SubmitCardParams"]
+ self, **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.
@@ -4184,7 +1937,7 @@ async def submit_card_async(
@class_method_variant("_cls_submit_card_async")
async def submit_card_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Card.SubmitCardParams"]
+ self, **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 94c26aff2..c9a8257ea 100644
--- a/stripe/issuing/_card_service.py
+++ b/stripe/issuing/_card_service.py
@@ -5,2242 +5,20 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.issuing._card import Card
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.issuing._card_create_params import CardCreateParams
+ from stripe.params.issuing._card_list_params import CardListParams
+ from stripe.params.issuing._card_retrieve_params import CardRetrieveParams
+ from stripe.params.issuing._card_update_params import CardUpdateParams
-class CardService(StripeService):
- class CreateParams(TypedDict):
- cardholder: NotRequired[str]
- """
- The [Cardholder](https://stripe.com/docs/api#issuing_cardholder_object) object with which the card will be associated.
- """
- currency: str
- """
- The currency for the card.
- """
- exp_month: NotRequired[int]
- """
- The desired expiration month (1-12) for this card if [specifying a custom expiration date](https://docs.stripe.com/issuing/cards/virtual/issue-cards?testing-method=with-code#exp-dates).
- """
- exp_year: NotRequired[int]
- """
- The desired 4-digit expiration year for this card if [specifying a custom expiration date](https://docs.stripe.com/issuing/cards/virtual/issue-cards?testing-method=with-code#exp-dates).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: NotRequired[str]
- """
- The new financial account ID the card will be associated with. This field allows a card to be reassigned to a different financial account.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- personalization_design: NotRequired[str]
- """
- The personalization design object belonging to this card.
- """
- pin: NotRequired["CardService.CreateParamsPin"]
- """
- The desired PIN for this card.
- """
- replacement_for: NotRequired[str]
- """
- The card this is meant to be a replacement for (if any).
- """
- replacement_reason: NotRequired[
- Literal["damaged", "expired", "lost", "stolen"]
- ]
- """
- If `replacement_for` is specified, this should indicate why that card is being replaced.
- """
- second_line: NotRequired["Literal['']|str"]
- """
- The second line to print on the card. Max length: 24 characters.
- """
- shipping: NotRequired["CardService.CreateParamsShipping"]
- """
- The address where the card will be shipped.
- """
- spending_controls: NotRequired[
- "CardService.CreateParamsSpendingControls"
- ]
- """
- Rules that control spending for this card. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
- """
- status: NotRequired[Literal["active", "inactive"]]
- """
- Whether authorizations can be approved on this card. May be blocked from activating cards depending on past-due Cardholder requirements. Defaults to `inactive`.
- """
- type: Literal["physical", "virtual"]
- """
- The type of card to issue. Possible values are `physical` or `virtual`.
- """
-
- class CreateParamsPin(TypedDict):
- encrypted_number: NotRequired[str]
- """
- The card's desired new PIN, encrypted under Stripe's public key.
- """
-
- class CreateParamsShipping(TypedDict):
- address: "CardService.CreateParamsShippingAddress"
- """
- The address that the card is shipped to.
- """
- address_validation: NotRequired[
- "CardService.CreateParamsShippingAddressValidation"
- ]
- """
- Address validation settings.
- """
- customs: NotRequired["CardService.CreateParamsShippingCustoms"]
- """
- Customs information for the shipment.
- """
- name: str
- """
- The name printed on the shipping label when shipping the card.
- """
- phone_number: NotRequired[str]
- """
- Phone number of the recipient of the shipment.
- """
- require_signature: NotRequired[bool]
- """
- Whether a signature is required for card delivery.
- """
- service: NotRequired[Literal["express", "priority", "standard"]]
- """
- Shipment service.
- """
- type: NotRequired[Literal["bulk", "individual"]]
- """
- Packaging options.
- """
-
- class CreateParamsShippingAddress(TypedDict):
- city: str
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: str
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsShippingAddressValidation(TypedDict):
- mode: Literal[
- "disabled", "normalization_only", "validation_and_normalization"
- ]
- """
- The address validation capabilities to use.
- """
-
- class CreateParamsShippingCustoms(TypedDict):
- eori_number: NotRequired[str]
- """
- The Economic Operators Registration and Identification (EORI) number to use for Customs. Required for bulk shipments to Europe.
- """
-
- class CreateParamsSpendingControls(TypedDict):
- allowed_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
- """
- allowed_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
- """
- blocked_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
- """
- blocked_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
- """
- spending_limits: NotRequired[
- List["CardService.CreateParamsSpendingControlsSpendingLimit"]
- ]
- """
- Limit spending with amount-based rules that apply across any cards this card replaced (i.e., its `replacement_for` card and _that_ card's `replacement_for` card, up the chain).
- """
-
- class CreateParamsSpendingControlsSpendingLimit(TypedDict):
- amount: int
- """
- Maximum amount allowed to spend per interval.
- """
- categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
- """
- interval: Literal[
- "all_time",
- "daily",
- "monthly",
- "per_authorization",
- "weekly",
- "yearly",
- ]
- """
- Interval (or event) to which the amount applies.
- """
-
- class ListParams(TypedDict):
- cardholder: NotRequired[str]
- """
- Only return cards belonging to the Cardholder with the provided ID.
- """
- created: NotRequired["CardService.ListParamsCreated|int"]
- """
- Only return cards that were issued during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- exp_month: NotRequired[int]
- """
- Only return cards that have the given expiration month.
- """
- exp_year: NotRequired[int]
- """
- Only return cards that have the given expiration year.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- last4: NotRequired[str]
- """
- Only return cards that have the given last four digits.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- personalization_design: NotRequired[str]
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["active", "canceled", "inactive"]]
- """
- Only return cards that have the given status. One of `active`, `inactive`, or `canceled`.
- """
- type: NotRequired[Literal["physical", "virtual"]]
- """
- Only return cards that have the given type. One of `virtual` or `physical`.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- cancellation_reason: NotRequired[Literal["lost", "stolen"]]
- """
- Reason why the `status` of this card is `canceled`.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- personalization_design: NotRequired[str]
- pin: NotRequired["CardService.UpdateParamsPin"]
- """
- The desired new PIN for this card.
- """
- shipping: NotRequired["CardService.UpdateParamsShipping"]
- """
- Updated shipping information for the card.
- """
- spending_controls: NotRequired[
- "CardService.UpdateParamsSpendingControls"
- ]
- """
- Rules that control spending for this card. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
- """
- status: NotRequired[Literal["active", "canceled", "inactive"]]
- """
- Dictates whether authorizations can be approved on this card. May be blocked from activating cards depending on past-due Cardholder requirements. Defaults to `inactive`. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`.
- """
-
- class UpdateParamsPin(TypedDict):
- encrypted_number: NotRequired[str]
- """
- The card's desired new PIN, encrypted under Stripe's public key.
- """
-
- class UpdateParamsShipping(TypedDict):
- address: "CardService.UpdateParamsShippingAddress"
- """
- The address that the card is shipped to.
- """
- address_validation: NotRequired[
- "CardService.UpdateParamsShippingAddressValidation"
- ]
- """
- Address validation settings.
- """
- customs: NotRequired["CardService.UpdateParamsShippingCustoms"]
- """
- Customs information for the shipment.
- """
- name: str
- """
- The name printed on the shipping label when shipping the card.
- """
- phone_number: NotRequired[str]
- """
- Phone number of the recipient of the shipment.
- """
- require_signature: NotRequired[bool]
- """
- Whether a signature is required for card delivery.
- """
- service: NotRequired[Literal["express", "priority", "standard"]]
- """
- Shipment service.
- """
- type: NotRequired[Literal["bulk", "individual"]]
- """
- Packaging options.
- """
-
- class UpdateParamsShippingAddress(TypedDict):
- city: str
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: str
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsShippingAddressValidation(TypedDict):
- mode: Literal[
- "disabled", "normalization_only", "validation_and_normalization"
- ]
- """
- The address validation capabilities to use.
- """
-
- class UpdateParamsShippingCustoms(TypedDict):
- eori_number: NotRequired[str]
- """
- The Economic Operators Registration and Identification (EORI) number to use for Customs. Required for bulk shipments to Europe.
- """
-
- class UpdateParamsSpendingControls(TypedDict):
- allowed_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
- """
- allowed_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
- """
- blocked_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
- """
- blocked_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
- """
- spending_limits: NotRequired[
- List["CardService.UpdateParamsSpendingControlsSpendingLimit"]
- ]
- """
- Limit spending with amount-based rules that apply across any cards this card replaced (i.e., its `replacement_for` card and _that_ card's `replacement_for` card, up the chain).
- """
-
- class UpdateParamsSpendingControlsSpendingLimit(TypedDict):
- amount: int
- """
- Maximum amount allowed to spend per interval.
- """
- categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
- """
- interval: Literal[
- "all_time",
- "daily",
- "monthly",
- "per_authorization",
- "weekly",
- "yearly",
- ]
- """
- Interval (or event) to which the amount applies.
- """
+class CardService(StripeService):
def list(
self,
- params: Optional["CardService.ListParams"] = None,
+ params: Optional["CardListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Card]:
"""
@@ -2259,7 +37,7 @@ def list(
async def list_async(
self,
- params: Optional["CardService.ListParams"] = None,
+ params: Optional["CardListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Card]:
"""
@@ -2278,7 +56,7 @@ async def list_async(
def create(
self,
- params: "CardService.CreateParams",
+ params: "CardCreateParams",
options: Optional[RequestOptions] = None,
) -> Card:
"""
@@ -2297,7 +75,7 @@ def create(
async def create_async(
self,
- params: "CardService.CreateParams",
+ params: "CardCreateParams",
options: Optional[RequestOptions] = None,
) -> Card:
"""
@@ -2317,7 +95,7 @@ async def create_async(
def retrieve(
self,
card: str,
- params: Optional["CardService.RetrieveParams"] = None,
+ params: Optional["CardRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Card:
"""
@@ -2337,7 +115,7 @@ def retrieve(
async def retrieve_async(
self,
card: str,
- params: Optional["CardService.RetrieveParams"] = None,
+ params: Optional["CardRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Card:
"""
@@ -2357,7 +135,7 @@ async def retrieve_async(
def update(
self,
card: str,
- params: Optional["CardService.UpdateParams"] = None,
+ params: Optional["CardUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Card:
"""
@@ -2377,7 +155,7 @@ def update(
async def update_async(
self,
card: str,
- params: Optional["CardService.UpdateParams"] = None,
+ params: Optional["CardUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Card:
"""
diff --git a/stripe/issuing/_cardholder.py b/stripe/issuing/_cardholder.py
index 86219de04..673668b82 100644
--- a/stripe/issuing/_cardholder.py
+++ b/stripe/issuing/_cardholder.py
@@ -4,21 +4,26 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import sanitize_id
from typing import ClassVar, Dict, List, Optional, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._file import File
+ from stripe.params.issuing._cardholder_create_params import (
+ CardholderCreateParams,
+ )
+ from stripe.params.issuing._cardholder_list_params import (
+ CardholderListParams,
+ )
+ from stripe.params.issuing._cardholder_modify_params import (
+ CardholderModifyParams,
+ )
+ from stripe.params.issuing._cardholder_retrieve_params import (
+ CardholderRetrieveParams,
+ )
class Cardholder(
@@ -1128,2304 +1133,6 @@ class SpendingLimit(StripeObject):
"""
_inner_class_types = {"spending_limits": SpendingLimit}
- class CreateParams(RequestOptions):
- billing: "Cardholder.CreateParamsBilling"
- """
- The cardholder's billing address.
- """
- company: NotRequired["Cardholder.CreateParamsCompany"]
- """
- Additional information about a `company` cardholder.
- """
- email: NotRequired[str]
- """
- The cardholder's email address.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- individual: NotRequired["Cardholder.CreateParamsIndividual"]
- """
- Additional information about an `individual` cardholder.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The cardholder's name. This will be printed on cards issued to them. The maximum length of this field is 24 characters. This field cannot contain any special characters or numbers.
- """
- phone_number: NotRequired[str]
- """
- The cardholder's phone number. This will be transformed to [E.164](https://en.wikipedia.org/wiki/E.164) if it is not provided in that format already. This is required for all cardholders who will be creating EU cards. See the [3D Secure documentation](https://stripe.com/docs/issuing/3d-secure#when-is-3d-secure-applied) for more details.
- """
- preferred_locales: NotRequired[
- List[Literal["de", "en", "es", "fr", "it"]]
- ]
- """
- The cardholder's preferred locales (languages), ordered by preference. Locales can be `de`, `en`, `es`, `fr`, or `it`.
- This changes the language of the [3D Secure flow](https://stripe.com/docs/issuing/3d-secure) and one-time password messages sent to the cardholder.
- """
- spending_controls: NotRequired[
- "Cardholder.CreateParamsSpendingControls"
- ]
- """
- Rules that control spending across this cardholder's cards. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
- """
- status: NotRequired[Literal["active", "inactive"]]
- """
- Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`.
- """
- type: NotRequired[Literal["company", "individual"]]
- """
- One of `individual` or `company`. See [Choose a cardholder type](https://stripe.com/docs/issuing/other/choose-cardholder) for more details.
- """
-
- class CreateParamsBilling(TypedDict):
- address: "Cardholder.CreateParamsBillingAddress"
- """
- The cardholder's billing address.
- """
-
- class CreateParamsBillingAddress(TypedDict):
- city: str
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: str
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsCompany(TypedDict):
- tax_id: NotRequired[str]
- """
- The entity's business ID number.
- """
-
- class CreateParamsIndividual(TypedDict):
- card_issuing: NotRequired[
- "Cardholder.CreateParamsIndividualCardIssuing"
- ]
- """
- Information related to the card_issuing program for this cardholder.
- """
- dob: NotRequired["Cardholder.CreateParamsIndividualDob"]
- """
- The date of birth of this cardholder. Cardholders must be older than 13 years old.
- """
- first_name: NotRequired[str]
- """
- The first name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
- """
- last_name: NotRequired[str]
- """
- The last name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
- """
- verification: NotRequired[
- "Cardholder.CreateParamsIndividualVerification"
- ]
- """
- Government-issued ID document for this cardholder.
- """
-
- class CreateParamsIndividualCardIssuing(TypedDict):
- user_terms_acceptance: NotRequired[
- "Cardholder.CreateParamsIndividualCardIssuingUserTermsAcceptance"
- ]
- """
- Information about cardholder acceptance of Celtic [Authorized User Terms](https://stripe.com/docs/issuing/cards#accept-authorized-user-terms). Required for cards backed by a Celtic program.
- """
-
- class CreateParamsIndividualCardIssuingUserTermsAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
- """
- ip: NotRequired[str]
- """
- The IP address from which the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the cardholder accepted the Authorized User Terms.
- """
-
- class CreateParamsIndividualDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsIndividualVerification(TypedDict):
- document: NotRequired[
- "Cardholder.CreateParamsIndividualVerificationDocument"
- ]
- """
- An identifying document, either a passport or local ID card.
- """
-
- class CreateParamsIndividualVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
- """
-
- class CreateParamsSpendingControls(TypedDict):
- allowed_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
- """
- allowed_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
- """
- blocked_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
- """
- blocked_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
- """
- spending_limits: NotRequired[
- List["Cardholder.CreateParamsSpendingControlsSpendingLimit"]
- ]
- """
- Limit spending with amount-based rules that apply across this cardholder's cards.
- """
- spending_limits_currency: NotRequired[str]
- """
- Currency of amounts within `spending_limits`. Defaults to your merchant country's currency.
- """
-
- class CreateParamsSpendingControlsSpendingLimit(TypedDict):
- amount: int
- """
- Maximum amount allowed to spend per interval.
- """
- categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
- """
- interval: Literal[
- "all_time",
- "daily",
- "monthly",
- "per_authorization",
- "weekly",
- "yearly",
- ]
- """
- Interval (or event) to which the amount applies.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["Cardholder.ListParamsCreated|int"]
- """
- Only return cardholders that were created during the given date interval.
- """
- email: NotRequired[str]
- """
- Only return cardholders that have the given email address.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- phone_number: NotRequired[str]
- """
- Only return cardholders that have the given phone number.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["active", "blocked", "inactive"]]
- """
- Only return cardholders that have the given status. One of `active`, `inactive`, or `blocked`.
- """
- type: NotRequired[Literal["company", "individual"]]
- """
- Only return cardholders that have the given type. One of `individual` or `company`.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- billing: NotRequired["Cardholder.ModifyParamsBilling"]
- """
- The cardholder's billing address.
- """
- company: NotRequired["Cardholder.ModifyParamsCompany"]
- """
- Additional information about a `company` cardholder.
- """
- email: NotRequired[str]
- """
- The cardholder's email address.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- individual: NotRequired["Cardholder.ModifyParamsIndividual"]
- """
- Additional information about an `individual` cardholder.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- phone_number: NotRequired[str]
- """
- The cardholder's phone number. This is required for all cardholders who will be creating EU cards. See the [3D Secure documentation](https://stripe.com/docs/issuing/3d-secure) for more details.
- """
- preferred_locales: NotRequired[
- List[Literal["de", "en", "es", "fr", "it"]]
- ]
- """
- The cardholder's preferred locales (languages), ordered by preference. Locales can be `de`, `en`, `es`, `fr`, or `it`.
- This changes the language of the [3D Secure flow](https://stripe.com/docs/issuing/3d-secure) and one-time password messages sent to the cardholder.
- """
- spending_controls: NotRequired[
- "Cardholder.ModifyParamsSpendingControls"
- ]
- """
- Rules that control spending across this cardholder's cards. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
- """
- status: NotRequired[Literal["active", "inactive"]]
- """
- Specifies whether to permit authorizations on this cardholder's cards.
- """
-
- class ModifyParamsBilling(TypedDict):
- address: "Cardholder.ModifyParamsBillingAddress"
- """
- The cardholder's billing address.
- """
-
- class ModifyParamsBillingAddress(TypedDict):
- city: str
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: str
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ModifyParamsCompany(TypedDict):
- tax_id: NotRequired[str]
- """
- The entity's business ID number.
- """
-
- class ModifyParamsIndividual(TypedDict):
- card_issuing: NotRequired[
- "Cardholder.ModifyParamsIndividualCardIssuing"
- ]
- """
- Information related to the card_issuing program for this cardholder.
- """
- dob: NotRequired["Cardholder.ModifyParamsIndividualDob"]
- """
- The date of birth of this cardholder. Cardholders must be older than 13 years old.
- """
- first_name: NotRequired[str]
- """
- The first name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
- """
- last_name: NotRequired[str]
- """
- The last name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
- """
- verification: NotRequired[
- "Cardholder.ModifyParamsIndividualVerification"
- ]
- """
- Government-issued ID document for this cardholder.
- """
-
- class ModifyParamsIndividualCardIssuing(TypedDict):
- user_terms_acceptance: NotRequired[
- "Cardholder.ModifyParamsIndividualCardIssuingUserTermsAcceptance"
- ]
- """
- Information about cardholder acceptance of Celtic [Authorized User Terms](https://stripe.com/docs/issuing/cards#accept-authorized-user-terms). Required for cards backed by a Celtic program.
- """
-
- class ModifyParamsIndividualCardIssuingUserTermsAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
- """
- ip: NotRequired[str]
- """
- The IP address from which the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the cardholder accepted the Authorized User Terms.
- """
-
- class ModifyParamsIndividualDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class ModifyParamsIndividualVerification(TypedDict):
- document: NotRequired[
- "Cardholder.ModifyParamsIndividualVerificationDocument"
- ]
- """
- An identifying document, either a passport or local ID card.
- """
-
- class ModifyParamsIndividualVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
- """
-
- class ModifyParamsSpendingControls(TypedDict):
- allowed_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
- """
- allowed_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
- """
- blocked_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
- """
- blocked_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
- """
- spending_limits: NotRequired[
- List["Cardholder.ModifyParamsSpendingControlsSpendingLimit"]
- ]
- """
- Limit spending with amount-based rules that apply across this cardholder's cards.
- """
- spending_limits_currency: NotRequired[str]
- """
- Currency of amounts within `spending_limits`. Defaults to your merchant country's currency.
- """
-
- class ModifyParamsSpendingControlsSpendingLimit(TypedDict):
- amount: int
- """
- Maximum amount allowed to spend per interval.
- """
- categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
- """
- interval: Literal[
- "all_time",
- "daily",
- "monthly",
- "per_authorization",
- "weekly",
- "yearly",
- ]
- """
- Interval (or event) to which the amount applies.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
billing: Billing
company: Optional[Company]
"""
@@ -3488,7 +1195,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["Cardholder.CreateParams"]
+ cls, **params: Unpack["CardholderCreateParams"]
) -> "Cardholder":
"""
Creates a new Issuing Cardholder object that can be issued cards.
@@ -3504,7 +1211,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["Cardholder.CreateParams"]
+ cls, **params: Unpack["CardholderCreateParams"]
) -> "Cardholder":
"""
Creates a new Issuing Cardholder object that can be issued cards.
@@ -3520,7 +1227,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["Cardholder.ListParams"]
+ cls, **params: Unpack["CardholderListParams"]
) -> ListObject["Cardholder"]:
"""
Returns a list of Issuing Cardholder objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -3540,7 +1247,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Cardholder.ListParams"]
+ cls, **params: Unpack["CardholderListParams"]
) -> ListObject["Cardholder"]:
"""
Returns a list of Issuing Cardholder objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -3560,7 +1267,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Cardholder.ModifyParams"]
+ cls, id: str, **params: Unpack["CardholderModifyParams"]
) -> "Cardholder":
"""
Updates the specified Issuing Cardholder object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -3577,7 +1284,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Cardholder.ModifyParams"]
+ cls, id: str, **params: Unpack["CardholderModifyParams"]
) -> "Cardholder":
"""
Updates the specified Issuing Cardholder object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -3594,7 +1301,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Cardholder.RetrieveParams"]
+ cls, id: str, **params: Unpack["CardholderRetrieveParams"]
) -> "Cardholder":
"""
Retrieves an Issuing Cardholder object.
@@ -3605,7 +1312,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Cardholder.RetrieveParams"]
+ cls, id: str, **params: Unpack["CardholderRetrieveParams"]
) -> "Cardholder":
"""
Retrieves an Issuing Cardholder object.
diff --git a/stripe/issuing/_cardholder_service.py b/stripe/issuing/_cardholder_service.py
index 54f9058dd..3ca7ae92a 100644
--- a/stripe/issuing/_cardholder_service.py
+++ b/stripe/issuing/_cardholder_service.py
@@ -5,2312 +5,28 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.issuing._cardholder import Cardholder
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.issuing._cardholder_create_params import (
+ CardholderCreateParams,
+ )
+ from stripe.params.issuing._cardholder_list_params import (
+ CardholderListParams,
+ )
+ from stripe.params.issuing._cardholder_retrieve_params import (
+ CardholderRetrieveParams,
+ )
+ from stripe.params.issuing._cardholder_update_params import (
+ CardholderUpdateParams,
+ )
class CardholderService(StripeService):
- class CreateParams(TypedDict):
- billing: "CardholderService.CreateParamsBilling"
- """
- The cardholder's billing address.
- """
- company: NotRequired["CardholderService.CreateParamsCompany"]
- """
- Additional information about a `company` cardholder.
- """
- email: NotRequired[str]
- """
- The cardholder's email address.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- individual: NotRequired["CardholderService.CreateParamsIndividual"]
- """
- Additional information about an `individual` cardholder.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The cardholder's name. This will be printed on cards issued to them. The maximum length of this field is 24 characters. This field cannot contain any special characters or numbers.
- """
- phone_number: NotRequired[str]
- """
- The cardholder's phone number. This will be transformed to [E.164](https://en.wikipedia.org/wiki/E.164) if it is not provided in that format already. This is required for all cardholders who will be creating EU cards. See the [3D Secure documentation](https://stripe.com/docs/issuing/3d-secure#when-is-3d-secure-applied) for more details.
- """
- preferred_locales: NotRequired[
- List[Literal["de", "en", "es", "fr", "it"]]
- ]
- """
- The cardholder's preferred locales (languages), ordered by preference. Locales can be `de`, `en`, `es`, `fr`, or `it`.
- This changes the language of the [3D Secure flow](https://stripe.com/docs/issuing/3d-secure) and one-time password messages sent to the cardholder.
- """
- spending_controls: NotRequired[
- "CardholderService.CreateParamsSpendingControls"
- ]
- """
- Rules that control spending across this cardholder's cards. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
- """
- status: NotRequired[Literal["active", "inactive"]]
- """
- Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`.
- """
- type: NotRequired[Literal["company", "individual"]]
- """
- One of `individual` or `company`. See [Choose a cardholder type](https://stripe.com/docs/issuing/other/choose-cardholder) for more details.
- """
-
- class CreateParamsBilling(TypedDict):
- address: "CardholderService.CreateParamsBillingAddress"
- """
- The cardholder's billing address.
- """
-
- class CreateParamsBillingAddress(TypedDict):
- city: str
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: str
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsCompany(TypedDict):
- tax_id: NotRequired[str]
- """
- The entity's business ID number.
- """
-
- class CreateParamsIndividual(TypedDict):
- card_issuing: NotRequired[
- "CardholderService.CreateParamsIndividualCardIssuing"
- ]
- """
- Information related to the card_issuing program for this cardholder.
- """
- dob: NotRequired["CardholderService.CreateParamsIndividualDob"]
- """
- The date of birth of this cardholder. Cardholders must be older than 13 years old.
- """
- first_name: NotRequired[str]
- """
- The first name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
- """
- last_name: NotRequired[str]
- """
- The last name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
- """
- verification: NotRequired[
- "CardholderService.CreateParamsIndividualVerification"
- ]
- """
- Government-issued ID document for this cardholder.
- """
-
- class CreateParamsIndividualCardIssuing(TypedDict):
- user_terms_acceptance: NotRequired[
- "CardholderService.CreateParamsIndividualCardIssuingUserTermsAcceptance"
- ]
- """
- Information about cardholder acceptance of Celtic [Authorized User Terms](https://stripe.com/docs/issuing/cards#accept-authorized-user-terms). Required for cards backed by a Celtic program.
- """
-
- class CreateParamsIndividualCardIssuingUserTermsAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
- """
- ip: NotRequired[str]
- """
- The IP address from which the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the cardholder accepted the Authorized User Terms.
- """
-
- class CreateParamsIndividualDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsIndividualVerification(TypedDict):
- document: NotRequired[
- "CardholderService.CreateParamsIndividualVerificationDocument"
- ]
- """
- An identifying document, either a passport or local ID card.
- """
-
- class CreateParamsIndividualVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
- """
-
- class CreateParamsSpendingControls(TypedDict):
- allowed_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
- """
- allowed_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
- """
- blocked_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
- """
- blocked_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
- """
- spending_limits: NotRequired[
- List["CardholderService.CreateParamsSpendingControlsSpendingLimit"]
- ]
- """
- Limit spending with amount-based rules that apply across this cardholder's cards.
- """
- spending_limits_currency: NotRequired[str]
- """
- Currency of amounts within `spending_limits`. Defaults to your merchant country's currency.
- """
-
- class CreateParamsSpendingControlsSpendingLimit(TypedDict):
- amount: int
- """
- Maximum amount allowed to spend per interval.
- """
- categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
- """
- interval: Literal[
- "all_time",
- "daily",
- "monthly",
- "per_authorization",
- "weekly",
- "yearly",
- ]
- """
- Interval (or event) to which the amount applies.
- """
-
- class ListParams(TypedDict):
- created: NotRequired["CardholderService.ListParamsCreated|int"]
- """
- Only return cardholders that were created during the given date interval.
- """
- email: NotRequired[str]
- """
- Only return cardholders that have the given email address.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- phone_number: NotRequired[str]
- """
- Only return cardholders that have the given phone number.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["active", "blocked", "inactive"]]
- """
- Only return cardholders that have the given status. One of `active`, `inactive`, or `blocked`.
- """
- type: NotRequired[Literal["company", "individual"]]
- """
- Only return cardholders that have the given type. One of `individual` or `company`.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- billing: NotRequired["CardholderService.UpdateParamsBilling"]
- """
- The cardholder's billing address.
- """
- company: NotRequired["CardholderService.UpdateParamsCompany"]
- """
- Additional information about a `company` cardholder.
- """
- email: NotRequired[str]
- """
- The cardholder's email address.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- individual: NotRequired["CardholderService.UpdateParamsIndividual"]
- """
- Additional information about an `individual` cardholder.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- phone_number: NotRequired[str]
- """
- The cardholder's phone number. This is required for all cardholders who will be creating EU cards. See the [3D Secure documentation](https://stripe.com/docs/issuing/3d-secure) for more details.
- """
- preferred_locales: NotRequired[
- List[Literal["de", "en", "es", "fr", "it"]]
- ]
- """
- The cardholder's preferred locales (languages), ordered by preference. Locales can be `de`, `en`, `es`, `fr`, or `it`.
- This changes the language of the [3D Secure flow](https://stripe.com/docs/issuing/3d-secure) and one-time password messages sent to the cardholder.
- """
- spending_controls: NotRequired[
- "CardholderService.UpdateParamsSpendingControls"
- ]
- """
- Rules that control spending across this cardholder's cards. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
- """
- status: NotRequired[Literal["active", "inactive"]]
- """
- Specifies whether to permit authorizations on this cardholder's cards.
- """
-
- class UpdateParamsBilling(TypedDict):
- address: "CardholderService.UpdateParamsBillingAddress"
- """
- The cardholder's billing address.
- """
-
- class UpdateParamsBillingAddress(TypedDict):
- city: str
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: str
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: str
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsCompany(TypedDict):
- tax_id: NotRequired[str]
- """
- The entity's business ID number.
- """
-
- class UpdateParamsIndividual(TypedDict):
- card_issuing: NotRequired[
- "CardholderService.UpdateParamsIndividualCardIssuing"
- ]
- """
- Information related to the card_issuing program for this cardholder.
- """
- dob: NotRequired["CardholderService.UpdateParamsIndividualDob"]
- """
- The date of birth of this cardholder. Cardholders must be older than 13 years old.
- """
- first_name: NotRequired[str]
- """
- The first name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
- """
- last_name: NotRequired[str]
- """
- The last name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
- """
- verification: NotRequired[
- "CardholderService.UpdateParamsIndividualVerification"
- ]
- """
- Government-issued ID document for this cardholder.
- """
-
- class UpdateParamsIndividualCardIssuing(TypedDict):
- user_terms_acceptance: NotRequired[
- "CardholderService.UpdateParamsIndividualCardIssuingUserTermsAcceptance"
- ]
- """
- Information about cardholder acceptance of Celtic [Authorized User Terms](https://stripe.com/docs/issuing/cards#accept-authorized-user-terms). Required for cards backed by a Celtic program.
- """
-
- class UpdateParamsIndividualCardIssuingUserTermsAcceptance(TypedDict):
- date: NotRequired[int]
- """
- The Unix timestamp marking when the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
- """
- ip: NotRequired[str]
- """
- The IP address from which the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
- """
- user_agent: NotRequired["Literal['']|str"]
- """
- The user agent of the browser from which the cardholder accepted the Authorized User Terms.
- """
-
- class UpdateParamsIndividualDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class UpdateParamsIndividualVerification(TypedDict):
- document: NotRequired[
- "CardholderService.UpdateParamsIndividualVerificationDocument"
- ]
- """
- An identifying document, either a passport or local ID card.
- """
-
- class UpdateParamsIndividualVerificationDocument(TypedDict):
- back: NotRequired[str]
- """
- The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
- """
- front: NotRequired[str]
- """
- The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
- """
-
- class UpdateParamsSpendingControls(TypedDict):
- allowed_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
- """
- allowed_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
- """
- blocked_categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
- """
- blocked_merchant_countries: NotRequired[List[str]]
- """
- Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
- """
- spending_limits: NotRequired[
- List["CardholderService.UpdateParamsSpendingControlsSpendingLimit"]
- ]
- """
- Limit spending with amount-based rules that apply across this cardholder's cards.
- """
- spending_limits_currency: NotRequired[str]
- """
- Currency of amounts within `spending_limits`. Defaults to your merchant country's currency.
- """
-
- class UpdateParamsSpendingControlsSpendingLimit(TypedDict):
- amount: int
- """
- Maximum amount allowed to spend per interval.
- """
- categories: NotRequired[
- List[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- ]
- """
- Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
- """
- interval: Literal[
- "all_time",
- "daily",
- "monthly",
- "per_authorization",
- "weekly",
- "yearly",
- ]
- """
- Interval (or event) to which the amount applies.
- """
-
def list(
self,
- params: Optional["CardholderService.ListParams"] = None,
+ params: Optional["CardholderListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Cardholder]:
"""
@@ -2329,7 +45,7 @@ def list(
async def list_async(
self,
- params: Optional["CardholderService.ListParams"] = None,
+ params: Optional["CardholderListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Cardholder]:
"""
@@ -2348,7 +64,7 @@ async def list_async(
def create(
self,
- params: "CardholderService.CreateParams",
+ params: "CardholderCreateParams",
options: Optional[RequestOptions] = None,
) -> Cardholder:
"""
@@ -2367,7 +83,7 @@ def create(
async def create_async(
self,
- params: "CardholderService.CreateParams",
+ params: "CardholderCreateParams",
options: Optional[RequestOptions] = None,
) -> Cardholder:
"""
@@ -2387,7 +103,7 @@ async def create_async(
def retrieve(
self,
cardholder: str,
- params: Optional["CardholderService.RetrieveParams"] = None,
+ params: Optional["CardholderRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Cardholder:
"""
@@ -2409,7 +125,7 @@ def retrieve(
async def retrieve_async(
self,
cardholder: str,
- params: Optional["CardholderService.RetrieveParams"] = None,
+ params: Optional["CardholderRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Cardholder:
"""
@@ -2431,7 +147,7 @@ async def retrieve_async(
def update(
self,
cardholder: str,
- params: Optional["CardholderService.UpdateParams"] = None,
+ params: Optional["CardholderUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Cardholder:
"""
@@ -2453,7 +169,7 @@ def update(
async def update_async(
self,
cardholder: str,
- params: Optional["CardholderService.UpdateParams"] = None,
+ params: Optional["CardholderUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Cardholder:
"""
diff --git a/stripe/issuing/_dispute.py b/stripe/issuing/_dispute.py
index b6a200243..2be6f914d 100644
--- a/stripe/issuing/_dispute.py
+++ b/stripe/issuing/_dispute.py
@@ -4,23 +4,29 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._balance_transaction import BalanceTransaction
from stripe._file import File
from stripe.issuing._transaction import Transaction
+ from stripe.params.issuing._dispute_create_params import (
+ DisputeCreateParams,
+ )
+ from stripe.params.issuing._dispute_list_params import DisputeListParams
+ from stripe.params.issuing._dispute_modify_params import (
+ DisputeModifyParams,
+ )
+ from stripe.params.issuing._dispute_retrieve_params import (
+ DisputeRetrieveParams,
+ )
+ from stripe.params.issuing._dispute_submit_params import (
+ DisputeSubmitParams,
+ )
class Dispute(
@@ -255,620 +261,6 @@ class Treasury(StripeObject):
The Treasury [ReceivedDebit](https://stripe.com/docs/api/treasury/received_debits) that is being disputed.
"""
- class CreateParams(RequestOptions):
- amount: NotRequired[int]
- """
- The dispute amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). If not set, defaults to the full transaction amount.
- """
- evidence: NotRequired["Dispute.CreateParamsEvidence"]
- """
- Evidence provided for the dispute.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- transaction: NotRequired[str]
- """
- The ID of the issuing transaction to create a dispute for. For transaction on Treasury FinancialAccounts, use `treasury.received_debit`.
- """
- treasury: NotRequired["Dispute.CreateParamsTreasury"]
- """
- Params for disputes related to Treasury FinancialAccounts
- """
-
- class CreateParamsEvidence(TypedDict):
- canceled: NotRequired[
- "Literal['']|Dispute.CreateParamsEvidenceCanceled"
- ]
- """
- Evidence provided when `reason` is 'canceled'.
- """
- duplicate: NotRequired[
- "Literal['']|Dispute.CreateParamsEvidenceDuplicate"
- ]
- """
- Evidence provided when `reason` is 'duplicate'.
- """
- fraudulent: NotRequired[
- "Literal['']|Dispute.CreateParamsEvidenceFraudulent"
- ]
- """
- Evidence provided when `reason` is 'fraudulent'.
- """
- merchandise_not_as_described: NotRequired[
- "Literal['']|Dispute.CreateParamsEvidenceMerchandiseNotAsDescribed"
- ]
- """
- Evidence provided when `reason` is 'merchandise_not_as_described'.
- """
- no_valid_authorization: NotRequired[
- "Literal['']|Dispute.CreateParamsEvidenceNoValidAuthorization"
- ]
- """
- Evidence provided when `reason` is 'no_valid_authorization'.
- """
- not_received: NotRequired[
- "Literal['']|Dispute.CreateParamsEvidenceNotReceived"
- ]
- """
- Evidence provided when `reason` is 'not_received'.
- """
- other: NotRequired["Literal['']|Dispute.CreateParamsEvidenceOther"]
- """
- Evidence provided when `reason` is 'other'.
- """
- reason: NotRequired[
- Literal[
- "canceled",
- "duplicate",
- "fraudulent",
- "merchandise_not_as_described",
- "no_valid_authorization",
- "not_received",
- "other",
- "service_not_as_described",
- ]
- ]
- """
- The reason for filing the dispute. The evidence should be submitted in the field of the same name.
- """
- service_not_as_described: NotRequired[
- "Literal['']|Dispute.CreateParamsEvidenceServiceNotAsDescribed"
- ]
- """
- Evidence provided when `reason` is 'service_not_as_described'.
- """
-
- class CreateParamsEvidenceCanceled(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- canceled_at: NotRequired["Literal['']|int"]
- """
- Date when order was canceled.
- """
- cancellation_policy_provided: NotRequired["Literal['']|bool"]
- """
- Whether the cardholder was provided with a cancellation policy.
- """
- cancellation_reason: NotRequired["Literal['']|str"]
- """
- Reason for canceling the order.
- """
- expected_at: NotRequired["Literal['']|int"]
- """
- Date when the cardholder expected to receive the product.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- Description of the merchandise or service that was purchased.
- """
- product_type: NotRequired[
- "Literal['']|Literal['merchandise', 'service']"
- ]
- """
- Whether the product was a merchandise or service.
- """
- return_status: NotRequired[
- "Literal['']|Literal['merchant_rejected', 'successful']"
- ]
- """
- Result of cardholder's attempt to return the product.
- """
- returned_at: NotRequired["Literal['']|int"]
- """
- Date when the product was returned or attempted to be returned.
- """
-
- class CreateParamsEvidenceDuplicate(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- card_statement: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the card statement showing that the product had already been paid for.
- """
- cash_receipt: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the receipt showing that the product had been paid for in cash.
- """
- check_image: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Image of the front and back of the check that was used to pay for the product.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- original_transaction: NotRequired[str]
- """
- Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one.
- """
-
- class CreateParamsEvidenceFraudulent(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
-
- class CreateParamsEvidenceMerchandiseNotAsDescribed(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- received_at: NotRequired["Literal['']|int"]
- """
- Date when the product was received.
- """
- return_description: NotRequired["Literal['']|str"]
- """
- Description of the cardholder's attempt to return the product.
- """
- return_status: NotRequired[
- "Literal['']|Literal['merchant_rejected', 'successful']"
- ]
- """
- Result of cardholder's attempt to return the product.
- """
- returned_at: NotRequired["Literal['']|int"]
- """
- Date when the product was returned or attempted to be returned.
- """
-
- class CreateParamsEvidenceNoValidAuthorization(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
-
- class CreateParamsEvidenceNotReceived(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- expected_at: NotRequired["Literal['']|int"]
- """
- Date when the cardholder expected to receive the product.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- Description of the merchandise or service that was purchased.
- """
- product_type: NotRequired[
- "Literal['']|Literal['merchandise', 'service']"
- ]
- """
- Whether the product was a merchandise or service.
- """
-
- class CreateParamsEvidenceOther(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- Description of the merchandise or service that was purchased.
- """
- product_type: NotRequired[
- "Literal['']|Literal['merchandise', 'service']"
- ]
- """
- Whether the product was a merchandise or service.
- """
-
- class CreateParamsEvidenceServiceNotAsDescribed(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- canceled_at: NotRequired["Literal['']|int"]
- """
- Date when order was canceled.
- """
- cancellation_reason: NotRequired["Literal['']|str"]
- """
- Reason for canceling the order.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- received_at: NotRequired["Literal['']|int"]
- """
- Date when the product was received.
- """
-
- class CreateParamsTreasury(TypedDict):
- received_debit: str
- """
- The ID of the ReceivedDebit to initiate an Issuings dispute for.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["Dispute.ListParamsCreated|int"]
- """
- Only return Issuing disputes that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["expired", "lost", "submitted", "unsubmitted", "won"]
- ]
- """
- Select Issuing disputes with the given status.
- """
- transaction: NotRequired[str]
- """
- Select the Issuing dispute for the given transaction.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- amount: NotRequired[int]
- """
- The dispute amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- evidence: NotRequired["Dispute.ModifyParamsEvidence"]
- """
- Evidence provided for the dispute.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class ModifyParamsEvidence(TypedDict):
- canceled: NotRequired[
- "Literal['']|Dispute.ModifyParamsEvidenceCanceled"
- ]
- """
- Evidence provided when `reason` is 'canceled'.
- """
- duplicate: NotRequired[
- "Literal['']|Dispute.ModifyParamsEvidenceDuplicate"
- ]
- """
- Evidence provided when `reason` is 'duplicate'.
- """
- fraudulent: NotRequired[
- "Literal['']|Dispute.ModifyParamsEvidenceFraudulent"
- ]
- """
- Evidence provided when `reason` is 'fraudulent'.
- """
- merchandise_not_as_described: NotRequired[
- "Literal['']|Dispute.ModifyParamsEvidenceMerchandiseNotAsDescribed"
- ]
- """
- Evidence provided when `reason` is 'merchandise_not_as_described'.
- """
- no_valid_authorization: NotRequired[
- "Literal['']|Dispute.ModifyParamsEvidenceNoValidAuthorization"
- ]
- """
- Evidence provided when `reason` is 'no_valid_authorization'.
- """
- not_received: NotRequired[
- "Literal['']|Dispute.ModifyParamsEvidenceNotReceived"
- ]
- """
- Evidence provided when `reason` is 'not_received'.
- """
- other: NotRequired["Literal['']|Dispute.ModifyParamsEvidenceOther"]
- """
- Evidence provided when `reason` is 'other'.
- """
- reason: NotRequired[
- Literal[
- "canceled",
- "duplicate",
- "fraudulent",
- "merchandise_not_as_described",
- "no_valid_authorization",
- "not_received",
- "other",
- "service_not_as_described",
- ]
- ]
- """
- The reason for filing the dispute. The evidence should be submitted in the field of the same name.
- """
- service_not_as_described: NotRequired[
- "Literal['']|Dispute.ModifyParamsEvidenceServiceNotAsDescribed"
- ]
- """
- Evidence provided when `reason` is 'service_not_as_described'.
- """
-
- class ModifyParamsEvidenceCanceled(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- canceled_at: NotRequired["Literal['']|int"]
- """
- Date when order was canceled.
- """
- cancellation_policy_provided: NotRequired["Literal['']|bool"]
- """
- Whether the cardholder was provided with a cancellation policy.
- """
- cancellation_reason: NotRequired["Literal['']|str"]
- """
- Reason for canceling the order.
- """
- expected_at: NotRequired["Literal['']|int"]
- """
- Date when the cardholder expected to receive the product.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- Description of the merchandise or service that was purchased.
- """
- product_type: NotRequired[
- "Literal['']|Literal['merchandise', 'service']"
- ]
- """
- Whether the product was a merchandise or service.
- """
- return_status: NotRequired[
- "Literal['']|Literal['merchant_rejected', 'successful']"
- ]
- """
- Result of cardholder's attempt to return the product.
- """
- returned_at: NotRequired["Literal['']|int"]
- """
- Date when the product was returned or attempted to be returned.
- """
-
- class ModifyParamsEvidenceDuplicate(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- card_statement: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the card statement showing that the product had already been paid for.
- """
- cash_receipt: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the receipt showing that the product had been paid for in cash.
- """
- check_image: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Image of the front and back of the check that was used to pay for the product.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- original_transaction: NotRequired[str]
- """
- Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one.
- """
-
- class ModifyParamsEvidenceFraudulent(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
-
- class ModifyParamsEvidenceMerchandiseNotAsDescribed(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- received_at: NotRequired["Literal['']|int"]
- """
- Date when the product was received.
- """
- return_description: NotRequired["Literal['']|str"]
- """
- Description of the cardholder's attempt to return the product.
- """
- return_status: NotRequired[
- "Literal['']|Literal['merchant_rejected', 'successful']"
- ]
- """
- Result of cardholder's attempt to return the product.
- """
- returned_at: NotRequired["Literal['']|int"]
- """
- Date when the product was returned or attempted to be returned.
- """
-
- class ModifyParamsEvidenceNoValidAuthorization(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
-
- class ModifyParamsEvidenceNotReceived(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- expected_at: NotRequired["Literal['']|int"]
- """
- Date when the cardholder expected to receive the product.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- Description of the merchandise or service that was purchased.
- """
- product_type: NotRequired[
- "Literal['']|Literal['merchandise', 'service']"
- ]
- """
- Whether the product was a merchandise or service.
- """
-
- class ModifyParamsEvidenceOther(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- Description of the merchandise or service that was purchased.
- """
- product_type: NotRequired[
- "Literal['']|Literal['merchandise', 'service']"
- ]
- """
- Whether the product was a merchandise or service.
- """
-
- class ModifyParamsEvidenceServiceNotAsDescribed(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- canceled_at: NotRequired["Literal['']|int"]
- """
- Date when order was canceled.
- """
- cancellation_reason: NotRequired["Literal['']|str"]
- """
- Reason for canceling the order.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- received_at: NotRequired["Literal['']|int"]
- """
- Date when the product was received.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SubmitParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
amount: int
"""
Disputed amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). Usually the amount of the `transaction`, but can differ (usually because of currency fluctuation).
@@ -943,7 +335,7 @@ class SubmitParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["Dispute.CreateParams"]) -> "Dispute":
+ def create(cls, **params: Unpack["DisputeCreateParams"]) -> "Dispute":
"""
Creates an Issuing Dispute object. Individual pieces of evidence within the evidence object are optional at this point. Stripe only validates that required evidence is present during submission. Refer to [Dispute reasons and evidence](https://docs.stripe.com/docs/issuing/purchases/disputes#dispute-reasons-and-evidence) for more details about evidence requirements.
"""
@@ -958,7 +350,7 @@ def create(cls, **params: Unpack["Dispute.CreateParams"]) -> "Dispute":
@classmethod
async def create_async(
- cls, **params: Unpack["Dispute.CreateParams"]
+ cls, **params: Unpack["DisputeCreateParams"]
) -> "Dispute":
"""
Creates an Issuing Dispute object. Individual pieces of evidence within the evidence object are optional at this point. Stripe only validates that required evidence is present during submission. Refer to [Dispute reasons and evidence](https://docs.stripe.com/docs/issuing/purchases/disputes#dispute-reasons-and-evidence) for more details about evidence requirements.
@@ -974,7 +366,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["Dispute.ListParams"]
+ cls, **params: Unpack["DisputeListParams"]
) -> ListObject["Dispute"]:
"""
Returns a list of Issuing Dispute objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -994,7 +386,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Dispute.ListParams"]
+ cls, **params: Unpack["DisputeListParams"]
) -> ListObject["Dispute"]:
"""
Returns a list of Issuing Dispute objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -1014,7 +406,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Dispute.ModifyParams"]
+ cls, id: str, **params: Unpack["DisputeModifyParams"]
) -> "Dispute":
"""
Updates the specified Issuing Dispute object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. Properties on the evidence object can be unset by passing in an empty string.
@@ -1031,7 +423,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Dispute.ModifyParams"]
+ cls, id: str, **params: Unpack["DisputeModifyParams"]
) -> "Dispute":
"""
Updates the specified Issuing Dispute object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. Properties on the evidence object can be unset by passing in an empty string.
@@ -1048,7 +440,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Dispute.RetrieveParams"]
+ cls, id: str, **params: Unpack["DisputeRetrieveParams"]
) -> "Dispute":
"""
Retrieves an Issuing Dispute object.
@@ -1059,7 +451,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Dispute.RetrieveParams"]
+ cls, id: str, **params: Unpack["DisputeRetrieveParams"]
) -> "Dispute":
"""
Retrieves an Issuing Dispute object.
@@ -1070,7 +462,7 @@ async def retrieve_async(
@classmethod
def _cls_submit(
- cls, dispute: str, **params: Unpack["Dispute.SubmitParams"]
+ 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).
@@ -1089,7 +481,7 @@ def _cls_submit(
@overload
@staticmethod
def submit(
- dispute: str, **params: Unpack["Dispute.SubmitParams"]
+ 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).
@@ -1097,7 +489,7 @@ def submit(
...
@overload
- def submit(self, **params: Unpack["Dispute.SubmitParams"]) -> "Dispute":
+ def submit(self, **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).
"""
@@ -1105,7 +497,7 @@ def submit(self, **params: Unpack["Dispute.SubmitParams"]) -> "Dispute":
@class_method_variant("_cls_submit")
def submit( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Dispute.SubmitParams"]
+ self, **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).
@@ -1123,7 +515,7 @@ def submit( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_submit_async(
- cls, dispute: str, **params: Unpack["Dispute.SubmitParams"]
+ 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).
@@ -1142,7 +534,7 @@ async def _cls_submit_async(
@overload
@staticmethod
async def submit_async(
- dispute: str, **params: Unpack["Dispute.SubmitParams"]
+ 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).
@@ -1151,7 +543,7 @@ async def submit_async(
@overload
async def submit_async(
- self, **params: Unpack["Dispute.SubmitParams"]
+ self, **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).
@@ -1160,7 +552,7 @@ async def submit_async(
@class_method_variant("_cls_submit_async")
async def submit_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Dispute.SubmitParams"]
+ self, **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 e48ceecbc..3d9ae040d 100644
--- a/stripe/issuing/_dispute_service.py
+++ b/stripe/issuing/_dispute_service.py
@@ -5,632 +5,29 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.issuing._dispute import Dispute
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.issuing._dispute_create_params import (
+ DisputeCreateParams,
+ )
+ from stripe.params.issuing._dispute_list_params import DisputeListParams
+ from stripe.params.issuing._dispute_retrieve_params import (
+ DisputeRetrieveParams,
+ )
+ from stripe.params.issuing._dispute_submit_params import (
+ DisputeSubmitParams,
+ )
+ from stripe.params.issuing._dispute_update_params import (
+ DisputeUpdateParams,
+ )
class DisputeService(StripeService):
- class CreateParams(TypedDict):
- amount: NotRequired[int]
- """
- The dispute amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). If not set, defaults to the full transaction amount.
- """
- evidence: NotRequired["DisputeService.CreateParamsEvidence"]
- """
- Evidence provided for the dispute.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- transaction: NotRequired[str]
- """
- The ID of the issuing transaction to create a dispute for. For transaction on Treasury FinancialAccounts, use `treasury.received_debit`.
- """
- treasury: NotRequired["DisputeService.CreateParamsTreasury"]
- """
- Params for disputes related to Treasury FinancialAccounts
- """
-
- class CreateParamsEvidence(TypedDict):
- canceled: NotRequired[
- "Literal['']|DisputeService.CreateParamsEvidenceCanceled"
- ]
- """
- Evidence provided when `reason` is 'canceled'.
- """
- duplicate: NotRequired[
- "Literal['']|DisputeService.CreateParamsEvidenceDuplicate"
- ]
- """
- Evidence provided when `reason` is 'duplicate'.
- """
- fraudulent: NotRequired[
- "Literal['']|DisputeService.CreateParamsEvidenceFraudulent"
- ]
- """
- Evidence provided when `reason` is 'fraudulent'.
- """
- merchandise_not_as_described: NotRequired[
- "Literal['']|DisputeService.CreateParamsEvidenceMerchandiseNotAsDescribed"
- ]
- """
- Evidence provided when `reason` is 'merchandise_not_as_described'.
- """
- no_valid_authorization: NotRequired[
- "Literal['']|DisputeService.CreateParamsEvidenceNoValidAuthorization"
- ]
- """
- Evidence provided when `reason` is 'no_valid_authorization'.
- """
- not_received: NotRequired[
- "Literal['']|DisputeService.CreateParamsEvidenceNotReceived"
- ]
- """
- Evidence provided when `reason` is 'not_received'.
- """
- other: NotRequired[
- "Literal['']|DisputeService.CreateParamsEvidenceOther"
- ]
- """
- Evidence provided when `reason` is 'other'.
- """
- reason: NotRequired[
- Literal[
- "canceled",
- "duplicate",
- "fraudulent",
- "merchandise_not_as_described",
- "no_valid_authorization",
- "not_received",
- "other",
- "service_not_as_described",
- ]
- ]
- """
- The reason for filing the dispute. The evidence should be submitted in the field of the same name.
- """
- service_not_as_described: NotRequired[
- "Literal['']|DisputeService.CreateParamsEvidenceServiceNotAsDescribed"
- ]
- """
- Evidence provided when `reason` is 'service_not_as_described'.
- """
-
- class CreateParamsEvidenceCanceled(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- canceled_at: NotRequired["Literal['']|int"]
- """
- Date when order was canceled.
- """
- cancellation_policy_provided: NotRequired["Literal['']|bool"]
- """
- Whether the cardholder was provided with a cancellation policy.
- """
- cancellation_reason: NotRequired["Literal['']|str"]
- """
- Reason for canceling the order.
- """
- expected_at: NotRequired["Literal['']|int"]
- """
- Date when the cardholder expected to receive the product.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- Description of the merchandise or service that was purchased.
- """
- product_type: NotRequired[
- "Literal['']|Literal['merchandise', 'service']"
- ]
- """
- Whether the product was a merchandise or service.
- """
- return_status: NotRequired[
- "Literal['']|Literal['merchant_rejected', 'successful']"
- ]
- """
- Result of cardholder's attempt to return the product.
- """
- returned_at: NotRequired["Literal['']|int"]
- """
- Date when the product was returned or attempted to be returned.
- """
-
- class CreateParamsEvidenceDuplicate(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- card_statement: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the card statement showing that the product had already been paid for.
- """
- cash_receipt: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the receipt showing that the product had been paid for in cash.
- """
- check_image: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Image of the front and back of the check that was used to pay for the product.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- original_transaction: NotRequired[str]
- """
- Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one.
- """
-
- class CreateParamsEvidenceFraudulent(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
-
- class CreateParamsEvidenceMerchandiseNotAsDescribed(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- received_at: NotRequired["Literal['']|int"]
- """
- Date when the product was received.
- """
- return_description: NotRequired["Literal['']|str"]
- """
- Description of the cardholder's attempt to return the product.
- """
- return_status: NotRequired[
- "Literal['']|Literal['merchant_rejected', 'successful']"
- ]
- """
- Result of cardholder's attempt to return the product.
- """
- returned_at: NotRequired["Literal['']|int"]
- """
- Date when the product was returned or attempted to be returned.
- """
-
- class CreateParamsEvidenceNoValidAuthorization(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
-
- class CreateParamsEvidenceNotReceived(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- expected_at: NotRequired["Literal['']|int"]
- """
- Date when the cardholder expected to receive the product.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- Description of the merchandise or service that was purchased.
- """
- product_type: NotRequired[
- "Literal['']|Literal['merchandise', 'service']"
- ]
- """
- Whether the product was a merchandise or service.
- """
-
- class CreateParamsEvidenceOther(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- Description of the merchandise or service that was purchased.
- """
- product_type: NotRequired[
- "Literal['']|Literal['merchandise', 'service']"
- ]
- """
- Whether the product was a merchandise or service.
- """
-
- class CreateParamsEvidenceServiceNotAsDescribed(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- canceled_at: NotRequired["Literal['']|int"]
- """
- Date when order was canceled.
- """
- cancellation_reason: NotRequired["Literal['']|str"]
- """
- Reason for canceling the order.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- received_at: NotRequired["Literal['']|int"]
- """
- Date when the product was received.
- """
-
- class CreateParamsTreasury(TypedDict):
- received_debit: str
- """
- The ID of the ReceivedDebit to initiate an Issuings dispute for.
- """
-
- class ListParams(TypedDict):
- created: NotRequired["DisputeService.ListParamsCreated|int"]
- """
- Only return Issuing disputes that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["expired", "lost", "submitted", "unsubmitted", "won"]
- ]
- """
- Select Issuing disputes with the given status.
- """
- transaction: NotRequired[str]
- """
- Select the Issuing dispute for the given transaction.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SubmitParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class UpdateParams(TypedDict):
- amount: NotRequired[int]
- """
- The dispute amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- evidence: NotRequired["DisputeService.UpdateParamsEvidence"]
- """
- Evidence provided for the dispute.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class UpdateParamsEvidence(TypedDict):
- canceled: NotRequired[
- "Literal['']|DisputeService.UpdateParamsEvidenceCanceled"
- ]
- """
- Evidence provided when `reason` is 'canceled'.
- """
- duplicate: NotRequired[
- "Literal['']|DisputeService.UpdateParamsEvidenceDuplicate"
- ]
- """
- Evidence provided when `reason` is 'duplicate'.
- """
- fraudulent: NotRequired[
- "Literal['']|DisputeService.UpdateParamsEvidenceFraudulent"
- ]
- """
- Evidence provided when `reason` is 'fraudulent'.
- """
- merchandise_not_as_described: NotRequired[
- "Literal['']|DisputeService.UpdateParamsEvidenceMerchandiseNotAsDescribed"
- ]
- """
- Evidence provided when `reason` is 'merchandise_not_as_described'.
- """
- no_valid_authorization: NotRequired[
- "Literal['']|DisputeService.UpdateParamsEvidenceNoValidAuthorization"
- ]
- """
- Evidence provided when `reason` is 'no_valid_authorization'.
- """
- not_received: NotRequired[
- "Literal['']|DisputeService.UpdateParamsEvidenceNotReceived"
- ]
- """
- Evidence provided when `reason` is 'not_received'.
- """
- other: NotRequired[
- "Literal['']|DisputeService.UpdateParamsEvidenceOther"
- ]
- """
- Evidence provided when `reason` is 'other'.
- """
- reason: NotRequired[
- Literal[
- "canceled",
- "duplicate",
- "fraudulent",
- "merchandise_not_as_described",
- "no_valid_authorization",
- "not_received",
- "other",
- "service_not_as_described",
- ]
- ]
- """
- The reason for filing the dispute. The evidence should be submitted in the field of the same name.
- """
- service_not_as_described: NotRequired[
- "Literal['']|DisputeService.UpdateParamsEvidenceServiceNotAsDescribed"
- ]
- """
- Evidence provided when `reason` is 'service_not_as_described'.
- """
-
- class UpdateParamsEvidenceCanceled(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- canceled_at: NotRequired["Literal['']|int"]
- """
- Date when order was canceled.
- """
- cancellation_policy_provided: NotRequired["Literal['']|bool"]
- """
- Whether the cardholder was provided with a cancellation policy.
- """
- cancellation_reason: NotRequired["Literal['']|str"]
- """
- Reason for canceling the order.
- """
- expected_at: NotRequired["Literal['']|int"]
- """
- Date when the cardholder expected to receive the product.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- Description of the merchandise or service that was purchased.
- """
- product_type: NotRequired[
- "Literal['']|Literal['merchandise', 'service']"
- ]
- """
- Whether the product was a merchandise or service.
- """
- return_status: NotRequired[
- "Literal['']|Literal['merchant_rejected', 'successful']"
- ]
- """
- Result of cardholder's attempt to return the product.
- """
- returned_at: NotRequired["Literal['']|int"]
- """
- Date when the product was returned or attempted to be returned.
- """
-
- class UpdateParamsEvidenceDuplicate(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- card_statement: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the card statement showing that the product had already been paid for.
- """
- cash_receipt: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the receipt showing that the product had been paid for in cash.
- """
- check_image: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Image of the front and back of the check that was used to pay for the product.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- original_transaction: NotRequired[str]
- """
- Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one.
- """
-
- class UpdateParamsEvidenceFraudulent(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
-
- class UpdateParamsEvidenceMerchandiseNotAsDescribed(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- received_at: NotRequired["Literal['']|int"]
- """
- Date when the product was received.
- """
- return_description: NotRequired["Literal['']|str"]
- """
- Description of the cardholder's attempt to return the product.
- """
- return_status: NotRequired[
- "Literal['']|Literal['merchant_rejected', 'successful']"
- ]
- """
- Result of cardholder's attempt to return the product.
- """
- returned_at: NotRequired["Literal['']|int"]
- """
- Date when the product was returned or attempted to be returned.
- """
-
- class UpdateParamsEvidenceNoValidAuthorization(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
-
- class UpdateParamsEvidenceNotReceived(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- expected_at: NotRequired["Literal['']|int"]
- """
- Date when the cardholder expected to receive the product.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- Description of the merchandise or service that was purchased.
- """
- product_type: NotRequired[
- "Literal['']|Literal['merchandise', 'service']"
- ]
- """
- Whether the product was a merchandise or service.
- """
-
- class UpdateParamsEvidenceOther(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- product_description: NotRequired["Literal['']|str"]
- """
- Description of the merchandise or service that was purchased.
- """
- product_type: NotRequired[
- "Literal['']|Literal['merchandise', 'service']"
- ]
- """
- Whether the product was a merchandise or service.
- """
-
- class UpdateParamsEvidenceServiceNotAsDescribed(TypedDict):
- additional_documentation: NotRequired["Literal['']|str"]
- """
- (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
- """
- canceled_at: NotRequired["Literal['']|int"]
- """
- Date when order was canceled.
- """
- cancellation_reason: NotRequired["Literal['']|str"]
- """
- Reason for canceling the order.
- """
- explanation: NotRequired["Literal['']|str"]
- """
- Explanation of why the cardholder is disputing this transaction.
- """
- received_at: NotRequired["Literal['']|int"]
- """
- Date when the product was received.
- """
-
def list(
self,
- params: Optional["DisputeService.ListParams"] = None,
+ params: Optional["DisputeListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Dispute]:
"""
@@ -649,7 +46,7 @@ def list(
async def list_async(
self,
- params: Optional["DisputeService.ListParams"] = None,
+ params: Optional["DisputeListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Dispute]:
"""
@@ -668,7 +65,7 @@ async def list_async(
def create(
self,
- params: Optional["DisputeService.CreateParams"] = None,
+ params: Optional["DisputeCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Dispute:
"""
@@ -687,7 +84,7 @@ def create(
async def create_async(
self,
- params: Optional["DisputeService.CreateParams"] = None,
+ params: Optional["DisputeCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Dispute:
"""
@@ -707,7 +104,7 @@ async def create_async(
def retrieve(
self,
dispute: str,
- params: Optional["DisputeService.RetrieveParams"] = None,
+ params: Optional["DisputeRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Dispute:
"""
@@ -729,7 +126,7 @@ def retrieve(
async def retrieve_async(
self,
dispute: str,
- params: Optional["DisputeService.RetrieveParams"] = None,
+ params: Optional["DisputeRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Dispute:
"""
@@ -751,7 +148,7 @@ async def retrieve_async(
def update(
self,
dispute: str,
- params: Optional["DisputeService.UpdateParams"] = None,
+ params: Optional["DisputeUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Dispute:
"""
@@ -773,7 +170,7 @@ def update(
async def update_async(
self,
dispute: str,
- params: Optional["DisputeService.UpdateParams"] = None,
+ params: Optional["DisputeUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Dispute:
"""
@@ -795,7 +192,7 @@ async def update_async(
def submit(
self,
dispute: str,
- params: Optional["DisputeService.SubmitParams"] = None,
+ params: Optional["DisputeSubmitParams"] = None,
options: Optional[RequestOptions] = None,
) -> Dispute:
"""
@@ -817,7 +214,7 @@ def submit(
async def submit_async(
self,
dispute: str,
- params: Optional["DisputeService.SubmitParams"] = None,
+ params: Optional["DisputeSubmitParams"] = None,
options: Optional[RequestOptions] = None,
) -> Dispute:
"""
diff --git a/stripe/issuing/_personalization_design.py b/stripe/issuing/_personalization_design.py
index c8520e8ee..fd65ab0ac 100644
--- a/stripe/issuing/_personalization_design.py
+++ b/stripe/issuing/_personalization_design.py
@@ -4,24 +4,37 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._test_helpers import APIResourceTestHelpers
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- Type,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Type, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._file import File
from stripe.issuing._physical_bundle import PhysicalBundle
+ from stripe.params.issuing._personalization_design_activate_params import (
+ PersonalizationDesignActivateParams,
+ )
+ from stripe.params.issuing._personalization_design_create_params import (
+ PersonalizationDesignCreateParams,
+ )
+ from stripe.params.issuing._personalization_design_deactivate_params import (
+ PersonalizationDesignDeactivateParams,
+ )
+ from stripe.params.issuing._personalization_design_list_params import (
+ PersonalizationDesignListParams,
+ )
+ from stripe.params.issuing._personalization_design_modify_params import (
+ PersonalizationDesignModifyParams,
+ )
+ from stripe.params.issuing._personalization_design_reject_params import (
+ PersonalizationDesignRejectParams,
+ )
+ from stripe.params.issuing._personalization_design_retrieve_params import (
+ PersonalizationDesignRetrieveParams,
+ )
class PersonalizationDesign(
@@ -100,243 +113,6 @@ class RejectionReasons(StripeObject):
The reason(s) the carrier text was rejected.
"""
- class ActivateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(RequestOptions):
- card_logo: NotRequired[str]
- """
- The file for the card logo, for use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`.
- """
- carrier_text: NotRequired[
- "PersonalizationDesign.CreateParamsCarrierText"
- ]
- """
- Hash containing carrier text, for use with physical bundles that support carrier text.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- lookup_key: NotRequired[str]
- """
- A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- Friendly display name.
- """
- physical_bundle: str
- """
- The physical bundle object belonging to this personalization design.
- """
- preferences: NotRequired[
- "PersonalizationDesign.CreateParamsPreferences"
- ]
- """
- Information on whether this personalization design is used to create cards when one is not specified.
- """
- transfer_lookup_key: NotRequired[bool]
- """
- If set to true, will atomically remove the lookup key from the existing personalization design, and assign it to this personalization design.
- """
-
- class CreateParamsCarrierText(TypedDict):
- footer_body: NotRequired["Literal['']|str"]
- """
- The footer body text of the carrier letter.
- """
- footer_title: NotRequired["Literal['']|str"]
- """
- The footer title text of the carrier letter.
- """
- header_body: NotRequired["Literal['']|str"]
- """
- The header body text of the carrier letter.
- """
- header_title: NotRequired["Literal['']|str"]
- """
- The header title text of the carrier letter.
- """
-
- class CreateParamsPreferences(TypedDict):
- is_default: bool
- """
- Whether we use this personalization design to create cards when one isn't specified. A connected account uses the Connect platform's default design if no personalization design is set as the default design.
- """
-
- class DeactivateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- lookup_keys: NotRequired[List[str]]
- """
- Only return personalization designs with the given lookup keys.
- """
- preferences: NotRequired["PersonalizationDesign.ListParamsPreferences"]
- """
- Only return personalization designs with the given preferences.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["active", "inactive", "rejected", "review"]
- ]
- """
- Only return personalization designs with the given status.
- """
-
- class ListParamsPreferences(TypedDict):
- is_default: NotRequired[bool]
- """
- Only return the personalization design that's set as the default. A connected account uses the Connect platform's default design if no personalization design is set as the default.
- """
- is_platform_default: NotRequired[bool]
- """
- Only return the personalization design that is set as the Connect platform's default. This parameter is only applicable to connected accounts.
- """
-
- class ModifyParams(RequestOptions):
- card_logo: NotRequired["Literal['']|str"]
- """
- The file for the card logo, for use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`.
- """
- carrier_text: NotRequired[
- "Literal['']|PersonalizationDesign.ModifyParamsCarrierText"
- ]
- """
- Hash containing carrier text, for use with physical bundles that support carrier text.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- lookup_key: NotRequired["Literal['']|str"]
- """
- A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired["Literal['']|str"]
- """
- Friendly display name. Providing an empty string will set the field to null.
- """
- physical_bundle: NotRequired[str]
- """
- The physical bundle object belonging to this personalization design.
- """
- preferences: NotRequired[
- "PersonalizationDesign.ModifyParamsPreferences"
- ]
- """
- Information on whether this personalization design is used to create cards when one is not specified.
- """
- transfer_lookup_key: NotRequired[bool]
- """
- If set to true, will atomically remove the lookup key from the existing personalization design, and assign it to this personalization design.
- """
-
- class ModifyParamsCarrierText(TypedDict):
- footer_body: NotRequired["Literal['']|str"]
- """
- The footer body text of the carrier letter.
- """
- footer_title: NotRequired["Literal['']|str"]
- """
- The footer title text of the carrier letter.
- """
- header_body: NotRequired["Literal['']|str"]
- """
- The header body text of the carrier letter.
- """
- header_title: NotRequired["Literal['']|str"]
- """
- The header title text of the carrier letter.
- """
-
- class ModifyParamsPreferences(TypedDict):
- is_default: bool
- """
- Whether we use this personalization design to create cards when one isn't specified. A connected account uses the Connect platform's default design if no personalization design is set as the default design.
- """
-
- class RejectParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- rejection_reasons: "PersonalizationDesign.RejectParamsRejectionReasons"
- """
- The reason(s) the personalization design was rejected.
- """
-
- class RejectParamsRejectionReasons(TypedDict):
- card_logo: NotRequired[
- List[
- Literal[
- "geographic_location",
- "inappropriate",
- "network_name",
- "non_binary_image",
- "non_fiat_currency",
- "other",
- "other_entity",
- "promotional_material",
- ]
- ]
- ]
- """
- The reason(s) the card logo was rejected.
- """
- carrier_text: NotRequired[
- List[
- Literal[
- "geographic_location",
- "inappropriate",
- "network_name",
- "non_fiat_currency",
- "other",
- "other_entity",
- "promotional_material",
- ]
- ]
- ]
- """
- The reason(s) the carrier text was rejected.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
card_logo: Optional[ExpandableField["File"]]
"""
The file for the card logo to use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`.
@@ -386,7 +162,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["PersonalizationDesign.CreateParams"]
+ cls, **params: Unpack["PersonalizationDesignCreateParams"]
) -> "PersonalizationDesign":
"""
Creates a personalization design object.
@@ -402,7 +178,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["PersonalizationDesign.CreateParams"]
+ cls, **params: Unpack["PersonalizationDesignCreateParams"]
) -> "PersonalizationDesign":
"""
Creates a personalization design object.
@@ -418,7 +194,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["PersonalizationDesign.ListParams"]
+ cls, **params: Unpack["PersonalizationDesignListParams"]
) -> ListObject["PersonalizationDesign"]:
"""
Returns a list of personalization design objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -438,7 +214,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["PersonalizationDesign.ListParams"]
+ cls, **params: Unpack["PersonalizationDesignListParams"]
) -> ListObject["PersonalizationDesign"]:
"""
Returns a list of personalization design objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -458,7 +234,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["PersonalizationDesign.ModifyParams"]
+ cls, id: str, **params: Unpack["PersonalizationDesignModifyParams"]
) -> "PersonalizationDesign":
"""
Updates a card personalization object.
@@ -475,7 +251,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["PersonalizationDesign.ModifyParams"]
+ cls, id: str, **params: Unpack["PersonalizationDesignModifyParams"]
) -> "PersonalizationDesign":
"""
Updates a card personalization object.
@@ -492,7 +268,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["PersonalizationDesign.RetrieveParams"]
+ cls, id: str, **params: Unpack["PersonalizationDesignRetrieveParams"]
) -> "PersonalizationDesign":
"""
Retrieves a personalization design object.
@@ -503,7 +279,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["PersonalizationDesign.RetrieveParams"]
+ cls, id: str, **params: Unpack["PersonalizationDesignRetrieveParams"]
) -> "PersonalizationDesign":
"""
Retrieves a personalization design object.
@@ -519,7 +295,7 @@ class TestHelpers(APIResourceTestHelpers["PersonalizationDesign"]):
def _cls_activate(
cls,
personalization_design: str,
- **params: Unpack["PersonalizationDesign.ActivateParams"],
+ **params: Unpack["PersonalizationDesignActivateParams"],
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to active.
@@ -541,7 +317,7 @@ def _cls_activate(
@staticmethod
def activate(
personalization_design: str,
- **params: Unpack["PersonalizationDesign.ActivateParams"],
+ **params: Unpack["PersonalizationDesignActivateParams"],
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to active.
@@ -550,7 +326,7 @@ def activate(
@overload
def activate(
- self, **params: Unpack["PersonalizationDesign.ActivateParams"]
+ self, **params: Unpack["PersonalizationDesignActivateParams"]
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to active.
@@ -559,7 +335,7 @@ def activate(
@class_method_variant("_cls_activate")
def activate( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PersonalizationDesign.ActivateParams"]
+ self, **params: Unpack["PersonalizationDesignActivateParams"]
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to active.
@@ -581,7 +357,7 @@ def activate( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_activate_async(
cls,
personalization_design: str,
- **params: Unpack["PersonalizationDesign.ActivateParams"],
+ **params: Unpack["PersonalizationDesignActivateParams"],
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to active.
@@ -603,7 +379,7 @@ async def _cls_activate_async(
@staticmethod
async def activate_async(
personalization_design: str,
- **params: Unpack["PersonalizationDesign.ActivateParams"],
+ **params: Unpack["PersonalizationDesignActivateParams"],
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to active.
@@ -612,7 +388,7 @@ async def activate_async(
@overload
async def activate_async(
- self, **params: Unpack["PersonalizationDesign.ActivateParams"]
+ self, **params: Unpack["PersonalizationDesignActivateParams"]
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to active.
@@ -621,7 +397,7 @@ async def activate_async(
@class_method_variant("_cls_activate_async")
async def activate_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PersonalizationDesign.ActivateParams"]
+ self, **params: Unpack["PersonalizationDesignActivateParams"]
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to active.
@@ -643,7 +419,7 @@ async def activate_async( # pyright: ignore[reportGeneralTypeIssues]
def _cls_deactivate(
cls,
personalization_design: str,
- **params: Unpack["PersonalizationDesign.DeactivateParams"],
+ **params: Unpack["PersonalizationDesignDeactivateParams"],
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to inactive.
@@ -665,7 +441,7 @@ def _cls_deactivate(
@staticmethod
def deactivate(
personalization_design: str,
- **params: Unpack["PersonalizationDesign.DeactivateParams"],
+ **params: Unpack["PersonalizationDesignDeactivateParams"],
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to inactive.
@@ -674,7 +450,7 @@ def deactivate(
@overload
def deactivate(
- self, **params: Unpack["PersonalizationDesign.DeactivateParams"]
+ self, **params: Unpack["PersonalizationDesignDeactivateParams"]
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to inactive.
@@ -683,7 +459,7 @@ def deactivate(
@class_method_variant("_cls_deactivate")
def deactivate( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PersonalizationDesign.DeactivateParams"]
+ self, **params: Unpack["PersonalizationDesignDeactivateParams"]
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to inactive.
@@ -705,7 +481,7 @@ def deactivate( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_deactivate_async(
cls,
personalization_design: str,
- **params: Unpack["PersonalizationDesign.DeactivateParams"],
+ **params: Unpack["PersonalizationDesignDeactivateParams"],
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to inactive.
@@ -727,7 +503,7 @@ async def _cls_deactivate_async(
@staticmethod
async def deactivate_async(
personalization_design: str,
- **params: Unpack["PersonalizationDesign.DeactivateParams"],
+ **params: Unpack["PersonalizationDesignDeactivateParams"],
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to inactive.
@@ -736,7 +512,7 @@ async def deactivate_async(
@overload
async def deactivate_async(
- self, **params: Unpack["PersonalizationDesign.DeactivateParams"]
+ self, **params: Unpack["PersonalizationDesignDeactivateParams"]
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to inactive.
@@ -745,7 +521,7 @@ async def deactivate_async(
@class_method_variant("_cls_deactivate_async")
async def deactivate_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PersonalizationDesign.DeactivateParams"]
+ self, **params: Unpack["PersonalizationDesignDeactivateParams"]
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to inactive.
@@ -767,7 +543,7 @@ async def deactivate_async( # pyright: ignore[reportGeneralTypeIssues]
def _cls_reject(
cls,
personalization_design: str,
- **params: Unpack["PersonalizationDesign.RejectParams"],
+ **params: Unpack["PersonalizationDesignRejectParams"],
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to rejected.
@@ -789,7 +565,7 @@ def _cls_reject(
@staticmethod
def reject(
personalization_design: str,
- **params: Unpack["PersonalizationDesign.RejectParams"],
+ **params: Unpack["PersonalizationDesignRejectParams"],
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to rejected.
@@ -798,7 +574,7 @@ def reject(
@overload
def reject(
- self, **params: Unpack["PersonalizationDesign.RejectParams"]
+ self, **params: Unpack["PersonalizationDesignRejectParams"]
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to rejected.
@@ -807,7 +583,7 @@ def reject(
@class_method_variant("_cls_reject")
def reject( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PersonalizationDesign.RejectParams"]
+ self, **params: Unpack["PersonalizationDesignRejectParams"]
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to rejected.
@@ -829,7 +605,7 @@ def reject( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_reject_async(
cls,
personalization_design: str,
- **params: Unpack["PersonalizationDesign.RejectParams"],
+ **params: Unpack["PersonalizationDesignRejectParams"],
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to rejected.
@@ -851,7 +627,7 @@ async def _cls_reject_async(
@staticmethod
async def reject_async(
personalization_design: str,
- **params: Unpack["PersonalizationDesign.RejectParams"],
+ **params: Unpack["PersonalizationDesignRejectParams"],
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to rejected.
@@ -860,7 +636,7 @@ async def reject_async(
@overload
async def reject_async(
- self, **params: Unpack["PersonalizationDesign.RejectParams"]
+ self, **params: Unpack["PersonalizationDesignRejectParams"]
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to rejected.
@@ -869,7 +645,7 @@ async def reject_async(
@class_method_variant("_cls_reject_async")
async def reject_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["PersonalizationDesign.RejectParams"]
+ self, **params: Unpack["PersonalizationDesignRejectParams"]
) -> "PersonalizationDesign":
"""
Updates the status of the specified testmode personalization design object to rejected.
diff --git a/stripe/issuing/_personalization_design_service.py b/stripe/issuing/_personalization_design_service.py
index cd8b2595f..090b9cbc3 100644
--- a/stripe/issuing/_personalization_design_service.py
+++ b/stripe/issuing/_personalization_design_service.py
@@ -5,196 +5,28 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.issuing._personalization_design import PersonalizationDesign
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.issuing._personalization_design_create_params import (
+ PersonalizationDesignCreateParams,
+ )
+ from stripe.params.issuing._personalization_design_list_params import (
+ PersonalizationDesignListParams,
+ )
+ from stripe.params.issuing._personalization_design_retrieve_params import (
+ PersonalizationDesignRetrieveParams,
+ )
+ from stripe.params.issuing._personalization_design_update_params import (
+ PersonalizationDesignUpdateParams,
+ )
class PersonalizationDesignService(StripeService):
- class CreateParams(TypedDict):
- card_logo: NotRequired[str]
- """
- The file for the card logo, for use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`.
- """
- carrier_text: NotRequired[
- "PersonalizationDesignService.CreateParamsCarrierText"
- ]
- """
- Hash containing carrier text, for use with physical bundles that support carrier text.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- lookup_key: NotRequired[str]
- """
- A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- Friendly display name.
- """
- physical_bundle: str
- """
- The physical bundle object belonging to this personalization design.
- """
- preferences: NotRequired[
- "PersonalizationDesignService.CreateParamsPreferences"
- ]
- """
- Information on whether this personalization design is used to create cards when one is not specified.
- """
- transfer_lookup_key: NotRequired[bool]
- """
- If set to true, will atomically remove the lookup key from the existing personalization design, and assign it to this personalization design.
- """
-
- class CreateParamsCarrierText(TypedDict):
- footer_body: NotRequired["Literal['']|str"]
- """
- The footer body text of the carrier letter.
- """
- footer_title: NotRequired["Literal['']|str"]
- """
- The footer title text of the carrier letter.
- """
- header_body: NotRequired["Literal['']|str"]
- """
- The header body text of the carrier letter.
- """
- header_title: NotRequired["Literal['']|str"]
- """
- The header title text of the carrier letter.
- """
-
- class CreateParamsPreferences(TypedDict):
- is_default: bool
- """
- Whether we use this personalization design to create cards when one isn't specified. A connected account uses the Connect platform's default design if no personalization design is set as the default design.
- """
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- lookup_keys: NotRequired[List[str]]
- """
- Only return personalization designs with the given lookup keys.
- """
- preferences: NotRequired[
- "PersonalizationDesignService.ListParamsPreferences"
- ]
- """
- Only return personalization designs with the given preferences.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["active", "inactive", "rejected", "review"]
- ]
- """
- Only return personalization designs with the given status.
- """
-
- class ListParamsPreferences(TypedDict):
- is_default: NotRequired[bool]
- """
- Only return the personalization design that's set as the default. A connected account uses the Connect platform's default design if no personalization design is set as the default.
- """
- is_platform_default: NotRequired[bool]
- """
- Only return the personalization design that is set as the Connect platform's default. This parameter is only applicable to connected accounts.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- card_logo: NotRequired["Literal['']|str"]
- """
- The file for the card logo, for use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`.
- """
- carrier_text: NotRequired[
- "Literal['']|PersonalizationDesignService.UpdateParamsCarrierText"
- ]
- """
- Hash containing carrier text, for use with physical bundles that support carrier text.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- lookup_key: NotRequired["Literal['']|str"]
- """
- A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired["Literal['']|str"]
- """
- Friendly display name. Providing an empty string will set the field to null.
- """
- physical_bundle: NotRequired[str]
- """
- The physical bundle object belonging to this personalization design.
- """
- preferences: NotRequired[
- "PersonalizationDesignService.UpdateParamsPreferences"
- ]
- """
- Information on whether this personalization design is used to create cards when one is not specified.
- """
- transfer_lookup_key: NotRequired[bool]
- """
- If set to true, will atomically remove the lookup key from the existing personalization design, and assign it to this personalization design.
- """
-
- class UpdateParamsCarrierText(TypedDict):
- footer_body: NotRequired["Literal['']|str"]
- """
- The footer body text of the carrier letter.
- """
- footer_title: NotRequired["Literal['']|str"]
- """
- The footer title text of the carrier letter.
- """
- header_body: NotRequired["Literal['']|str"]
- """
- The header body text of the carrier letter.
- """
- header_title: NotRequired["Literal['']|str"]
- """
- The header title text of the carrier letter.
- """
-
- class UpdateParamsPreferences(TypedDict):
- is_default: bool
- """
- Whether we use this personalization design to create cards when one isn't specified. A connected account uses the Connect platform's default design if no personalization design is set as the default design.
- """
-
def list(
self,
- params: Optional["PersonalizationDesignService.ListParams"] = None,
+ params: Optional["PersonalizationDesignListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PersonalizationDesign]:
"""
@@ -213,7 +45,7 @@ def list(
async def list_async(
self,
- params: Optional["PersonalizationDesignService.ListParams"] = None,
+ params: Optional["PersonalizationDesignListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PersonalizationDesign]:
"""
@@ -232,7 +64,7 @@ async def list_async(
def create(
self,
- params: "PersonalizationDesignService.CreateParams",
+ params: "PersonalizationDesignCreateParams",
options: Optional[RequestOptions] = None,
) -> PersonalizationDesign:
"""
@@ -251,7 +83,7 @@ def create(
async def create_async(
self,
- params: "PersonalizationDesignService.CreateParams",
+ params: "PersonalizationDesignCreateParams",
options: Optional[RequestOptions] = None,
) -> PersonalizationDesign:
"""
@@ -271,7 +103,7 @@ async def create_async(
def retrieve(
self,
personalization_design: str,
- params: Optional["PersonalizationDesignService.RetrieveParams"] = None,
+ params: Optional["PersonalizationDesignRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PersonalizationDesign:
"""
@@ -293,7 +125,7 @@ def retrieve(
async def retrieve_async(
self,
personalization_design: str,
- params: Optional["PersonalizationDesignService.RetrieveParams"] = None,
+ params: Optional["PersonalizationDesignRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PersonalizationDesign:
"""
@@ -315,7 +147,7 @@ async def retrieve_async(
def update(
self,
personalization_design: str,
- params: Optional["PersonalizationDesignService.UpdateParams"] = None,
+ params: Optional["PersonalizationDesignUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PersonalizationDesign:
"""
@@ -337,7 +169,7 @@ def update(
async def update_async(
self,
personalization_design: str,
- params: Optional["PersonalizationDesignService.UpdateParams"] = None,
+ params: Optional["PersonalizationDesignUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PersonalizationDesign:
"""
diff --git a/stripe/issuing/_physical_bundle.py b/stripe/issuing/_physical_bundle.py
index 7f2661d49..0e5b33878 100644
--- a/stripe/issuing/_physical_bundle.py
+++ b/stripe/issuing/_physical_bundle.py
@@ -2,10 +2,17 @@
# File generated from our OpenAPI spec
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
-from typing import ClassVar, List
-from typing_extensions import Literal, NotRequired, Unpack
+from typing import ClassVar
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.issuing._physical_bundle_list_params import (
+ PhysicalBundleListParams,
+ )
+ from stripe.params.issuing._physical_bundle_retrieve_params import (
+ PhysicalBundleRetrieveParams,
+ )
class PhysicalBundle(ListableAPIResource["PhysicalBundle"]):
@@ -31,38 +38,6 @@ class Features(StripeObject):
The policy for how to use a second line on a card with this physical bundle.
"""
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["active", "inactive", "review"]]
- """
- Only return physical bundles with the given status.
- """
- type: NotRequired[Literal["custom", "standard"]]
- """
- Only return physical bundles with the given type.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
features: Features
id: str
"""
@@ -91,7 +66,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["PhysicalBundle.ListParams"]
+ cls, **params: Unpack["PhysicalBundleListParams"]
) -> ListObject["PhysicalBundle"]:
"""
Returns a list of physical bundle objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -111,7 +86,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["PhysicalBundle.ListParams"]
+ cls, **params: Unpack["PhysicalBundleListParams"]
) -> ListObject["PhysicalBundle"]:
"""
Returns a list of physical bundle objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -131,7 +106,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["PhysicalBundle.RetrieveParams"]
+ cls, id: str, **params: Unpack["PhysicalBundleRetrieveParams"]
) -> "PhysicalBundle":
"""
Retrieves a physical bundle object.
@@ -142,7 +117,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["PhysicalBundle.RetrieveParams"]
+ cls, id: str, **params: Unpack["PhysicalBundleRetrieveParams"]
) -> "PhysicalBundle":
"""
Retrieves a physical bundle object.
diff --git a/stripe/issuing/_physical_bundle_service.py b/stripe/issuing/_physical_bundle_service.py
index 00c7398ba..65c161191 100644
--- a/stripe/issuing/_physical_bundle_service.py
+++ b/stripe/issuing/_physical_bundle_service.py
@@ -5,46 +5,22 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.issuing._physical_bundle import PhysicalBundle
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.issuing._physical_bundle_list_params import (
+ PhysicalBundleListParams,
+ )
+ from stripe.params.issuing._physical_bundle_retrieve_params import (
+ PhysicalBundleRetrieveParams,
+ )
-class PhysicalBundleService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["active", "inactive", "review"]]
- """
- Only return physical bundles with the given status.
- """
- type: NotRequired[Literal["custom", "standard"]]
- """
- Only return physical bundles with the given type.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class PhysicalBundleService(StripeService):
def list(
self,
- params: Optional["PhysicalBundleService.ListParams"] = None,
+ params: Optional["PhysicalBundleListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PhysicalBundle]:
"""
@@ -63,7 +39,7 @@ def list(
async def list_async(
self,
- params: Optional["PhysicalBundleService.ListParams"] = None,
+ params: Optional["PhysicalBundleListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[PhysicalBundle]:
"""
@@ -83,7 +59,7 @@ async def list_async(
def retrieve(
self,
physical_bundle: str,
- params: Optional["PhysicalBundleService.RetrieveParams"] = None,
+ params: Optional["PhysicalBundleRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PhysicalBundle:
"""
@@ -105,7 +81,7 @@ def retrieve(
async def retrieve_async(
self,
physical_bundle: str,
- params: Optional["PhysicalBundleService.RetrieveParams"] = None,
+ params: Optional["PhysicalBundleRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> PhysicalBundle:
"""
diff --git a/stripe/issuing/_token.py b/stripe/issuing/_token.py
index 214976671..85434e3ea 100644
--- a/stripe/issuing/_token.py
+++ b/stripe/issuing/_token.py
@@ -3,21 +3,19 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import sanitize_id
from typing import ClassVar, List, Optional, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe.issuing._card import Card
+ from stripe.params.issuing._token_list_params import TokenListParams
+ from stripe.params.issuing._token_modify_params import TokenModifyParams
+ from stripe.params.issuing._token_retrieve_params import (
+ TokenRetrieveParams,
+ )
class Token(ListableAPIResource["Token"], UpdateableAPIResource["Token"]):
@@ -192,72 +190,6 @@ class CardholderAddress(StripeObject):
"wallet_provider": WalletProvider,
}
- class ListParams(RequestOptions):
- card: str
- """
- The Issuing card identifier to list tokens for.
- """
- created: NotRequired["Token.ListParamsCreated|int"]
- """
- Only return Issuing tokens that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["active", "deleted", "requested", "suspended"]
- ]
- """
- Select Issuing tokens with the given status.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- status: Literal["active", "deleted", "suspended"]
- """
- Specifies which status the token should be updated to.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
card: ExpandableField["Card"]
"""
Card associated with this token.
@@ -307,7 +239,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def list(cls, **params: Unpack["Token.ListParams"]) -> ListObject["Token"]:
+ def list(cls, **params: Unpack["TokenListParams"]) -> ListObject["Token"]:
"""
Lists all Issuing Token objects for a given card.
"""
@@ -326,7 +258,7 @@ def list(cls, **params: Unpack["Token.ListParams"]) -> ListObject["Token"]:
@classmethod
async def list_async(
- cls, **params: Unpack["Token.ListParams"]
+ cls, **params: Unpack["TokenListParams"]
) -> ListObject["Token"]:
"""
Lists all Issuing Token objects for a given card.
@@ -345,9 +277,7 @@ async def list_async(
return result
@classmethod
- def modify(
- cls, id: str, **params: Unpack["Token.ModifyParams"]
- ) -> "Token":
+ def modify(cls, id: str, **params: Unpack["TokenModifyParams"]) -> "Token":
"""
Attempts to update the specified Issuing Token object to the status specified.
"""
@@ -363,7 +293,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Token.ModifyParams"]
+ cls, id: str, **params: Unpack["TokenModifyParams"]
) -> "Token":
"""
Attempts to update the specified Issuing Token object to the status specified.
@@ -380,7 +310,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Token.RetrieveParams"]
+ cls, id: str, **params: Unpack["TokenRetrieveParams"]
) -> "Token":
"""
Retrieves an Issuing Token object.
@@ -391,7 +321,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Token.RetrieveParams"]
+ cls, id: str, **params: Unpack["TokenRetrieveParams"]
) -> "Token":
"""
Retrieves an Issuing Token object.
diff --git a/stripe/issuing/_token_service.py b/stripe/issuing/_token_service.py
index 81de27914..e1d305780 100644
--- a/stripe/issuing/_token_service.py
+++ b/stripe/issuing/_token_service.py
@@ -5,80 +5,21 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.issuing._token import Token
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.issuing._token_list_params import TokenListParams
+ from stripe.params.issuing._token_retrieve_params import (
+ TokenRetrieveParams,
+ )
+ from stripe.params.issuing._token_update_params import TokenUpdateParams
-class TokenService(StripeService):
- class ListParams(TypedDict):
- card: str
- """
- The Issuing card identifier to list tokens for.
- """
- created: NotRequired["TokenService.ListParamsCreated|int"]
- """
- Only return Issuing tokens that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["active", "deleted", "requested", "suspended"]
- ]
- """
- Select Issuing tokens with the given status.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- status: Literal["active", "deleted", "suspended"]
- """
- Specifies which status the token should be updated to.
- """
+class TokenService(StripeService):
def list(
self,
- params: "TokenService.ListParams",
+ params: "TokenListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[Token]:
"""
@@ -97,7 +38,7 @@ def list(
async def list_async(
self,
- params: "TokenService.ListParams",
+ params: "TokenListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[Token]:
"""
@@ -117,7 +58,7 @@ async def list_async(
def retrieve(
self,
token: str,
- params: Optional["TokenService.RetrieveParams"] = None,
+ params: Optional["TokenRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Token:
"""
@@ -137,7 +78,7 @@ def retrieve(
async def retrieve_async(
self,
token: str,
- params: Optional["TokenService.RetrieveParams"] = None,
+ params: Optional["TokenRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Token:
"""
@@ -157,7 +98,7 @@ async def retrieve_async(
def update(
self,
token: str,
- params: "TokenService.UpdateParams",
+ params: "TokenUpdateParams",
options: Optional[RequestOptions] = None,
) -> Token:
"""
@@ -177,7 +118,7 @@ def update(
async def update_async(
self,
token: str,
- params: "TokenService.UpdateParams",
+ params: "TokenUpdateParams",
options: Optional[RequestOptions] = None,
) -> Token:
"""
diff --git a/stripe/issuing/_transaction.py b/stripe/issuing/_transaction.py
index f8baaa07e..4677555a5 100644
--- a/stripe/issuing/_transaction.py
+++ b/stripe/issuing/_transaction.py
@@ -3,20 +3,12 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._test_helpers import APIResourceTestHelpers
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- Type,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Type, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._balance_transaction import BalanceTransaction
@@ -25,6 +17,24 @@
from stripe.issuing._cardholder import Cardholder
from stripe.issuing._dispute import Dispute
from stripe.issuing._token import Token
+ from stripe.params.issuing._transaction_create_force_capture_params import (
+ TransactionCreateForceCaptureParams,
+ )
+ from stripe.params.issuing._transaction_create_unlinked_refund_params import (
+ TransactionCreateUnlinkedRefundParams,
+ )
+ from stripe.params.issuing._transaction_list_params import (
+ TransactionListParams,
+ )
+ from stripe.params.issuing._transaction_modify_params import (
+ TransactionModifyParams,
+ )
+ from stripe.params.issuing._transaction_refund_params import (
+ TransactionRefundParams,
+ )
+ from stripe.params.issuing._transaction_retrieve_params import (
+ TransactionRetrieveParams,
+ )
class Transaction(
@@ -340,1314 +350,6 @@ class Treasury(StripeObject):
The Treasury [ReceivedDebit](https://stripe.com/docs/api/treasury/received_debits) representing this Issuing transaction if it is a capture
"""
- class CreateForceCaptureParams(RequestOptions):
- amount: int
- """
- The total amount to attempt to capture. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- card: str
- """
- Card associated with this transaction.
- """
- currency: NotRequired[str]
- """
- The currency of the capture. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- merchant_data: NotRequired[
- "Transaction.CreateForceCaptureParamsMerchantData"
- ]
- """
- Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
- """
- purchase_details: NotRequired[
- "Transaction.CreateForceCaptureParamsPurchaseDetails"
- ]
- """
- Additional purchase information that is optionally provided by the merchant.
- """
-
- class CreateForceCaptureParamsMerchantData(TypedDict):
- category: NotRequired[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- """
- A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
- """
- city: NotRequired[str]
- """
- City where the seller is located
- """
- country: NotRequired[str]
- """
- Country where the seller is located
- """
- name: NotRequired[str]
- """
- Name of the seller
- """
- network_id: NotRequired[str]
- """
- Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
- """
- postal_code: NotRequired[str]
- """
- Postal code where the seller is located
- """
- state: NotRequired[str]
- """
- State where the seller is located
- """
- terminal_id: NotRequired[str]
- """
- An ID assigned by the seller to the location of the sale.
- """
- url: NotRequired[str]
- """
- URL provided by the merchant on a 3DS request
- """
-
- class CreateForceCaptureParamsPurchaseDetails(TypedDict):
- fleet: NotRequired[
- "Transaction.CreateForceCaptureParamsPurchaseDetailsFleet"
- ]
- """
- Fleet-specific information for transactions using Fleet cards.
- """
- flight: NotRequired[
- "Transaction.CreateForceCaptureParamsPurchaseDetailsFlight"
- ]
- """
- Information about the flight that was purchased with this transaction.
- """
- fuel: NotRequired[
- "Transaction.CreateForceCaptureParamsPurchaseDetailsFuel"
- ]
- """
- Information about fuel that was purchased with this transaction.
- """
- lodging: NotRequired[
- "Transaction.CreateForceCaptureParamsPurchaseDetailsLodging"
- ]
- """
- Information about lodging that was purchased with this transaction.
- """
- receipt: NotRequired[
- List["Transaction.CreateForceCaptureParamsPurchaseDetailsReceipt"]
- ]
- """
- The line items in the purchase.
- """
- reference: NotRequired[str]
- """
- A merchant-specific order number.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFleet(TypedDict):
- cardholder_prompt_data: NotRequired[
- "Transaction.CreateForceCaptureParamsPurchaseDetailsFleetCardholderPromptData"
- ]
- """
- Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
- """
- purchase_type: NotRequired[
- Literal[
- "fuel_and_non_fuel_purchase",
- "fuel_purchase",
- "non_fuel_purchase",
- ]
- ]
- """
- The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
- """
- reported_breakdown: NotRequired[
- "Transaction.CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdown"
- ]
- """
- More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
- """
- service_type: NotRequired[
- Literal["full_service", "non_fuel_transaction", "self_service"]
- ]
- """
- The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFleetCardholderPromptData(
- TypedDict,
- ):
- driver_id: NotRequired[str]
- """
- Driver ID.
- """
- odometer: NotRequired[int]
- """
- Odometer reading.
- """
- unspecified_id: NotRequired[str]
- """
- An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
- """
- user_id: NotRequired[str]
- """
- User ID.
- """
- vehicle_number: NotRequired[str]
- """
- Vehicle number.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdown(
- TypedDict,
- ):
- fuel: NotRequired[
- "Transaction.CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownFuel"
- ]
- """
- Breakdown of fuel portion of the purchase.
- """
- non_fuel: NotRequired[
- "Transaction.CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel"
- ]
- """
- Breakdown of non-fuel portion of the purchase.
- """
- tax: NotRequired[
- "Transaction.CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownTax"
- ]
- """
- Information about tax included in this transaction.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownFuel(
- TypedDict,
- ):
- gross_amount_decimal: NotRequired[str]
- """
- Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel(
- TypedDict,
- ):
- gross_amount_decimal: NotRequired[str]
- """
- Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownTax(
- TypedDict,
- ):
- local_amount_decimal: NotRequired[str]
- """
- Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
- national_amount_decimal: NotRequired[str]
- """
- Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFlight(TypedDict):
- departure_at: NotRequired[int]
- """
- The time that the flight departed.
- """
- passenger_name: NotRequired[str]
- """
- The name of the passenger.
- """
- refundable: NotRequired[bool]
- """
- Whether the ticket is refundable.
- """
- segments: NotRequired[
- List[
- "Transaction.CreateForceCaptureParamsPurchaseDetailsFlightSegment"
- ]
- ]
- """
- The legs of the trip.
- """
- travel_agency: NotRequired[str]
- """
- The travel agency that issued the ticket.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFlightSegment(TypedDict):
- arrival_airport_code: NotRequired[str]
- """
- The three-letter IATA airport code of the flight's destination.
- """
- carrier: NotRequired[str]
- """
- The airline carrier code.
- """
- departure_airport_code: NotRequired[str]
- """
- The three-letter IATA airport code that the flight departed from.
- """
- flight_number: NotRequired[str]
- """
- The flight number.
- """
- service_class: NotRequired[str]
- """
- The flight's service class.
- """
- stopover_allowed: NotRequired[bool]
- """
- Whether a stopover is allowed on this flight.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFuel(TypedDict):
- industry_product_code: NotRequired[str]
- """
- [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
- """
- quantity_decimal: NotRequired[str]
- """
- The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
- """
- type: NotRequired[
- Literal[
- "diesel",
- "other",
- "unleaded_plus",
- "unleaded_regular",
- "unleaded_super",
- ]
- ]
- """
- The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
- """
- unit: NotRequired[
- Literal[
- "charging_minute",
- "imperial_gallon",
- "kilogram",
- "kilowatt_hour",
- "liter",
- "other",
- "pound",
- "us_gallon",
- ]
- ]
- """
- The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
- """
- unit_cost_decimal: NotRequired[str]
- """
- The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsLodging(TypedDict):
- check_in_at: NotRequired[int]
- """
- The time of checking into the lodging.
- """
- nights: NotRequired[int]
- """
- The number of nights stayed at the lodging.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsReceipt(TypedDict):
- description: NotRequired[str]
- quantity: NotRequired[str]
- total: NotRequired[int]
- unit_cost: NotRequired[int]
-
- class CreateUnlinkedRefundParams(RequestOptions):
- amount: int
- """
- The total amount to attempt to refund. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- card: str
- """
- Card associated with this unlinked refund transaction.
- """
- currency: NotRequired[str]
- """
- The currency of the unlinked refund. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- merchant_data: NotRequired[
- "Transaction.CreateUnlinkedRefundParamsMerchantData"
- ]
- """
- Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
- """
- purchase_details: NotRequired[
- "Transaction.CreateUnlinkedRefundParamsPurchaseDetails"
- ]
- """
- Additional purchase information that is optionally provided by the merchant.
- """
-
- class CreateUnlinkedRefundParamsMerchantData(TypedDict):
- category: NotRequired[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- """
- A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
- """
- city: NotRequired[str]
- """
- City where the seller is located
- """
- country: NotRequired[str]
- """
- Country where the seller is located
- """
- name: NotRequired[str]
- """
- Name of the seller
- """
- network_id: NotRequired[str]
- """
- Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
- """
- postal_code: NotRequired[str]
- """
- Postal code where the seller is located
- """
- state: NotRequired[str]
- """
- State where the seller is located
- """
- terminal_id: NotRequired[str]
- """
- An ID assigned by the seller to the location of the sale.
- """
- url: NotRequired[str]
- """
- URL provided by the merchant on a 3DS request
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetails(TypedDict):
- fleet: NotRequired[
- "Transaction.CreateUnlinkedRefundParamsPurchaseDetailsFleet"
- ]
- """
- Fleet-specific information for transactions using Fleet cards.
- """
- flight: NotRequired[
- "Transaction.CreateUnlinkedRefundParamsPurchaseDetailsFlight"
- ]
- """
- Information about the flight that was purchased with this transaction.
- """
- fuel: NotRequired[
- "Transaction.CreateUnlinkedRefundParamsPurchaseDetailsFuel"
- ]
- """
- Information about fuel that was purchased with this transaction.
- """
- lodging: NotRequired[
- "Transaction.CreateUnlinkedRefundParamsPurchaseDetailsLodging"
- ]
- """
- Information about lodging that was purchased with this transaction.
- """
- receipt: NotRequired[
- List[
- "Transaction.CreateUnlinkedRefundParamsPurchaseDetailsReceipt"
- ]
- ]
- """
- The line items in the purchase.
- """
- reference: NotRequired[str]
- """
- A merchant-specific order number.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFleet(TypedDict):
- cardholder_prompt_data: NotRequired[
- "Transaction.CreateUnlinkedRefundParamsPurchaseDetailsFleetCardholderPromptData"
- ]
- """
- Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
- """
- purchase_type: NotRequired[
- Literal[
- "fuel_and_non_fuel_purchase",
- "fuel_purchase",
- "non_fuel_purchase",
- ]
- ]
- """
- The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
- """
- reported_breakdown: NotRequired[
- "Transaction.CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdown"
- ]
- """
- More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
- """
- service_type: NotRequired[
- Literal["full_service", "non_fuel_transaction", "self_service"]
- ]
- """
- The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFleetCardholderPromptData(
- TypedDict,
- ):
- driver_id: NotRequired[str]
- """
- Driver ID.
- """
- odometer: NotRequired[int]
- """
- Odometer reading.
- """
- unspecified_id: NotRequired[str]
- """
- An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
- """
- user_id: NotRequired[str]
- """
- User ID.
- """
- vehicle_number: NotRequired[str]
- """
- Vehicle number.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdown(
- TypedDict,
- ):
- fuel: NotRequired[
- "Transaction.CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownFuel"
- ]
- """
- Breakdown of fuel portion of the purchase.
- """
- non_fuel: NotRequired[
- "Transaction.CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownNonFuel"
- ]
- """
- Breakdown of non-fuel portion of the purchase.
- """
- tax: NotRequired[
- "Transaction.CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownTax"
- ]
- """
- Information about tax included in this transaction.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownFuel(
- TypedDict,
- ):
- gross_amount_decimal: NotRequired[str]
- """
- Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownNonFuel(
- TypedDict,
- ):
- gross_amount_decimal: NotRequired[str]
- """
- Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownTax(
- TypedDict,
- ):
- local_amount_decimal: NotRequired[str]
- """
- Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
- national_amount_decimal: NotRequired[str]
- """
- Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFlight(TypedDict):
- departure_at: NotRequired[int]
- """
- The time that the flight departed.
- """
- passenger_name: NotRequired[str]
- """
- The name of the passenger.
- """
- refundable: NotRequired[bool]
- """
- Whether the ticket is refundable.
- """
- segments: NotRequired[
- List[
- "Transaction.CreateUnlinkedRefundParamsPurchaseDetailsFlightSegment"
- ]
- ]
- """
- The legs of the trip.
- """
- travel_agency: NotRequired[str]
- """
- The travel agency that issued the ticket.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFlightSegment(TypedDict):
- arrival_airport_code: NotRequired[str]
- """
- The three-letter IATA airport code of the flight's destination.
- """
- carrier: NotRequired[str]
- """
- The airline carrier code.
- """
- departure_airport_code: NotRequired[str]
- """
- The three-letter IATA airport code that the flight departed from.
- """
- flight_number: NotRequired[str]
- """
- The flight number.
- """
- service_class: NotRequired[str]
- """
- The flight's service class.
- """
- stopover_allowed: NotRequired[bool]
- """
- Whether a stopover is allowed on this flight.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFuel(TypedDict):
- industry_product_code: NotRequired[str]
- """
- [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
- """
- quantity_decimal: NotRequired[str]
- """
- The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
- """
- type: NotRequired[
- Literal[
- "diesel",
- "other",
- "unleaded_plus",
- "unleaded_regular",
- "unleaded_super",
- ]
- ]
- """
- The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
- """
- unit: NotRequired[
- Literal[
- "charging_minute",
- "imperial_gallon",
- "kilogram",
- "kilowatt_hour",
- "liter",
- "other",
- "pound",
- "us_gallon",
- ]
- ]
- """
- The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
- """
- unit_cost_decimal: NotRequired[str]
- """
- The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsLodging(TypedDict):
- check_in_at: NotRequired[int]
- """
- The time of checking into the lodging.
- """
- nights: NotRequired[int]
- """
- The number of nights stayed at the lodging.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsReceipt(TypedDict):
- description: NotRequired[str]
- quantity: NotRequired[str]
- total: NotRequired[int]
- unit_cost: NotRequired[int]
-
- class ListParams(RequestOptions):
- card: NotRequired[str]
- """
- Only return transactions that belong to the given card.
- """
- cardholder: NotRequired[str]
- """
- Only return transactions that belong to the given cardholder.
- """
- created: NotRequired["Transaction.ListParamsCreated|int"]
- """
- Only return transactions that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[Literal["capture", "refund"]]
- """
- Only return transactions that have the given type. One of `capture` or `refund`.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class RefundParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- refund_amount: NotRequired[int]
- """
- The total amount to attempt to refund. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount: int
"""
The transaction amount, which will be reflected in your balance. This amount is in your currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
@@ -1736,7 +438,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["Transaction.ListParams"]
+ cls, **params: Unpack["TransactionListParams"]
) -> ListObject["Transaction"]:
"""
Returns a list of Issuing Transaction objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -1756,7 +458,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Transaction.ListParams"]
+ cls, **params: Unpack["TransactionListParams"]
) -> ListObject["Transaction"]:
"""
Returns a list of Issuing Transaction objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -1776,7 +478,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Transaction.ModifyParams"]
+ cls, id: str, **params: Unpack["TransactionModifyParams"]
) -> "Transaction":
"""
Updates the specified Issuing Transaction object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -1793,7 +495,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Transaction.ModifyParams"]
+ cls, id: str, **params: Unpack["TransactionModifyParams"]
) -> "Transaction":
"""
Updates the specified Issuing Transaction object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -1810,7 +512,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Transaction.RetrieveParams"]
+ cls, id: str, **params: Unpack["TransactionRetrieveParams"]
) -> "Transaction":
"""
Retrieves an Issuing Transaction object.
@@ -1821,7 +523,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Transaction.RetrieveParams"]
+ cls, id: str, **params: Unpack["TransactionRetrieveParams"]
) -> "Transaction":
"""
Retrieves an Issuing Transaction object.
@@ -1835,7 +537,7 @@ class TestHelpers(APIResourceTestHelpers["Transaction"]):
@classmethod
def create_force_capture(
- cls, **params: Unpack["Transaction.CreateForceCaptureParams"]
+ cls, **params: Unpack["TransactionCreateForceCaptureParams"]
) -> "Transaction":
"""
Allows the user to capture an arbitrary amount, also known as a forced capture.
@@ -1851,7 +553,7 @@ def create_force_capture(
@classmethod
async def create_force_capture_async(
- cls, **params: Unpack["Transaction.CreateForceCaptureParams"]
+ cls, **params: Unpack["TransactionCreateForceCaptureParams"]
) -> "Transaction":
"""
Allows the user to capture an arbitrary amount, also known as a forced capture.
@@ -1867,7 +569,7 @@ async def create_force_capture_async(
@classmethod
def create_unlinked_refund(
- cls, **params: Unpack["Transaction.CreateUnlinkedRefundParams"]
+ cls, **params: Unpack["TransactionCreateUnlinkedRefundParams"]
) -> "Transaction":
"""
Allows the user to refund an arbitrary amount, also known as a unlinked refund.
@@ -1883,7 +585,7 @@ def create_unlinked_refund(
@classmethod
async def create_unlinked_refund_async(
- cls, **params: Unpack["Transaction.CreateUnlinkedRefundParams"]
+ cls, **params: Unpack["TransactionCreateUnlinkedRefundParams"]
) -> "Transaction":
"""
Allows the user to refund an arbitrary amount, also known as a unlinked refund.
@@ -1899,7 +601,7 @@ async def create_unlinked_refund_async(
@classmethod
def _cls_refund(
- cls, transaction: str, **params: Unpack["Transaction.RefundParams"]
+ cls, transaction: str, **params: Unpack["TransactionRefundParams"]
) -> "Transaction":
"""
Refund a test-mode Transaction.
@@ -1918,7 +620,7 @@ def _cls_refund(
@overload
@staticmethod
def refund(
- transaction: str, **params: Unpack["Transaction.RefundParams"]
+ transaction: str, **params: Unpack["TransactionRefundParams"]
) -> "Transaction":
"""
Refund a test-mode Transaction.
@@ -1927,7 +629,7 @@ def refund(
@overload
def refund(
- self, **params: Unpack["Transaction.RefundParams"]
+ self, **params: Unpack["TransactionRefundParams"]
) -> "Transaction":
"""
Refund a test-mode Transaction.
@@ -1936,7 +638,7 @@ def refund(
@class_method_variant("_cls_refund")
def refund( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Transaction.RefundParams"]
+ self, **params: Unpack["TransactionRefundParams"]
) -> "Transaction":
"""
Refund a test-mode Transaction.
@@ -1954,7 +656,7 @@ def refund( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_refund_async(
- cls, transaction: str, **params: Unpack["Transaction.RefundParams"]
+ cls, transaction: str, **params: Unpack["TransactionRefundParams"]
) -> "Transaction":
"""
Refund a test-mode Transaction.
@@ -1973,7 +675,7 @@ async def _cls_refund_async(
@overload
@staticmethod
async def refund_async(
- transaction: str, **params: Unpack["Transaction.RefundParams"]
+ transaction: str, **params: Unpack["TransactionRefundParams"]
) -> "Transaction":
"""
Refund a test-mode Transaction.
@@ -1982,7 +684,7 @@ async def refund_async(
@overload
async def refund_async(
- self, **params: Unpack["Transaction.RefundParams"]
+ self, **params: Unpack["TransactionRefundParams"]
) -> "Transaction":
"""
Refund a test-mode Transaction.
@@ -1991,7 +693,7 @@ async def refund_async(
@class_method_variant("_cls_refund_async")
async def refund_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Transaction.RefundParams"]
+ self, **params: Unpack["TransactionRefundParams"]
) -> "Transaction":
"""
Refund a test-mode Transaction.
diff --git a/stripe/issuing/_transaction_service.py b/stripe/issuing/_transaction_service.py
index a16c82625..c5d93b736 100644
--- a/stripe/issuing/_transaction_service.py
+++ b/stripe/issuing/_transaction_service.py
@@ -5,82 +5,25 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.issuing._transaction import Transaction
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.issuing._transaction_list_params import (
+ TransactionListParams,
+ )
+ from stripe.params.issuing._transaction_retrieve_params import (
+ TransactionRetrieveParams,
+ )
+ from stripe.params.issuing._transaction_update_params import (
+ TransactionUpdateParams,
+ )
-class TransactionService(StripeService):
- class ListParams(TypedDict):
- card: NotRequired[str]
- """
- Only return transactions that belong to the given card.
- """
- cardholder: NotRequired[str]
- """
- Only return transactions that belong to the given cardholder.
- """
- created: NotRequired["TransactionService.ListParamsCreated|int"]
- """
- Only return transactions that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- type: NotRequired[Literal["capture", "refund"]]
- """
- Only return transactions that have the given type. One of `capture` or `refund`.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
+class TransactionService(StripeService):
def list(
self,
- params: Optional["TransactionService.ListParams"] = None,
+ params: Optional["TransactionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Transaction]:
"""
@@ -99,7 +42,7 @@ def list(
async def list_async(
self,
- params: Optional["TransactionService.ListParams"] = None,
+ params: Optional["TransactionListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Transaction]:
"""
@@ -119,7 +62,7 @@ async def list_async(
def retrieve(
self,
transaction: str,
- params: Optional["TransactionService.RetrieveParams"] = None,
+ params: Optional["TransactionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
@@ -141,7 +84,7 @@ def retrieve(
async def retrieve_async(
self,
transaction: str,
- params: Optional["TransactionService.RetrieveParams"] = None,
+ params: Optional["TransactionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
@@ -163,7 +106,7 @@ async def retrieve_async(
def update(
self,
transaction: str,
- params: Optional["TransactionService.UpdateParams"] = None,
+ params: Optional["TransactionUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
@@ -185,7 +128,7 @@ def update(
async def update_async(
self,
transaction: str,
- params: Optional["TransactionService.UpdateParams"] = None,
+ params: Optional["TransactionUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
diff --git a/stripe/params/__init__.py b/stripe/params/__init__.py
new file mode 100644
index 000000000..6f8630378
--- /dev/null
+++ b/stripe/params/__init__.py
@@ -0,0 +1,1135 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params import (
+ apps as apps,
+ billing as billing,
+ billing_portal as billing_portal,
+ checkout as checkout,
+ climate as climate,
+ entitlements as entitlements,
+ financial_connections as financial_connections,
+ forwarding as forwarding,
+ identity as identity,
+ issuing as issuing,
+ radar as radar,
+ reporting as reporting,
+ sigma as sigma,
+ tax as tax,
+ terminal as terminal,
+ test_helpers as test_helpers,
+ treasury as treasury,
+)
+from stripe.params._account_capability_list_params import (
+ AccountCapabilityListParams as AccountCapabilityListParams,
+)
+from stripe.params._account_capability_retrieve_params import (
+ AccountCapabilityRetrieveParams as AccountCapabilityRetrieveParams,
+)
+from stripe.params._account_capability_update_params import (
+ AccountCapabilityUpdateParams as AccountCapabilityUpdateParams,
+)
+from stripe.params._account_create_external_account_params import (
+ AccountCreateExternalAccountParams as AccountCreateExternalAccountParams,
+)
+from stripe.params._account_create_login_link_params import (
+ AccountCreateLoginLinkParams as AccountCreateLoginLinkParams,
+)
+from stripe.params._account_create_params import (
+ AccountCreateParams as AccountCreateParams,
+)
+from stripe.params._account_create_person_params import (
+ AccountCreatePersonParams as AccountCreatePersonParams,
+)
+from stripe.params._account_delete_external_account_params import (
+ AccountDeleteExternalAccountParams as AccountDeleteExternalAccountParams,
+)
+from stripe.params._account_delete_params import (
+ AccountDeleteParams as AccountDeleteParams,
+)
+from stripe.params._account_delete_person_params import (
+ AccountDeletePersonParams as AccountDeletePersonParams,
+)
+from stripe.params._account_external_account_create_params import (
+ AccountExternalAccountCreateParams as AccountExternalAccountCreateParams,
+)
+from stripe.params._account_external_account_delete_params import (
+ AccountExternalAccountDeleteParams as AccountExternalAccountDeleteParams,
+)
+from stripe.params._account_external_account_list_params import (
+ AccountExternalAccountListParams as AccountExternalAccountListParams,
+)
+from stripe.params._account_external_account_retrieve_params import (
+ AccountExternalAccountRetrieveParams as AccountExternalAccountRetrieveParams,
+)
+from stripe.params._account_external_account_update_params import (
+ AccountExternalAccountUpdateParams as AccountExternalAccountUpdateParams,
+)
+from stripe.params._account_link_create_params import (
+ AccountLinkCreateParams as AccountLinkCreateParams,
+)
+from stripe.params._account_list_capabilities_params import (
+ AccountListCapabilitiesParams as AccountListCapabilitiesParams,
+)
+from stripe.params._account_list_external_accounts_params import (
+ AccountListExternalAccountsParams as AccountListExternalAccountsParams,
+)
+from stripe.params._account_list_params import (
+ AccountListParams as AccountListParams,
+)
+from stripe.params._account_list_persons_params import (
+ AccountListPersonsParams as AccountListPersonsParams,
+)
+from stripe.params._account_login_link_create_params import (
+ AccountLoginLinkCreateParams as AccountLoginLinkCreateParams,
+)
+from stripe.params._account_modify_capability_params import (
+ AccountModifyCapabilityParams as AccountModifyCapabilityParams,
+)
+from stripe.params._account_modify_external_account_params import (
+ AccountModifyExternalAccountParams as AccountModifyExternalAccountParams,
+)
+from stripe.params._account_modify_person_params import (
+ AccountModifyPersonParams as AccountModifyPersonParams,
+)
+from stripe.params._account_person_create_params import (
+ AccountPersonCreateParams as AccountPersonCreateParams,
+)
+from stripe.params._account_person_delete_params import (
+ AccountPersonDeleteParams as AccountPersonDeleteParams,
+)
+from stripe.params._account_person_list_params import (
+ AccountPersonListParams as AccountPersonListParams,
+)
+from stripe.params._account_person_retrieve_params import (
+ AccountPersonRetrieveParams as AccountPersonRetrieveParams,
+)
+from stripe.params._account_person_update_params import (
+ AccountPersonUpdateParams as AccountPersonUpdateParams,
+)
+from stripe.params._account_persons_params import (
+ AccountPersonsParams as AccountPersonsParams,
+)
+from stripe.params._account_reject_params import (
+ AccountRejectParams as AccountRejectParams,
+)
+from stripe.params._account_retrieve_capability_params import (
+ AccountRetrieveCapabilityParams as AccountRetrieveCapabilityParams,
+)
+from stripe.params._account_retrieve_current_params import (
+ AccountRetrieveCurrentParams as AccountRetrieveCurrentParams,
+)
+from stripe.params._account_retrieve_external_account_params import (
+ AccountRetrieveExternalAccountParams as AccountRetrieveExternalAccountParams,
+)
+from stripe.params._account_retrieve_params import (
+ AccountRetrieveParams as AccountRetrieveParams,
+)
+from stripe.params._account_retrieve_person_params import (
+ AccountRetrievePersonParams as AccountRetrievePersonParams,
+)
+from stripe.params._account_session_create_params import (
+ AccountSessionCreateParams as AccountSessionCreateParams,
+)
+from stripe.params._account_update_params import (
+ AccountUpdateParams as AccountUpdateParams,
+)
+from stripe.params._apple_pay_domain_create_params import (
+ ApplePayDomainCreateParams as ApplePayDomainCreateParams,
+)
+from stripe.params._apple_pay_domain_delete_params import (
+ ApplePayDomainDeleteParams as ApplePayDomainDeleteParams,
+)
+from stripe.params._apple_pay_domain_list_params import (
+ ApplePayDomainListParams as ApplePayDomainListParams,
+)
+from stripe.params._apple_pay_domain_retrieve_params import (
+ ApplePayDomainRetrieveParams as ApplePayDomainRetrieveParams,
+)
+from stripe.params._application_fee_create_refund_params import (
+ ApplicationFeeCreateRefundParams as ApplicationFeeCreateRefundParams,
+)
+from stripe.params._application_fee_list_params import (
+ ApplicationFeeListParams as ApplicationFeeListParams,
+)
+from stripe.params._application_fee_list_refunds_params import (
+ ApplicationFeeListRefundsParams as ApplicationFeeListRefundsParams,
+)
+from stripe.params._application_fee_modify_refund_params import (
+ ApplicationFeeModifyRefundParams as ApplicationFeeModifyRefundParams,
+)
+from stripe.params._application_fee_refund_create_params import (
+ ApplicationFeeRefundCreateParams as ApplicationFeeRefundCreateParams,
+)
+from stripe.params._application_fee_refund_list_params import (
+ ApplicationFeeRefundListParams as ApplicationFeeRefundListParams,
+)
+from stripe.params._application_fee_refund_params import (
+ ApplicationFeeRefundParams as ApplicationFeeRefundParams,
+)
+from stripe.params._application_fee_refund_retrieve_params import (
+ ApplicationFeeRefundRetrieveParams as ApplicationFeeRefundRetrieveParams,
+)
+from stripe.params._application_fee_refund_update_params import (
+ ApplicationFeeRefundUpdateParams as ApplicationFeeRefundUpdateParams,
+)
+from stripe.params._application_fee_retrieve_params import (
+ ApplicationFeeRetrieveParams as ApplicationFeeRetrieveParams,
+)
+from stripe.params._application_fee_retrieve_refund_params import (
+ ApplicationFeeRetrieveRefundParams as ApplicationFeeRetrieveRefundParams,
+)
+from stripe.params._balance_retrieve_params import (
+ BalanceRetrieveParams as BalanceRetrieveParams,
+)
+from stripe.params._balance_settings_modify_params import (
+ BalanceSettingsModifyParams as BalanceSettingsModifyParams,
+)
+from stripe.params._balance_settings_retrieve_params import (
+ BalanceSettingsRetrieveParams as BalanceSettingsRetrieveParams,
+)
+from stripe.params._balance_settings_update_params import (
+ BalanceSettingsUpdateParams as BalanceSettingsUpdateParams,
+)
+from stripe.params._balance_transaction_list_params import (
+ BalanceTransactionListParams as BalanceTransactionListParams,
+)
+from stripe.params._balance_transaction_retrieve_params import (
+ BalanceTransactionRetrieveParams as BalanceTransactionRetrieveParams,
+)
+from stripe.params._bank_account_delete_params import (
+ BankAccountDeleteParams as BankAccountDeleteParams,
+)
+from stripe.params._card_delete_params import (
+ CardDeleteParams as CardDeleteParams,
+)
+from stripe.params._charge_capture_params import (
+ ChargeCaptureParams as ChargeCaptureParams,
+)
+from stripe.params._charge_create_params import (
+ ChargeCreateParams as ChargeCreateParams,
+)
+from stripe.params._charge_list_params import (
+ ChargeListParams as ChargeListParams,
+)
+from stripe.params._charge_list_refunds_params import (
+ ChargeListRefundsParams as ChargeListRefundsParams,
+)
+from stripe.params._charge_modify_params import (
+ ChargeModifyParams as ChargeModifyParams,
+)
+from stripe.params._charge_retrieve_params import (
+ ChargeRetrieveParams as ChargeRetrieveParams,
+)
+from stripe.params._charge_retrieve_refund_params import (
+ ChargeRetrieveRefundParams as ChargeRetrieveRefundParams,
+)
+from stripe.params._charge_search_params import (
+ ChargeSearchParams as ChargeSearchParams,
+)
+from stripe.params._charge_update_params import (
+ ChargeUpdateParams as ChargeUpdateParams,
+)
+from stripe.params._confirmation_token_create_params import (
+ ConfirmationTokenCreateParams as ConfirmationTokenCreateParams,
+)
+from stripe.params._confirmation_token_retrieve_params import (
+ ConfirmationTokenRetrieveParams as ConfirmationTokenRetrieveParams,
+)
+from stripe.params._country_spec_list_params import (
+ CountrySpecListParams as CountrySpecListParams,
+)
+from stripe.params._country_spec_retrieve_params import (
+ CountrySpecRetrieveParams as CountrySpecRetrieveParams,
+)
+from stripe.params._coupon_create_params import (
+ CouponCreateParams as CouponCreateParams,
+)
+from stripe.params._coupon_delete_params import (
+ CouponDeleteParams as CouponDeleteParams,
+)
+from stripe.params._coupon_list_params import (
+ CouponListParams as CouponListParams,
+)
+from stripe.params._coupon_modify_params import (
+ CouponModifyParams as CouponModifyParams,
+)
+from stripe.params._coupon_retrieve_params import (
+ CouponRetrieveParams as CouponRetrieveParams,
+)
+from stripe.params._coupon_update_params import (
+ CouponUpdateParams as CouponUpdateParams,
+)
+from stripe.params._credit_note_create_params import (
+ CreditNoteCreateParams as CreditNoteCreateParams,
+)
+from stripe.params._credit_note_line_item_list_params import (
+ CreditNoteLineItemListParams as CreditNoteLineItemListParams,
+)
+from stripe.params._credit_note_list_lines_params import (
+ CreditNoteListLinesParams as CreditNoteListLinesParams,
+)
+from stripe.params._credit_note_list_params import (
+ CreditNoteListParams as CreditNoteListParams,
+)
+from stripe.params._credit_note_modify_params import (
+ CreditNoteModifyParams as CreditNoteModifyParams,
+)
+from stripe.params._credit_note_preview_lines_list_params import (
+ CreditNotePreviewLinesListParams as CreditNotePreviewLinesListParams,
+)
+from stripe.params._credit_note_preview_lines_params import (
+ CreditNotePreviewLinesParams as CreditNotePreviewLinesParams,
+)
+from stripe.params._credit_note_preview_params import (
+ CreditNotePreviewParams as CreditNotePreviewParams,
+)
+from stripe.params._credit_note_retrieve_params import (
+ CreditNoteRetrieveParams as CreditNoteRetrieveParams,
+)
+from stripe.params._credit_note_update_params import (
+ CreditNoteUpdateParams as CreditNoteUpdateParams,
+)
+from stripe.params._credit_note_void_credit_note_params import (
+ CreditNoteVoidCreditNoteParams as CreditNoteVoidCreditNoteParams,
+)
+from stripe.params._customer_balance_transaction_create_params import (
+ CustomerBalanceTransactionCreateParams as CustomerBalanceTransactionCreateParams,
+)
+from stripe.params._customer_balance_transaction_list_params import (
+ CustomerBalanceTransactionListParams as CustomerBalanceTransactionListParams,
+)
+from stripe.params._customer_balance_transaction_retrieve_params import (
+ CustomerBalanceTransactionRetrieveParams as CustomerBalanceTransactionRetrieveParams,
+)
+from stripe.params._customer_balance_transaction_update_params import (
+ CustomerBalanceTransactionUpdateParams as CustomerBalanceTransactionUpdateParams,
+)
+from stripe.params._customer_cash_balance_retrieve_params import (
+ CustomerCashBalanceRetrieveParams as CustomerCashBalanceRetrieveParams,
+)
+from stripe.params._customer_cash_balance_transaction_list_params import (
+ CustomerCashBalanceTransactionListParams as CustomerCashBalanceTransactionListParams,
+)
+from stripe.params._customer_cash_balance_transaction_retrieve_params import (
+ CustomerCashBalanceTransactionRetrieveParams as CustomerCashBalanceTransactionRetrieveParams,
+)
+from stripe.params._customer_cash_balance_update_params import (
+ CustomerCashBalanceUpdateParams as CustomerCashBalanceUpdateParams,
+)
+from stripe.params._customer_create_balance_transaction_params import (
+ CustomerCreateBalanceTransactionParams as CustomerCreateBalanceTransactionParams,
+)
+from stripe.params._customer_create_funding_instructions_params import (
+ CustomerCreateFundingInstructionsParams as CustomerCreateFundingInstructionsParams,
+)
+from stripe.params._customer_create_params import (
+ CustomerCreateParams as CustomerCreateParams,
+)
+from stripe.params._customer_create_source_params import (
+ CustomerCreateSourceParams as CustomerCreateSourceParams,
+)
+from stripe.params._customer_create_tax_id_params import (
+ CustomerCreateTaxIdParams as CustomerCreateTaxIdParams,
+)
+from stripe.params._customer_delete_discount_params import (
+ CustomerDeleteDiscountParams as CustomerDeleteDiscountParams,
+)
+from stripe.params._customer_delete_params import (
+ CustomerDeleteParams as CustomerDeleteParams,
+)
+from stripe.params._customer_delete_source_params import (
+ CustomerDeleteSourceParams as CustomerDeleteSourceParams,
+)
+from stripe.params._customer_delete_tax_id_params import (
+ CustomerDeleteTaxIdParams as CustomerDeleteTaxIdParams,
+)
+from stripe.params._customer_fund_cash_balance_params import (
+ CustomerFundCashBalanceParams as CustomerFundCashBalanceParams,
+)
+from stripe.params._customer_funding_instructions_create_params import (
+ CustomerFundingInstructionsCreateParams as CustomerFundingInstructionsCreateParams,
+)
+from stripe.params._customer_list_balance_transactions_params import (
+ CustomerListBalanceTransactionsParams as CustomerListBalanceTransactionsParams,
+)
+from stripe.params._customer_list_cash_balance_transactions_params import (
+ CustomerListCashBalanceTransactionsParams as CustomerListCashBalanceTransactionsParams,
+)
+from stripe.params._customer_list_params import (
+ CustomerListParams as CustomerListParams,
+)
+from stripe.params._customer_list_payment_methods_params import (
+ CustomerListPaymentMethodsParams as CustomerListPaymentMethodsParams,
+)
+from stripe.params._customer_list_sources_params import (
+ CustomerListSourcesParams as CustomerListSourcesParams,
+)
+from stripe.params._customer_list_tax_ids_params import (
+ CustomerListTaxIdsParams as CustomerListTaxIdsParams,
+)
+from stripe.params._customer_modify_balance_transaction_params import (
+ CustomerModifyBalanceTransactionParams as CustomerModifyBalanceTransactionParams,
+)
+from stripe.params._customer_modify_cash_balance_params import (
+ CustomerModifyCashBalanceParams as CustomerModifyCashBalanceParams,
+)
+from stripe.params._customer_modify_params import (
+ CustomerModifyParams as CustomerModifyParams,
+)
+from stripe.params._customer_modify_source_params import (
+ CustomerModifySourceParams as CustomerModifySourceParams,
+)
+from stripe.params._customer_payment_method_list_params import (
+ CustomerPaymentMethodListParams as CustomerPaymentMethodListParams,
+)
+from stripe.params._customer_payment_method_retrieve_params import (
+ CustomerPaymentMethodRetrieveParams as CustomerPaymentMethodRetrieveParams,
+)
+from stripe.params._customer_payment_source_create_params import (
+ CustomerPaymentSourceCreateParams as CustomerPaymentSourceCreateParams,
+)
+from stripe.params._customer_payment_source_delete_params import (
+ CustomerPaymentSourceDeleteParams as CustomerPaymentSourceDeleteParams,
+)
+from stripe.params._customer_payment_source_list_params import (
+ CustomerPaymentSourceListParams as CustomerPaymentSourceListParams,
+)
+from stripe.params._customer_payment_source_retrieve_params import (
+ CustomerPaymentSourceRetrieveParams as CustomerPaymentSourceRetrieveParams,
+)
+from stripe.params._customer_payment_source_update_params import (
+ CustomerPaymentSourceUpdateParams as CustomerPaymentSourceUpdateParams,
+)
+from stripe.params._customer_payment_source_verify_params import (
+ CustomerPaymentSourceVerifyParams as CustomerPaymentSourceVerifyParams,
+)
+from stripe.params._customer_retrieve_balance_transaction_params import (
+ CustomerRetrieveBalanceTransactionParams as CustomerRetrieveBalanceTransactionParams,
+)
+from stripe.params._customer_retrieve_cash_balance_params import (
+ CustomerRetrieveCashBalanceParams as CustomerRetrieveCashBalanceParams,
+)
+from stripe.params._customer_retrieve_cash_balance_transaction_params import (
+ CustomerRetrieveCashBalanceTransactionParams as CustomerRetrieveCashBalanceTransactionParams,
+)
+from stripe.params._customer_retrieve_params import (
+ CustomerRetrieveParams as CustomerRetrieveParams,
+)
+from stripe.params._customer_retrieve_payment_method_params import (
+ CustomerRetrievePaymentMethodParams as CustomerRetrievePaymentMethodParams,
+)
+from stripe.params._customer_retrieve_source_params import (
+ CustomerRetrieveSourceParams as CustomerRetrieveSourceParams,
+)
+from stripe.params._customer_retrieve_tax_id_params import (
+ CustomerRetrieveTaxIdParams as CustomerRetrieveTaxIdParams,
+)
+from stripe.params._customer_search_params import (
+ CustomerSearchParams as CustomerSearchParams,
+)
+from stripe.params._customer_session_create_params import (
+ CustomerSessionCreateParams as CustomerSessionCreateParams,
+)
+from stripe.params._customer_tax_id_create_params import (
+ CustomerTaxIdCreateParams as CustomerTaxIdCreateParams,
+)
+from stripe.params._customer_tax_id_delete_params import (
+ CustomerTaxIdDeleteParams as CustomerTaxIdDeleteParams,
+)
+from stripe.params._customer_tax_id_list_params import (
+ CustomerTaxIdListParams as CustomerTaxIdListParams,
+)
+from stripe.params._customer_tax_id_retrieve_params import (
+ CustomerTaxIdRetrieveParams as CustomerTaxIdRetrieveParams,
+)
+from stripe.params._customer_update_params import (
+ CustomerUpdateParams as CustomerUpdateParams,
+)
+from stripe.params._dispute_close_params import (
+ DisputeCloseParams as DisputeCloseParams,
+)
+from stripe.params._dispute_list_params import (
+ DisputeListParams as DisputeListParams,
+)
+from stripe.params._dispute_modify_params import (
+ DisputeModifyParams as DisputeModifyParams,
+)
+from stripe.params._dispute_retrieve_params import (
+ DisputeRetrieveParams as DisputeRetrieveParams,
+)
+from stripe.params._dispute_update_params import (
+ DisputeUpdateParams as DisputeUpdateParams,
+)
+from stripe.params._ephemeral_key_create_params import (
+ EphemeralKeyCreateParams as EphemeralKeyCreateParams,
+)
+from stripe.params._ephemeral_key_delete_params import (
+ EphemeralKeyDeleteParams as EphemeralKeyDeleteParams,
+)
+from stripe.params._event_list_params import EventListParams as EventListParams
+from stripe.params._event_retrieve_params import (
+ EventRetrieveParams as EventRetrieveParams,
+)
+from stripe.params._exchange_rate_list_params import (
+ ExchangeRateListParams as ExchangeRateListParams,
+)
+from stripe.params._exchange_rate_retrieve_params import (
+ ExchangeRateRetrieveParams as ExchangeRateRetrieveParams,
+)
+from stripe.params._file_create_params import (
+ FileCreateParams as FileCreateParams,
+)
+from stripe.params._file_link_create_params import (
+ FileLinkCreateParams as FileLinkCreateParams,
+)
+from stripe.params._file_link_list_params import (
+ FileLinkListParams as FileLinkListParams,
+)
+from stripe.params._file_link_modify_params import (
+ FileLinkModifyParams as FileLinkModifyParams,
+)
+from stripe.params._file_link_retrieve_params import (
+ FileLinkRetrieveParams as FileLinkRetrieveParams,
+)
+from stripe.params._file_link_update_params import (
+ FileLinkUpdateParams as FileLinkUpdateParams,
+)
+from stripe.params._file_list_params import FileListParams as FileListParams
+from stripe.params._file_retrieve_params import (
+ FileRetrieveParams as FileRetrieveParams,
+)
+from stripe.params._invoice_add_lines_params import (
+ InvoiceAddLinesParams as InvoiceAddLinesParams,
+)
+from stripe.params._invoice_attach_payment_params import (
+ InvoiceAttachPaymentParams as InvoiceAttachPaymentParams,
+)
+from stripe.params._invoice_create_params import (
+ InvoiceCreateParams as InvoiceCreateParams,
+)
+from stripe.params._invoice_create_preview_params import (
+ InvoiceCreatePreviewParams as InvoiceCreatePreviewParams,
+)
+from stripe.params._invoice_delete_params import (
+ InvoiceDeleteParams as InvoiceDeleteParams,
+)
+from stripe.params._invoice_finalize_invoice_params import (
+ InvoiceFinalizeInvoiceParams as InvoiceFinalizeInvoiceParams,
+)
+from stripe.params._invoice_item_create_params import (
+ InvoiceItemCreateParams as InvoiceItemCreateParams,
+)
+from stripe.params._invoice_item_delete_params import (
+ InvoiceItemDeleteParams as InvoiceItemDeleteParams,
+)
+from stripe.params._invoice_item_list_params import (
+ InvoiceItemListParams as InvoiceItemListParams,
+)
+from stripe.params._invoice_item_modify_params import (
+ InvoiceItemModifyParams as InvoiceItemModifyParams,
+)
+from stripe.params._invoice_item_retrieve_params import (
+ InvoiceItemRetrieveParams as InvoiceItemRetrieveParams,
+)
+from stripe.params._invoice_item_update_params import (
+ InvoiceItemUpdateParams as InvoiceItemUpdateParams,
+)
+from stripe.params._invoice_line_item_list_params import (
+ InvoiceLineItemListParams as InvoiceLineItemListParams,
+)
+from stripe.params._invoice_line_item_update_params import (
+ InvoiceLineItemUpdateParams as InvoiceLineItemUpdateParams,
+)
+from stripe.params._invoice_list_lines_params import (
+ InvoiceListLinesParams as InvoiceListLinesParams,
+)
+from stripe.params._invoice_list_params import (
+ InvoiceListParams as InvoiceListParams,
+)
+from stripe.params._invoice_mark_uncollectible_params import (
+ InvoiceMarkUncollectibleParams as InvoiceMarkUncollectibleParams,
+)
+from stripe.params._invoice_modify_params import (
+ InvoiceModifyParams as InvoiceModifyParams,
+)
+from stripe.params._invoice_pay_params import (
+ InvoicePayParams as InvoicePayParams,
+)
+from stripe.params._invoice_payment_list_params import (
+ InvoicePaymentListParams as InvoicePaymentListParams,
+)
+from stripe.params._invoice_payment_retrieve_params import (
+ InvoicePaymentRetrieveParams as InvoicePaymentRetrieveParams,
+)
+from stripe.params._invoice_remove_lines_params import (
+ InvoiceRemoveLinesParams as InvoiceRemoveLinesParams,
+)
+from stripe.params._invoice_rendering_template_archive_params import (
+ InvoiceRenderingTemplateArchiveParams as InvoiceRenderingTemplateArchiveParams,
+)
+from stripe.params._invoice_rendering_template_list_params import (
+ InvoiceRenderingTemplateListParams as InvoiceRenderingTemplateListParams,
+)
+from stripe.params._invoice_rendering_template_retrieve_params import (
+ InvoiceRenderingTemplateRetrieveParams as InvoiceRenderingTemplateRetrieveParams,
+)
+from stripe.params._invoice_rendering_template_unarchive_params import (
+ InvoiceRenderingTemplateUnarchiveParams as InvoiceRenderingTemplateUnarchiveParams,
+)
+from stripe.params._invoice_retrieve_params import (
+ InvoiceRetrieveParams as InvoiceRetrieveParams,
+)
+from stripe.params._invoice_search_params import (
+ InvoiceSearchParams as InvoiceSearchParams,
+)
+from stripe.params._invoice_send_invoice_params import (
+ InvoiceSendInvoiceParams as InvoiceSendInvoiceParams,
+)
+from stripe.params._invoice_update_lines_params import (
+ InvoiceUpdateLinesParams as InvoiceUpdateLinesParams,
+)
+from stripe.params._invoice_update_params import (
+ InvoiceUpdateParams as InvoiceUpdateParams,
+)
+from stripe.params._invoice_void_invoice_params import (
+ InvoiceVoidInvoiceParams as InvoiceVoidInvoiceParams,
+)
+from stripe.params._mandate_retrieve_params import (
+ MandateRetrieveParams as MandateRetrieveParams,
+)
+from stripe.params._payment_intent_apply_customer_balance_params import (
+ PaymentIntentApplyCustomerBalanceParams as PaymentIntentApplyCustomerBalanceParams,
+)
+from stripe.params._payment_intent_cancel_params import (
+ PaymentIntentCancelParams as PaymentIntentCancelParams,
+)
+from stripe.params._payment_intent_capture_params import (
+ PaymentIntentCaptureParams as PaymentIntentCaptureParams,
+)
+from stripe.params._payment_intent_confirm_params import (
+ PaymentIntentConfirmParams as PaymentIntentConfirmParams,
+)
+from stripe.params._payment_intent_create_params import (
+ PaymentIntentCreateParams as PaymentIntentCreateParams,
+)
+from stripe.params._payment_intent_increment_authorization_params import (
+ PaymentIntentIncrementAuthorizationParams as PaymentIntentIncrementAuthorizationParams,
+)
+from stripe.params._payment_intent_list_params import (
+ PaymentIntentListParams as PaymentIntentListParams,
+)
+from stripe.params._payment_intent_modify_params import (
+ PaymentIntentModifyParams as PaymentIntentModifyParams,
+)
+from stripe.params._payment_intent_retrieve_params import (
+ PaymentIntentRetrieveParams as PaymentIntentRetrieveParams,
+)
+from stripe.params._payment_intent_search_params import (
+ PaymentIntentSearchParams as PaymentIntentSearchParams,
+)
+from stripe.params._payment_intent_update_params import (
+ PaymentIntentUpdateParams as PaymentIntentUpdateParams,
+)
+from stripe.params._payment_intent_verify_microdeposits_params import (
+ PaymentIntentVerifyMicrodepositsParams as PaymentIntentVerifyMicrodepositsParams,
+)
+from stripe.params._payment_link_create_params import (
+ PaymentLinkCreateParams as PaymentLinkCreateParams,
+)
+from stripe.params._payment_link_line_item_list_params import (
+ PaymentLinkLineItemListParams as PaymentLinkLineItemListParams,
+)
+from stripe.params._payment_link_list_line_items_params import (
+ PaymentLinkListLineItemsParams as PaymentLinkListLineItemsParams,
+)
+from stripe.params._payment_link_list_params import (
+ PaymentLinkListParams as PaymentLinkListParams,
+)
+from stripe.params._payment_link_modify_params import (
+ PaymentLinkModifyParams as PaymentLinkModifyParams,
+)
+from stripe.params._payment_link_retrieve_params import (
+ PaymentLinkRetrieveParams as PaymentLinkRetrieveParams,
+)
+from stripe.params._payment_link_update_params import (
+ PaymentLinkUpdateParams as PaymentLinkUpdateParams,
+)
+from stripe.params._payment_method_attach_params import (
+ PaymentMethodAttachParams as PaymentMethodAttachParams,
+)
+from stripe.params._payment_method_configuration_create_params import (
+ PaymentMethodConfigurationCreateParams as PaymentMethodConfigurationCreateParams,
+)
+from stripe.params._payment_method_configuration_list_params import (
+ PaymentMethodConfigurationListParams as PaymentMethodConfigurationListParams,
+)
+from stripe.params._payment_method_configuration_modify_params import (
+ PaymentMethodConfigurationModifyParams as PaymentMethodConfigurationModifyParams,
+)
+from stripe.params._payment_method_configuration_retrieve_params import (
+ PaymentMethodConfigurationRetrieveParams as PaymentMethodConfigurationRetrieveParams,
+)
+from stripe.params._payment_method_configuration_update_params import (
+ PaymentMethodConfigurationUpdateParams as PaymentMethodConfigurationUpdateParams,
+)
+from stripe.params._payment_method_create_params import (
+ PaymentMethodCreateParams as PaymentMethodCreateParams,
+)
+from stripe.params._payment_method_detach_params import (
+ PaymentMethodDetachParams as PaymentMethodDetachParams,
+)
+from stripe.params._payment_method_domain_create_params import (
+ PaymentMethodDomainCreateParams as PaymentMethodDomainCreateParams,
+)
+from stripe.params._payment_method_domain_list_params import (
+ PaymentMethodDomainListParams as PaymentMethodDomainListParams,
+)
+from stripe.params._payment_method_domain_modify_params import (
+ PaymentMethodDomainModifyParams as PaymentMethodDomainModifyParams,
+)
+from stripe.params._payment_method_domain_retrieve_params import (
+ PaymentMethodDomainRetrieveParams as PaymentMethodDomainRetrieveParams,
+)
+from stripe.params._payment_method_domain_update_params import (
+ PaymentMethodDomainUpdateParams as PaymentMethodDomainUpdateParams,
+)
+from stripe.params._payment_method_domain_validate_params import (
+ PaymentMethodDomainValidateParams as PaymentMethodDomainValidateParams,
+)
+from stripe.params._payment_method_list_params import (
+ PaymentMethodListParams as PaymentMethodListParams,
+)
+from stripe.params._payment_method_modify_params import (
+ PaymentMethodModifyParams as PaymentMethodModifyParams,
+)
+from stripe.params._payment_method_retrieve_params import (
+ PaymentMethodRetrieveParams as PaymentMethodRetrieveParams,
+)
+from stripe.params._payment_method_update_params import (
+ PaymentMethodUpdateParams as PaymentMethodUpdateParams,
+)
+from stripe.params._payout_cancel_params import (
+ PayoutCancelParams as PayoutCancelParams,
+)
+from stripe.params._payout_create_params import (
+ PayoutCreateParams as PayoutCreateParams,
+)
+from stripe.params._payout_list_params import (
+ PayoutListParams as PayoutListParams,
+)
+from stripe.params._payout_modify_params import (
+ PayoutModifyParams as PayoutModifyParams,
+)
+from stripe.params._payout_retrieve_params import (
+ PayoutRetrieveParams as PayoutRetrieveParams,
+)
+from stripe.params._payout_reverse_params import (
+ PayoutReverseParams as PayoutReverseParams,
+)
+from stripe.params._payout_update_params import (
+ PayoutUpdateParams as PayoutUpdateParams,
+)
+from stripe.params._plan_create_params import (
+ PlanCreateParams as PlanCreateParams,
+)
+from stripe.params._plan_delete_params import (
+ PlanDeleteParams as PlanDeleteParams,
+)
+from stripe.params._plan_list_params import PlanListParams as PlanListParams
+from stripe.params._plan_modify_params import (
+ PlanModifyParams as PlanModifyParams,
+)
+from stripe.params._plan_retrieve_params import (
+ PlanRetrieveParams as PlanRetrieveParams,
+)
+from stripe.params._plan_update_params import (
+ PlanUpdateParams as PlanUpdateParams,
+)
+from stripe.params._price_create_params import (
+ PriceCreateParams as PriceCreateParams,
+)
+from stripe.params._price_list_params import PriceListParams as PriceListParams
+from stripe.params._price_modify_params import (
+ PriceModifyParams as PriceModifyParams,
+)
+from stripe.params._price_retrieve_params import (
+ PriceRetrieveParams as PriceRetrieveParams,
+)
+from stripe.params._price_search_params import (
+ PriceSearchParams as PriceSearchParams,
+)
+from stripe.params._price_update_params import (
+ PriceUpdateParams as PriceUpdateParams,
+)
+from stripe.params._product_create_feature_params import (
+ ProductCreateFeatureParams as ProductCreateFeatureParams,
+)
+from stripe.params._product_create_params import (
+ ProductCreateParams as ProductCreateParams,
+)
+from stripe.params._product_delete_feature_params import (
+ ProductDeleteFeatureParams as ProductDeleteFeatureParams,
+)
+from stripe.params._product_delete_params import (
+ ProductDeleteParams as ProductDeleteParams,
+)
+from stripe.params._product_feature_create_params import (
+ ProductFeatureCreateParams as ProductFeatureCreateParams,
+)
+from stripe.params._product_feature_delete_params import (
+ ProductFeatureDeleteParams as ProductFeatureDeleteParams,
+)
+from stripe.params._product_feature_list_params import (
+ ProductFeatureListParams as ProductFeatureListParams,
+)
+from stripe.params._product_feature_retrieve_params import (
+ ProductFeatureRetrieveParams as ProductFeatureRetrieveParams,
+)
+from stripe.params._product_list_features_params import (
+ ProductListFeaturesParams as ProductListFeaturesParams,
+)
+from stripe.params._product_list_params import (
+ ProductListParams as ProductListParams,
+)
+from stripe.params._product_modify_params import (
+ ProductModifyParams as ProductModifyParams,
+)
+from stripe.params._product_retrieve_feature_params import (
+ ProductRetrieveFeatureParams as ProductRetrieveFeatureParams,
+)
+from stripe.params._product_retrieve_params import (
+ ProductRetrieveParams as ProductRetrieveParams,
+)
+from stripe.params._product_search_params import (
+ ProductSearchParams as ProductSearchParams,
+)
+from stripe.params._product_update_params import (
+ ProductUpdateParams as ProductUpdateParams,
+)
+from stripe.params._promotion_code_create_params import (
+ PromotionCodeCreateParams as PromotionCodeCreateParams,
+)
+from stripe.params._promotion_code_list_params import (
+ PromotionCodeListParams as PromotionCodeListParams,
+)
+from stripe.params._promotion_code_modify_params import (
+ PromotionCodeModifyParams as PromotionCodeModifyParams,
+)
+from stripe.params._promotion_code_retrieve_params import (
+ PromotionCodeRetrieveParams as PromotionCodeRetrieveParams,
+)
+from stripe.params._promotion_code_update_params import (
+ PromotionCodeUpdateParams as PromotionCodeUpdateParams,
+)
+from stripe.params._quote_accept_params import (
+ QuoteAcceptParams as QuoteAcceptParams,
+)
+from stripe.params._quote_cancel_params import (
+ QuoteCancelParams as QuoteCancelParams,
+)
+from stripe.params._quote_computed_upfront_line_items_list_params import (
+ QuoteComputedUpfrontLineItemsListParams as QuoteComputedUpfrontLineItemsListParams,
+)
+from stripe.params._quote_create_params import (
+ QuoteCreateParams as QuoteCreateParams,
+)
+from stripe.params._quote_finalize_quote_params import (
+ QuoteFinalizeQuoteParams as QuoteFinalizeQuoteParams,
+)
+from stripe.params._quote_line_item_list_params import (
+ QuoteLineItemListParams as QuoteLineItemListParams,
+)
+from stripe.params._quote_list_computed_upfront_line_items_params import (
+ QuoteListComputedUpfrontLineItemsParams as QuoteListComputedUpfrontLineItemsParams,
+)
+from stripe.params._quote_list_line_items_params import (
+ QuoteListLineItemsParams as QuoteListLineItemsParams,
+)
+from stripe.params._quote_list_params import QuoteListParams as QuoteListParams
+from stripe.params._quote_modify_params import (
+ QuoteModifyParams as QuoteModifyParams,
+)
+from stripe.params._quote_pdf_params import QuotePdfParams as QuotePdfParams
+from stripe.params._quote_retrieve_params import (
+ QuoteRetrieveParams as QuoteRetrieveParams,
+)
+from stripe.params._quote_update_params import (
+ QuoteUpdateParams as QuoteUpdateParams,
+)
+from stripe.params._refund_cancel_params import (
+ RefundCancelParams as RefundCancelParams,
+)
+from stripe.params._refund_create_params import (
+ RefundCreateParams as RefundCreateParams,
+)
+from stripe.params._refund_expire_params import (
+ RefundExpireParams as RefundExpireParams,
+)
+from stripe.params._refund_list_params import (
+ RefundListParams as RefundListParams,
+)
+from stripe.params._refund_modify_params import (
+ RefundModifyParams as RefundModifyParams,
+)
+from stripe.params._refund_retrieve_params import (
+ RefundRetrieveParams as RefundRetrieveParams,
+)
+from stripe.params._refund_update_params import (
+ RefundUpdateParams as RefundUpdateParams,
+)
+from stripe.params._review_approve_params import (
+ ReviewApproveParams as ReviewApproveParams,
+)
+from stripe.params._review_list_params import (
+ ReviewListParams as ReviewListParams,
+)
+from stripe.params._review_retrieve_params import (
+ ReviewRetrieveParams as ReviewRetrieveParams,
+)
+from stripe.params._setup_attempt_list_params import (
+ SetupAttemptListParams as SetupAttemptListParams,
+)
+from stripe.params._setup_intent_cancel_params import (
+ SetupIntentCancelParams as SetupIntentCancelParams,
+)
+from stripe.params._setup_intent_confirm_params import (
+ SetupIntentConfirmParams as SetupIntentConfirmParams,
+)
+from stripe.params._setup_intent_create_params import (
+ SetupIntentCreateParams as SetupIntentCreateParams,
+)
+from stripe.params._setup_intent_list_params import (
+ SetupIntentListParams as SetupIntentListParams,
+)
+from stripe.params._setup_intent_modify_params import (
+ SetupIntentModifyParams as SetupIntentModifyParams,
+)
+from stripe.params._setup_intent_retrieve_params import (
+ SetupIntentRetrieveParams as SetupIntentRetrieveParams,
+)
+from stripe.params._setup_intent_update_params import (
+ SetupIntentUpdateParams as SetupIntentUpdateParams,
+)
+from stripe.params._setup_intent_verify_microdeposits_params import (
+ SetupIntentVerifyMicrodepositsParams as SetupIntentVerifyMicrodepositsParams,
+)
+from stripe.params._shipping_rate_create_params import (
+ ShippingRateCreateParams as ShippingRateCreateParams,
+)
+from stripe.params._shipping_rate_list_params import (
+ ShippingRateListParams as ShippingRateListParams,
+)
+from stripe.params._shipping_rate_modify_params import (
+ ShippingRateModifyParams as ShippingRateModifyParams,
+)
+from stripe.params._shipping_rate_retrieve_params import (
+ ShippingRateRetrieveParams as ShippingRateRetrieveParams,
+)
+from stripe.params._shipping_rate_update_params import (
+ ShippingRateUpdateParams as ShippingRateUpdateParams,
+)
+from stripe.params._source_create_params import (
+ SourceCreateParams as SourceCreateParams,
+)
+from stripe.params._source_detach_params import (
+ SourceDetachParams as SourceDetachParams,
+)
+from stripe.params._source_list_source_transactions_params import (
+ SourceListSourceTransactionsParams as SourceListSourceTransactionsParams,
+)
+from stripe.params._source_modify_params import (
+ SourceModifyParams as SourceModifyParams,
+)
+from stripe.params._source_retrieve_params import (
+ SourceRetrieveParams as SourceRetrieveParams,
+)
+from stripe.params._source_transaction_list_params import (
+ SourceTransactionListParams as SourceTransactionListParams,
+)
+from stripe.params._source_update_params import (
+ SourceUpdateParams as SourceUpdateParams,
+)
+from stripe.params._source_verify_params import (
+ SourceVerifyParams as SourceVerifyParams,
+)
+from stripe.params._subscription_cancel_params import (
+ SubscriptionCancelParams as SubscriptionCancelParams,
+)
+from stripe.params._subscription_create_params import (
+ SubscriptionCreateParams as SubscriptionCreateParams,
+)
+from stripe.params._subscription_delete_discount_params import (
+ SubscriptionDeleteDiscountParams as SubscriptionDeleteDiscountParams,
+)
+from stripe.params._subscription_item_create_params import (
+ SubscriptionItemCreateParams as SubscriptionItemCreateParams,
+)
+from stripe.params._subscription_item_delete_params import (
+ SubscriptionItemDeleteParams as SubscriptionItemDeleteParams,
+)
+from stripe.params._subscription_item_list_params import (
+ SubscriptionItemListParams as SubscriptionItemListParams,
+)
+from stripe.params._subscription_item_modify_params import (
+ SubscriptionItemModifyParams as SubscriptionItemModifyParams,
+)
+from stripe.params._subscription_item_retrieve_params import (
+ SubscriptionItemRetrieveParams as SubscriptionItemRetrieveParams,
+)
+from stripe.params._subscription_item_update_params import (
+ SubscriptionItemUpdateParams as SubscriptionItemUpdateParams,
+)
+from stripe.params._subscription_list_params import (
+ SubscriptionListParams as SubscriptionListParams,
+)
+from stripe.params._subscription_migrate_params import (
+ SubscriptionMigrateParams as SubscriptionMigrateParams,
+)
+from stripe.params._subscription_modify_params import (
+ SubscriptionModifyParams as SubscriptionModifyParams,
+)
+from stripe.params._subscription_resume_params import (
+ SubscriptionResumeParams as SubscriptionResumeParams,
+)
+from stripe.params._subscription_retrieve_params import (
+ SubscriptionRetrieveParams as SubscriptionRetrieveParams,
+)
+from stripe.params._subscription_schedule_cancel_params import (
+ SubscriptionScheduleCancelParams as SubscriptionScheduleCancelParams,
+)
+from stripe.params._subscription_schedule_create_params import (
+ SubscriptionScheduleCreateParams as SubscriptionScheduleCreateParams,
+)
+from stripe.params._subscription_schedule_list_params import (
+ SubscriptionScheduleListParams as SubscriptionScheduleListParams,
+)
+from stripe.params._subscription_schedule_modify_params import (
+ SubscriptionScheduleModifyParams as SubscriptionScheduleModifyParams,
+)
+from stripe.params._subscription_schedule_release_params import (
+ SubscriptionScheduleReleaseParams as SubscriptionScheduleReleaseParams,
+)
+from stripe.params._subscription_schedule_retrieve_params import (
+ SubscriptionScheduleRetrieveParams as SubscriptionScheduleRetrieveParams,
+)
+from stripe.params._subscription_schedule_update_params import (
+ SubscriptionScheduleUpdateParams as SubscriptionScheduleUpdateParams,
+)
+from stripe.params._subscription_search_params import (
+ SubscriptionSearchParams as SubscriptionSearchParams,
+)
+from stripe.params._subscription_update_params import (
+ SubscriptionUpdateParams as SubscriptionUpdateParams,
+)
+from stripe.params._tax_code_list_params import (
+ TaxCodeListParams as TaxCodeListParams,
+)
+from stripe.params._tax_code_retrieve_params import (
+ TaxCodeRetrieveParams as TaxCodeRetrieveParams,
+)
+from stripe.params._tax_id_create_params import (
+ TaxIdCreateParams as TaxIdCreateParams,
+)
+from stripe.params._tax_id_delete_params import (
+ TaxIdDeleteParams as TaxIdDeleteParams,
+)
+from stripe.params._tax_id_list_params import (
+ TaxIdListParams as TaxIdListParams,
+)
+from stripe.params._tax_id_retrieve_params import (
+ TaxIdRetrieveParams as TaxIdRetrieveParams,
+)
+from stripe.params._tax_rate_create_params import (
+ TaxRateCreateParams as TaxRateCreateParams,
+)
+from stripe.params._tax_rate_list_params import (
+ TaxRateListParams as TaxRateListParams,
+)
+from stripe.params._tax_rate_modify_params import (
+ TaxRateModifyParams as TaxRateModifyParams,
+)
+from stripe.params._tax_rate_retrieve_params import (
+ TaxRateRetrieveParams as TaxRateRetrieveParams,
+)
+from stripe.params._tax_rate_update_params import (
+ TaxRateUpdateParams as TaxRateUpdateParams,
+)
+from stripe.params._token_create_params import (
+ TokenCreateParams as TokenCreateParams,
+)
+from stripe.params._token_retrieve_params import (
+ TokenRetrieveParams as TokenRetrieveParams,
+)
+from stripe.params._topup_cancel_params import (
+ TopupCancelParams as TopupCancelParams,
+)
+from stripe.params._topup_create_params import (
+ TopupCreateParams as TopupCreateParams,
+)
+from stripe.params._topup_list_params import TopupListParams as TopupListParams
+from stripe.params._topup_modify_params import (
+ TopupModifyParams as TopupModifyParams,
+)
+from stripe.params._topup_retrieve_params import (
+ TopupRetrieveParams as TopupRetrieveParams,
+)
+from stripe.params._topup_update_params import (
+ TopupUpdateParams as TopupUpdateParams,
+)
+from stripe.params._transfer_create_params import (
+ TransferCreateParams as TransferCreateParams,
+)
+from stripe.params._transfer_create_reversal_params import (
+ TransferCreateReversalParams as TransferCreateReversalParams,
+)
+from stripe.params._transfer_list_params import (
+ TransferListParams as TransferListParams,
+)
+from stripe.params._transfer_list_reversals_params import (
+ TransferListReversalsParams as TransferListReversalsParams,
+)
+from stripe.params._transfer_modify_params import (
+ TransferModifyParams as TransferModifyParams,
+)
+from stripe.params._transfer_modify_reversal_params import (
+ TransferModifyReversalParams as TransferModifyReversalParams,
+)
+from stripe.params._transfer_retrieve_params import (
+ TransferRetrieveParams as TransferRetrieveParams,
+)
+from stripe.params._transfer_retrieve_reversal_params import (
+ TransferRetrieveReversalParams as TransferRetrieveReversalParams,
+)
+from stripe.params._transfer_reversal_create_params import (
+ TransferReversalCreateParams as TransferReversalCreateParams,
+)
+from stripe.params._transfer_reversal_list_params import (
+ TransferReversalListParams as TransferReversalListParams,
+)
+from stripe.params._transfer_reversal_retrieve_params import (
+ TransferReversalRetrieveParams as TransferReversalRetrieveParams,
+)
+from stripe.params._transfer_reversal_update_params import (
+ TransferReversalUpdateParams as TransferReversalUpdateParams,
+)
+from stripe.params._transfer_update_params import (
+ TransferUpdateParams as TransferUpdateParams,
+)
+from stripe.params._webhook_endpoint_create_params import (
+ WebhookEndpointCreateParams as WebhookEndpointCreateParams,
+)
+from stripe.params._webhook_endpoint_delete_params import (
+ WebhookEndpointDeleteParams as WebhookEndpointDeleteParams,
+)
+from stripe.params._webhook_endpoint_list_params import (
+ WebhookEndpointListParams as WebhookEndpointListParams,
+)
+from stripe.params._webhook_endpoint_modify_params import (
+ WebhookEndpointModifyParams as WebhookEndpointModifyParams,
+)
+from stripe.params._webhook_endpoint_retrieve_params import (
+ WebhookEndpointRetrieveParams as WebhookEndpointRetrieveParams,
+)
+from stripe.params._webhook_endpoint_update_params import (
+ WebhookEndpointUpdateParams as WebhookEndpointUpdateParams,
+)
diff --git a/stripe/params/_account_capability_list_params.py b/stripe/params/_account_capability_list_params.py
new file mode 100644
index 000000000..efeeb3cb1
--- /dev/null
+++ b/stripe/params/_account_capability_list_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AccountCapabilityListParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_account_capability_retrieve_params.py b/stripe/params/_account_capability_retrieve_params.py
new file mode 100644
index 000000000..c6ac87f36
--- /dev/null
+++ b/stripe/params/_account_capability_retrieve_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AccountCapabilityRetrieveParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_account_capability_update_params.py b/stripe/params/_account_capability_update_params.py
new file mode 100644
index 000000000..3c323d676
--- /dev/null
+++ b/stripe/params/_account_capability_update_params.py
@@ -0,0 +1,17 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AccountCapabilityUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ requested: NotRequired[bool]
+ """
+ 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. Some capabilities are permanent after they've been requested. Attempting to remove a permanent capability returns an error.
+ """
diff --git a/stripe/params/_account_create_external_account_params.py b/stripe/params/_account_create_external_account_params.py
new file mode 100644
index 000000000..82ccbfb58
--- /dev/null
+++ b/stripe/params/_account_create_external_account_params.py
@@ -0,0 +1,83 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List, Union
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AccountCreateExternalAccountParams(RequestOptions):
+ default_for_currency: NotRequired[bool]
+ """
+ When set to true, or if this is the first external account added in this currency, this account becomes the default external account for its currency.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ external_account: Union[
+ str,
+ "AccountCreateExternalAccountParamsCard",
+ "AccountCreateExternalAccountParamsBankAccount",
+ "AccountCreateExternalAccountParamsCardToken",
+ ]
+ """
+ A token, like the ones returned by [Stripe.js](https://stripe.com/docs/js) or a dictionary containing a user's external account details (with the options shown below). Please refer to full [documentation](https://stripe.com/docs/api/external_accounts) instead.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+
+
+class AccountCreateExternalAccountParamsCard(TypedDict):
+ object: Literal["card"]
+ address_city: NotRequired[str]
+ address_country: NotRequired[str]
+ address_line1: NotRequired[str]
+ address_line2: NotRequired[str]
+ address_state: NotRequired[str]
+ address_zip: NotRequired[str]
+ currency: NotRequired[str]
+ cvc: NotRequired[str]
+ exp_month: int
+ exp_year: int
+ name: NotRequired[str]
+ number: str
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
+ """
+
+
+class AccountCreateExternalAccountParamsBankAccount(TypedDict):
+ object: Literal["bank_account"]
+ account_holder_name: NotRequired[str]
+ """
+ The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object.
+ """
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
+ """
+ account_number: str
+ """
+ The account number for the bank account, in string form. Must be a checking account.
+ """
+ country: str
+ """
+ The country in which the bank account is located.
+ """
+ currency: NotRequired[str]
+ """
+ The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts)
+ """
+ routing_number: NotRequired[str]
+ """
+ The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
+ """
+
+
+class AccountCreateExternalAccountParamsCardToken(TypedDict):
+ object: Literal["card"]
+ currency: NotRequired[str]
+ token: str
diff --git a/stripe/params/_account_create_login_link_params.py b/stripe/params/_account_create_login_link_params.py
new file mode 100644
index 000000000..a9b2f6282
--- /dev/null
+++ b/stripe/params/_account_create_login_link_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AccountCreateLoginLinkParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_account_create_params.py b/stripe/params/_account_create_params.py
new file mode 100644
index 000000000..607e900f4
--- /dev/null
+++ b/stripe/params/_account_create_params.py
@@ -0,0 +1,1959 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AccountCreateParams(RequestOptions):
+ account_token: NotRequired[str]
+ """
+ An [account token](https://stripe.com/docs/api#create_account_token), used to securely provide details to the account.
+ """
+ business_profile: NotRequired["AccountCreateParamsBusinessProfile"]
+ """
+ Business information about the account.
+ """
+ business_type: NotRequired[
+ Literal["company", "government_entity", "individual", "non_profit"]
+ ]
+ """
+ The business type. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
+ """
+ capabilities: NotRequired["AccountCreateParamsCapabilities"]
+ """
+ Each key of the dictionary represents a capability, and each capability
+ maps to its settings (for example, whether it has been requested or not). Each
+ capability is inactive until you have provided its specific
+ requirements and Stripe has verified them. An account might have some
+ of its requested capabilities be active and some be inactive.
+
+ Required when [account.controller.stripe_dashboard.type](https://docs.stripe.com/api/accounts/create#create_account-controller-dashboard-type)
+ is `none`, which includes Custom accounts.
+ """
+ company: NotRequired["AccountCreateParamsCompany"]
+ """
+ Information about the company or business. This field is available for any `business_type`. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
+ """
+ controller: NotRequired["AccountCreateParamsController"]
+ """
+ A hash of configuration describing the account controller's attributes.
+ """
+ country: NotRequired[str]
+ """
+ The country in which the account holder resides, or in which the business is legally established. This should be an ISO 3166-1 alpha-2 country code. For example, if you are in the United States and the business for which you're creating an account is legally represented in Canada, you would use `CA` as the country for the account being created. Available countries include [Stripe's global markets](https://stripe.com/global) as well as countries where [cross-border payouts](https://stripe.com/docs/connect/cross-border-payouts) are supported.
+ """
+ default_currency: NotRequired[str]
+ """
+ Three-letter ISO currency code representing the default currency for the account. This must be a currency that [Stripe supports in the account's country](https://docs.stripe.com/payouts).
+ """
+ documents: NotRequired["AccountCreateParamsDocuments"]
+ """
+ Documents that may be submitted to satisfy various informational requests.
+ """
+ email: NotRequired[str]
+ """
+ The email address of the account holder. This is only to make the account easier to identify to you. If [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, Stripe doesn't email the account without your consent.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ external_account: NotRequired[
+ "str|AccountCreateParamsBankAccount|AccountCreateParamsCard|AccountCreateParamsCardToken"
+ ]
+ """
+ A card or bank account to attach to the account for receiving [payouts](https://docs.stripe.com/connect/bank-debit-card-payouts) (you won't be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](https://docs.stripe.com/js), or a dictionary, as documented in the `external_account` parameter for [bank account](https://docs.stripe.com/api#account_create_bank_account) creation.
+
+ By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the [bank account](https://docs.stripe.com/api#account_create_bank_account) or [card creation](https://docs.stripe.com/api#account_create_card) APIs. After you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
+ """
+ groups: NotRequired["AccountCreateParamsGroups"]
+ """
+ A hash of account group type to tokens. These are account groups this account should be added to.
+ """
+ individual: NotRequired["AccountCreateParamsIndividual"]
+ """
+ Information about the person represented by the account. This field is null unless `business_type` is set to `individual`. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ settings: NotRequired["AccountCreateParamsSettings"]
+ """
+ Options for customizing how the account functions within Stripe.
+ """
+ tos_acceptance: NotRequired["AccountCreateParamsTosAcceptance"]
+ """
+ Details on the account's acceptance of the [Stripe Services Agreement](https://docs.stripe.com/connect/updating-accounts#tos-acceptance). This property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts. This property defaults to a `full` service agreement when empty.
+ """
+ type: NotRequired[Literal["custom", "express", "standard"]]
+ """
+ The type of Stripe account to create. May be one of `custom`, `express` or `standard`.
+ """
+
+
+class AccountCreateParamsBusinessProfile(TypedDict):
+ annual_revenue: NotRequired[
+ "AccountCreateParamsBusinessProfileAnnualRevenue"
+ ]
+ """
+ The applicant's gross annual revenue for its preceding fiscal year.
+ """
+ estimated_worker_count: NotRequired[int]
+ """
+ An estimated upper bound of employees, contractors, vendors, etc. currently working for the business.
+ """
+ mcc: NotRequired[str]
+ """
+ [The merchant category code for the account](https://docs.stripe.com/connect/setting-mcc). MCCs are used to classify businesses based on the goods or services they provide.
+ """
+ minority_owned_business_designation: NotRequired[
+ List[
+ Literal[
+ "lgbtqi_owned_business",
+ "minority_owned_business",
+ "none_of_these_apply",
+ "prefer_not_to_answer",
+ "women_owned_business",
+ ]
+ ]
+ ]
+ """
+ Whether the business is a minority-owned, women-owned, and/or LGBTQI+ -owned business.
+ """
+ monthly_estimated_revenue: NotRequired[
+ "AccountCreateParamsBusinessProfileMonthlyEstimatedRevenue"
+ ]
+ """
+ An estimate of the monthly revenue of the business. Only accepted for accounts in Brazil and India.
+ """
+ name: NotRequired[str]
+ """
+ The customer-facing business name.
+ """
+ product_description: NotRequired[str]
+ """
+ Internal-only description of the product sold by, or service provided by, the business. Used by Stripe for risk and underwriting purposes.
+ """
+ support_address: NotRequired[
+ "AccountCreateParamsBusinessProfileSupportAddress"
+ ]
+ """
+ A publicly available mailing address for sending support issues to.
+ """
+ support_email: NotRequired[str]
+ """
+ A publicly available email address for sending support issues to.
+ """
+ support_phone: NotRequired[str]
+ """
+ A publicly available phone number to call with support issues.
+ """
+ support_url: NotRequired["Literal['']|str"]
+ """
+ A publicly available website for handling support issues.
+ """
+ url: NotRequired[str]
+ """
+ The business's publicly available website.
+ """
+
+
+class AccountCreateParamsBusinessProfileAnnualRevenue(TypedDict):
+ amount: int
+ """
+ A non-negative integer representing the amount in the [smallest currency unit](https://docs.stripe.com/currencies#zero-decimal).
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ fiscal_year_end: str
+ """
+ The close-out date of the preceding fiscal year in ISO 8601 format. E.g. 2023-12-31 for the 31st of December, 2023.
+ """
+
+
+class AccountCreateParamsBusinessProfileMonthlyEstimatedRevenue(TypedDict):
+ amount: int
+ """
+ A non-negative integer representing how much to charge in the [smallest currency unit](https://docs.stripe.com/currencies#zero-decimal).
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+
+
+class AccountCreateParamsBusinessProfileSupportAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountCreateParamsCapabilities(TypedDict):
+ acss_debit_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesAcssDebitPayments"
+ ]
+ """
+ The acss_debit_payments capability.
+ """
+ affirm_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesAffirmPayments"
+ ]
+ """
+ The affirm_payments capability.
+ """
+ afterpay_clearpay_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesAfterpayClearpayPayments"
+ ]
+ """
+ The afterpay_clearpay_payments capability.
+ """
+ alma_payments: NotRequired["AccountCreateParamsCapabilitiesAlmaPayments"]
+ """
+ The alma_payments capability.
+ """
+ amazon_pay_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesAmazonPayPayments"
+ ]
+ """
+ The amazon_pay_payments capability.
+ """
+ au_becs_debit_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesAuBecsDebitPayments"
+ ]
+ """
+ The au_becs_debit_payments capability.
+ """
+ bacs_debit_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesBacsDebitPayments"
+ ]
+ """
+ The bacs_debit_payments capability.
+ """
+ bancontact_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesBancontactPayments"
+ ]
+ """
+ The bancontact_payments capability.
+ """
+ bank_transfer_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesBankTransferPayments"
+ ]
+ """
+ The bank_transfer_payments capability.
+ """
+ billie_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesBilliePayments"
+ ]
+ """
+ The billie_payments capability.
+ """
+ blik_payments: NotRequired["AccountCreateParamsCapabilitiesBlikPayments"]
+ """
+ The blik_payments capability.
+ """
+ boleto_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesBoletoPayments"
+ ]
+ """
+ The boleto_payments capability.
+ """
+ card_issuing: NotRequired["AccountCreateParamsCapabilitiesCardIssuing"]
+ """
+ The card_issuing capability.
+ """
+ card_payments: NotRequired["AccountCreateParamsCapabilitiesCardPayments"]
+ """
+ The card_payments capability.
+ """
+ cartes_bancaires_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesCartesBancairesPayments"
+ ]
+ """
+ The cartes_bancaires_payments capability.
+ """
+ cashapp_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesCashappPayments"
+ ]
+ """
+ The cashapp_payments capability.
+ """
+ crypto_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesCryptoPayments"
+ ]
+ """
+ The crypto_payments capability.
+ """
+ eps_payments: NotRequired["AccountCreateParamsCapabilitiesEpsPayments"]
+ """
+ The eps_payments capability.
+ """
+ fpx_payments: NotRequired["AccountCreateParamsCapabilitiesFpxPayments"]
+ """
+ The fpx_payments capability.
+ """
+ gb_bank_transfer_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesGbBankTransferPayments"
+ ]
+ """
+ The gb_bank_transfer_payments capability.
+ """
+ giropay_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesGiropayPayments"
+ ]
+ """
+ The giropay_payments capability.
+ """
+ grabpay_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesGrabpayPayments"
+ ]
+ """
+ The grabpay_payments capability.
+ """
+ ideal_payments: NotRequired["AccountCreateParamsCapabilitiesIdealPayments"]
+ """
+ The ideal_payments capability.
+ """
+ india_international_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesIndiaInternationalPayments"
+ ]
+ """
+ The india_international_payments capability.
+ """
+ jcb_payments: NotRequired["AccountCreateParamsCapabilitiesJcbPayments"]
+ """
+ The jcb_payments capability.
+ """
+ jp_bank_transfer_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesJpBankTransferPayments"
+ ]
+ """
+ The jp_bank_transfer_payments capability.
+ """
+ kakao_pay_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesKakaoPayPayments"
+ ]
+ """
+ The kakao_pay_payments capability.
+ """
+ klarna_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesKlarnaPayments"
+ ]
+ """
+ The klarna_payments capability.
+ """
+ konbini_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesKonbiniPayments"
+ ]
+ """
+ The konbini_payments capability.
+ """
+ kr_card_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesKrCardPayments"
+ ]
+ """
+ The kr_card_payments capability.
+ """
+ legacy_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesLegacyPayments"
+ ]
+ """
+ The legacy_payments capability.
+ """
+ link_payments: NotRequired["AccountCreateParamsCapabilitiesLinkPayments"]
+ """
+ The link_payments capability.
+ """
+ mb_way_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesMbWayPayments"
+ ]
+ """
+ The mb_way_payments capability.
+ """
+ mobilepay_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesMobilepayPayments"
+ ]
+ """
+ The mobilepay_payments capability.
+ """
+ multibanco_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesMultibancoPayments"
+ ]
+ """
+ The multibanco_payments capability.
+ """
+ mx_bank_transfer_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesMxBankTransferPayments"
+ ]
+ """
+ The mx_bank_transfer_payments capability.
+ """
+ naver_pay_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesNaverPayPayments"
+ ]
+ """
+ The naver_pay_payments capability.
+ """
+ nz_bank_account_becs_debit_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesNzBankAccountBecsDebitPayments"
+ ]
+ """
+ The nz_bank_account_becs_debit_payments capability.
+ """
+ oxxo_payments: NotRequired["AccountCreateParamsCapabilitiesOxxoPayments"]
+ """
+ The oxxo_payments capability.
+ """
+ p24_payments: NotRequired["AccountCreateParamsCapabilitiesP24Payments"]
+ """
+ The p24_payments capability.
+ """
+ pay_by_bank_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesPayByBankPayments"
+ ]
+ """
+ The pay_by_bank_payments capability.
+ """
+ payco_payments: NotRequired["AccountCreateParamsCapabilitiesPaycoPayments"]
+ """
+ The payco_payments capability.
+ """
+ paynow_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesPaynowPayments"
+ ]
+ """
+ The paynow_payments capability.
+ """
+ pix_payments: NotRequired["AccountCreateParamsCapabilitiesPixPayments"]
+ """
+ The pix_payments capability.
+ """
+ promptpay_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesPromptpayPayments"
+ ]
+ """
+ The promptpay_payments capability.
+ """
+ revolut_pay_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesRevolutPayPayments"
+ ]
+ """
+ The revolut_pay_payments capability.
+ """
+ samsung_pay_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesSamsungPayPayments"
+ ]
+ """
+ The samsung_pay_payments capability.
+ """
+ satispay_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesSatispayPayments"
+ ]
+ """
+ The satispay_payments capability.
+ """
+ sepa_bank_transfer_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesSepaBankTransferPayments"
+ ]
+ """
+ The sepa_bank_transfer_payments capability.
+ """
+ sepa_debit_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesSepaDebitPayments"
+ ]
+ """
+ The sepa_debit_payments capability.
+ """
+ sofort_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesSofortPayments"
+ ]
+ """
+ The sofort_payments capability.
+ """
+ swish_payments: NotRequired["AccountCreateParamsCapabilitiesSwishPayments"]
+ """
+ The swish_payments capability.
+ """
+ tax_reporting_us_1099_k: NotRequired[
+ "AccountCreateParamsCapabilitiesTaxReportingUs1099K"
+ ]
+ """
+ The tax_reporting_us_1099_k capability.
+ """
+ tax_reporting_us_1099_misc: NotRequired[
+ "AccountCreateParamsCapabilitiesTaxReportingUs1099Misc"
+ ]
+ """
+ The tax_reporting_us_1099_misc capability.
+ """
+ transfers: NotRequired["AccountCreateParamsCapabilitiesTransfers"]
+ """
+ The transfers capability.
+ """
+ treasury: NotRequired["AccountCreateParamsCapabilitiesTreasury"]
+ """
+ The treasury capability.
+ """
+ twint_payments: NotRequired["AccountCreateParamsCapabilitiesTwintPayments"]
+ """
+ The twint_payments capability.
+ """
+ us_bank_account_ach_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesUsBankAccountAchPayments"
+ ]
+ """
+ The us_bank_account_ach_payments capability.
+ """
+ us_bank_transfer_payments: NotRequired[
+ "AccountCreateParamsCapabilitiesUsBankTransferPayments"
+ ]
+ """
+ The us_bank_transfer_payments capability.
+ """
+ zip_payments: NotRequired["AccountCreateParamsCapabilitiesZipPayments"]
+ """
+ The zip_payments capability.
+ """
+
+
+class AccountCreateParamsCapabilitiesAcssDebitPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesAffirmPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesAfterpayClearpayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesAlmaPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesAmazonPayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesAuBecsDebitPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesBacsDebitPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesBancontactPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesBankTransferPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesBilliePayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesBlikPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesBoletoPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesCardIssuing(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesCardPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesCartesBancairesPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesCashappPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesCryptoPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesEpsPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesFpxPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesGbBankTransferPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesGiropayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesGrabpayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesIdealPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesIndiaInternationalPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesJcbPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesJpBankTransferPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesKakaoPayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesKlarnaPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesKonbiniPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesKrCardPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesLegacyPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesLinkPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesMbWayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesMobilepayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesMultibancoPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesMxBankTransferPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesNaverPayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesNzBankAccountBecsDebitPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesOxxoPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesP24Payments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesPayByBankPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesPaycoPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesPaynowPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesPixPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesPromptpayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesRevolutPayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesSamsungPayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesSatispayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesSepaBankTransferPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesSepaDebitPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesSofortPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesSwishPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesTaxReportingUs1099K(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesTaxReportingUs1099Misc(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesTransfers(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesTreasury(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesTwintPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesUsBankAccountAchPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesUsBankTransferPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCapabilitiesZipPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountCreateParamsCompany(TypedDict):
+ address: NotRequired["AccountCreateParamsCompanyAddress"]
+ """
+ The company's primary address.
+ """
+ address_kana: NotRequired["AccountCreateParamsCompanyAddressKana"]
+ """
+ The Kana variation of the company's primary address (Japan only).
+ """
+ address_kanji: NotRequired["AccountCreateParamsCompanyAddressKanji"]
+ """
+ The Kanji variation of the company's primary address (Japan only).
+ """
+ directors_provided: NotRequired[bool]
+ """
+ Whether the company's directors have been provided. Set this Boolean to `true` after creating all the company's directors with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.director` requirement. This value is not automatically set to `true` after creating directors, so it needs to be updated to indicate all directors have been provided.
+ """
+ directorship_declaration: NotRequired[
+ "AccountCreateParamsCompanyDirectorshipDeclaration"
+ ]
+ """
+ This hash is used to attest that the directors information provided to Stripe is both current and correct.
+ """
+ executives_provided: NotRequired[bool]
+ """
+ Whether the company's executives have been provided. Set this Boolean to `true` after creating all the company's executives with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.executive` requirement.
+ """
+ export_license_id: NotRequired[str]
+ """
+ The export license ID number of the company, also referred as Import Export Code (India only).
+ """
+ export_purpose_code: NotRequired[str]
+ """
+ The purpose code to use for export transactions (India only).
+ """
+ name: NotRequired[str]
+ """
+ The company's legal name.
+ """
+ name_kana: NotRequired[str]
+ """
+ The Kana variation of the company's legal name (Japan only).
+ """
+ name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the company's legal name (Japan only).
+ """
+ owners_provided: NotRequired[bool]
+ """
+ Whether the company's owners have been provided. Set this Boolean to `true` after creating all the company's owners with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.owner` requirement.
+ """
+ ownership_declaration: NotRequired[
+ "AccountCreateParamsCompanyOwnershipDeclaration"
+ ]
+ """
+ This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
+ """
+ ownership_exemption_reason: NotRequired[
+ "Literal['']|Literal['qualified_entity_exceeds_ownership_threshold', 'qualifies_as_financial_institution']"
+ ]
+ """
+ This value is used to determine if a business is exempt from providing ultimate beneficial owners. See [this support article](https://support.stripe.com/questions/exemption-from-providing-ownership-details) and [changelog](https://docs.stripe.com/changelog/acacia/2025-01-27/ownership-exemption-reason-accounts-api) for more details.
+ """
+ phone: NotRequired[str]
+ """
+ The company's phone number (used for verification).
+ """
+ registration_date: NotRequired[
+ "Literal['']|AccountCreateParamsCompanyRegistrationDate"
+ ]
+ """
+ When the business was incorporated or registered.
+ """
+ registration_number: NotRequired[str]
+ """
+ The identification number given to a company when it is registered or incorporated, if distinct from the identification number used for filing taxes. (Examples are the CIN for companies and LLP IN for partnerships in India, and the Company Registration Number in Hong Kong).
+ """
+ structure: NotRequired[
+ "Literal['']|Literal['free_zone_establishment', 'free_zone_llc', 'government_instrumentality', 'governmental_unit', 'incorporated_non_profit', 'incorporated_partnership', 'limited_liability_partnership', 'llc', 'multi_member_llc', 'private_company', 'private_corporation', 'private_partnership', 'public_company', 'public_corporation', 'public_partnership', 'registered_charity', 'single_member_llc', 'sole_establishment', 'sole_proprietorship', 'tax_exempt_government_instrumentality', 'unincorporated_association', 'unincorporated_non_profit', 'unincorporated_partnership']"
+ ]
+ """
+ The category identifying the legal structure of the company or legal entity. See [Business structure](https://docs.stripe.com/connect/identity-verification#business-structure) for more details. Pass an empty string to unset this value.
+ """
+ tax_id: NotRequired[str]
+ """
+ The business ID number of the company, as appropriate for the company's country. (Examples are an Employer ID Number in the U.S., a Business Number in Canada, or a Company Number in the UK.)
+ """
+ tax_id_registrar: NotRequired[str]
+ """
+ The jurisdiction in which the `tax_id` is registered (Germany-based companies only).
+ """
+ vat_id: NotRequired[str]
+ """
+ The VAT number of the company.
+ """
+ verification: NotRequired["AccountCreateParamsCompanyVerification"]
+ """
+ Information on the verification state of the company.
+ """
+
+
+class AccountCreateParamsCompanyAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountCreateParamsCompanyAddressKana(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountCreateParamsCompanyAddressKanji(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountCreateParamsCompanyDirectorshipDeclaration(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the directorship declaration attestation was made.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the directorship declaration attestation was made.
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the directorship declaration attestation was made.
+ """
+
+
+class AccountCreateParamsCompanyOwnershipDeclaration(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the beneficial owner attestation was made.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the beneficial owner attestation was made.
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the beneficial owner attestation was made.
+ """
+
+
+class AccountCreateParamsCompanyRegistrationDate(TypedDict):
+ day: int
+ """
+ The day of registration, between 1 and 31.
+ """
+ month: int
+ """
+ The month of registration, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of registration.
+ """
+
+
+class AccountCreateParamsCompanyVerification(TypedDict):
+ document: NotRequired["AccountCreateParamsCompanyVerificationDocument"]
+ """
+ A document verifying the business.
+ """
+
+
+class AccountCreateParamsCompanyVerificationDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+
+
+class AccountCreateParamsController(TypedDict):
+ fees: NotRequired["AccountCreateParamsControllerFees"]
+ """
+ A hash of configuration for who pays Stripe fees for product usage on this account.
+ """
+ losses: NotRequired["AccountCreateParamsControllerLosses"]
+ """
+ A hash of configuration for products that have negative balance liability, and whether Stripe or a Connect application is responsible for them.
+ """
+ requirement_collection: NotRequired[Literal["application", "stripe"]]
+ """
+ A value indicating responsibility for collecting updated information when requirements on the account are due or change. Defaults to `stripe`.
+ """
+ stripe_dashboard: NotRequired[
+ "AccountCreateParamsControllerStripeDashboard"
+ ]
+ """
+ A hash of configuration for Stripe-hosted dashboards.
+ """
+
+
+class AccountCreateParamsControllerFees(TypedDict):
+ payer: NotRequired[Literal["account", "application"]]
+ """
+ A value indicating the responsible payer of Stripe fees on this account. Defaults to `account`. Learn more about [fee behavior on connected accounts](https://docs.stripe.com/connect/direct-charges-fee-payer-behavior).
+ """
+
+
+class AccountCreateParamsControllerLosses(TypedDict):
+ payments: NotRequired[Literal["application", "stripe"]]
+ """
+ A value indicating who is liable when this account can't pay back negative balances resulting from payments. Defaults to `stripe`.
+ """
+
+
+class AccountCreateParamsControllerStripeDashboard(TypedDict):
+ type: NotRequired[Literal["express", "full", "none"]]
+ """
+ Whether this account should have access to the full Stripe Dashboard (`full`), to the Express Dashboard (`express`), or to no Stripe-hosted dashboard (`none`). Defaults to `full`.
+ """
+
+
+class AccountCreateParamsDocuments(TypedDict):
+ bank_account_ownership_verification: NotRequired[
+ "AccountCreateParamsDocumentsBankAccountOwnershipVerification"
+ ]
+ """
+ One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the account's primary active bank account that displays the last 4 digits of the account number, either a statement or a check.
+ """
+ company_license: NotRequired["AccountCreateParamsDocumentsCompanyLicense"]
+ """
+ One or more documents that demonstrate proof of a company's license to operate.
+ """
+ company_memorandum_of_association: NotRequired[
+ "AccountCreateParamsDocumentsCompanyMemorandumOfAssociation"
+ ]
+ """
+ One or more documents showing the company's Memorandum of Association.
+ """
+ company_ministerial_decree: NotRequired[
+ "AccountCreateParamsDocumentsCompanyMinisterialDecree"
+ ]
+ """
+ (Certain countries only) One or more documents showing the ministerial decree legalizing the company's establishment.
+ """
+ company_registration_verification: NotRequired[
+ "AccountCreateParamsDocumentsCompanyRegistrationVerification"
+ ]
+ """
+ One or more documents that demonstrate proof of a company's registration with the appropriate local authorities.
+ """
+ company_tax_id_verification: NotRequired[
+ "AccountCreateParamsDocumentsCompanyTaxIdVerification"
+ ]
+ """
+ One or more documents that demonstrate proof of a company's tax ID.
+ """
+ proof_of_address: NotRequired["AccountCreateParamsDocumentsProofOfAddress"]
+ """
+ One or more documents that demonstrate proof of address.
+ """
+ proof_of_registration: NotRequired[
+ "AccountCreateParamsDocumentsProofOfRegistration"
+ ]
+ """
+ One or more documents showing the company's proof of registration with the national business registry.
+ """
+ proof_of_ultimate_beneficial_ownership: NotRequired[
+ "AccountCreateParamsDocumentsProofOfUltimateBeneficialOwnership"
+ ]
+ """
+ One or more documents that demonstrate proof of ultimate beneficial ownership.
+ """
+
+
+class AccountCreateParamsDocumentsBankAccountOwnershipVerification(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountCreateParamsDocumentsCompanyLicense(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountCreateParamsDocumentsCompanyMemorandumOfAssociation(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountCreateParamsDocumentsCompanyMinisterialDecree(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountCreateParamsDocumentsCompanyRegistrationVerification(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountCreateParamsDocumentsCompanyTaxIdVerification(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountCreateParamsDocumentsProofOfAddress(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountCreateParamsDocumentsProofOfRegistration(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountCreateParamsDocumentsProofOfUltimateBeneficialOwnership(
+ TypedDict
+):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountCreateParamsBankAccount(TypedDict):
+ object: Literal["bank_account"]
+ account_holder_name: NotRequired[str]
+ """
+ The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object.
+ """
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
+ """
+ account_number: str
+ """
+ The account number for the bank account, in string form. Must be a checking account.
+ """
+ country: str
+ """
+ The country in which the bank account is located.
+ """
+ currency: NotRequired[str]
+ """
+ The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts)
+ """
+ routing_number: NotRequired[str]
+ """
+ The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
+ """
+
+
+class AccountCreateParamsCard(TypedDict):
+ object: Literal["card"]
+ address_city: NotRequired[str]
+ address_country: NotRequired[str]
+ address_line1: NotRequired[str]
+ address_line2: NotRequired[str]
+ address_state: NotRequired[str]
+ address_zip: NotRequired[str]
+ currency: NotRequired[str]
+ cvc: NotRequired[str]
+ exp_month: int
+ exp_year: int
+ name: NotRequired[str]
+ number: str
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
+ """
+ default_for_currency: NotRequired[bool]
+
+
+class AccountCreateParamsCardToken(TypedDict):
+ object: Literal["card"]
+ currency: NotRequired[str]
+ token: str
+
+
+class AccountCreateParamsGroups(TypedDict):
+ payments_pricing: NotRequired["Literal['']|str"]
+ """
+ The group the account is in to determine their payments pricing, and null if the account is on customized pricing. [See the Platform pricing tool documentation](https://stripe.com/docs/connect/platform-pricing-tools) for details.
+ """
+
+
+class AccountCreateParamsIndividual(TypedDict):
+ address: NotRequired["AccountCreateParamsIndividualAddress"]
+ """
+ The individual's primary address.
+ """
+ address_kana: NotRequired["AccountCreateParamsIndividualAddressKana"]
+ """
+ The Kana variation of the individual's primary address (Japan only).
+ """
+ address_kanji: NotRequired["AccountCreateParamsIndividualAddressKanji"]
+ """
+ The Kanji variation of the individual's primary address (Japan only).
+ """
+ dob: NotRequired["Literal['']|AccountCreateParamsIndividualDob"]
+ """
+ The individual's date of birth.
+ """
+ email: NotRequired[str]
+ """
+ The individual's email address.
+ """
+ first_name: NotRequired[str]
+ """
+ The individual's first name.
+ """
+ first_name_kana: NotRequired[str]
+ """
+ The Kana variation of the individual's first name (Japan only).
+ """
+ first_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the individual's first name (Japan only).
+ """
+ full_name_aliases: NotRequired["Literal['']|List[str]"]
+ """
+ A list of alternate names or aliases that the individual is known by.
+ """
+ gender: NotRequired[str]
+ """
+ The individual's gender
+ """
+ id_number: NotRequired[str]
+ """
+ The government-issued ID number of the individual, as appropriate for the representative's country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in Canada). Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ id_number_secondary: NotRequired[str]
+ """
+ The government-issued secondary ID number of the individual, as appropriate for the representative's country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ last_name: NotRequired[str]
+ """
+ The individual's last name.
+ """
+ last_name_kana: NotRequired[str]
+ """
+ The Kana variation of the individual's last name (Japan only).
+ """
+ last_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the individual's last name (Japan only).
+ """
+ maiden_name: NotRequired[str]
+ """
+ The individual's maiden name.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ phone: NotRequired[str]
+ """
+ The individual's phone number.
+ """
+ political_exposure: NotRequired[Literal["existing", "none"]]
+ """
+ Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
+ """
+ registered_address: NotRequired[
+ "AccountCreateParamsIndividualRegisteredAddress"
+ ]
+ """
+ The individual's registered address.
+ """
+ relationship: NotRequired["AccountCreateParamsIndividualRelationship"]
+ """
+ Describes the person's relationship to the account.
+ """
+ ssn_last_4: NotRequired[str]
+ """
+ The last four digits of the individual's Social Security Number (U.S. only).
+ """
+ verification: NotRequired["AccountCreateParamsIndividualVerification"]
+ """
+ The individual's verification document information.
+ """
+
+
+class AccountCreateParamsIndividualAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountCreateParamsIndividualAddressKana(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountCreateParamsIndividualAddressKanji(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountCreateParamsIndividualDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class AccountCreateParamsIndividualRegisteredAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountCreateParamsIndividualRelationship(TypedDict):
+ director: NotRequired[bool]
+ """
+ Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
+ """
+ executive: NotRequired[bool]
+ """
+ Whether the person has significant responsibility to control, manage, or direct the organization.
+ """
+ owner: NotRequired[bool]
+ """
+ Whether the person is an owner of the account's legal entity.
+ """
+ percent_ownership: NotRequired["Literal['']|float"]
+ """
+ The percent owned by the person of the account's legal entity.
+ """
+ title: NotRequired[str]
+ """
+ The person's title (e.g., CEO, Support Engineer).
+ """
+
+
+class AccountCreateParamsIndividualVerification(TypedDict):
+ additional_document: NotRequired[
+ "AccountCreateParamsIndividualVerificationAdditionalDocument"
+ ]
+ """
+ A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
+ """
+ document: NotRequired["AccountCreateParamsIndividualVerificationDocument"]
+ """
+ An identifying document, either a passport or local ID card.
+ """
+
+
+class AccountCreateParamsIndividualVerificationAdditionalDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+
+
+class AccountCreateParamsIndividualVerificationDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+
+
+class AccountCreateParamsSettings(TypedDict):
+ bacs_debit_payments: NotRequired[
+ "AccountCreateParamsSettingsBacsDebitPayments"
+ ]
+ """
+ Settings specific to Bacs Direct Debit.
+ """
+ branding: NotRequired["AccountCreateParamsSettingsBranding"]
+ """
+ Settings used to apply the account's branding to email receipts, invoices, Checkout, and other products.
+ """
+ card_issuing: NotRequired["AccountCreateParamsSettingsCardIssuing"]
+ """
+ Settings specific to the account's use of the Card Issuing product.
+ """
+ card_payments: NotRequired["AccountCreateParamsSettingsCardPayments"]
+ """
+ Settings specific to card charging on the account.
+ """
+ invoices: NotRequired["AccountCreateParamsSettingsInvoices"]
+ """
+ Settings specific to the account's use of Invoices.
+ """
+ payments: NotRequired["AccountCreateParamsSettingsPayments"]
+ """
+ Settings that apply across payment methods for charging on the account.
+ """
+ payouts: NotRequired["AccountCreateParamsSettingsPayouts"]
+ """
+ Settings specific to the account's payouts.
+ """
+ treasury: NotRequired["AccountCreateParamsSettingsTreasury"]
+ """
+ Settings specific to the account's Treasury FinancialAccounts.
+ """
+
+
+class AccountCreateParamsSettingsBacsDebitPayments(TypedDict):
+ display_name: NotRequired[str]
+ """
+ The Bacs Direct Debit Display Name for this account. For payments made with Bacs Direct Debit, this name appears on the mandate as the statement descriptor. Mobile banking apps display it as the name of the business. To use custom branding, set the Bacs Direct Debit Display Name during or right after creation. Custom branding incurs an additional monthly fee for the platform. If you don't set the display name before requesting Bacs capability, it's automatically set as "Stripe" and the account is onboarded to Stripe branding, which is free.
+ """
+
+
+class AccountCreateParamsSettingsBranding(TypedDict):
+ icon: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) An icon for the account. Must be square and at least 128px x 128px.
+ """
+ logo: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A logo for the account that will be used in Checkout instead of the icon and without the account's name next to it if provided. Must be at least 128px x 128px.
+ """
+ primary_color: NotRequired[str]
+ """
+ A CSS hex color value representing the primary branding color for this account.
+ """
+ secondary_color: NotRequired[str]
+ """
+ A CSS hex color value representing the secondary branding color for this account.
+ """
+
+
+class AccountCreateParamsSettingsCardIssuing(TypedDict):
+ tos_acceptance: NotRequired[
+ "AccountCreateParamsSettingsCardIssuingTosAcceptance"
+ ]
+ """
+ Details on the account's acceptance of the [Stripe Issuing Terms and Disclosures](https://docs.stripe.com/issuing/connect/tos_acceptance).
+ """
+
+
+class AccountCreateParamsSettingsCardIssuingTosAcceptance(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the account representative accepted the service agreement.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the account representative accepted the service agreement.
+ """
+ user_agent: NotRequired["Literal['']|str"]
+ """
+ The user agent of the browser from which the account representative accepted the service agreement.
+ """
+
+
+class AccountCreateParamsSettingsCardPayments(TypedDict):
+ decline_on: NotRequired["AccountCreateParamsSettingsCardPaymentsDeclineOn"]
+ """
+ Automatically declines certain charge types regardless of whether the card issuer accepted or declined the charge.
+ """
+ statement_descriptor_prefix: NotRequired[str]
+ """
+ The default text that appears on credit card statements when a charge is made. This field prefixes any dynamic `statement_descriptor` specified on the charge. `statement_descriptor_prefix` is useful for maximizing descriptor space for the dynamic portion.
+ """
+ statement_descriptor_prefix_kana: NotRequired["Literal['']|str"]
+ """
+ The Kana variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kana` specified on the charge. `statement_descriptor_prefix_kana` is useful for maximizing descriptor space for the dynamic portion.
+ """
+ statement_descriptor_prefix_kanji: NotRequired["Literal['']|str"]
+ """
+ The Kanji variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kanji` specified on the charge. `statement_descriptor_prefix_kanji` is useful for maximizing descriptor space for the dynamic portion.
+ """
+
+
+class AccountCreateParamsSettingsCardPaymentsDeclineOn(TypedDict):
+ avs_failure: NotRequired[bool]
+ """
+ Whether Stripe automatically declines charges with an incorrect ZIP or postal code. This setting only applies when a ZIP or postal code is provided and they fail bank verification.
+ """
+ cvc_failure: NotRequired[bool]
+ """
+ Whether Stripe automatically declines charges with an incorrect CVC. This setting only applies when a CVC is provided and it fails bank verification.
+ """
+
+
+class AccountCreateParamsSettingsInvoices(TypedDict):
+ hosted_payment_method_save: NotRequired[
+ Literal["always", "never", "offer"]
+ ]
+ """
+ Whether payment methods should be saved when a payment is completed for a one-time invoices on a hosted invoice page.
+ """
+
+
+class AccountCreateParamsSettingsPayments(TypedDict):
+ statement_descriptor: NotRequired[str]
+ """
+ The default text that appears on statements for non-card charges outside of Japan. For card charges, if you don't set a `statement_descriptor_prefix`, this text is also used as the statement descriptor prefix. In that case, if concatenating the statement descriptor suffix causes the combined statement descriptor to exceed 22 characters, we truncate the `statement_descriptor` text to limit the full descriptor to 22 characters. For more information about statement descriptors and their requirements, see the [account settings documentation](https://docs.stripe.com/get-started/account/statement-descriptors).
+ """
+ statement_descriptor_kana: NotRequired[str]
+ """
+ The Kana variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
+ """
+ statement_descriptor_kanji: NotRequired[str]
+ """
+ The Kanji variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
+ """
+
+
+class AccountCreateParamsSettingsPayouts(TypedDict):
+ debit_negative_balances: NotRequired[bool]
+ """
+ A Boolean indicating whether Stripe should try to reclaim negative balances from an attached bank account. For details, see [Understanding Connect Account Balances](https://docs.stripe.com/connect/account-balances).
+ """
+ schedule: NotRequired["AccountCreateParamsSettingsPayoutsSchedule"]
+ """
+ Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](https://docs.stripe.com/connect/bank-transfers#payout-information) documentation.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
+ """
+
+
+class AccountCreateParamsSettingsPayoutsSchedule(TypedDict):
+ delay_days: NotRequired["Literal['minimum']|int"]
+ """
+ The number of days charge funds are held before being paid out. May also be set to `minimum`, representing the lowest available value for the account country. Default is `minimum`. The `delay_days` parameter remains at the last configured value if `interval` is `manual`. [Learn more about controlling payout delay days](https://docs.stripe.com/connect/manage-payout-schedule).
+ """
+ interval: NotRequired[Literal["daily", "manual", "monthly", "weekly"]]
+ """
+ How frequently available funds are paid out. One of: `daily`, `manual`, `weekly`, or `monthly`. Default is `daily`.
+ """
+ monthly_anchor: NotRequired[int]
+ """
+ The day of the month when available funds are paid out, specified as a number between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly`.
+ """
+ monthly_payout_days: NotRequired[List[int]]
+ """
+ The days of the month when available funds are paid out, specified as an array of numbers between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly` and `monthly_anchor` is not set.
+ """
+ weekly_anchor: NotRequired[
+ Literal[
+ "friday",
+ "monday",
+ "saturday",
+ "sunday",
+ "thursday",
+ "tuesday",
+ "wednesday",
+ ]
+ ]
+ """
+ The day of the week when available funds are paid out, specified as `monday`, `tuesday`, etc. Required and applicable only if `interval` is `weekly`.
+ """
+ weekly_payout_days: NotRequired[
+ List[Literal["friday", "monday", "thursday", "tuesday", "wednesday"]]
+ ]
+ """
+ The days of the week when available funds are paid out, specified as an array, e.g., [`monday`, `tuesday`]. Required and applicable only if `interval` is `weekly`.
+ """
+
+
+class AccountCreateParamsSettingsTreasury(TypedDict):
+ tos_acceptance: NotRequired[
+ "AccountCreateParamsSettingsTreasuryTosAcceptance"
+ ]
+ """
+ Details on the account's acceptance of the Stripe Treasury Services Agreement.
+ """
+
+
+class AccountCreateParamsSettingsTreasuryTosAcceptance(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the account representative accepted the service agreement.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the account representative accepted the service agreement.
+ """
+ user_agent: NotRequired["Literal['']|str"]
+ """
+ The user agent of the browser from which the account representative accepted the service agreement.
+ """
+
+
+class AccountCreateParamsTosAcceptance(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the account representative accepted their service agreement.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the account representative accepted their service agreement.
+ """
+ service_agreement: NotRequired[str]
+ """
+ The user's service agreement type.
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the account representative accepted their service agreement.
+ """
diff --git a/stripe/params/_account_create_person_params.py b/stripe/params/_account_create_person_params.py
new file mode 100644
index 000000000..d52502b95
--- /dev/null
+++ b/stripe/params/_account_create_person_params.py
@@ -0,0 +1,471 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AccountCreatePersonParams(RequestOptions):
+ additional_tos_acceptances: NotRequired[
+ "AccountCreatePersonParamsAdditionalTosAcceptances"
+ ]
+ """
+ Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.
+ """
+ address: NotRequired["AccountCreatePersonParamsAddress"]
+ """
+ The person's address.
+ """
+ address_kana: NotRequired["AccountCreatePersonParamsAddressKana"]
+ """
+ The Kana variation of the person's address (Japan only).
+ """
+ address_kanji: NotRequired["AccountCreatePersonParamsAddressKanji"]
+ """
+ The Kanji variation of the person's address (Japan only).
+ """
+ dob: NotRequired["Literal['']|AccountCreatePersonParamsDob"]
+ """
+ The person's date of birth.
+ """
+ documents: NotRequired["AccountCreatePersonParamsDocuments"]
+ """
+ Documents that may be submitted to satisfy various informational requests.
+ """
+ email: NotRequired[str]
+ """
+ The person's email address.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ first_name: NotRequired[str]
+ """
+ The person's first name.
+ """
+ first_name_kana: NotRequired[str]
+ """
+ The Kana variation of the person's first name (Japan only).
+ """
+ first_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the person's first name (Japan only).
+ """
+ full_name_aliases: NotRequired["Literal['']|List[str]"]
+ """
+ A list of alternate names or aliases that the person is known by.
+ """
+ gender: NotRequired[str]
+ """
+ The person's gender (International regulations require either "male" or "female").
+ """
+ id_number: NotRequired[str]
+ """
+ The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ id_number_secondary: NotRequired[str]
+ """
+ The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ last_name: NotRequired[str]
+ """
+ The person's last name.
+ """
+ last_name_kana: NotRequired[str]
+ """
+ The Kana variation of the person's last name (Japan only).
+ """
+ last_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the person's last name (Japan only).
+ """
+ maiden_name: NotRequired[str]
+ """
+ The person's maiden name.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ nationality: NotRequired[str]
+ """
+ The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or "XX" if unavailable.
+ """
+ person_token: NotRequired[str]
+ """
+ A [person token](https://docs.stripe.com/connect/account-tokens), used to securely provide details to the person.
+ """
+ phone: NotRequired[str]
+ """
+ The person's phone number.
+ """
+ political_exposure: NotRequired[Literal["existing", "none"]]
+ """
+ Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
+ """
+ registered_address: NotRequired[
+ "AccountCreatePersonParamsRegisteredAddress"
+ ]
+ """
+ The person's registered address.
+ """
+ relationship: NotRequired["AccountCreatePersonParamsRelationship"]
+ """
+ The relationship that this person has with the account's legal entity.
+ """
+ ssn_last_4: NotRequired[str]
+ """
+ The last four digits of the person's Social Security number (U.S. only).
+ """
+ us_cfpb_data: NotRequired["AccountCreatePersonParamsUsCfpbData"]
+ """
+ Demographic data related to the person.
+ """
+ verification: NotRequired["AccountCreatePersonParamsVerification"]
+ """
+ The person's verification status.
+ """
+
+
+class AccountCreatePersonParamsAdditionalTosAcceptances(TypedDict):
+ account: NotRequired[
+ "AccountCreatePersonParamsAdditionalTosAcceptancesAccount"
+ ]
+ """
+ Details on the legal guardian's acceptance of the main Stripe service agreement.
+ """
+
+
+class AccountCreatePersonParamsAdditionalTosAcceptancesAccount(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the account representative accepted the service agreement.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the account representative accepted the service agreement.
+ """
+ user_agent: NotRequired["Literal['']|str"]
+ """
+ The user agent of the browser from which the account representative accepted the service agreement.
+ """
+
+
+class AccountCreatePersonParamsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountCreatePersonParamsAddressKana(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountCreatePersonParamsAddressKanji(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountCreatePersonParamsDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class AccountCreatePersonParamsDocuments(TypedDict):
+ company_authorization: NotRequired[
+ "AccountCreatePersonParamsDocumentsCompanyAuthorization"
+ ]
+ """
+ One or more documents that demonstrate proof that this person is authorized to represent the company.
+ """
+ passport: NotRequired["AccountCreatePersonParamsDocumentsPassport"]
+ """
+ One or more documents showing the person's passport page with photo and personal data.
+ """
+ visa: NotRequired["AccountCreatePersonParamsDocumentsVisa"]
+ """
+ One or more documents showing the person's visa required for living in the country where they are residing.
+ """
+
+
+class AccountCreatePersonParamsDocumentsCompanyAuthorization(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountCreatePersonParamsDocumentsPassport(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountCreatePersonParamsDocumentsVisa(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountCreatePersonParamsRegisteredAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountCreatePersonParamsRelationship(TypedDict):
+ authorizer: NotRequired[bool]
+ """
+ Whether the person is the authorizer of the account's representative.
+ """
+ director: NotRequired[bool]
+ """
+ Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
+ """
+ executive: NotRequired[bool]
+ """
+ Whether the person has significant responsibility to control, manage, or direct the organization.
+ """
+ legal_guardian: NotRequired[bool]
+ """
+ Whether the person is the legal guardian of the account's representative.
+ """
+ owner: NotRequired[bool]
+ """
+ Whether the person is an owner of the account's legal entity.
+ """
+ percent_ownership: NotRequired["Literal['']|float"]
+ """
+ The percent owned by the person of the account's legal entity.
+ """
+ representative: NotRequired[bool]
+ """
+ Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
+ """
+ title: NotRequired[str]
+ """
+ The person's title (e.g., CEO, Support Engineer).
+ """
+
+
+class AccountCreatePersonParamsUsCfpbData(TypedDict):
+ ethnicity_details: NotRequired[
+ "AccountCreatePersonParamsUsCfpbDataEthnicityDetails"
+ ]
+ """
+ The persons ethnicity details
+ """
+ race_details: NotRequired["AccountCreatePersonParamsUsCfpbDataRaceDetails"]
+ """
+ The persons race details
+ """
+ self_identified_gender: NotRequired[str]
+ """
+ The persons self-identified gender
+ """
+
+
+class AccountCreatePersonParamsUsCfpbDataEthnicityDetails(TypedDict):
+ ethnicity: NotRequired[
+ List[
+ Literal[
+ "cuban",
+ "hispanic_or_latino",
+ "mexican",
+ "not_hispanic_or_latino",
+ "other_hispanic_or_latino",
+ "prefer_not_to_answer",
+ "puerto_rican",
+ ]
+ ]
+ ]
+ """
+ The persons ethnicity
+ """
+ ethnicity_other: NotRequired[str]
+ """
+ Please specify your origin, when other is selected.
+ """
+
+
+class AccountCreatePersonParamsUsCfpbDataRaceDetails(TypedDict):
+ race: NotRequired[
+ List[
+ Literal[
+ "african_american",
+ "american_indian_or_alaska_native",
+ "asian",
+ "asian_indian",
+ "black_or_african_american",
+ "chinese",
+ "ethiopian",
+ "filipino",
+ "guamanian_or_chamorro",
+ "haitian",
+ "jamaican",
+ "japanese",
+ "korean",
+ "native_hawaiian",
+ "native_hawaiian_or_other_pacific_islander",
+ "nigerian",
+ "other_asian",
+ "other_black_or_african_american",
+ "other_pacific_islander",
+ "prefer_not_to_answer",
+ "samoan",
+ "somali",
+ "vietnamese",
+ "white",
+ ]
+ ]
+ ]
+ """
+ The persons race.
+ """
+ race_other: NotRequired[str]
+ """
+ Please specify your race, when other is selected.
+ """
+
+
+class AccountCreatePersonParamsVerification(TypedDict):
+ additional_document: NotRequired[
+ "AccountCreatePersonParamsVerificationAdditionalDocument"
+ ]
+ """
+ A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
+ """
+ document: NotRequired["AccountCreatePersonParamsVerificationDocument"]
+ """
+ An identifying document, either a passport or local ID card.
+ """
+
+
+class AccountCreatePersonParamsVerificationAdditionalDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+
+
+class AccountCreatePersonParamsVerificationDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
diff --git a/stripe/params/_account_delete_external_account_params.py b/stripe/params/_account_delete_external_account_params.py
new file mode 100644
index 000000000..dd702e9c1
--- /dev/null
+++ b/stripe/params/_account_delete_external_account_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class AccountDeleteExternalAccountParams(RequestOptions):
+ pass
diff --git a/stripe/params/_account_delete_params.py b/stripe/params/_account_delete_params.py
new file mode 100644
index 000000000..9a587fb78
--- /dev/null
+++ b/stripe/params/_account_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class AccountDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/_account_delete_person_params.py b/stripe/params/_account_delete_person_params.py
new file mode 100644
index 000000000..843ae3733
--- /dev/null
+++ b/stripe/params/_account_delete_person_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class AccountDeletePersonParams(RequestOptions):
+ pass
diff --git a/stripe/params/_account_external_account_create_params.py b/stripe/params/_account_external_account_create_params.py
new file mode 100644
index 000000000..144d75853
--- /dev/null
+++ b/stripe/params/_account_external_account_create_params.py
@@ -0,0 +1,82 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List, Union
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AccountExternalAccountCreateParams(TypedDict):
+ default_for_currency: NotRequired[bool]
+ """
+ When set to true, or if this is the first external account added in this currency, this account becomes the default external account for its currency.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ external_account: Union[
+ str,
+ "AccountExternalAccountCreateParamsCard",
+ "AccountExternalAccountCreateParamsBankAccount",
+ "AccountExternalAccountCreateParamsCardToken",
+ ]
+ """
+ A token, like the ones returned by [Stripe.js](https://stripe.com/docs/js) or a dictionary containing a user's external account details (with the options shown below). Please refer to full [documentation](https://stripe.com/docs/api/external_accounts) instead.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+
+
+class AccountExternalAccountCreateParamsCard(TypedDict):
+ object: Literal["card"]
+ address_city: NotRequired[str]
+ address_country: NotRequired[str]
+ address_line1: NotRequired[str]
+ address_line2: NotRequired[str]
+ address_state: NotRequired[str]
+ address_zip: NotRequired[str]
+ currency: NotRequired[str]
+ cvc: NotRequired[str]
+ exp_month: int
+ exp_year: int
+ name: NotRequired[str]
+ number: str
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
+ """
+
+
+class AccountExternalAccountCreateParamsBankAccount(TypedDict):
+ object: Literal["bank_account"]
+ account_holder_name: NotRequired[str]
+ """
+ The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object.
+ """
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
+ """
+ account_number: str
+ """
+ The account number for the bank account, in string form. Must be a checking account.
+ """
+ country: str
+ """
+ The country in which the bank account is located.
+ """
+ currency: NotRequired[str]
+ """
+ The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts)
+ """
+ routing_number: NotRequired[str]
+ """
+ The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
+ """
+
+
+class AccountExternalAccountCreateParamsCardToken(TypedDict):
+ object: Literal["card"]
+ currency: NotRequired[str]
+ token: str
diff --git a/stripe/params/_account_external_account_delete_params.py b/stripe/params/_account_external_account_delete_params.py
new file mode 100644
index 000000000..441739cba
--- /dev/null
+++ b/stripe/params/_account_external_account_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing_extensions import TypedDict
+
+
+class AccountExternalAccountDeleteParams(TypedDict):
+ pass
diff --git a/stripe/params/_account_external_account_list_params.py b/stripe/params/_account_external_account_list_params.py
new file mode 100644
index 000000000..1afd1d469
--- /dev/null
+++ b/stripe/params/_account_external_account_list_params.py
@@ -0,0 +1,27 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AccountExternalAccountListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ object: NotRequired[Literal["bank_account", "card"]]
+ """
+ Filter external accounts according to a particular object type.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_account_external_account_retrieve_params.py b/stripe/params/_account_external_account_retrieve_params.py
new file mode 100644
index 000000000..70ebac586
--- /dev/null
+++ b/stripe/params/_account_external_account_retrieve_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AccountExternalAccountRetrieveParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_account_external_account_update_params.py b/stripe/params/_account_external_account_update_params.py
new file mode 100644
index 000000000..04642cd79
--- /dev/null
+++ b/stripe/params/_account_external_account_update_params.py
@@ -0,0 +1,91 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AccountExternalAccountUpdateParams(TypedDict):
+ account_holder_name: NotRequired[str]
+ """
+ The name of the person or business that owns the bank account.
+ """
+ account_holder_type: NotRequired[
+ "Literal['']|Literal['company', 'individual']"
+ ]
+ """
+ The type of entity that holds the account. This can be either `individual` or `company`.
+ """
+ account_type: NotRequired[Literal["checking", "futsu", "savings", "toza"]]
+ """
+ The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`.
+ """
+ address_city: NotRequired[str]
+ """
+ City/District/Suburb/Town/Village.
+ """
+ address_country: NotRequired[str]
+ """
+ Billing address country, if provided when creating card.
+ """
+ address_line1: NotRequired[str]
+ """
+ Address line 1 (Street address/PO Box/Company name).
+ """
+ address_line2: NotRequired[str]
+ """
+ Address line 2 (Apartment/Suite/Unit/Building).
+ """
+ address_state: NotRequired[str]
+ """
+ State/County/Province/Region.
+ """
+ address_zip: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ default_for_currency: NotRequired[bool]
+ """
+ When set to true, this becomes the default external account for its currency.
+ """
+ documents: NotRequired["AccountExternalAccountUpdateParamsDocuments"]
+ """
+ Documents that may be submitted to satisfy various informational requests.
+ """
+ exp_month: NotRequired[str]
+ """
+ Two digit number representing the card's expiration month.
+ """
+ exp_year: NotRequired[str]
+ """
+ Four digit number representing the card's expiration year.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired[str]
+ """
+ Cardholder name.
+ """
+
+
+class AccountExternalAccountUpdateParamsDocuments(TypedDict):
+ bank_account_ownership_verification: NotRequired[
+ "AccountExternalAccountUpdateParamsDocumentsBankAccountOwnershipVerification"
+ ]
+ """
+ One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the bank account that displays the last 4 digits of the account number, either a statement or a check.
+ """
+
+
+class AccountExternalAccountUpdateParamsDocumentsBankAccountOwnershipVerification(
+ TypedDict,
+):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
diff --git a/stripe/params/_account_link_create_params.py b/stripe/params/_account_link_create_params.py
new file mode 100644
index 000000000..aa7168afd
--- /dev/null
+++ b/stripe/params/_account_link_create_params.py
@@ -0,0 +1,49 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AccountLinkCreateParams(RequestOptions):
+ account: str
+ """
+ The identifier of the account to create an account link for.
+ """
+ collect: NotRequired[Literal["currently_due", "eventually_due"]]
+ """
+ The collect parameter is deprecated. Use `collection_options` instead.
+ """
+ collection_options: NotRequired["AccountLinkCreateParamsCollectionOptions"]
+ """
+ Specifies the requirements that Stripe collects from connected accounts in the Connect Onboarding flow.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ refresh_url: NotRequired[str]
+ """
+ The URL the user will be redirected to if the account link is expired, has been previously-visited, or is otherwise invalid. The URL you specify should attempt to generate a new account link with the same parameters used to create the original account link, then redirect the user to the new account link's URL so they can continue with Connect Onboarding. If a new account link cannot be generated or the redirect fails you should display a useful error to the user.
+ """
+ return_url: NotRequired[str]
+ """
+ The URL that the user will be redirected to upon leaving or completing the linked flow.
+ """
+ type: Literal["account_onboarding", "account_update"]
+ """
+ The type of account link the user is requesting.
+
+ You can create Account Links of type `account_update` only for connected accounts where your platform is responsible for collecting requirements, including Custom accounts. You can't create them for accounts that have access to a Stripe-hosted Dashboard. If you use [Connect embedded components](https://docs.stripe.com/connect/get-started-connect-embedded-components), you can include components that allow your connected accounts to update their own information. For an account without Stripe-hosted Dashboard access where Stripe is liable for negative balances, you must use embedded components.
+ """
+
+
+class AccountLinkCreateParamsCollectionOptions(TypedDict):
+ fields: NotRequired[Literal["currently_due", "eventually_due"]]
+ """
+ Specifies whether the platform collects only currently_due requirements (`currently_due`) or both currently_due and eventually_due requirements (`eventually_due`). If you don't specify `collection_options`, the default value is `currently_due`.
+ """
+ future_requirements: NotRequired[Literal["include", "omit"]]
+ """
+ Specifies whether the platform collects future_requirements in addition to requirements in Connect Onboarding. The default value is `omit`.
+ """
diff --git a/stripe/params/_account_list_capabilities_params.py b/stripe/params/_account_list_capabilities_params.py
new file mode 100644
index 000000000..390ea3815
--- /dev/null
+++ b/stripe/params/_account_list_capabilities_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AccountListCapabilitiesParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_account_list_external_accounts_params.py b/stripe/params/_account_list_external_accounts_params.py
new file mode 100644
index 000000000..45f1f078b
--- /dev/null
+++ b/stripe/params/_account_list_external_accounts_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class AccountListExternalAccountsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ object: NotRequired[Literal["bank_account", "card"]]
+ """
+ Filter external accounts according to a particular object type.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_account_list_params.py b/stripe/params/_account_list_params.py
new file mode 100644
index 000000000..541093c07
--- /dev/null
+++ b/stripe/params/_account_list_params.py
@@ -0,0 +1,47 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AccountListParams(RequestOptions):
+ created: NotRequired["AccountListParamsCreated|int"]
+ """
+ Only return connected accounts that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class AccountListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_account_list_persons_params.py b/stripe/params/_account_list_persons_params.py
new file mode 100644
index 000000000..fbd9cb28f
--- /dev/null
+++ b/stripe/params/_account_list_persons_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AccountListPersonsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ relationship: NotRequired["AccountListPersonsParamsRelationship"]
+ """
+ Filters on the list of people returned based on the person's relationship to the account's company.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class AccountListPersonsParamsRelationship(TypedDict):
+ authorizer: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are authorizers of the account's representative.
+ """
+ director: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are directors of the account's company.
+ """
+ executive: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are executives of the account's company.
+ """
+ legal_guardian: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are legal guardians of the account's representative.
+ """
+ owner: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are owners of the account's company.
+ """
+ representative: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are the representative of the account's company.
+ """
diff --git a/stripe/params/_account_login_link_create_params.py b/stripe/params/_account_login_link_create_params.py
new file mode 100644
index 000000000..f9a0ea384
--- /dev/null
+++ b/stripe/params/_account_login_link_create_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AccountLoginLinkCreateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_account_modify_capability_params.py b/stripe/params/_account_modify_capability_params.py
new file mode 100644
index 000000000..ebbfa934a
--- /dev/null
+++ b/stripe/params/_account_modify_capability_params.py
@@ -0,0 +1,18 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AccountModifyCapabilityParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ requested: NotRequired[bool]
+ """
+ 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. Some capabilities are permanent after they've been requested. Attempting to remove a permanent capability returns an error.
+ """
diff --git a/stripe/params/_account_modify_external_account_params.py b/stripe/params/_account_modify_external_account_params.py
new file mode 100644
index 000000000..682ec49ed
--- /dev/null
+++ b/stripe/params/_account_modify_external_account_params.py
@@ -0,0 +1,92 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AccountModifyExternalAccountParams(RequestOptions):
+ account_holder_name: NotRequired[str]
+ """
+ The name of the person or business that owns the bank account.
+ """
+ account_holder_type: NotRequired[
+ "Literal['']|Literal['company', 'individual']"
+ ]
+ """
+ The type of entity that holds the account. This can be either `individual` or `company`.
+ """
+ account_type: NotRequired[Literal["checking", "futsu", "savings", "toza"]]
+ """
+ The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`.
+ """
+ address_city: NotRequired[str]
+ """
+ City/District/Suburb/Town/Village.
+ """
+ address_country: NotRequired[str]
+ """
+ Billing address country, if provided when creating card.
+ """
+ address_line1: NotRequired[str]
+ """
+ Address line 1 (Street address/PO Box/Company name).
+ """
+ address_line2: NotRequired[str]
+ """
+ Address line 2 (Apartment/Suite/Unit/Building).
+ """
+ address_state: NotRequired[str]
+ """
+ State/County/Province/Region.
+ """
+ address_zip: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ default_for_currency: NotRequired[bool]
+ """
+ When set to true, this becomes the default external account for its currency.
+ """
+ documents: NotRequired["AccountModifyExternalAccountParamsDocuments"]
+ """
+ Documents that may be submitted to satisfy various informational requests.
+ """
+ exp_month: NotRequired[str]
+ """
+ Two digit number representing the card's expiration month.
+ """
+ exp_year: NotRequired[str]
+ """
+ Four digit number representing the card's expiration year.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired[str]
+ """
+ Cardholder name.
+ """
+
+
+class AccountModifyExternalAccountParamsDocuments(TypedDict):
+ bank_account_ownership_verification: NotRequired[
+ "AccountModifyExternalAccountParamsDocumentsBankAccountOwnershipVerification"
+ ]
+ """
+ One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the bank account that displays the last 4 digits of the account number, either a statement or a check.
+ """
+
+
+class AccountModifyExternalAccountParamsDocumentsBankAccountOwnershipVerification(
+ TypedDict,
+):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
diff --git a/stripe/params/_account_modify_person_params.py b/stripe/params/_account_modify_person_params.py
new file mode 100644
index 000000000..08a3455a9
--- /dev/null
+++ b/stripe/params/_account_modify_person_params.py
@@ -0,0 +1,471 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AccountModifyPersonParams(RequestOptions):
+ additional_tos_acceptances: NotRequired[
+ "AccountModifyPersonParamsAdditionalTosAcceptances"
+ ]
+ """
+ Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.
+ """
+ address: NotRequired["AccountModifyPersonParamsAddress"]
+ """
+ The person's address.
+ """
+ address_kana: NotRequired["AccountModifyPersonParamsAddressKana"]
+ """
+ The Kana variation of the person's address (Japan only).
+ """
+ address_kanji: NotRequired["AccountModifyPersonParamsAddressKanji"]
+ """
+ The Kanji variation of the person's address (Japan only).
+ """
+ dob: NotRequired["Literal['']|AccountModifyPersonParamsDob"]
+ """
+ The person's date of birth.
+ """
+ documents: NotRequired["AccountModifyPersonParamsDocuments"]
+ """
+ Documents that may be submitted to satisfy various informational requests.
+ """
+ email: NotRequired[str]
+ """
+ The person's email address.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ first_name: NotRequired[str]
+ """
+ The person's first name.
+ """
+ first_name_kana: NotRequired[str]
+ """
+ The Kana variation of the person's first name (Japan only).
+ """
+ first_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the person's first name (Japan only).
+ """
+ full_name_aliases: NotRequired["Literal['']|List[str]"]
+ """
+ A list of alternate names or aliases that the person is known by.
+ """
+ gender: NotRequired[str]
+ """
+ The person's gender (International regulations require either "male" or "female").
+ """
+ id_number: NotRequired[str]
+ """
+ The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ id_number_secondary: NotRequired[str]
+ """
+ The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ last_name: NotRequired[str]
+ """
+ The person's last name.
+ """
+ last_name_kana: NotRequired[str]
+ """
+ The Kana variation of the person's last name (Japan only).
+ """
+ last_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the person's last name (Japan only).
+ """
+ maiden_name: NotRequired[str]
+ """
+ The person's maiden name.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ nationality: NotRequired[str]
+ """
+ The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or "XX" if unavailable.
+ """
+ person_token: NotRequired[str]
+ """
+ A [person token](https://docs.stripe.com/connect/account-tokens), used to securely provide details to the person.
+ """
+ phone: NotRequired[str]
+ """
+ The person's phone number.
+ """
+ political_exposure: NotRequired[Literal["existing", "none"]]
+ """
+ Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
+ """
+ registered_address: NotRequired[
+ "AccountModifyPersonParamsRegisteredAddress"
+ ]
+ """
+ The person's registered address.
+ """
+ relationship: NotRequired["AccountModifyPersonParamsRelationship"]
+ """
+ The relationship that this person has with the account's legal entity.
+ """
+ ssn_last_4: NotRequired[str]
+ """
+ The last four digits of the person's Social Security number (U.S. only).
+ """
+ us_cfpb_data: NotRequired["AccountModifyPersonParamsUsCfpbData"]
+ """
+ Demographic data related to the person.
+ """
+ verification: NotRequired["AccountModifyPersonParamsVerification"]
+ """
+ The person's verification status.
+ """
+
+
+class AccountModifyPersonParamsAdditionalTosAcceptances(TypedDict):
+ account: NotRequired[
+ "AccountModifyPersonParamsAdditionalTosAcceptancesAccount"
+ ]
+ """
+ Details on the legal guardian's acceptance of the main Stripe service agreement.
+ """
+
+
+class AccountModifyPersonParamsAdditionalTosAcceptancesAccount(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the account representative accepted the service agreement.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the account representative accepted the service agreement.
+ """
+ user_agent: NotRequired["Literal['']|str"]
+ """
+ The user agent of the browser from which the account representative accepted the service agreement.
+ """
+
+
+class AccountModifyPersonParamsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountModifyPersonParamsAddressKana(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountModifyPersonParamsAddressKanji(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountModifyPersonParamsDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class AccountModifyPersonParamsDocuments(TypedDict):
+ company_authorization: NotRequired[
+ "AccountModifyPersonParamsDocumentsCompanyAuthorization"
+ ]
+ """
+ One or more documents that demonstrate proof that this person is authorized to represent the company.
+ """
+ passport: NotRequired["AccountModifyPersonParamsDocumentsPassport"]
+ """
+ One or more documents showing the person's passport page with photo and personal data.
+ """
+ visa: NotRequired["AccountModifyPersonParamsDocumentsVisa"]
+ """
+ One or more documents showing the person's visa required for living in the country where they are residing.
+ """
+
+
+class AccountModifyPersonParamsDocumentsCompanyAuthorization(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountModifyPersonParamsDocumentsPassport(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountModifyPersonParamsDocumentsVisa(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountModifyPersonParamsRegisteredAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountModifyPersonParamsRelationship(TypedDict):
+ authorizer: NotRequired[bool]
+ """
+ Whether the person is the authorizer of the account's representative.
+ """
+ director: NotRequired[bool]
+ """
+ Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
+ """
+ executive: NotRequired[bool]
+ """
+ Whether the person has significant responsibility to control, manage, or direct the organization.
+ """
+ legal_guardian: NotRequired[bool]
+ """
+ Whether the person is the legal guardian of the account's representative.
+ """
+ owner: NotRequired[bool]
+ """
+ Whether the person is an owner of the account's legal entity.
+ """
+ percent_ownership: NotRequired["Literal['']|float"]
+ """
+ The percent owned by the person of the account's legal entity.
+ """
+ representative: NotRequired[bool]
+ """
+ Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
+ """
+ title: NotRequired[str]
+ """
+ The person's title (e.g., CEO, Support Engineer).
+ """
+
+
+class AccountModifyPersonParamsUsCfpbData(TypedDict):
+ ethnicity_details: NotRequired[
+ "AccountModifyPersonParamsUsCfpbDataEthnicityDetails"
+ ]
+ """
+ The persons ethnicity details
+ """
+ race_details: NotRequired["AccountModifyPersonParamsUsCfpbDataRaceDetails"]
+ """
+ The persons race details
+ """
+ self_identified_gender: NotRequired[str]
+ """
+ The persons self-identified gender
+ """
+
+
+class AccountModifyPersonParamsUsCfpbDataEthnicityDetails(TypedDict):
+ ethnicity: NotRequired[
+ List[
+ Literal[
+ "cuban",
+ "hispanic_or_latino",
+ "mexican",
+ "not_hispanic_or_latino",
+ "other_hispanic_or_latino",
+ "prefer_not_to_answer",
+ "puerto_rican",
+ ]
+ ]
+ ]
+ """
+ The persons ethnicity
+ """
+ ethnicity_other: NotRequired[str]
+ """
+ Please specify your origin, when other is selected.
+ """
+
+
+class AccountModifyPersonParamsUsCfpbDataRaceDetails(TypedDict):
+ race: NotRequired[
+ List[
+ Literal[
+ "african_american",
+ "american_indian_or_alaska_native",
+ "asian",
+ "asian_indian",
+ "black_or_african_american",
+ "chinese",
+ "ethiopian",
+ "filipino",
+ "guamanian_or_chamorro",
+ "haitian",
+ "jamaican",
+ "japanese",
+ "korean",
+ "native_hawaiian",
+ "native_hawaiian_or_other_pacific_islander",
+ "nigerian",
+ "other_asian",
+ "other_black_or_african_american",
+ "other_pacific_islander",
+ "prefer_not_to_answer",
+ "samoan",
+ "somali",
+ "vietnamese",
+ "white",
+ ]
+ ]
+ ]
+ """
+ The persons race.
+ """
+ race_other: NotRequired[str]
+ """
+ Please specify your race, when other is selected.
+ """
+
+
+class AccountModifyPersonParamsVerification(TypedDict):
+ additional_document: NotRequired[
+ "AccountModifyPersonParamsVerificationAdditionalDocument"
+ ]
+ """
+ A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
+ """
+ document: NotRequired["AccountModifyPersonParamsVerificationDocument"]
+ """
+ An identifying document, either a passport or local ID card.
+ """
+
+
+class AccountModifyPersonParamsVerificationAdditionalDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+
+
+class AccountModifyPersonParamsVerificationDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
diff --git a/stripe/params/_account_person_create_params.py b/stripe/params/_account_person_create_params.py
new file mode 100644
index 000000000..bf5abaf4c
--- /dev/null
+++ b/stripe/params/_account_person_create_params.py
@@ -0,0 +1,470 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AccountPersonCreateParams(TypedDict):
+ additional_tos_acceptances: NotRequired[
+ "AccountPersonCreateParamsAdditionalTosAcceptances"
+ ]
+ """
+ Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.
+ """
+ address: NotRequired["AccountPersonCreateParamsAddress"]
+ """
+ The person's address.
+ """
+ address_kana: NotRequired["AccountPersonCreateParamsAddressKana"]
+ """
+ The Kana variation of the person's address (Japan only).
+ """
+ address_kanji: NotRequired["AccountPersonCreateParamsAddressKanji"]
+ """
+ The Kanji variation of the person's address (Japan only).
+ """
+ dob: NotRequired["Literal['']|AccountPersonCreateParamsDob"]
+ """
+ The person's date of birth.
+ """
+ documents: NotRequired["AccountPersonCreateParamsDocuments"]
+ """
+ Documents that may be submitted to satisfy various informational requests.
+ """
+ email: NotRequired[str]
+ """
+ The person's email address.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ first_name: NotRequired[str]
+ """
+ The person's first name.
+ """
+ first_name_kana: NotRequired[str]
+ """
+ The Kana variation of the person's first name (Japan only).
+ """
+ first_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the person's first name (Japan only).
+ """
+ full_name_aliases: NotRequired["Literal['']|List[str]"]
+ """
+ A list of alternate names or aliases that the person is known by.
+ """
+ gender: NotRequired[str]
+ """
+ The person's gender (International regulations require either "male" or "female").
+ """
+ id_number: NotRequired[str]
+ """
+ The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ id_number_secondary: NotRequired[str]
+ """
+ The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ last_name: NotRequired[str]
+ """
+ The person's last name.
+ """
+ last_name_kana: NotRequired[str]
+ """
+ The Kana variation of the person's last name (Japan only).
+ """
+ last_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the person's last name (Japan only).
+ """
+ maiden_name: NotRequired[str]
+ """
+ The person's maiden name.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ nationality: NotRequired[str]
+ """
+ The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or "XX" if unavailable.
+ """
+ person_token: NotRequired[str]
+ """
+ A [person token](https://docs.stripe.com/connect/account-tokens), used to securely provide details to the person.
+ """
+ phone: NotRequired[str]
+ """
+ The person's phone number.
+ """
+ political_exposure: NotRequired[Literal["existing", "none"]]
+ """
+ Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
+ """
+ registered_address: NotRequired[
+ "AccountPersonCreateParamsRegisteredAddress"
+ ]
+ """
+ The person's registered address.
+ """
+ relationship: NotRequired["AccountPersonCreateParamsRelationship"]
+ """
+ The relationship that this person has with the account's legal entity.
+ """
+ ssn_last_4: NotRequired[str]
+ """
+ The last four digits of the person's Social Security number (U.S. only).
+ """
+ us_cfpb_data: NotRequired["AccountPersonCreateParamsUsCfpbData"]
+ """
+ Demographic data related to the person.
+ """
+ verification: NotRequired["AccountPersonCreateParamsVerification"]
+ """
+ The person's verification status.
+ """
+
+
+class AccountPersonCreateParamsAdditionalTosAcceptances(TypedDict):
+ account: NotRequired[
+ "AccountPersonCreateParamsAdditionalTosAcceptancesAccount"
+ ]
+ """
+ Details on the legal guardian's acceptance of the main Stripe service agreement.
+ """
+
+
+class AccountPersonCreateParamsAdditionalTosAcceptancesAccount(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the account representative accepted the service agreement.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the account representative accepted the service agreement.
+ """
+ user_agent: NotRequired["Literal['']|str"]
+ """
+ The user agent of the browser from which the account representative accepted the service agreement.
+ """
+
+
+class AccountPersonCreateParamsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountPersonCreateParamsAddressKana(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountPersonCreateParamsAddressKanji(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountPersonCreateParamsDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class AccountPersonCreateParamsDocuments(TypedDict):
+ company_authorization: NotRequired[
+ "AccountPersonCreateParamsDocumentsCompanyAuthorization"
+ ]
+ """
+ One or more documents that demonstrate proof that this person is authorized to represent the company.
+ """
+ passport: NotRequired["AccountPersonCreateParamsDocumentsPassport"]
+ """
+ One or more documents showing the person's passport page with photo and personal data.
+ """
+ visa: NotRequired["AccountPersonCreateParamsDocumentsVisa"]
+ """
+ One or more documents showing the person's visa required for living in the country where they are residing.
+ """
+
+
+class AccountPersonCreateParamsDocumentsCompanyAuthorization(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountPersonCreateParamsDocumentsPassport(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountPersonCreateParamsDocumentsVisa(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountPersonCreateParamsRegisteredAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountPersonCreateParamsRelationship(TypedDict):
+ authorizer: NotRequired[bool]
+ """
+ Whether the person is the authorizer of the account's representative.
+ """
+ director: NotRequired[bool]
+ """
+ Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
+ """
+ executive: NotRequired[bool]
+ """
+ Whether the person has significant responsibility to control, manage, or direct the organization.
+ """
+ legal_guardian: NotRequired[bool]
+ """
+ Whether the person is the legal guardian of the account's representative.
+ """
+ owner: NotRequired[bool]
+ """
+ Whether the person is an owner of the account's legal entity.
+ """
+ percent_ownership: NotRequired["Literal['']|float"]
+ """
+ The percent owned by the person of the account's legal entity.
+ """
+ representative: NotRequired[bool]
+ """
+ Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
+ """
+ title: NotRequired[str]
+ """
+ The person's title (e.g., CEO, Support Engineer).
+ """
+
+
+class AccountPersonCreateParamsUsCfpbData(TypedDict):
+ ethnicity_details: NotRequired[
+ "AccountPersonCreateParamsUsCfpbDataEthnicityDetails"
+ ]
+ """
+ The persons ethnicity details
+ """
+ race_details: NotRequired["AccountPersonCreateParamsUsCfpbDataRaceDetails"]
+ """
+ The persons race details
+ """
+ self_identified_gender: NotRequired[str]
+ """
+ The persons self-identified gender
+ """
+
+
+class AccountPersonCreateParamsUsCfpbDataEthnicityDetails(TypedDict):
+ ethnicity: NotRequired[
+ List[
+ Literal[
+ "cuban",
+ "hispanic_or_latino",
+ "mexican",
+ "not_hispanic_or_latino",
+ "other_hispanic_or_latino",
+ "prefer_not_to_answer",
+ "puerto_rican",
+ ]
+ ]
+ ]
+ """
+ The persons ethnicity
+ """
+ ethnicity_other: NotRequired[str]
+ """
+ Please specify your origin, when other is selected.
+ """
+
+
+class AccountPersonCreateParamsUsCfpbDataRaceDetails(TypedDict):
+ race: NotRequired[
+ List[
+ Literal[
+ "african_american",
+ "american_indian_or_alaska_native",
+ "asian",
+ "asian_indian",
+ "black_or_african_american",
+ "chinese",
+ "ethiopian",
+ "filipino",
+ "guamanian_or_chamorro",
+ "haitian",
+ "jamaican",
+ "japanese",
+ "korean",
+ "native_hawaiian",
+ "native_hawaiian_or_other_pacific_islander",
+ "nigerian",
+ "other_asian",
+ "other_black_or_african_american",
+ "other_pacific_islander",
+ "prefer_not_to_answer",
+ "samoan",
+ "somali",
+ "vietnamese",
+ "white",
+ ]
+ ]
+ ]
+ """
+ The persons race.
+ """
+ race_other: NotRequired[str]
+ """
+ Please specify your race, when other is selected.
+ """
+
+
+class AccountPersonCreateParamsVerification(TypedDict):
+ additional_document: NotRequired[
+ "AccountPersonCreateParamsVerificationAdditionalDocument"
+ ]
+ """
+ A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
+ """
+ document: NotRequired["AccountPersonCreateParamsVerificationDocument"]
+ """
+ An identifying document, either a passport or local ID card.
+ """
+
+
+class AccountPersonCreateParamsVerificationAdditionalDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+
+
+class AccountPersonCreateParamsVerificationDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
diff --git a/stripe/params/_account_person_delete_params.py b/stripe/params/_account_person_delete_params.py
new file mode 100644
index 000000000..14b51a6f5
--- /dev/null
+++ b/stripe/params/_account_person_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing_extensions import TypedDict
+
+
+class AccountPersonDeleteParams(TypedDict):
+ pass
diff --git a/stripe/params/_account_person_list_params.py b/stripe/params/_account_person_list_params.py
new file mode 100644
index 000000000..053853a29
--- /dev/null
+++ b/stripe/params/_account_person_list_params.py
@@ -0,0 +1,54 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AccountPersonListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ relationship: NotRequired["AccountPersonListParamsRelationship"]
+ """
+ Filters on the list of people returned based on the person's relationship to the account's company.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class AccountPersonListParamsRelationship(TypedDict):
+ authorizer: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are authorizers of the account's representative.
+ """
+ director: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are directors of the account's company.
+ """
+ executive: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are executives of the account's company.
+ """
+ legal_guardian: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are legal guardians of the account's representative.
+ """
+ owner: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are owners of the account's company.
+ """
+ representative: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are the representative of the account's company.
+ """
diff --git a/stripe/params/_account_person_retrieve_params.py b/stripe/params/_account_person_retrieve_params.py
new file mode 100644
index 000000000..aa5b0f94a
--- /dev/null
+++ b/stripe/params/_account_person_retrieve_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AccountPersonRetrieveParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_account_person_update_params.py b/stripe/params/_account_person_update_params.py
new file mode 100644
index 000000000..c15713705
--- /dev/null
+++ b/stripe/params/_account_person_update_params.py
@@ -0,0 +1,470 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AccountPersonUpdateParams(TypedDict):
+ additional_tos_acceptances: NotRequired[
+ "AccountPersonUpdateParamsAdditionalTosAcceptances"
+ ]
+ """
+ Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.
+ """
+ address: NotRequired["AccountPersonUpdateParamsAddress"]
+ """
+ The person's address.
+ """
+ address_kana: NotRequired["AccountPersonUpdateParamsAddressKana"]
+ """
+ The Kana variation of the person's address (Japan only).
+ """
+ address_kanji: NotRequired["AccountPersonUpdateParamsAddressKanji"]
+ """
+ The Kanji variation of the person's address (Japan only).
+ """
+ dob: NotRequired["Literal['']|AccountPersonUpdateParamsDob"]
+ """
+ The person's date of birth.
+ """
+ documents: NotRequired["AccountPersonUpdateParamsDocuments"]
+ """
+ Documents that may be submitted to satisfy various informational requests.
+ """
+ email: NotRequired[str]
+ """
+ The person's email address.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ first_name: NotRequired[str]
+ """
+ The person's first name.
+ """
+ first_name_kana: NotRequired[str]
+ """
+ The Kana variation of the person's first name (Japan only).
+ """
+ first_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the person's first name (Japan only).
+ """
+ full_name_aliases: NotRequired["Literal['']|List[str]"]
+ """
+ A list of alternate names or aliases that the person is known by.
+ """
+ gender: NotRequired[str]
+ """
+ The person's gender (International regulations require either "male" or "female").
+ """
+ id_number: NotRequired[str]
+ """
+ The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ id_number_secondary: NotRequired[str]
+ """
+ The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ last_name: NotRequired[str]
+ """
+ The person's last name.
+ """
+ last_name_kana: NotRequired[str]
+ """
+ The Kana variation of the person's last name (Japan only).
+ """
+ last_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the person's last name (Japan only).
+ """
+ maiden_name: NotRequired[str]
+ """
+ The person's maiden name.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ nationality: NotRequired[str]
+ """
+ The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or "XX" if unavailable.
+ """
+ person_token: NotRequired[str]
+ """
+ A [person token](https://docs.stripe.com/connect/account-tokens), used to securely provide details to the person.
+ """
+ phone: NotRequired[str]
+ """
+ The person's phone number.
+ """
+ political_exposure: NotRequired[Literal["existing", "none"]]
+ """
+ Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
+ """
+ registered_address: NotRequired[
+ "AccountPersonUpdateParamsRegisteredAddress"
+ ]
+ """
+ The person's registered address.
+ """
+ relationship: NotRequired["AccountPersonUpdateParamsRelationship"]
+ """
+ The relationship that this person has with the account's legal entity.
+ """
+ ssn_last_4: NotRequired[str]
+ """
+ The last four digits of the person's Social Security number (U.S. only).
+ """
+ us_cfpb_data: NotRequired["AccountPersonUpdateParamsUsCfpbData"]
+ """
+ Demographic data related to the person.
+ """
+ verification: NotRequired["AccountPersonUpdateParamsVerification"]
+ """
+ The person's verification status.
+ """
+
+
+class AccountPersonUpdateParamsAdditionalTosAcceptances(TypedDict):
+ account: NotRequired[
+ "AccountPersonUpdateParamsAdditionalTosAcceptancesAccount"
+ ]
+ """
+ Details on the legal guardian's acceptance of the main Stripe service agreement.
+ """
+
+
+class AccountPersonUpdateParamsAdditionalTosAcceptancesAccount(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the account representative accepted the service agreement.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the account representative accepted the service agreement.
+ """
+ user_agent: NotRequired["Literal['']|str"]
+ """
+ The user agent of the browser from which the account representative accepted the service agreement.
+ """
+
+
+class AccountPersonUpdateParamsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountPersonUpdateParamsAddressKana(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountPersonUpdateParamsAddressKanji(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountPersonUpdateParamsDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class AccountPersonUpdateParamsDocuments(TypedDict):
+ company_authorization: NotRequired[
+ "AccountPersonUpdateParamsDocumentsCompanyAuthorization"
+ ]
+ """
+ One or more documents that demonstrate proof that this person is authorized to represent the company.
+ """
+ passport: NotRequired["AccountPersonUpdateParamsDocumentsPassport"]
+ """
+ One or more documents showing the person's passport page with photo and personal data.
+ """
+ visa: NotRequired["AccountPersonUpdateParamsDocumentsVisa"]
+ """
+ One or more documents showing the person's visa required for living in the country where they are residing.
+ """
+
+
+class AccountPersonUpdateParamsDocumentsCompanyAuthorization(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountPersonUpdateParamsDocumentsPassport(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountPersonUpdateParamsDocumentsVisa(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountPersonUpdateParamsRegisteredAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountPersonUpdateParamsRelationship(TypedDict):
+ authorizer: NotRequired[bool]
+ """
+ Whether the person is the authorizer of the account's representative.
+ """
+ director: NotRequired[bool]
+ """
+ Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
+ """
+ executive: NotRequired[bool]
+ """
+ Whether the person has significant responsibility to control, manage, or direct the organization.
+ """
+ legal_guardian: NotRequired[bool]
+ """
+ Whether the person is the legal guardian of the account's representative.
+ """
+ owner: NotRequired[bool]
+ """
+ Whether the person is an owner of the account's legal entity.
+ """
+ percent_ownership: NotRequired["Literal['']|float"]
+ """
+ The percent owned by the person of the account's legal entity.
+ """
+ representative: NotRequired[bool]
+ """
+ Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
+ """
+ title: NotRequired[str]
+ """
+ The person's title (e.g., CEO, Support Engineer).
+ """
+
+
+class AccountPersonUpdateParamsUsCfpbData(TypedDict):
+ ethnicity_details: NotRequired[
+ "AccountPersonUpdateParamsUsCfpbDataEthnicityDetails"
+ ]
+ """
+ The persons ethnicity details
+ """
+ race_details: NotRequired["AccountPersonUpdateParamsUsCfpbDataRaceDetails"]
+ """
+ The persons race details
+ """
+ self_identified_gender: NotRequired[str]
+ """
+ The persons self-identified gender
+ """
+
+
+class AccountPersonUpdateParamsUsCfpbDataEthnicityDetails(TypedDict):
+ ethnicity: NotRequired[
+ List[
+ Literal[
+ "cuban",
+ "hispanic_or_latino",
+ "mexican",
+ "not_hispanic_or_latino",
+ "other_hispanic_or_latino",
+ "prefer_not_to_answer",
+ "puerto_rican",
+ ]
+ ]
+ ]
+ """
+ The persons ethnicity
+ """
+ ethnicity_other: NotRequired[str]
+ """
+ Please specify your origin, when other is selected.
+ """
+
+
+class AccountPersonUpdateParamsUsCfpbDataRaceDetails(TypedDict):
+ race: NotRequired[
+ List[
+ Literal[
+ "african_american",
+ "american_indian_or_alaska_native",
+ "asian",
+ "asian_indian",
+ "black_or_african_american",
+ "chinese",
+ "ethiopian",
+ "filipino",
+ "guamanian_or_chamorro",
+ "haitian",
+ "jamaican",
+ "japanese",
+ "korean",
+ "native_hawaiian",
+ "native_hawaiian_or_other_pacific_islander",
+ "nigerian",
+ "other_asian",
+ "other_black_or_african_american",
+ "other_pacific_islander",
+ "prefer_not_to_answer",
+ "samoan",
+ "somali",
+ "vietnamese",
+ "white",
+ ]
+ ]
+ ]
+ """
+ The persons race.
+ """
+ race_other: NotRequired[str]
+ """
+ Please specify your race, when other is selected.
+ """
+
+
+class AccountPersonUpdateParamsVerification(TypedDict):
+ additional_document: NotRequired[
+ "AccountPersonUpdateParamsVerificationAdditionalDocument"
+ ]
+ """
+ A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
+ """
+ document: NotRequired["AccountPersonUpdateParamsVerificationDocument"]
+ """
+ An identifying document, either a passport or local ID card.
+ """
+
+
+class AccountPersonUpdateParamsVerificationAdditionalDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+
+
+class AccountPersonUpdateParamsVerificationDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
diff --git a/stripe/params/_account_persons_params.py b/stripe/params/_account_persons_params.py
new file mode 100644
index 000000000..326548281
--- /dev/null
+++ b/stripe/params/_account_persons_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AccountPersonsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ relationship: NotRequired["AccountPersonsParamsRelationship"]
+ """
+ Filters on the list of people returned based on the person's relationship to the account's company.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class AccountPersonsParamsRelationship(TypedDict):
+ authorizer: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are authorizers of the account's representative.
+ """
+ director: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are directors of the account's company.
+ """
+ executive: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are executives of the account's company.
+ """
+ legal_guardian: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are legal guardians of the account's representative.
+ """
+ owner: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are owners of the account's company.
+ """
+ representative: NotRequired[bool]
+ """
+ A filter on the list of people returned based on whether these people are the representative of the account's company.
+ """
diff --git a/stripe/params/_account_reject_params.py b/stripe/params/_account_reject_params.py
new file mode 100644
index 000000000..d94d097b1
--- /dev/null
+++ b/stripe/params/_account_reject_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AccountRejectParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ reason: str
+ """
+ The reason for rejecting the account. Can be `fraud`, `terms_of_service`, or `other`.
+ """
diff --git a/stripe/params/_account_retrieve_capability_params.py b/stripe/params/_account_retrieve_capability_params.py
new file mode 100644
index 000000000..64072972d
--- /dev/null
+++ b/stripe/params/_account_retrieve_capability_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AccountRetrieveCapabilityParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_account_retrieve_current_params.py b/stripe/params/_account_retrieve_current_params.py
new file mode 100644
index 000000000..4ac5f8eeb
--- /dev/null
+++ b/stripe/params/_account_retrieve_current_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AccountRetrieveCurrentParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_account_retrieve_external_account_params.py b/stripe/params/_account_retrieve_external_account_params.py
new file mode 100644
index 000000000..46990ff24
--- /dev/null
+++ b/stripe/params/_account_retrieve_external_account_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AccountRetrieveExternalAccountParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_account_retrieve_params.py b/stripe/params/_account_retrieve_params.py
new file mode 100644
index 000000000..a9e3c8a22
--- /dev/null
+++ b/stripe/params/_account_retrieve_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AccountRetrieveParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_account_retrieve_person_params.py b/stripe/params/_account_retrieve_person_params.py
new file mode 100644
index 000000000..77eb3ff14
--- /dev/null
+++ b/stripe/params/_account_retrieve_person_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AccountRetrievePersonParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_account_session_create_params.py b/stripe/params/_account_session_create_params.py
new file mode 100644
index 000000000..41812dfe2
--- /dev/null
+++ b/stripe/params/_account_session_create_params.py
@@ -0,0 +1,638 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AccountSessionCreateParams(RequestOptions):
+ account: str
+ """
+ The identifier of the account to create an Account Session for.
+ """
+ components: "AccountSessionCreateParamsComponents"
+ """
+ Each key of the dictionary represents an embedded component, and each embedded component maps to its configuration (e.g. whether it has been enabled or not).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+
+
+class AccountSessionCreateParamsComponents(TypedDict):
+ account_management: NotRequired[
+ "AccountSessionCreateParamsComponentsAccountManagement"
+ ]
+ """
+ Configuration for the [account management](https://docs.stripe.com/connect/supported-embedded-components/account-management/) embedded component.
+ """
+ account_onboarding: NotRequired[
+ "AccountSessionCreateParamsComponentsAccountOnboarding"
+ ]
+ """
+ Configuration for the [account onboarding](https://docs.stripe.com/connect/supported-embedded-components/account-onboarding/) embedded component.
+ """
+ balances: NotRequired["AccountSessionCreateParamsComponentsBalances"]
+ """
+ Configuration for the [balances](https://docs.stripe.com/connect/supported-embedded-components/balances/) embedded component.
+ """
+ disputes_list: NotRequired[
+ "AccountSessionCreateParamsComponentsDisputesList"
+ ]
+ """
+ Configuration for the [disputes list](https://docs.stripe.com/connect/supported-embedded-components/disputes-list/) embedded component.
+ """
+ documents: NotRequired["AccountSessionCreateParamsComponentsDocuments"]
+ """
+ Configuration for the [documents](https://docs.stripe.com/connect/supported-embedded-components/documents/) embedded component.
+ """
+ financial_account: NotRequired[
+ "AccountSessionCreateParamsComponentsFinancialAccount"
+ ]
+ """
+ Configuration for the [financial account](https://docs.stripe.com/connect/supported-embedded-components/financial-account/) embedded component.
+ """
+ financial_account_transactions: NotRequired[
+ "AccountSessionCreateParamsComponentsFinancialAccountTransactions"
+ ]
+ """
+ Configuration for the [financial account transactions](https://docs.stripe.com/connect/supported-embedded-components/financial-account-transactions/) embedded component.
+ """
+ instant_payouts_promotion: NotRequired[
+ "AccountSessionCreateParamsComponentsInstantPayoutsPromotion"
+ ]
+ """
+ Configuration for the [instant payouts promotion](https://docs.stripe.com/connect/supported-embedded-components/instant-payouts-promotion/) embedded component.
+ """
+ issuing_card: NotRequired[
+ "AccountSessionCreateParamsComponentsIssuingCard"
+ ]
+ """
+ Configuration for the [issuing card](https://docs.stripe.com/connect/supported-embedded-components/issuing-card/) embedded component.
+ """
+ issuing_cards_list: NotRequired[
+ "AccountSessionCreateParamsComponentsIssuingCardsList"
+ ]
+ """
+ Configuration for the [issuing cards list](https://docs.stripe.com/connect/supported-embedded-components/issuing-cards-list/) embedded component.
+ """
+ notification_banner: NotRequired[
+ "AccountSessionCreateParamsComponentsNotificationBanner"
+ ]
+ """
+ Configuration for the [notification banner](https://docs.stripe.com/connect/supported-embedded-components/notification-banner/) embedded component.
+ """
+ payment_details: NotRequired[
+ "AccountSessionCreateParamsComponentsPaymentDetails"
+ ]
+ """
+ Configuration for the [payment details](https://docs.stripe.com/connect/supported-embedded-components/payment-details/) embedded component.
+ """
+ payment_disputes: NotRequired[
+ "AccountSessionCreateParamsComponentsPaymentDisputes"
+ ]
+ """
+ Configuration for the [payment disputes](https://docs.stripe.com/connect/supported-embedded-components/payment-disputes/) embedded component.
+ """
+ payments: NotRequired["AccountSessionCreateParamsComponentsPayments"]
+ """
+ Configuration for the [payments](https://docs.stripe.com/connect/supported-embedded-components/payments/) embedded component.
+ """
+ payout_details: NotRequired[
+ "AccountSessionCreateParamsComponentsPayoutDetails"
+ ]
+ """
+ Configuration for the [payout details](https://docs.stripe.com/connect/supported-embedded-components/payout-details/) embedded component.
+ """
+ payouts: NotRequired["AccountSessionCreateParamsComponentsPayouts"]
+ """
+ Configuration for the [payouts](https://docs.stripe.com/connect/supported-embedded-components/payouts/) embedded component.
+ """
+ payouts_list: NotRequired[
+ "AccountSessionCreateParamsComponentsPayoutsList"
+ ]
+ """
+ Configuration for the [payouts list](https://docs.stripe.com/connect/supported-embedded-components/payouts-list/) embedded component.
+ """
+ tax_registrations: NotRequired[
+ "AccountSessionCreateParamsComponentsTaxRegistrations"
+ ]
+ """
+ Configuration for the [tax registrations](https://docs.stripe.com/connect/supported-embedded-components/tax-registrations/) embedded component.
+ """
+ tax_settings: NotRequired[
+ "AccountSessionCreateParamsComponentsTaxSettings"
+ ]
+ """
+ Configuration for the [tax settings](https://docs.stripe.com/connect/supported-embedded-components/tax-settings/) embedded component.
+ """
+
+
+class AccountSessionCreateParamsComponentsAccountManagement(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsAccountManagementFeatures"
+ ]
+ """
+ The list of features enabled in the embedded component.
+ """
+
+
+class AccountSessionCreateParamsComponentsAccountManagementFeatures(TypedDict):
+ disable_stripe_user_authentication: NotRequired[bool]
+ """
+ Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
+ """
+ external_account_collection: NotRequired[bool]
+ """
+ Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
+ """
+
+
+class AccountSessionCreateParamsComponentsAccountOnboarding(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsAccountOnboardingFeatures"
+ ]
+ """
+ The list of features enabled in the embedded component.
+ """
+
+
+class AccountSessionCreateParamsComponentsAccountOnboardingFeatures(TypedDict):
+ disable_stripe_user_authentication: NotRequired[bool]
+ """
+ Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
+ """
+ external_account_collection: NotRequired[bool]
+ """
+ Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
+ """
+
+
+class AccountSessionCreateParamsComponentsBalances(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsBalancesFeatures"
+ ]
+ """
+ The list of features enabled in the embedded component.
+ """
+
+
+class AccountSessionCreateParamsComponentsBalancesFeatures(TypedDict):
+ disable_stripe_user_authentication: NotRequired[bool]
+ """
+ Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
+ """
+ edit_payout_schedule: NotRequired[bool]
+ """
+ Whether to allow payout schedule to be changed. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
+ """
+ external_account_collection: NotRequired[bool]
+ """
+ Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
+ """
+ instant_payouts: NotRequired[bool]
+ """
+ Whether to allow creation of instant payouts. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
+ """
+ standard_payouts: NotRequired[bool]
+ """
+ Whether to allow creation of standard payouts. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
+ """
+
+
+class AccountSessionCreateParamsComponentsDisputesList(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsDisputesListFeatures"
+ ]
+ """
+ The list of features enabled in the embedded component.
+ """
+
+
+class AccountSessionCreateParamsComponentsDisputesListFeatures(TypedDict):
+ capture_payments: NotRequired[bool]
+ """
+ Whether to allow capturing and cancelling payment intents. This is `true` by default.
+ """
+ destination_on_behalf_of_charge_management: NotRequired[bool]
+ """
+ Whether connected accounts can manage destination charges that are created on behalf of them. This is `false` by default.
+ """
+ dispute_management: NotRequired[bool]
+ """
+ Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This is `true` by default.
+ """
+ refund_management: NotRequired[bool]
+ """
+ Whether sending refunds is enabled. This is `true` by default.
+ """
+
+
+class AccountSessionCreateParamsComponentsDocuments(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsDocumentsFeatures"
+ ]
+ """
+ An empty list, because this embedded component has no features.
+ """
+
+
+class AccountSessionCreateParamsComponentsDocumentsFeatures(TypedDict):
+ pass
+
+
+class AccountSessionCreateParamsComponentsFinancialAccount(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsFinancialAccountFeatures"
+ ]
+ """
+ The list of features enabled in the embedded component.
+ """
+
+
+class AccountSessionCreateParamsComponentsFinancialAccountFeatures(TypedDict):
+ disable_stripe_user_authentication: NotRequired[bool]
+ """
+ Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
+ """
+ external_account_collection: NotRequired[bool]
+ """
+ Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
+ """
+ send_money: NotRequired[bool]
+ """
+ Whether to allow sending money.
+ """
+ transfer_balance: NotRequired[bool]
+ """
+ Whether to allow transferring balance.
+ """
+
+
+class AccountSessionCreateParamsComponentsFinancialAccountTransactions(
+ TypedDict,
+):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsFinancialAccountTransactionsFeatures"
+ ]
+ """
+ The list of features enabled in the embedded component.
+ """
+
+
+class AccountSessionCreateParamsComponentsFinancialAccountTransactionsFeatures(
+ TypedDict,
+):
+ card_spend_dispute_management: NotRequired[bool]
+ """
+ Whether to allow card spend dispute management features.
+ """
+
+
+class AccountSessionCreateParamsComponentsInstantPayoutsPromotion(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsInstantPayoutsPromotionFeatures"
+ ]
+ """
+ The list of features enabled in the embedded component.
+ """
+
+
+class AccountSessionCreateParamsComponentsInstantPayoutsPromotionFeatures(
+ TypedDict,
+):
+ disable_stripe_user_authentication: NotRequired[bool]
+ """
+ Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
+ """
+ external_account_collection: NotRequired[bool]
+ """
+ Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
+ """
+ instant_payouts: NotRequired[bool]
+ """
+ Whether to allow creation of instant payouts. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
+ """
+
+
+class AccountSessionCreateParamsComponentsIssuingCard(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsIssuingCardFeatures"
+ ]
+ """
+ The list of features enabled in the embedded component.
+ """
+
+
+class AccountSessionCreateParamsComponentsIssuingCardFeatures(TypedDict):
+ card_management: NotRequired[bool]
+ """
+ Whether to allow card management features.
+ """
+ card_spend_dispute_management: NotRequired[bool]
+ """
+ Whether to allow card spend dispute management features.
+ """
+ cardholder_management: NotRequired[bool]
+ """
+ Whether to allow cardholder management features.
+ """
+ spend_control_management: NotRequired[bool]
+ """
+ Whether to allow spend control management features.
+ """
+
+
+class AccountSessionCreateParamsComponentsIssuingCardsList(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsIssuingCardsListFeatures"
+ ]
+ """
+ The list of features enabled in the embedded component.
+ """
+
+
+class AccountSessionCreateParamsComponentsIssuingCardsListFeatures(TypedDict):
+ card_management: NotRequired[bool]
+ """
+ Whether to allow card management features.
+ """
+ card_spend_dispute_management: NotRequired[bool]
+ """
+ Whether to allow card spend dispute management features.
+ """
+ cardholder_management: NotRequired[bool]
+ """
+ Whether to allow cardholder management features.
+ """
+ disable_stripe_user_authentication: NotRequired[bool]
+ """
+ Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
+ """
+ spend_control_management: NotRequired[bool]
+ """
+ Whether to allow spend control management features.
+ """
+
+
+class AccountSessionCreateParamsComponentsNotificationBanner(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsNotificationBannerFeatures"
+ ]
+ """
+ The list of features enabled in the embedded component.
+ """
+
+
+class AccountSessionCreateParamsComponentsNotificationBannerFeatures(
+ TypedDict
+):
+ disable_stripe_user_authentication: NotRequired[bool]
+ """
+ Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
+ """
+ external_account_collection: NotRequired[bool]
+ """
+ Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
+ """
+
+
+class AccountSessionCreateParamsComponentsPaymentDetails(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsPaymentDetailsFeatures"
+ ]
+ """
+ The list of features enabled in the embedded component.
+ """
+
+
+class AccountSessionCreateParamsComponentsPaymentDetailsFeatures(TypedDict):
+ capture_payments: NotRequired[bool]
+ """
+ Whether to allow capturing and cancelling payment intents. This is `true` by default.
+ """
+ destination_on_behalf_of_charge_management: NotRequired[bool]
+ """
+ Whether connected accounts can manage destination charges that are created on behalf of them. This is `false` by default.
+ """
+ dispute_management: NotRequired[bool]
+ """
+ Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This is `true` by default.
+ """
+ refund_management: NotRequired[bool]
+ """
+ Whether sending refunds is enabled. This is `true` by default.
+ """
+
+
+class AccountSessionCreateParamsComponentsPaymentDisputes(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsPaymentDisputesFeatures"
+ ]
+ """
+ The list of features enabled in the embedded component.
+ """
+
+
+class AccountSessionCreateParamsComponentsPaymentDisputesFeatures(TypedDict):
+ destination_on_behalf_of_charge_management: NotRequired[bool]
+ """
+ Whether connected accounts can manage destination charges that are created on behalf of them. This is `false` by default.
+ """
+ dispute_management: NotRequired[bool]
+ """
+ Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This is `true` by default.
+ """
+ refund_management: NotRequired[bool]
+ """
+ Whether sending refunds is enabled. This is `true` by default.
+ """
+
+
+class AccountSessionCreateParamsComponentsPayments(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsPaymentsFeatures"
+ ]
+ """
+ The list of features enabled in the embedded component.
+ """
+
+
+class AccountSessionCreateParamsComponentsPaymentsFeatures(TypedDict):
+ capture_payments: NotRequired[bool]
+ """
+ Whether to allow capturing and cancelling payment intents. This is `true` by default.
+ """
+ destination_on_behalf_of_charge_management: NotRequired[bool]
+ """
+ Whether connected accounts can manage destination charges that are created on behalf of them. This is `false` by default.
+ """
+ dispute_management: NotRequired[bool]
+ """
+ Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This is `true` by default.
+ """
+ refund_management: NotRequired[bool]
+ """
+ Whether sending refunds is enabled. This is `true` by default.
+ """
+
+
+class AccountSessionCreateParamsComponentsPayoutDetails(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsPayoutDetailsFeatures"
+ ]
+ """
+ An empty list, because this embedded component has no features.
+ """
+
+
+class AccountSessionCreateParamsComponentsPayoutDetailsFeatures(TypedDict):
+ pass
+
+
+class AccountSessionCreateParamsComponentsPayouts(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsPayoutsFeatures"
+ ]
+ """
+ The list of features enabled in the embedded component.
+ """
+
+
+class AccountSessionCreateParamsComponentsPayoutsFeatures(TypedDict):
+ disable_stripe_user_authentication: NotRequired[bool]
+ """
+ Whether Stripe user authentication is disabled. This value can only be `true` for accounts where `controller.requirement_collection` is `application` for the account. The default value is the opposite of the `external_account_collection` value. For example, if you don't set `external_account_collection`, it defaults to `true` and `disable_stripe_user_authentication` defaults to `false`.
+ """
+ edit_payout_schedule: NotRequired[bool]
+ """
+ Whether to allow payout schedule to be changed. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
+ """
+ external_account_collection: NotRequired[bool]
+ """
+ Whether external account collection is enabled. This feature can only be `false` for accounts where you're responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature is `true`.
+ """
+ instant_payouts: NotRequired[bool]
+ """
+ Whether to allow creation of instant payouts. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
+ """
+ standard_payouts: NotRequired[bool]
+ """
+ Whether to allow creation of standard payouts. Defaults to `true` when `controller.losses.payments` is set to `stripe` for the account, otherwise `false`.
+ """
+
+
+class AccountSessionCreateParamsComponentsPayoutsList(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsPayoutsListFeatures"
+ ]
+ """
+ An empty list, because this embedded component has no features.
+ """
+
+
+class AccountSessionCreateParamsComponentsPayoutsListFeatures(TypedDict):
+ pass
+
+
+class AccountSessionCreateParamsComponentsTaxRegistrations(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsTaxRegistrationsFeatures"
+ ]
+ """
+ An empty list, because this embedded component has no features.
+ """
+
+
+class AccountSessionCreateParamsComponentsTaxRegistrationsFeatures(TypedDict):
+ pass
+
+
+class AccountSessionCreateParamsComponentsTaxSettings(TypedDict):
+ enabled: bool
+ """
+ Whether the embedded component is enabled.
+ """
+ features: NotRequired[
+ "AccountSessionCreateParamsComponentsTaxSettingsFeatures"
+ ]
+ """
+ An empty list, because this embedded component has no features.
+ """
+
+
+class AccountSessionCreateParamsComponentsTaxSettingsFeatures(TypedDict):
+ pass
diff --git a/stripe/params/_account_update_params.py b/stripe/params/_account_update_params.py
new file mode 100644
index 000000000..df3925492
--- /dev/null
+++ b/stripe/params/_account_update_params.py
@@ -0,0 +1,1905 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AccountUpdateParams(TypedDict):
+ account_token: NotRequired[str]
+ """
+ An [account token](https://stripe.com/docs/api#create_account_token), used to securely provide details to the account.
+ """
+ business_profile: NotRequired["AccountUpdateParamsBusinessProfile"]
+ """
+ Business information about the account.
+ """
+ business_type: NotRequired[
+ Literal["company", "government_entity", "individual", "non_profit"]
+ ]
+ """
+ The business type. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
+ """
+ capabilities: NotRequired["AccountUpdateParamsCapabilities"]
+ """
+ Each key of the dictionary represents a capability, and each capability
+ maps to its settings (for example, whether it has been requested or not). Each
+ capability is inactive until you have provided its specific
+ requirements and Stripe has verified them. An account might have some
+ of its requested capabilities be active and some be inactive.
+
+ Required when [account.controller.stripe_dashboard.type](https://docs.stripe.com/api/accounts/create#create_account-controller-dashboard-type)
+ is `none`, which includes Custom accounts.
+ """
+ company: NotRequired["AccountUpdateParamsCompany"]
+ """
+ Information about the company or business. This field is available for any `business_type`. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
+ """
+ default_currency: NotRequired[str]
+ """
+ Three-letter ISO currency code representing the default currency for the account. This must be a currency that [Stripe supports in the account's country](https://docs.stripe.com/payouts).
+ """
+ documents: NotRequired["AccountUpdateParamsDocuments"]
+ """
+ Documents that may be submitted to satisfy various informational requests.
+ """
+ email: NotRequired[str]
+ """
+ The email address of the account holder. This is only to make the account easier to identify to you. If [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, Stripe doesn't email the account without your consent.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ external_account: NotRequired[
+ "Literal['']|str|AccountUpdateParamsBankAccount|AccountUpdateParamsCard|AccountUpdateParamsCardToken"
+ ]
+ """
+ A card or bank account to attach to the account for receiving [payouts](https://docs.stripe.com/connect/bank-debit-card-payouts) (you won't be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](https://docs.stripe.com/js), or a dictionary, as documented in the `external_account` parameter for [bank account](https://docs.stripe.com/api#account_create_bank_account) creation.
+
+ By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the [bank account](https://docs.stripe.com/api#account_create_bank_account) or [card creation](https://docs.stripe.com/api#account_create_card) APIs. After you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
+ """
+ groups: NotRequired["AccountUpdateParamsGroups"]
+ """
+ A hash of account group type to tokens. These are account groups this account should be added to.
+ """
+ individual: NotRequired["AccountUpdateParamsIndividual"]
+ """
+ Information about the person represented by the account. This field is null unless `business_type` is set to `individual`. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ settings: NotRequired["AccountUpdateParamsSettings"]
+ """
+ Options for customizing how the account functions within Stripe.
+ """
+ tos_acceptance: NotRequired["AccountUpdateParamsTosAcceptance"]
+ """
+ Details on the account's acceptance of the [Stripe Services Agreement](https://docs.stripe.com/connect/updating-accounts#tos-acceptance). This property can only be updated for accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts. This property defaults to a `full` service agreement when empty.
+ """
+
+
+class AccountUpdateParamsBusinessProfile(TypedDict):
+ annual_revenue: NotRequired[
+ "AccountUpdateParamsBusinessProfileAnnualRevenue"
+ ]
+ """
+ The applicant's gross annual revenue for its preceding fiscal year.
+ """
+ estimated_worker_count: NotRequired[int]
+ """
+ An estimated upper bound of employees, contractors, vendors, etc. currently working for the business.
+ """
+ mcc: NotRequired[str]
+ """
+ [The merchant category code for the account](https://docs.stripe.com/connect/setting-mcc). MCCs are used to classify businesses based on the goods or services they provide.
+ """
+ minority_owned_business_designation: NotRequired[
+ List[
+ Literal[
+ "lgbtqi_owned_business",
+ "minority_owned_business",
+ "none_of_these_apply",
+ "prefer_not_to_answer",
+ "women_owned_business",
+ ]
+ ]
+ ]
+ """
+ Whether the business is a minority-owned, women-owned, and/or LGBTQI+ -owned business.
+ """
+ monthly_estimated_revenue: NotRequired[
+ "AccountUpdateParamsBusinessProfileMonthlyEstimatedRevenue"
+ ]
+ """
+ An estimate of the monthly revenue of the business. Only accepted for accounts in Brazil and India.
+ """
+ name: NotRequired[str]
+ """
+ The customer-facing business name.
+ """
+ product_description: NotRequired[str]
+ """
+ Internal-only description of the product sold by, or service provided by, the business. Used by Stripe for risk and underwriting purposes.
+ """
+ support_address: NotRequired[
+ "AccountUpdateParamsBusinessProfileSupportAddress"
+ ]
+ """
+ A publicly available mailing address for sending support issues to.
+ """
+ support_email: NotRequired[str]
+ """
+ A publicly available email address for sending support issues to.
+ """
+ support_phone: NotRequired[str]
+ """
+ A publicly available phone number to call with support issues.
+ """
+ support_url: NotRequired["Literal['']|str"]
+ """
+ A publicly available website for handling support issues.
+ """
+ url: NotRequired[str]
+ """
+ The business's publicly available website.
+ """
+
+
+class AccountUpdateParamsBusinessProfileAnnualRevenue(TypedDict):
+ amount: int
+ """
+ A non-negative integer representing the amount in the [smallest currency unit](https://docs.stripe.com/currencies#zero-decimal).
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ fiscal_year_end: str
+ """
+ The close-out date of the preceding fiscal year in ISO 8601 format. E.g. 2023-12-31 for the 31st of December, 2023.
+ """
+
+
+class AccountUpdateParamsBusinessProfileMonthlyEstimatedRevenue(TypedDict):
+ amount: int
+ """
+ A non-negative integer representing how much to charge in the [smallest currency unit](https://docs.stripe.com/currencies#zero-decimal).
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+
+
+class AccountUpdateParamsBusinessProfileSupportAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountUpdateParamsCapabilities(TypedDict):
+ acss_debit_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesAcssDebitPayments"
+ ]
+ """
+ The acss_debit_payments capability.
+ """
+ affirm_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesAffirmPayments"
+ ]
+ """
+ The affirm_payments capability.
+ """
+ afterpay_clearpay_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesAfterpayClearpayPayments"
+ ]
+ """
+ The afterpay_clearpay_payments capability.
+ """
+ alma_payments: NotRequired["AccountUpdateParamsCapabilitiesAlmaPayments"]
+ """
+ The alma_payments capability.
+ """
+ amazon_pay_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesAmazonPayPayments"
+ ]
+ """
+ The amazon_pay_payments capability.
+ """
+ au_becs_debit_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesAuBecsDebitPayments"
+ ]
+ """
+ The au_becs_debit_payments capability.
+ """
+ bacs_debit_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesBacsDebitPayments"
+ ]
+ """
+ The bacs_debit_payments capability.
+ """
+ bancontact_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesBancontactPayments"
+ ]
+ """
+ The bancontact_payments capability.
+ """
+ bank_transfer_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesBankTransferPayments"
+ ]
+ """
+ The bank_transfer_payments capability.
+ """
+ billie_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesBilliePayments"
+ ]
+ """
+ The billie_payments capability.
+ """
+ blik_payments: NotRequired["AccountUpdateParamsCapabilitiesBlikPayments"]
+ """
+ The blik_payments capability.
+ """
+ boleto_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesBoletoPayments"
+ ]
+ """
+ The boleto_payments capability.
+ """
+ card_issuing: NotRequired["AccountUpdateParamsCapabilitiesCardIssuing"]
+ """
+ The card_issuing capability.
+ """
+ card_payments: NotRequired["AccountUpdateParamsCapabilitiesCardPayments"]
+ """
+ The card_payments capability.
+ """
+ cartes_bancaires_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesCartesBancairesPayments"
+ ]
+ """
+ The cartes_bancaires_payments capability.
+ """
+ cashapp_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesCashappPayments"
+ ]
+ """
+ The cashapp_payments capability.
+ """
+ crypto_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesCryptoPayments"
+ ]
+ """
+ The crypto_payments capability.
+ """
+ eps_payments: NotRequired["AccountUpdateParamsCapabilitiesEpsPayments"]
+ """
+ The eps_payments capability.
+ """
+ fpx_payments: NotRequired["AccountUpdateParamsCapabilitiesFpxPayments"]
+ """
+ The fpx_payments capability.
+ """
+ gb_bank_transfer_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesGbBankTransferPayments"
+ ]
+ """
+ The gb_bank_transfer_payments capability.
+ """
+ giropay_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesGiropayPayments"
+ ]
+ """
+ The giropay_payments capability.
+ """
+ grabpay_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesGrabpayPayments"
+ ]
+ """
+ The grabpay_payments capability.
+ """
+ ideal_payments: NotRequired["AccountUpdateParamsCapabilitiesIdealPayments"]
+ """
+ The ideal_payments capability.
+ """
+ india_international_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesIndiaInternationalPayments"
+ ]
+ """
+ The india_international_payments capability.
+ """
+ jcb_payments: NotRequired["AccountUpdateParamsCapabilitiesJcbPayments"]
+ """
+ The jcb_payments capability.
+ """
+ jp_bank_transfer_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesJpBankTransferPayments"
+ ]
+ """
+ The jp_bank_transfer_payments capability.
+ """
+ kakao_pay_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesKakaoPayPayments"
+ ]
+ """
+ The kakao_pay_payments capability.
+ """
+ klarna_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesKlarnaPayments"
+ ]
+ """
+ The klarna_payments capability.
+ """
+ konbini_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesKonbiniPayments"
+ ]
+ """
+ The konbini_payments capability.
+ """
+ kr_card_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesKrCardPayments"
+ ]
+ """
+ The kr_card_payments capability.
+ """
+ legacy_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesLegacyPayments"
+ ]
+ """
+ The legacy_payments capability.
+ """
+ link_payments: NotRequired["AccountUpdateParamsCapabilitiesLinkPayments"]
+ """
+ The link_payments capability.
+ """
+ mb_way_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesMbWayPayments"
+ ]
+ """
+ The mb_way_payments capability.
+ """
+ mobilepay_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesMobilepayPayments"
+ ]
+ """
+ The mobilepay_payments capability.
+ """
+ multibanco_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesMultibancoPayments"
+ ]
+ """
+ The multibanco_payments capability.
+ """
+ mx_bank_transfer_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesMxBankTransferPayments"
+ ]
+ """
+ The mx_bank_transfer_payments capability.
+ """
+ naver_pay_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesNaverPayPayments"
+ ]
+ """
+ The naver_pay_payments capability.
+ """
+ nz_bank_account_becs_debit_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesNzBankAccountBecsDebitPayments"
+ ]
+ """
+ The nz_bank_account_becs_debit_payments capability.
+ """
+ oxxo_payments: NotRequired["AccountUpdateParamsCapabilitiesOxxoPayments"]
+ """
+ The oxxo_payments capability.
+ """
+ p24_payments: NotRequired["AccountUpdateParamsCapabilitiesP24Payments"]
+ """
+ The p24_payments capability.
+ """
+ pay_by_bank_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesPayByBankPayments"
+ ]
+ """
+ The pay_by_bank_payments capability.
+ """
+ payco_payments: NotRequired["AccountUpdateParamsCapabilitiesPaycoPayments"]
+ """
+ The payco_payments capability.
+ """
+ paynow_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesPaynowPayments"
+ ]
+ """
+ The paynow_payments capability.
+ """
+ pix_payments: NotRequired["AccountUpdateParamsCapabilitiesPixPayments"]
+ """
+ The pix_payments capability.
+ """
+ promptpay_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesPromptpayPayments"
+ ]
+ """
+ The promptpay_payments capability.
+ """
+ revolut_pay_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesRevolutPayPayments"
+ ]
+ """
+ The revolut_pay_payments capability.
+ """
+ samsung_pay_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesSamsungPayPayments"
+ ]
+ """
+ The samsung_pay_payments capability.
+ """
+ satispay_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesSatispayPayments"
+ ]
+ """
+ The satispay_payments capability.
+ """
+ sepa_bank_transfer_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesSepaBankTransferPayments"
+ ]
+ """
+ The sepa_bank_transfer_payments capability.
+ """
+ sepa_debit_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesSepaDebitPayments"
+ ]
+ """
+ The sepa_debit_payments capability.
+ """
+ sofort_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesSofortPayments"
+ ]
+ """
+ The sofort_payments capability.
+ """
+ swish_payments: NotRequired["AccountUpdateParamsCapabilitiesSwishPayments"]
+ """
+ The swish_payments capability.
+ """
+ tax_reporting_us_1099_k: NotRequired[
+ "AccountUpdateParamsCapabilitiesTaxReportingUs1099K"
+ ]
+ """
+ The tax_reporting_us_1099_k capability.
+ """
+ tax_reporting_us_1099_misc: NotRequired[
+ "AccountUpdateParamsCapabilitiesTaxReportingUs1099Misc"
+ ]
+ """
+ The tax_reporting_us_1099_misc capability.
+ """
+ transfers: NotRequired["AccountUpdateParamsCapabilitiesTransfers"]
+ """
+ The transfers capability.
+ """
+ treasury: NotRequired["AccountUpdateParamsCapabilitiesTreasury"]
+ """
+ The treasury capability.
+ """
+ twint_payments: NotRequired["AccountUpdateParamsCapabilitiesTwintPayments"]
+ """
+ The twint_payments capability.
+ """
+ us_bank_account_ach_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesUsBankAccountAchPayments"
+ ]
+ """
+ The us_bank_account_ach_payments capability.
+ """
+ us_bank_transfer_payments: NotRequired[
+ "AccountUpdateParamsCapabilitiesUsBankTransferPayments"
+ ]
+ """
+ The us_bank_transfer_payments capability.
+ """
+ zip_payments: NotRequired["AccountUpdateParamsCapabilitiesZipPayments"]
+ """
+ The zip_payments capability.
+ """
+
+
+class AccountUpdateParamsCapabilitiesAcssDebitPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesAffirmPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesAfterpayClearpayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesAlmaPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesAmazonPayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesAuBecsDebitPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesBacsDebitPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesBancontactPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesBankTransferPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesBilliePayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesBlikPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesBoletoPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesCardIssuing(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesCardPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesCartesBancairesPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesCashappPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesCryptoPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesEpsPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesFpxPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesGbBankTransferPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesGiropayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesGrabpayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesIdealPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesIndiaInternationalPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesJcbPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesJpBankTransferPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesKakaoPayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesKlarnaPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesKonbiniPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesKrCardPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesLegacyPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesLinkPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesMbWayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesMobilepayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesMultibancoPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesMxBankTransferPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesNaverPayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesNzBankAccountBecsDebitPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesOxxoPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesP24Payments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesPayByBankPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesPaycoPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesPaynowPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesPixPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesPromptpayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesRevolutPayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesSamsungPayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesSatispayPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesSepaBankTransferPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesSepaDebitPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesSofortPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesSwishPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesTaxReportingUs1099K(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesTaxReportingUs1099Misc(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesTransfers(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesTreasury(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesTwintPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesUsBankAccountAchPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesUsBankTransferPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCapabilitiesZipPayments(TypedDict):
+ requested: NotRequired[bool]
+ """
+ Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
+ """
+
+
+class AccountUpdateParamsCompany(TypedDict):
+ address: NotRequired["AccountUpdateParamsCompanyAddress"]
+ """
+ The company's primary address.
+ """
+ address_kana: NotRequired["AccountUpdateParamsCompanyAddressKana"]
+ """
+ The Kana variation of the company's primary address (Japan only).
+ """
+ address_kanji: NotRequired["AccountUpdateParamsCompanyAddressKanji"]
+ """
+ The Kanji variation of the company's primary address (Japan only).
+ """
+ directors_provided: NotRequired[bool]
+ """
+ Whether the company's directors have been provided. Set this Boolean to `true` after creating all the company's directors with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.director` requirement. This value is not automatically set to `true` after creating directors, so it needs to be updated to indicate all directors have been provided.
+ """
+ directorship_declaration: NotRequired[
+ "AccountUpdateParamsCompanyDirectorshipDeclaration"
+ ]
+ """
+ This hash is used to attest that the directors information provided to Stripe is both current and correct.
+ """
+ executives_provided: NotRequired[bool]
+ """
+ Whether the company's executives have been provided. Set this Boolean to `true` after creating all the company's executives with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.executive` requirement.
+ """
+ export_license_id: NotRequired[str]
+ """
+ The export license ID number of the company, also referred as Import Export Code (India only).
+ """
+ export_purpose_code: NotRequired[str]
+ """
+ The purpose code to use for export transactions (India only).
+ """
+ name: NotRequired[str]
+ """
+ The company's legal name.
+ """
+ name_kana: NotRequired[str]
+ """
+ The Kana variation of the company's legal name (Japan only).
+ """
+ name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the company's legal name (Japan only).
+ """
+ owners_provided: NotRequired[bool]
+ """
+ Whether the company's owners have been provided. Set this Boolean to `true` after creating all the company's owners with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.owner` requirement.
+ """
+ ownership_declaration: NotRequired[
+ "AccountUpdateParamsCompanyOwnershipDeclaration"
+ ]
+ """
+ This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
+ """
+ ownership_exemption_reason: NotRequired[
+ "Literal['']|Literal['qualified_entity_exceeds_ownership_threshold', 'qualifies_as_financial_institution']"
+ ]
+ """
+ This value is used to determine if a business is exempt from providing ultimate beneficial owners. See [this support article](https://support.stripe.com/questions/exemption-from-providing-ownership-details) and [changelog](https://docs.stripe.com/changelog/acacia/2025-01-27/ownership-exemption-reason-accounts-api) for more details.
+ """
+ phone: NotRequired[str]
+ """
+ The company's phone number (used for verification).
+ """
+ registration_date: NotRequired[
+ "Literal['']|AccountUpdateParamsCompanyRegistrationDate"
+ ]
+ registration_number: NotRequired[str]
+ """
+ The identification number given to a company when it is registered or incorporated, if distinct from the identification number used for filing taxes. (Examples are the CIN for companies and LLP IN for partnerships in India, and the Company Registration Number in Hong Kong).
+ """
+ structure: NotRequired[
+ "Literal['']|Literal['free_zone_establishment', 'free_zone_llc', 'government_instrumentality', 'governmental_unit', 'incorporated_non_profit', 'incorporated_partnership', 'limited_liability_partnership', 'llc', 'multi_member_llc', 'private_company', 'private_corporation', 'private_partnership', 'public_company', 'public_corporation', 'public_partnership', 'registered_charity', 'single_member_llc', 'sole_establishment', 'sole_proprietorship', 'tax_exempt_government_instrumentality', 'unincorporated_association', 'unincorporated_non_profit', 'unincorporated_partnership']"
+ ]
+ """
+ The category identifying the legal structure of the company or legal entity. See [Business structure](https://docs.stripe.com/connect/identity-verification#business-structure) for more details. Pass an empty string to unset this value.
+ """
+ tax_id: NotRequired[str]
+ """
+ The business ID number of the company, as appropriate for the company's country. (Examples are an Employer ID Number in the U.S., a Business Number in Canada, or a Company Number in the UK.)
+ """
+ tax_id_registrar: NotRequired[str]
+ """
+ The jurisdiction in which the `tax_id` is registered (Germany-based companies only).
+ """
+ vat_id: NotRequired[str]
+ """
+ The VAT number of the company.
+ """
+ verification: NotRequired["AccountUpdateParamsCompanyVerification"]
+ """
+ Information on the verification state of the company.
+ """
+
+
+class AccountUpdateParamsCompanyAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountUpdateParamsCompanyAddressKana(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountUpdateParamsCompanyAddressKanji(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountUpdateParamsCompanyDirectorshipDeclaration(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the directorship declaration attestation was made.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the directorship declaration attestation was made.
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the directorship declaration attestation was made.
+ """
+
+
+class AccountUpdateParamsCompanyOwnershipDeclaration(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the beneficial owner attestation was made.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the beneficial owner attestation was made.
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the beneficial owner attestation was made.
+ """
+
+
+class AccountUpdateParamsCompanyRegistrationDate(TypedDict):
+ day: int
+ """
+ The day of registration, between 1 and 31.
+ """
+ month: int
+ """
+ The month of registration, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of registration.
+ """
+
+
+class AccountUpdateParamsCompanyVerification(TypedDict):
+ document: NotRequired["AccountUpdateParamsCompanyVerificationDocument"]
+ """
+ A document verifying the business.
+ """
+
+
+class AccountUpdateParamsCompanyVerificationDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+
+
+class AccountUpdateParamsDocuments(TypedDict):
+ bank_account_ownership_verification: NotRequired[
+ "AccountUpdateParamsDocumentsBankAccountOwnershipVerification"
+ ]
+ """
+ One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the account's primary active bank account that displays the last 4 digits of the account number, either a statement or a check.
+ """
+ company_license: NotRequired["AccountUpdateParamsDocumentsCompanyLicense"]
+ """
+ One or more documents that demonstrate proof of a company's license to operate.
+ """
+ company_memorandum_of_association: NotRequired[
+ "AccountUpdateParamsDocumentsCompanyMemorandumOfAssociation"
+ ]
+ """
+ One or more documents showing the company's Memorandum of Association.
+ """
+ company_ministerial_decree: NotRequired[
+ "AccountUpdateParamsDocumentsCompanyMinisterialDecree"
+ ]
+ """
+ (Certain countries only) One or more documents showing the ministerial decree legalizing the company's establishment.
+ """
+ company_registration_verification: NotRequired[
+ "AccountUpdateParamsDocumentsCompanyRegistrationVerification"
+ ]
+ """
+ One or more documents that demonstrate proof of a company's registration with the appropriate local authorities.
+ """
+ company_tax_id_verification: NotRequired[
+ "AccountUpdateParamsDocumentsCompanyTaxIdVerification"
+ ]
+ """
+ One or more documents that demonstrate proof of a company's tax ID.
+ """
+ proof_of_address: NotRequired["AccountUpdateParamsDocumentsProofOfAddress"]
+ """
+ One or more documents that demonstrate proof of address.
+ """
+ proof_of_registration: NotRequired[
+ "AccountUpdateParamsDocumentsProofOfRegistration"
+ ]
+ """
+ One or more documents showing the company's proof of registration with the national business registry.
+ """
+ proof_of_ultimate_beneficial_ownership: NotRequired[
+ "AccountUpdateParamsDocumentsProofOfUltimateBeneficialOwnership"
+ ]
+ """
+ One or more documents that demonstrate proof of ultimate beneficial ownership.
+ """
+
+
+class AccountUpdateParamsDocumentsBankAccountOwnershipVerification(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountUpdateParamsDocumentsCompanyLicense(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountUpdateParamsDocumentsCompanyMemorandumOfAssociation(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountUpdateParamsDocumentsCompanyMinisterialDecree(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountUpdateParamsDocumentsCompanyRegistrationVerification(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountUpdateParamsDocumentsCompanyTaxIdVerification(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountUpdateParamsDocumentsProofOfAddress(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountUpdateParamsDocumentsProofOfRegistration(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountUpdateParamsDocumentsProofOfUltimateBeneficialOwnership(
+ TypedDict
+):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class AccountUpdateParamsBankAccount(TypedDict):
+ object: Literal["bank_account"]
+ account_holder_name: NotRequired[str]
+ """
+ The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object.
+ """
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
+ """
+ account_number: str
+ """
+ The account number for the bank account, in string form. Must be a checking account.
+ """
+ country: str
+ """
+ The country in which the bank account is located.
+ """
+ currency: NotRequired[str]
+ """
+ The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts)
+ """
+ routing_number: NotRequired[str]
+ """
+ The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
+ """
+
+
+class AccountUpdateParamsCard(TypedDict):
+ object: Literal["card"]
+ address_city: NotRequired[str]
+ address_country: NotRequired[str]
+ address_line1: NotRequired[str]
+ address_line2: NotRequired[str]
+ address_state: NotRequired[str]
+ address_zip: NotRequired[str]
+ currency: NotRequired[str]
+ cvc: NotRequired[str]
+ exp_month: int
+ exp_year: int
+ name: NotRequired[str]
+ number: str
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
+ """
+ default_for_currency: NotRequired[bool]
+
+
+class AccountUpdateParamsCardToken(TypedDict):
+ object: Literal["card"]
+ currency: NotRequired[str]
+ token: str
+
+
+class AccountUpdateParamsGroups(TypedDict):
+ payments_pricing: NotRequired["Literal['']|str"]
+ """
+ The group the account is in to determine their payments pricing, and null if the account is on customized pricing. [See the Platform pricing tool documentation](https://stripe.com/docs/connect/platform-pricing-tools) for details.
+ """
+
+
+class AccountUpdateParamsIndividual(TypedDict):
+ address: NotRequired["AccountUpdateParamsIndividualAddress"]
+ """
+ The individual's primary address.
+ """
+ address_kana: NotRequired["AccountUpdateParamsIndividualAddressKana"]
+ """
+ The Kana variation of the individual's primary address (Japan only).
+ """
+ address_kanji: NotRequired["AccountUpdateParamsIndividualAddressKanji"]
+ """
+ The Kanji variation of the individual's primary address (Japan only).
+ """
+ dob: NotRequired["Literal['']|AccountUpdateParamsIndividualDob"]
+ """
+ The individual's date of birth.
+ """
+ email: NotRequired[str]
+ """
+ The individual's email address.
+ """
+ first_name: NotRequired[str]
+ """
+ The individual's first name.
+ """
+ first_name_kana: NotRequired[str]
+ """
+ The Kana variation of the individual's first name (Japan only).
+ """
+ first_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the individual's first name (Japan only).
+ """
+ full_name_aliases: NotRequired["Literal['']|List[str]"]
+ """
+ A list of alternate names or aliases that the individual is known by.
+ """
+ gender: NotRequired[str]
+ """
+ The individual's gender
+ """
+ id_number: NotRequired[str]
+ """
+ The government-issued ID number of the individual, as appropriate for the representative's country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in Canada). Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ id_number_secondary: NotRequired[str]
+ """
+ The government-issued secondary ID number of the individual, as appropriate for the representative's country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ last_name: NotRequired[str]
+ """
+ The individual's last name.
+ """
+ last_name_kana: NotRequired[str]
+ """
+ The Kana variation of the individual's last name (Japan only).
+ """
+ last_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the individual's last name (Japan only).
+ """
+ maiden_name: NotRequired[str]
+ """
+ The individual's maiden name.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ phone: NotRequired[str]
+ """
+ The individual's phone number.
+ """
+ political_exposure: NotRequired[Literal["existing", "none"]]
+ """
+ Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
+ """
+ registered_address: NotRequired[
+ "AccountUpdateParamsIndividualRegisteredAddress"
+ ]
+ """
+ The individual's registered address.
+ """
+ relationship: NotRequired["AccountUpdateParamsIndividualRelationship"]
+ """
+ Describes the person's relationship to the account.
+ """
+ ssn_last_4: NotRequired[str]
+ """
+ The last four digits of the individual's Social Security Number (U.S. only).
+ """
+ verification: NotRequired["AccountUpdateParamsIndividualVerification"]
+ """
+ The individual's verification document information.
+ """
+
+
+class AccountUpdateParamsIndividualAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountUpdateParamsIndividualAddressKana(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountUpdateParamsIndividualAddressKanji(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class AccountUpdateParamsIndividualDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class AccountUpdateParamsIndividualRegisteredAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class AccountUpdateParamsIndividualRelationship(TypedDict):
+ director: NotRequired[bool]
+ """
+ Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
+ """
+ executive: NotRequired[bool]
+ """
+ Whether the person has significant responsibility to control, manage, or direct the organization.
+ """
+ owner: NotRequired[bool]
+ """
+ Whether the person is an owner of the account's legal entity.
+ """
+ percent_ownership: NotRequired["Literal['']|float"]
+ """
+ The percent owned by the person of the account's legal entity.
+ """
+ title: NotRequired[str]
+ """
+ The person's title (e.g., CEO, Support Engineer).
+ """
+
+
+class AccountUpdateParamsIndividualVerification(TypedDict):
+ additional_document: NotRequired[
+ "AccountUpdateParamsIndividualVerificationAdditionalDocument"
+ ]
+ """
+ A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
+ """
+ document: NotRequired["AccountUpdateParamsIndividualVerificationDocument"]
+ """
+ An identifying document, either a passport or local ID card.
+ """
+
+
+class AccountUpdateParamsIndividualVerificationAdditionalDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+
+
+class AccountUpdateParamsIndividualVerificationDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+
+
+class AccountUpdateParamsSettings(TypedDict):
+ bacs_debit_payments: NotRequired[
+ "AccountUpdateParamsSettingsBacsDebitPayments"
+ ]
+ """
+ Settings specific to Bacs Direct Debit payments.
+ """
+ branding: NotRequired["AccountUpdateParamsSettingsBranding"]
+ """
+ Settings used to apply the account's branding to email receipts, invoices, Checkout, and other products.
+ """
+ card_issuing: NotRequired["AccountUpdateParamsSettingsCardIssuing"]
+ """
+ Settings specific to the account's use of the Card Issuing product.
+ """
+ card_payments: NotRequired["AccountUpdateParamsSettingsCardPayments"]
+ """
+ Settings specific to card charging on the account.
+ """
+ invoices: NotRequired["AccountUpdateParamsSettingsInvoices"]
+ """
+ Settings specific to the account's use of Invoices.
+ """
+ payments: NotRequired["AccountUpdateParamsSettingsPayments"]
+ """
+ Settings that apply across payment methods for charging on the account.
+ """
+ payouts: NotRequired["AccountUpdateParamsSettingsPayouts"]
+ """
+ Settings specific to the account's payouts.
+ """
+ treasury: NotRequired["AccountUpdateParamsSettingsTreasury"]
+ """
+ Settings specific to the account's Treasury FinancialAccounts.
+ """
+
+
+class AccountUpdateParamsSettingsBacsDebitPayments(TypedDict):
+ display_name: NotRequired[str]
+ """
+ The Bacs Direct Debit Display Name for this account. For payments made with Bacs Direct Debit, this name appears on the mandate as the statement descriptor. Mobile banking apps display it as the name of the business. To use custom branding, set the Bacs Direct Debit Display Name during or right after creation. Custom branding incurs an additional monthly fee for the platform. If you don't set the display name before requesting Bacs capability, it's automatically set as "Stripe" and the account is onboarded to Stripe branding, which is free.
+ """
+
+
+class AccountUpdateParamsSettingsBranding(TypedDict):
+ icon: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) An icon for the account. Must be square and at least 128px x 128px.
+ """
+ logo: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A logo for the account that will be used in Checkout instead of the icon and without the account's name next to it if provided. Must be at least 128px x 128px.
+ """
+ primary_color: NotRequired[str]
+ """
+ A CSS hex color value representing the primary branding color for this account.
+ """
+ secondary_color: NotRequired[str]
+ """
+ A CSS hex color value representing the secondary branding color for this account.
+ """
+
+
+class AccountUpdateParamsSettingsCardIssuing(TypedDict):
+ tos_acceptance: NotRequired[
+ "AccountUpdateParamsSettingsCardIssuingTosAcceptance"
+ ]
+ """
+ Details on the account's acceptance of the [Stripe Issuing Terms and Disclosures](https://docs.stripe.com/issuing/connect/tos_acceptance).
+ """
+
+
+class AccountUpdateParamsSettingsCardIssuingTosAcceptance(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the account representative accepted the service agreement.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the account representative accepted the service agreement.
+ """
+ user_agent: NotRequired["Literal['']|str"]
+ """
+ The user agent of the browser from which the account representative accepted the service agreement.
+ """
+
+
+class AccountUpdateParamsSettingsCardPayments(TypedDict):
+ decline_on: NotRequired["AccountUpdateParamsSettingsCardPaymentsDeclineOn"]
+ """
+ Automatically declines certain charge types regardless of whether the card issuer accepted or declined the charge.
+ """
+ statement_descriptor_prefix: NotRequired[str]
+ """
+ The default text that appears on credit card statements when a charge is made. This field prefixes any dynamic `statement_descriptor` specified on the charge. `statement_descriptor_prefix` is useful for maximizing descriptor space for the dynamic portion.
+ """
+ statement_descriptor_prefix_kana: NotRequired["Literal['']|str"]
+ """
+ The Kana variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kana` specified on the charge. `statement_descriptor_prefix_kana` is useful for maximizing descriptor space for the dynamic portion.
+ """
+ statement_descriptor_prefix_kanji: NotRequired["Literal['']|str"]
+ """
+ The Kanji variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kanji` specified on the charge. `statement_descriptor_prefix_kanji` is useful for maximizing descriptor space for the dynamic portion.
+ """
+
+
+class AccountUpdateParamsSettingsCardPaymentsDeclineOn(TypedDict):
+ avs_failure: NotRequired[bool]
+ """
+ Whether Stripe automatically declines charges with an incorrect ZIP or postal code. This setting only applies when a ZIP or postal code is provided and they fail bank verification.
+ """
+ cvc_failure: NotRequired[bool]
+ """
+ Whether Stripe automatically declines charges with an incorrect CVC. This setting only applies when a CVC is provided and it fails bank verification.
+ """
+
+
+class AccountUpdateParamsSettingsInvoices(TypedDict):
+ default_account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The list of default Account Tax IDs to automatically include on invoices. Account Tax IDs get added when an invoice is finalized.
+ """
+ hosted_payment_method_save: NotRequired[
+ Literal["always", "never", "offer"]
+ ]
+ """
+ Whether payment methods should be saved when a payment is completed for a one-time invoices on a hosted invoice page.
+ """
+
+
+class AccountUpdateParamsSettingsPayments(TypedDict):
+ statement_descriptor: NotRequired[str]
+ """
+ The default text that appears on statements for non-card charges outside of Japan. For card charges, if you don't set a `statement_descriptor_prefix`, this text is also used as the statement descriptor prefix. In that case, if concatenating the statement descriptor suffix causes the combined statement descriptor to exceed 22 characters, we truncate the `statement_descriptor` text to limit the full descriptor to 22 characters. For more information about statement descriptors and their requirements, see the [account settings documentation](https://docs.stripe.com/get-started/account/statement-descriptors).
+ """
+ statement_descriptor_kana: NotRequired[str]
+ """
+ The Kana variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
+ """
+ statement_descriptor_kanji: NotRequired[str]
+ """
+ The Kanji variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
+ """
+
+
+class AccountUpdateParamsSettingsPayouts(TypedDict):
+ debit_negative_balances: NotRequired[bool]
+ """
+ A Boolean indicating whether Stripe should try to reclaim negative balances from an attached bank account. For details, see [Understanding Connect Account Balances](https://docs.stripe.com/connect/account-balances).
+ """
+ schedule: NotRequired["AccountUpdateParamsSettingsPayoutsSchedule"]
+ """
+ Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](https://docs.stripe.com/connect/bank-transfers#payout-information) documentation.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
+ """
+
+
+class AccountUpdateParamsSettingsPayoutsSchedule(TypedDict):
+ delay_days: NotRequired["Literal['minimum']|int"]
+ """
+ The number of days charge funds are held before being paid out. May also be set to `minimum`, representing the lowest available value for the account country. Default is `minimum`. The `delay_days` parameter remains at the last configured value if `interval` is `manual`. [Learn more about controlling payout delay days](https://docs.stripe.com/connect/manage-payout-schedule).
+ """
+ interval: NotRequired[Literal["daily", "manual", "monthly", "weekly"]]
+ """
+ How frequently available funds are paid out. One of: `daily`, `manual`, `weekly`, or `monthly`. Default is `daily`.
+ """
+ monthly_anchor: NotRequired[int]
+ """
+ The day of the month when available funds are paid out, specified as a number between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly`.
+ """
+ monthly_payout_days: NotRequired[List[int]]
+ """
+ The days of the month when available funds are paid out, specified as an array of numbers between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly` and `monthly_anchor` is not set.
+ """
+ weekly_anchor: NotRequired[
+ Literal[
+ "friday",
+ "monday",
+ "saturday",
+ "sunday",
+ "thursday",
+ "tuesday",
+ "wednesday",
+ ]
+ ]
+ """
+ The day of the week when available funds are paid out, specified as `monday`, `tuesday`, etc. Required and applicable only if `interval` is `weekly`.
+ """
+ weekly_payout_days: NotRequired[
+ List[Literal["friday", "monday", "thursday", "tuesday", "wednesday"]]
+ ]
+ """
+ The days of the week when available funds are paid out, specified as an array, e.g., [`monday`, `tuesday`]. Required and applicable only if `interval` is `weekly`.
+ """
+
+
+class AccountUpdateParamsSettingsTreasury(TypedDict):
+ tos_acceptance: NotRequired[
+ "AccountUpdateParamsSettingsTreasuryTosAcceptance"
+ ]
+ """
+ Details on the account's acceptance of the Stripe Treasury Services Agreement.
+ """
+
+
+class AccountUpdateParamsSettingsTreasuryTosAcceptance(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the account representative accepted the service agreement.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the account representative accepted the service agreement.
+ """
+ user_agent: NotRequired["Literal['']|str"]
+ """
+ The user agent of the browser from which the account representative accepted the service agreement.
+ """
+
+
+class AccountUpdateParamsTosAcceptance(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the account representative accepted their service agreement.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the account representative accepted their service agreement.
+ """
+ service_agreement: NotRequired[str]
+ """
+ The user's service agreement type.
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the account representative accepted their service agreement.
+ """
diff --git a/stripe/params/_apple_pay_domain_create_params.py b/stripe/params/_apple_pay_domain_create_params.py
new file mode 100644
index 000000000..42db145a2
--- /dev/null
+++ b/stripe/params/_apple_pay_domain_create_params.py
@@ -0,0 +1,13 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ApplePayDomainCreateParams(RequestOptions):
+ domain_name: str
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_apple_pay_domain_delete_params.py b/stripe/params/_apple_pay_domain_delete_params.py
new file mode 100644
index 000000000..11099305a
--- /dev/null
+++ b/stripe/params/_apple_pay_domain_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class ApplePayDomainDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/_apple_pay_domain_list_params.py b/stripe/params/_apple_pay_domain_list_params.py
new file mode 100644
index 000000000..c301315ac
--- /dev/null
+++ b/stripe/params/_apple_pay_domain_list_params.py
@@ -0,0 +1,25 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ApplePayDomainListParams(RequestOptions):
+ domain_name: NotRequired[str]
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_apple_pay_domain_retrieve_params.py b/stripe/params/_apple_pay_domain_retrieve_params.py
new file mode 100644
index 000000000..6730ed447
--- /dev/null
+++ b/stripe/params/_apple_pay_domain_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ApplePayDomainRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_application_fee_create_refund_params.py b/stripe/params/_application_fee_create_refund_params.py
new file mode 100644
index 000000000..4d209e6a4
--- /dev/null
+++ b/stripe/params/_application_fee_create_refund_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import NotRequired
+
+
+class ApplicationFeeCreateRefundParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ A positive integer, in _cents (or local equivalent)_, representing how much of this fee to refund. Can refund only up to the remaining unrefunded amount of the fee.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_application_fee_list_params.py b/stripe/params/_application_fee_list_params.py
new file mode 100644
index 000000000..988ecd888
--- /dev/null
+++ b/stripe/params/_application_fee_list_params.py
@@ -0,0 +1,51 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ApplicationFeeListParams(RequestOptions):
+ charge: NotRequired[str]
+ """
+ Only return application fees for the charge specified by this charge ID.
+ """
+ created: NotRequired["ApplicationFeeListParamsCreated|int"]
+ """
+ Only return applications fees that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class ApplicationFeeListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_application_fee_list_refunds_params.py b/stripe/params/_application_fee_list_refunds_params.py
new file mode 100644
index 000000000..e109a31fa
--- /dev/null
+++ b/stripe/params/_application_fee_list_refunds_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ApplicationFeeListRefundsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_application_fee_modify_refund_params.py b/stripe/params/_application_fee_modify_refund_params.py
new file mode 100644
index 000000000..a0b49b616
--- /dev/null
+++ b/stripe/params/_application_fee_modify_refund_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class ApplicationFeeModifyRefundParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_application_fee_refund_create_params.py b/stripe/params/_application_fee_refund_create_params.py
new file mode 100644
index 000000000..6f7a75697
--- /dev/null
+++ b/stripe/params/_application_fee_refund_create_params.py
@@ -0,0 +1,19 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ApplicationFeeRefundCreateParams(TypedDict):
+ amount: NotRequired[int]
+ """
+ A positive integer, in _cents (or local equivalent)_, representing how much of this fee to refund. Can refund only up to the remaining unrefunded amount of the fee.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_application_fee_refund_list_params.py b/stripe/params/_application_fee_refund_list_params.py
new file mode 100644
index 000000000..d19af68bd
--- /dev/null
+++ b/stripe/params/_application_fee_refund_list_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ApplicationFeeRefundListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_application_fee_refund_params.py b/stripe/params/_application_fee_refund_params.py
new file mode 100644
index 000000000..66e53b611
--- /dev/null
+++ b/stripe/params/_application_fee_refund_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import NotRequired
+
+
+class ApplicationFeeRefundParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ A positive integer, in _cents (or local equivalent)_, representing how much of this fee to refund. Can refund only up to the remaining unrefunded amount of the fee.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_application_fee_refund_retrieve_params.py b/stripe/params/_application_fee_refund_retrieve_params.py
new file mode 100644
index 000000000..440811579
--- /dev/null
+++ b/stripe/params/_application_fee_refund_retrieve_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ApplicationFeeRefundRetrieveParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_application_fee_refund_update_params.py b/stripe/params/_application_fee_refund_update_params.py
new file mode 100644
index 000000000..9d2a63eb6
--- /dev/null
+++ b/stripe/params/_application_fee_refund_update_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ApplicationFeeRefundUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_application_fee_retrieve_params.py b/stripe/params/_application_fee_retrieve_params.py
new file mode 100644
index 000000000..f569febcf
--- /dev/null
+++ b/stripe/params/_application_fee_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ApplicationFeeRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_application_fee_retrieve_refund_params.py b/stripe/params/_application_fee_retrieve_refund_params.py
new file mode 100644
index 000000000..b4ec7af1b
--- /dev/null
+++ b/stripe/params/_application_fee_retrieve_refund_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ApplicationFeeRetrieveRefundParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_balance_retrieve_params.py b/stripe/params/_balance_retrieve_params.py
new file mode 100644
index 000000000..2c3d9a3b2
--- /dev/null
+++ b/stripe/params/_balance_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class BalanceRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_balance_settings_modify_params.py b/stripe/params/_balance_settings_modify_params.py
new file mode 100644
index 000000000..86ae9e1bc
--- /dev/null
+++ b/stripe/params/_balance_settings_modify_params.py
@@ -0,0 +1,74 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List, Union
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class BalanceSettingsModifyParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ payments: NotRequired["BalanceSettingsModifyParamsPayments"]
+ """
+ Settings that apply to the [Payments Balance](https://docs.stripe.com/api/balance).
+ """
+
+
+class BalanceSettingsModifyParamsPayments(TypedDict):
+ debit_negative_balances: NotRequired[bool]
+ """
+ A Boolean indicating whether Stripe should try to reclaim negative balances from an attached bank account. For details, see [Understanding Connect Account Balances](https://docs.stripe.com/connect/account-balances).
+ """
+ payouts: NotRequired["BalanceSettingsModifyParamsPaymentsPayouts"]
+ """
+ Settings specific to the account's payouts.
+ """
+ settlement_timing: NotRequired[
+ "BalanceSettingsModifyParamsPaymentsSettlementTiming"
+ ]
+ """
+ Settings related to the account's balance settlement timing.
+ """
+
+
+class BalanceSettingsModifyParamsPaymentsPayouts(TypedDict):
+ minimum_balance_by_currency: NotRequired[
+ "Literal['']|Dict[str, Union[Literal[''], int]]"
+ ]
+ """
+ The minimum balance amount to retain per currency after automatic payouts. Only funds that exceed these amounts are paid out. Learn more about the [minimum balances for automatic payouts](https://docs.stripe.com/payouts/minimum-balances-for-automatic-payouts).
+ """
+ schedule: NotRequired["BalanceSettingsModifyParamsPaymentsPayoutsSchedule"]
+ """
+ Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](https://docs.stripe.com/connect/bank-transfers#payout-information) documentation.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
+ """
+
+
+class BalanceSettingsModifyParamsPaymentsPayoutsSchedule(TypedDict):
+ interval: NotRequired[Literal["daily", "manual", "monthly", "weekly"]]
+ """
+ How frequently available funds are paid out. One of: `daily`, `manual`, `weekly`, or `monthly`. Default is `daily`.
+ """
+ monthly_payout_days: NotRequired[List[int]]
+ """
+ The days of the month when available funds are paid out, specified as an array of numbers between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly`.
+ """
+ weekly_payout_days: NotRequired[
+ List[Literal["friday", "monday", "thursday", "tuesday", "wednesday"]]
+ ]
+ """
+ The days of the week when available funds are paid out, specified as an array, e.g., [`monday`, `tuesday`]. Required and applicable only if `interval` is `weekly`.
+ """
+
+
+class BalanceSettingsModifyParamsPaymentsSettlementTiming(TypedDict):
+ delay_days_override: NotRequired["Literal['']|int"]
+ """
+ Change `delay_days` for this account, which determines the number of days charge funds are held before becoming available. The maximum value is 31. Passing an empty string to `delay_days_override` will return `delay_days` to the default, which is the lowest available value for the account. [Learn more about controlling delay days](https://docs.stripe.com/connect/manage-payout-schedule).
+ """
diff --git a/stripe/params/_balance_settings_retrieve_params.py b/stripe/params/_balance_settings_retrieve_params.py
new file mode 100644
index 000000000..a47e2c01c
--- /dev/null
+++ b/stripe/params/_balance_settings_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class BalanceSettingsRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_balance_settings_update_params.py b/stripe/params/_balance_settings_update_params.py
new file mode 100644
index 000000000..24bbf7821
--- /dev/null
+++ b/stripe/params/_balance_settings_update_params.py
@@ -0,0 +1,73 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List, Union
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class BalanceSettingsUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ payments: NotRequired["BalanceSettingsUpdateParamsPayments"]
+ """
+ Settings that apply to the [Payments Balance](https://docs.stripe.com/api/balance).
+ """
+
+
+class BalanceSettingsUpdateParamsPayments(TypedDict):
+ debit_negative_balances: NotRequired[bool]
+ """
+ A Boolean indicating whether Stripe should try to reclaim negative balances from an attached bank account. For details, see [Understanding Connect Account Balances](https://docs.stripe.com/connect/account-balances).
+ """
+ payouts: NotRequired["BalanceSettingsUpdateParamsPaymentsPayouts"]
+ """
+ Settings specific to the account's payouts.
+ """
+ settlement_timing: NotRequired[
+ "BalanceSettingsUpdateParamsPaymentsSettlementTiming"
+ ]
+ """
+ Settings related to the account's balance settlement timing.
+ """
+
+
+class BalanceSettingsUpdateParamsPaymentsPayouts(TypedDict):
+ minimum_balance_by_currency: NotRequired[
+ "Literal['']|Dict[str, Union[Literal[''], int]]"
+ ]
+ """
+ The minimum balance amount to retain per currency after automatic payouts. Only funds that exceed these amounts are paid out. Learn more about the [minimum balances for automatic payouts](https://docs.stripe.com/payouts/minimum-balances-for-automatic-payouts).
+ """
+ schedule: NotRequired["BalanceSettingsUpdateParamsPaymentsPayoutsSchedule"]
+ """
+ Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](https://docs.stripe.com/connect/bank-transfers#payout-information) documentation.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
+ """
+
+
+class BalanceSettingsUpdateParamsPaymentsPayoutsSchedule(TypedDict):
+ interval: NotRequired[Literal["daily", "manual", "monthly", "weekly"]]
+ """
+ How frequently available funds are paid out. One of: `daily`, `manual`, `weekly`, or `monthly`. Default is `daily`.
+ """
+ monthly_payout_days: NotRequired[List[int]]
+ """
+ The days of the month when available funds are paid out, specified as an array of numbers between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly`.
+ """
+ weekly_payout_days: NotRequired[
+ List[Literal["friday", "monday", "thursday", "tuesday", "wednesday"]]
+ ]
+ """
+ The days of the week when available funds are paid out, specified as an array, e.g., [`monday`, `tuesday`]. Required and applicable only if `interval` is `weekly`.
+ """
+
+
+class BalanceSettingsUpdateParamsPaymentsSettlementTiming(TypedDict):
+ delay_days_override: NotRequired["Literal['']|int"]
+ """
+ Change `delay_days` for this account, which determines the number of days charge funds are held before becoming available. The maximum value is 31. Passing an empty string to `delay_days_override` will return `delay_days` to the default, which is the lowest available value for the account. [Learn more about controlling delay days](https://docs.stripe.com/connect/manage-payout-schedule).
+ """
diff --git a/stripe/params/_balance_transaction_list_params.py b/stripe/params/_balance_transaction_list_params.py
new file mode 100644
index 000000000..4c154b4cb
--- /dev/null
+++ b/stripe/params/_balance_transaction_list_params.py
@@ -0,0 +1,63 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class BalanceTransactionListParams(RequestOptions):
+ created: NotRequired["BalanceTransactionListParamsCreated|int"]
+ """
+ Only return transactions that were created during the given date interval.
+ """
+ currency: NotRequired[str]
+ """
+ Only return transactions in a certain currency. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ payout: NotRequired[str]
+ """
+ For automatic Stripe payouts only, only returns transactions that were paid out on the specified payout ID.
+ """
+ source: NotRequired[str]
+ """
+ Only returns the original transaction.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ type: NotRequired[str]
+ """
+ Only returns transactions of the given type. One of: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `climate_order_purchase`, `climate_order_refund`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `obligation_outbound`, `obligation_reversal_inbound`, `payment`, `payment_failure_refund`, `payment_network_reserve_hold`, `payment_network_reserve_release`, `payment_refund`, `payment_reversal`, `payment_unreconciled`, `payout`, `payout_cancel`, `payout_failure`, `payout_minimum_balance_hold`, `payout_minimum_balance_release`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `stripe_balance_payment_debit`, `stripe_balance_payment_debit_reversal`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`.
+ """
+
+
+class BalanceTransactionListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_balance_transaction_retrieve_params.py b/stripe/params/_balance_transaction_retrieve_params.py
new file mode 100644
index 000000000..b674c88c0
--- /dev/null
+++ b/stripe/params/_balance_transaction_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class BalanceTransactionRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_bank_account_delete_params.py b/stripe/params/_bank_account_delete_params.py
new file mode 100644
index 000000000..e804f5bf6
--- /dev/null
+++ b/stripe/params/_bank_account_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class BankAccountDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/_card_delete_params.py b/stripe/params/_card_delete_params.py
new file mode 100644
index 000000000..6e56a15f5
--- /dev/null
+++ b/stripe/params/_card_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class CardDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/_charge_capture_params.py b/stripe/params/_charge_capture_params.py
new file mode 100644
index 000000000..6de381293
--- /dev/null
+++ b/stripe/params/_charge_capture_params.py
@@ -0,0 +1,53 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ChargeCaptureParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ The amount to capture, which must be less than or equal to the original amount.
+ """
+ application_fee: NotRequired[int]
+ """
+ An application fee to add on to this charge.
+ """
+ application_fee_amount: NotRequired[int]
+ """
+ An application fee amount to add on to this charge, which must be less than or equal to the original amount.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ receipt_email: NotRequired[str]
+ """
+ The email address to send this charge's receipt to. This will override the previously-specified email address for this charge, if one was set. Receipts will not be sent in test mode.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
+
+ For a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.
+ """
+ statement_descriptor_suffix: NotRequired[str]
+ """
+ Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.
+ """
+ transfer_data: NotRequired["ChargeCaptureParamsTransferData"]
+ """
+ An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.
+ """
+ transfer_group: NotRequired[str]
+ """
+ A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
+ """
+
+
+class ChargeCaptureParamsTransferData(TypedDict):
+ amount: NotRequired[int]
+ """
+ The amount transferred to the destination account, if specified. By default, the entire charge amount is transferred to the destination account.
+ """
diff --git a/stripe/params/_charge_create_params.py b/stripe/params/_charge_create_params.py
new file mode 100644
index 000000000..a305b0f81
--- /dev/null
+++ b/stripe/params/_charge_create_params.py
@@ -0,0 +1,159 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ChargeCreateParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ Amount intended to be collected by this payment. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
+ """
+ application_fee: NotRequired[int]
+ application_fee_amount: NotRequired[int]
+ """
+ A fee in cents (or local equivalent) that will be applied to the charge and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the `Stripe-Account` header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/connect/direct-charges#collect-fees).
+ """
+ capture: NotRequired[bool]
+ """
+ Whether to immediately capture the charge. Defaults to `true`. When `false`, the charge issues an authorization (or pre-authorization), and will need to be [captured](https://stripe.com/docs/api#capture_charge) later. Uncaptured charges expire after a set number of days (7 by default). For more information, see the [authorizing charges and settling later](https://stripe.com/docs/charges/placing-a-hold) documentation.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ customer: NotRequired[str]
+ """
+ The ID of an existing customer that will be charged in this request.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string which you can attach to a `Charge` object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.
+ """
+ destination: NotRequired["ChargeCreateParamsDestination"]
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ on_behalf_of: NotRequired[str]
+ """
+ The Stripe account ID for which these funds are intended. Automatically set if you use the `destination` parameter. For details, see [Creating Separate Charges and Transfers](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant).
+ """
+ radar_options: NotRequired["ChargeCreateParamsRadarOptions"]
+ """
+ Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
+ """
+ receipt_email: NotRequired[str]
+ """
+ The email address to which this charge's [receipt](https://stripe.com/docs/dashboard/receipts) will be sent. The receipt will not be sent until the charge is paid, and no receipts will be sent for test mode charges. If this charge is for a [Customer](https://stripe.com/docs/api/customers/object), the email address specified here will override the customer's email address. If `receipt_email` is specified for a charge in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
+ """
+ shipping: NotRequired["ChargeCreateParamsShipping"]
+ """
+ Shipping information for the charge. Helps prevent fraud on charges for physical goods.
+ """
+ source: NotRequired[str]
+ """
+ A payment source to be charged. This can be the ID of a [card](https://stripe.com/docs/api#cards) (i.e., credit or debit card), a [bank account](https://stripe.com/docs/api#bank_accounts), a [source](https://stripe.com/docs/api#sources), a [token](https://stripe.com/docs/api#tokens), or a [connected account](https://stripe.com/docs/connect/account-debits#charging-a-connected-account). For certain sources---namely, [cards](https://stripe.com/docs/api#cards), [bank accounts](https://stripe.com/docs/api#bank_accounts), and attached [sources](https://stripe.com/docs/api#sources)---you must also pass the ID of the associated customer.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
+
+ For a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.
+ """
+ statement_descriptor_suffix: NotRequired[str]
+ """
+ Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.
+ """
+ transfer_data: NotRequired["ChargeCreateParamsTransferData"]
+ """
+ An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.
+ """
+ transfer_group: NotRequired[str]
+ """
+ A string that identifies this transaction as part of a group. For details, see [Grouping transactions](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options).
+ """
+
+
+class ChargeCreateParamsDestination(TypedDict):
+ account: str
+ """
+ ID of an existing, connected Stripe account.
+ """
+ amount: NotRequired[int]
+ """
+ The amount to transfer to the destination account without creating an `Application Fee` object. Cannot be combined with the `application_fee` parameter. Must be less than or equal to the charge amount.
+ """
+
+
+class ChargeCreateParamsRadarOptions(TypedDict):
+ session: NotRequired[str]
+ """
+ A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
+ """
+
+
+class ChargeCreateParamsShipping(TypedDict):
+ address: "ChargeCreateParamsShippingAddress"
+ """
+ Shipping address.
+ """
+ carrier: NotRequired[str]
+ """
+ The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
+ """
+ name: str
+ """
+ Recipient name.
+ """
+ phone: NotRequired[str]
+ """
+ Recipient phone (including extension).
+ """
+ tracking_number: NotRequired[str]
+ """
+ The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
+ """
+
+
+class ChargeCreateParamsShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class ChargeCreateParamsTransferData(TypedDict):
+ amount: NotRequired[int]
+ """
+ The amount transferred to the destination account, if specified. By default, the entire charge amount is transferred to the destination account.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
diff --git a/stripe/params/_charge_list_params.py b/stripe/params/_charge_list_params.py
new file mode 100644
index 000000000..748fb6b51
--- /dev/null
+++ b/stripe/params/_charge_list_params.py
@@ -0,0 +1,59 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ChargeListParams(RequestOptions):
+ created: NotRequired["ChargeListParamsCreated|int"]
+ """
+ Only return charges that were created during the given date interval.
+ """
+ customer: NotRequired[str]
+ """
+ Only return charges for the customer specified by this customer ID.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ payment_intent: NotRequired[str]
+ """
+ Only return charges that were created by the PaymentIntent specified by this PaymentIntent ID.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ transfer_group: NotRequired[str]
+ """
+ Only return charges for this transfer group, limited to 100.
+ """
+
+
+class ChargeListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_charge_list_refunds_params.py b/stripe/params/_charge_list_refunds_params.py
new file mode 100644
index 000000000..6971b3ca5
--- /dev/null
+++ b/stripe/params/_charge_list_refunds_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ChargeListRefundsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_charge_modify_params.py b/stripe/params/_charge_modify_params.py
new file mode 100644
index 000000000..dd881f578
--- /dev/null
+++ b/stripe/params/_charge_modify_params.py
@@ -0,0 +1,97 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List, Union
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ChargeModifyParams(RequestOptions):
+ customer: NotRequired[str]
+ """
+ The ID of an existing customer that will be associated with this request. This field may only be updated if there is no existing associated customer with this charge.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string which you can attach to a charge object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ fraud_details: NotRequired["ChargeModifyParamsFraudDetails"]
+ """
+ A set of key-value pairs you can attach to a charge giving information about its riskiness. If you believe a charge is fraudulent, include a `user_report` key with a value of `fraudulent`. If you believe a charge is safe, include a `user_report` key with a value of `safe`. Stripe will use the information you send to improve our fraud detection algorithms.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ receipt_email: NotRequired[str]
+ """
+ This is the email address that the receipt for this charge will be sent to. If this field is updated, then a new email receipt will be sent to the updated address.
+ """
+ shipping: NotRequired["ChargeModifyParamsShipping"]
+ """
+ Shipping information for the charge. Helps prevent fraud on charges for physical goods.
+ """
+ transfer_group: NotRequired[str]
+ """
+ A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
+ """
+
+
+class ChargeModifyParamsFraudDetails(TypedDict):
+ user_report: Union[Literal[""], Literal["fraudulent", "safe"]]
+ """
+ Either `safe` or `fraudulent`.
+ """
+
+
+class ChargeModifyParamsShipping(TypedDict):
+ address: "ChargeModifyParamsShippingAddress"
+ """
+ Shipping address.
+ """
+ carrier: NotRequired[str]
+ """
+ The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
+ """
+ name: str
+ """
+ Recipient name.
+ """
+ phone: NotRequired[str]
+ """
+ Recipient phone (including extension).
+ """
+ tracking_number: NotRequired[str]
+ """
+ The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
+ """
+
+
+class ChargeModifyParamsShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
diff --git a/stripe/params/_charge_retrieve_params.py b/stripe/params/_charge_retrieve_params.py
new file mode 100644
index 000000000..7f47da1dc
--- /dev/null
+++ b/stripe/params/_charge_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ChargeRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_charge_retrieve_refund_params.py b/stripe/params/_charge_retrieve_refund_params.py
new file mode 100644
index 000000000..8e05f9faf
--- /dev/null
+++ b/stripe/params/_charge_retrieve_refund_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ChargeRetrieveRefundParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_charge_search_params.py b/stripe/params/_charge_search_params.py
new file mode 100644
index 000000000..a936ec939
--- /dev/null
+++ b/stripe/params/_charge_search_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ChargeSearchParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ page: NotRequired[str]
+ """
+ A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
+ """
+ query: str
+ """
+ The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for charges](https://stripe.com/docs/search#query-fields-for-charges).
+ """
diff --git a/stripe/params/_charge_update_params.py b/stripe/params/_charge_update_params.py
new file mode 100644
index 000000000..be2e3c23a
--- /dev/null
+++ b/stripe/params/_charge_update_params.py
@@ -0,0 +1,96 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List, Union
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ChargeUpdateParams(TypedDict):
+ customer: NotRequired[str]
+ """
+ The ID of an existing customer that will be associated with this request. This field may only be updated if there is no existing associated customer with this charge.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string which you can attach to a charge object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ fraud_details: NotRequired["ChargeUpdateParamsFraudDetails"]
+ """
+ A set of key-value pairs you can attach to a charge giving information about its riskiness. If you believe a charge is fraudulent, include a `user_report` key with a value of `fraudulent`. If you believe a charge is safe, include a `user_report` key with a value of `safe`. Stripe will use the information you send to improve our fraud detection algorithms.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ receipt_email: NotRequired[str]
+ """
+ This is the email address that the receipt for this charge will be sent to. If this field is updated, then a new email receipt will be sent to the updated address.
+ """
+ shipping: NotRequired["ChargeUpdateParamsShipping"]
+ """
+ Shipping information for the charge. Helps prevent fraud on charges for physical goods.
+ """
+ transfer_group: NotRequired[str]
+ """
+ A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
+ """
+
+
+class ChargeUpdateParamsFraudDetails(TypedDict):
+ user_report: Union[Literal[""], Literal["fraudulent", "safe"]]
+ """
+ Either `safe` or `fraudulent`.
+ """
+
+
+class ChargeUpdateParamsShipping(TypedDict):
+ address: "ChargeUpdateParamsShippingAddress"
+ """
+ Shipping address.
+ """
+ carrier: NotRequired[str]
+ """
+ The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
+ """
+ name: str
+ """
+ Recipient name.
+ """
+ phone: NotRequired[str]
+ """
+ Recipient phone (including extension).
+ """
+ tracking_number: NotRequired[str]
+ """
+ The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
+ """
+
+
+class ChargeUpdateParamsShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
diff --git a/stripe/params/_confirmation_token_create_params.py b/stripe/params/_confirmation_token_create_params.py
new file mode 100644
index 000000000..3c7244096
--- /dev/null
+++ b/stripe/params/_confirmation_token_create_params.py
@@ -0,0 +1,926 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ConfirmationTokenCreateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ payment_method: NotRequired[str]
+ """
+ ID of an existing PaymentMethod.
+ """
+ payment_method_data: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodData"
+ ]
+ """
+ If provided, this hash will be used to create a PaymentMethod.
+ """
+ payment_method_options: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodOptions"
+ ]
+ """
+ Payment-method-specific configuration for this ConfirmationToken.
+ """
+ return_url: NotRequired[str]
+ """
+ Return URL used to confirm the Intent.
+ """
+ setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
+ """
+ Indicates that you intend to make future payments with this ConfirmationToken's payment method.
+
+ The presence of this property will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete.
+ """
+ shipping: NotRequired["ConfirmationTokenCreateParamsShipping"]
+ """
+ Shipping information for this ConfirmationToken.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodData(TypedDict):
+ acss_debit: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataAcssDebit"
+ ]
+ """
+ If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
+ """
+ affirm: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataAffirm"]
+ """
+ If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
+ """
+ afterpay_clearpay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataAfterpayClearpay"
+ ]
+ """
+ If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
+ """
+ alipay: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataAlipay"]
+ """
+ If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
+ """
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
+ """
+ alma: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataAlma"]
+ """
+ If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
+ """
+ amazon_pay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataAmazonPay"
+ ]
+ """
+ If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
+ """
+ au_becs_debit: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataAuBecsDebit"
+ ]
+ """
+ If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
+ """
+ bacs_debit: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
+ """
+ bancontact: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataBancontact"
+ ]
+ """
+ If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
+ """
+ billie: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataBillie"]
+ """
+ If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
+ """
+ billing_details: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataBillingDetails"
+ ]
+ """
+ Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+ """
+ blik: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataBlik"]
+ """
+ If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
+ """
+ boleto: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataBoleto"]
+ """
+ If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
+ """
+ cashapp: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataCashapp"
+ ]
+ """
+ If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
+ """
+ crypto: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataCrypto"]
+ """
+ If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
+ """
+ customer_balance: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataCustomerBalance"
+ ]
+ """
+ If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
+ """
+ eps: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataEps"]
+ """
+ If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
+ """
+ fpx: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataFpx"]
+ """
+ If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
+ """
+ giropay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataGiropay"
+ ]
+ """
+ If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
+ """
+ grabpay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataGrabpay"
+ ]
+ """
+ If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
+ """
+ ideal: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataIdeal"]
+ """
+ If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
+ """
+ interac_present: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataInteracPresent"
+ ]
+ """
+ If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
+ """
+ kakao_pay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataKakaoPay"
+ ]
+ """
+ If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
+ """
+ klarna: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataKlarna"]
+ """
+ If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
+ """
+ konbini: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataKonbini"
+ ]
+ """
+ If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
+ """
+ kr_card: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataKrCard"
+ ]
+ """
+ If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
+ """
+ link: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataLink"]
+ """
+ If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
+ """
+ mb_way: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataMbWay"]
+ """
+ If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ mobilepay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataMobilepay"
+ ]
+ """
+ If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
+ """
+ multibanco: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataMultibanco"
+ ]
+ """
+ If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
+ """
+ naver_pay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataNaverPay"
+ ]
+ """
+ If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
+ """
+ nz_bank_account: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataNzBankAccount"
+ ]
+ """
+ If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
+ """
+ oxxo: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataOxxo"]
+ """
+ If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
+ """
+ p24: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataP24"]
+ """
+ If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
+ """
+ pay_by_bank: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataPayByBank"
+ ]
+ """
+ If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
+ """
+ payco: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataPayco"]
+ """
+ If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
+ """
+ paynow: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataPaynow"]
+ """
+ If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
+ """
+ paypal: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataPaypal"]
+ """
+ If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
+ """
+ pix: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataPix"]
+ """
+ If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
+ """
+ promptpay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataPromptpay"
+ ]
+ """
+ If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
+ """
+ radar_options: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataRadarOptions"
+ ]
+ """
+ Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
+ """
+ revolut_pay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataRevolutPay"
+ ]
+ """
+ If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
+ """
+ samsung_pay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataSamsungPay"
+ ]
+ """
+ If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
+ """
+ satispay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataSatispay"
+ ]
+ """
+ If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
+ """
+ sepa_debit: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
+ """
+ sofort: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataSofort"]
+ """
+ If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
+ """
+ swish: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataSwish"]
+ """
+ If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
+ """
+ twint: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataTwint"]
+ """
+ If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
+ """
+ type: Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "link",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ """
+ The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
+ """
+ us_bank_account: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataUsBankAccount"
+ ]
+ """
+ If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
+ """
+ wechat_pay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataWechatPay"
+ ]
+ """
+ If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
+ """
+ zip: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataZip"]
+ """
+ If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataAcssDebit(TypedDict):
+ account_number: str
+ """
+ Customer's bank account number.
+ """
+ institution_number: str
+ """
+ Institution number of the customer's bank.
+ """
+ transit_number: str
+ """
+ Transit number of the customer's bank.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataAffirm(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataAfterpayClearpay(
+ TypedDict
+):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataAlipay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataAlma(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataAmazonPay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataAuBecsDebit(TypedDict):
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bsb_number: str
+ """
+ Bank-State-Branch number of the bank account.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataBacsDebit(TypedDict):
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account that the funds will be debited from.
+ """
+ sort_code: NotRequired[str]
+ """
+ Sort code of the bank account. (e.g., `10-20-30`)
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataBancontact(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataBillie(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataBillingDetails(TypedDict):
+ address: NotRequired[
+ "Literal['']|ConfirmationTokenCreateParamsPaymentMethodDataBillingDetailsAddress"
+ ]
+ """
+ Billing address.
+ """
+ email: NotRequired["Literal['']|str"]
+ """
+ Email address.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Full name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Billing phone number (including extension).
+ """
+ tax_id: NotRequired[str]
+ """
+ Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataBillingDetailsAddress(
+ TypedDict,
+):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataBlik(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataBoleto(TypedDict):
+ tax_id: str
+ """
+ The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataCashapp(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataCrypto(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataCustomerBalance(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataEps(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "arzte_und_apotheker_bank",
+ "austrian_anadi_bank_ag",
+ "bank_austria",
+ "bankhaus_carl_spangler",
+ "bankhaus_schelhammer_und_schattera_ag",
+ "bawag_psk_ag",
+ "bks_bank_ag",
+ "brull_kallmus_bank_ag",
+ "btv_vier_lander_bank",
+ "capital_bank_grawe_gruppe_ag",
+ "deutsche_bank_ag",
+ "dolomitenbank",
+ "easybank_ag",
+ "erste_bank_und_sparkassen",
+ "hypo_alpeadriabank_international_ag",
+ "hypo_bank_burgenland_aktiengesellschaft",
+ "hypo_noe_lb_fur_niederosterreich_u_wien",
+ "hypo_oberosterreich_salzburg_steiermark",
+ "hypo_tirol_bank_ag",
+ "hypo_vorarlberg_bank_ag",
+ "marchfelder_bank",
+ "oberbank_ag",
+ "raiffeisen_bankengruppe_osterreich",
+ "schoellerbank_ag",
+ "sparda_bank_wien",
+ "volksbank_gruppe",
+ "volkskreditbank_ag",
+ "vr_bank_braunau",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataFpx(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type for FPX transaction
+ """
+ bank: Literal[
+ "affin_bank",
+ "agrobank",
+ "alliance_bank",
+ "ambank",
+ "bank_islam",
+ "bank_muamalat",
+ "bank_of_china",
+ "bank_rakyat",
+ "bsn",
+ "cimb",
+ "deutsche_bank",
+ "hong_leong_bank",
+ "hsbc",
+ "kfh",
+ "maybank2e",
+ "maybank2u",
+ "ocbc",
+ "pb_enterprise",
+ "public_bank",
+ "rhb",
+ "standard_chartered",
+ "uob",
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataGiropay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataGrabpay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataIdeal(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "abn_amro",
+ "asn_bank",
+ "bunq",
+ "buut",
+ "handelsbanken",
+ "ing",
+ "knab",
+ "moneyou",
+ "n26",
+ "nn",
+ "rabobank",
+ "regiobank",
+ "revolut",
+ "sns_bank",
+ "triodos_bank",
+ "van_lanschot",
+ "yoursafe",
+ ]
+ ]
+ """
+ The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataInteracPresent(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataKakaoPay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataKlarna(TypedDict):
+ dob: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataKlarnaDob"]
+ """
+ Customer's date of birth
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataKlarnaDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataKonbini(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataKrCard(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataLink(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataMbWay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataMobilepay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataMultibanco(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataNaverPay(TypedDict):
+ funding: NotRequired[Literal["card", "points"]]
+ """
+ Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataNzBankAccount(TypedDict):
+ account_holder_name: NotRequired[str]
+ """
+ The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
+ """
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bank_code: str
+ """
+ The numeric code for the bank account's bank.
+ """
+ branch_code: str
+ """
+ The numeric code for the bank account's bank branch.
+ """
+ reference: NotRequired[str]
+ suffix: str
+ """
+ The suffix of the bank account number.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataOxxo(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataP24(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "alior_bank",
+ "bank_millennium",
+ "bank_nowy_bfg_sa",
+ "bank_pekao_sa",
+ "banki_spbdzielcze",
+ "blik",
+ "bnp_paribas",
+ "boz",
+ "citi_handlowy",
+ "credit_agricole",
+ "envelobank",
+ "etransfer_pocztowy24",
+ "getin_bank",
+ "ideabank",
+ "ing",
+ "inteligo",
+ "mbank_mtransfer",
+ "nest_przelew",
+ "noble_pay",
+ "pbac_z_ipko",
+ "plus_bank",
+ "santander_przelew24",
+ "tmobile_usbugi_bankowe",
+ "toyota_bank",
+ "velobank",
+ "volkswagen_bank",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataPayByBank(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataPayco(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataPaynow(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataPaypal(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataPix(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataPromptpay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataRadarOptions(TypedDict):
+ session: NotRequired[str]
+ """
+ A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataRevolutPay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataSamsungPay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataSatispay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataSepaDebit(TypedDict):
+ iban: str
+ """
+ IBAN of the bank account.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataSofort(TypedDict):
+ country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
+ """
+ Two-letter ISO code representing the country the bank account is located in.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataSwish(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataTwint(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataUsBankAccount(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type: individual or company.
+ """
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account.
+ """
+ account_type: NotRequired[Literal["checking", "savings"]]
+ """
+ Account type: checkings or savings. Defaults to checking if omitted.
+ """
+ financial_connections_account: NotRequired[str]
+ """
+ The ID of a Financial Connections Account to use as a payment method.
+ """
+ routing_number: NotRequired[str]
+ """
+ Routing number of the bank account.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataWechatPay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataZip(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodOptions(TypedDict):
+ card: NotRequired["ConfirmationTokenCreateParamsPaymentMethodOptionsCard"]
+ """
+ Configuration for any card payments confirmed using this ConfirmationToken.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodOptionsCard(TypedDict):
+ installments: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodOptionsCardInstallments"
+ ]
+ """
+ Installment configuration for payments confirmed using this ConfirmationToken.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodOptionsCardInstallments(
+ TypedDict,
+):
+ plan: (
+ "ConfirmationTokenCreateParamsPaymentMethodOptionsCardInstallmentsPlan"
+ )
+ """
+ The selected installment plan to use for this payment attempt.
+ This parameter can only be provided during confirmation.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodOptionsCardInstallmentsPlan(
+ TypedDict,
+):
+ count: NotRequired[int]
+ """
+ For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
+ """
+ interval: NotRequired[Literal["month"]]
+ """
+ For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
+ One of `month`.
+ """
+ type: Literal["bonus", "fixed_count", "revolving"]
+ """
+ Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
+ """
+
+
+class ConfirmationTokenCreateParamsShipping(TypedDict):
+ address: "ConfirmationTokenCreateParamsShippingAddress"
+ """
+ Shipping address
+ """
+ name: str
+ """
+ Recipient name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Recipient phone (including extension)
+ """
+
+
+class ConfirmationTokenCreateParamsShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
diff --git a/stripe/params/_confirmation_token_retrieve_params.py b/stripe/params/_confirmation_token_retrieve_params.py
new file mode 100644
index 000000000..f2725628a
--- /dev/null
+++ b/stripe/params/_confirmation_token_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ConfirmationTokenRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_country_spec_list_params.py b/stripe/params/_country_spec_list_params.py
new file mode 100644
index 000000000..33261a593
--- /dev/null
+++ b/stripe/params/_country_spec_list_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CountrySpecListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_country_spec_retrieve_params.py b/stripe/params/_country_spec_retrieve_params.py
new file mode 100644
index 000000000..cecc86f31
--- /dev/null
+++ b/stripe/params/_country_spec_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CountrySpecRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_coupon_create_params.py b/stripe/params/_coupon_create_params.py
new file mode 100644
index 000000000..f6b02506f
--- /dev/null
+++ b/stripe/params/_coupon_create_params.py
@@ -0,0 +1,76 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CouponCreateParams(RequestOptions):
+ amount_off: NotRequired[int]
+ """
+ A positive integer representing the amount to subtract from an invoice total (required if `percent_off` is not passed).
+ """
+ applies_to: NotRequired["CouponCreateParamsAppliesTo"]
+ """
+ A hash containing directions for what this Coupon will apply discounts to.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `amount_off` parameter (required if `amount_off` is passed).
+ """
+ currency_options: NotRequired[
+ Dict[str, "CouponCreateParamsCurrencyOptions"]
+ ]
+ """
+ Coupons defined in each available currency option (only supported if `amount_off` is passed). Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+ duration: NotRequired[Literal["forever", "once", "repeating"]]
+ """
+ Specifies how long the discount will be in effect if used on a subscription. Defaults to `once`.
+ """
+ duration_in_months: NotRequired[int]
+ """
+ Required only if `duration` is `repeating`, in which case it must be a positive integer that specifies the number of months the discount will be in effect.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ id: NotRequired[str]
+ """
+ Unique string of your choice that will be used to identify this coupon when applying it to a customer. If you don't want to specify a particular code, you can leave the ID blank and we'll generate a random code for you.
+ """
+ max_redemptions: NotRequired[int]
+ """
+ A positive integer specifying the number of times the coupon can be redeemed before it's no longer valid. For example, you might have a 50% off coupon that the first 20 readers of your blog can use.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired[str]
+ """
+ Name of the coupon displayed to customers on, for instance invoices, or receipts. By default the `id` is shown if `name` is not set.
+ """
+ percent_off: NotRequired[float]
+ """
+ A positive float larger than 0, and smaller or equal to 100, that represents the discount the coupon will apply (required if `amount_off` is not passed).
+ """
+ redeem_by: NotRequired[int]
+ """
+ Unix timestamp specifying the last time at which the coupon can be redeemed. After the redeem_by date, the coupon can no longer be applied to new customers.
+ """
+
+
+class CouponCreateParamsAppliesTo(TypedDict):
+ products: NotRequired[List[str]]
+ """
+ An array of Product IDs that this Coupon will apply to.
+ """
+
+
+class CouponCreateParamsCurrencyOptions(TypedDict):
+ amount_off: int
+ """
+ A positive integer representing the amount to subtract from an invoice total.
+ """
diff --git a/stripe/params/_coupon_delete_params.py b/stripe/params/_coupon_delete_params.py
new file mode 100644
index 000000000..2b64b4dc4
--- /dev/null
+++ b/stripe/params/_coupon_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class CouponDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/_coupon_list_params.py b/stripe/params/_coupon_list_params.py
new file mode 100644
index 000000000..bf133f0e5
--- /dev/null
+++ b/stripe/params/_coupon_list_params.py
@@ -0,0 +1,47 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CouponListParams(RequestOptions):
+ created: NotRequired["CouponListParamsCreated|int"]
+ """
+ A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class CouponListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_coupon_modify_params.py b/stripe/params/_coupon_modify_params.py
new file mode 100644
index 000000000..3a40e77aa
--- /dev/null
+++ b/stripe/params/_coupon_modify_params.py
@@ -0,0 +1,33 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CouponModifyParams(RequestOptions):
+ currency_options: NotRequired[
+ Dict[str, "CouponModifyParamsCurrencyOptions"]
+ ]
+ """
+ Coupons defined in each available currency option (only supported if the coupon is amount-based). Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired[str]
+ """
+ Name of the coupon displayed to customers on, for instance invoices, or receipts. By default the `id` is shown if `name` is not set.
+ """
+
+
+class CouponModifyParamsCurrencyOptions(TypedDict):
+ amount_off: int
+ """
+ A positive integer representing the amount to subtract from an invoice total.
+ """
diff --git a/stripe/params/_coupon_retrieve_params.py b/stripe/params/_coupon_retrieve_params.py
new file mode 100644
index 000000000..34e1a8e85
--- /dev/null
+++ b/stripe/params/_coupon_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CouponRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_coupon_update_params.py b/stripe/params/_coupon_update_params.py
new file mode 100644
index 000000000..bbd7d067b
--- /dev/null
+++ b/stripe/params/_coupon_update_params.py
@@ -0,0 +1,32 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CouponUpdateParams(TypedDict):
+ currency_options: NotRequired[
+ Dict[str, "CouponUpdateParamsCurrencyOptions"]
+ ]
+ """
+ Coupons defined in each available currency option (only supported if the coupon is amount-based). Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired[str]
+ """
+ Name of the coupon displayed to customers on, for instance invoices, or receipts. By default the `id` is shown if `name` is not set.
+ """
+
+
+class CouponUpdateParamsCurrencyOptions(TypedDict):
+ amount_off: int
+ """
+ A positive integer representing the amount to subtract from an invoice total.
+ """
diff --git a/stripe/params/_credit_note_create_params.py b/stripe/params/_credit_note_create_params.py
new file mode 100644
index 000000000..b56295fda
--- /dev/null
+++ b/stripe/params/_credit_note_create_params.py
@@ -0,0 +1,142 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CreditNoteCreateParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the total amount of the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
+ """
+ credit_amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
+ """
+ effective_at: NotRequired[int]
+ """
+ The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
+ """
+ email_type: NotRequired[Literal["credit_note", "none"]]
+ """
+ Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice: str
+ """
+ ID of the invoice.
+ """
+ lines: NotRequired[List["CreditNoteCreateParamsLine"]]
+ """
+ Line items that make up the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
+ """
+ memo: NotRequired[str]
+ """
+ The credit note's memo appears on the credit note PDF.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ out_of_band_amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
+ """
+ reason: NotRequired[
+ Literal[
+ "duplicate", "fraudulent", "order_change", "product_unsatisfactory"
+ ]
+ ]
+ """
+ Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
+ """
+ refund_amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
+ """
+ refunds: NotRequired[List["CreditNoteCreateParamsRefund"]]
+ """
+ Refunds to link to this credit note.
+ """
+ shipping_cost: NotRequired["CreditNoteCreateParamsShippingCost"]
+ """
+ When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
+ """
+
+
+class CreditNoteCreateParamsLine(TypedDict):
+ amount: NotRequired[int]
+ """
+ The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
+ """
+ description: NotRequired[str]
+ """
+ The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
+ """
+ invoice_line_item: NotRequired[str]
+ """
+ The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
+ """
+ quantity: NotRequired[int]
+ """
+ The line item quantity to credit.
+ """
+ tax_amounts: NotRequired[
+ "Literal['']|List[CreditNoteCreateParamsLineTaxAmount]"
+ ]
+ """
+ A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
+ """
+ type: Literal["custom_line_item", "invoice_line_item"]
+ """
+ Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
+ """
+ unit_amount: NotRequired[int]
+ """
+ The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class CreditNoteCreateParamsLineTaxAmount(TypedDict):
+ amount: int
+ """
+ The amount, in cents (or local equivalent), of the tax.
+ """
+ tax_rate: str
+ """
+ The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
+ """
+ taxable_amount: int
+ """
+ The amount on which tax is calculated, in cents (or local equivalent).
+ """
+
+
+class CreditNoteCreateParamsRefund(TypedDict):
+ amount_refunded: NotRequired[int]
+ """
+ Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
+ """
+ refund: NotRequired[str]
+ """
+ ID of an existing refund to link this credit note to. Required when `type` is `refund`.
+ """
+
+
+class CreditNoteCreateParamsShippingCost(TypedDict):
+ shipping_rate: NotRequired[str]
+ """
+ The ID of the shipping rate to use for this order.
+ """
diff --git a/stripe/params/_credit_note_line_item_list_params.py b/stripe/params/_credit_note_line_item_list_params.py
new file mode 100644
index 000000000..4eda752b3
--- /dev/null
+++ b/stripe/params/_credit_note_line_item_list_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CreditNoteLineItemListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_credit_note_list_lines_params.py b/stripe/params/_credit_note_list_lines_params.py
new file mode 100644
index 000000000..4eb8eacce
--- /dev/null
+++ b/stripe/params/_credit_note_list_lines_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CreditNoteListLinesParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_credit_note_list_params.py b/stripe/params/_credit_note_list_params.py
new file mode 100644
index 000000000..1f2f7e638
--- /dev/null
+++ b/stripe/params/_credit_note_list_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CreditNoteListParams(RequestOptions):
+ created: NotRequired["CreditNoteListParamsCreated|int"]
+ """
+ Only return credit notes that were created during the given date interval.
+ """
+ customer: NotRequired[str]
+ """
+ Only return credit notes for the customer specified by this customer ID.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice: NotRequired[str]
+ """
+ Only return credit notes for the invoice specified by this invoice ID.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class CreditNoteListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_credit_note_modify_params.py b/stripe/params/_credit_note_modify_params.py
new file mode 100644
index 000000000..7b53aa673
--- /dev/null
+++ b/stripe/params/_credit_note_modify_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import NotRequired
+
+
+class CreditNoteModifyParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ memo: NotRequired[str]
+ """
+ Credit note memo.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_credit_note_preview_lines_list_params.py b/stripe/params/_credit_note_preview_lines_list_params.py
new file mode 100644
index 000000000..49fa12d76
--- /dev/null
+++ b/stripe/params/_credit_note_preview_lines_list_params.py
@@ -0,0 +1,153 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CreditNotePreviewLinesListParams(TypedDict):
+ amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the total amount of the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
+ """
+ credit_amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
+ """
+ effective_at: NotRequired[int]
+ """
+ The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
+ """
+ email_type: NotRequired[Literal["credit_note", "none"]]
+ """
+ Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice: str
+ """
+ ID of the invoice.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ lines: NotRequired[List["CreditNotePreviewLinesListParamsLine"]]
+ """
+ Line items that make up the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
+ """
+ memo: NotRequired[str]
+ """
+ The credit note's memo appears on the credit note PDF.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ out_of_band_amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
+ """
+ reason: NotRequired[
+ Literal[
+ "duplicate", "fraudulent", "order_change", "product_unsatisfactory"
+ ]
+ ]
+ """
+ Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
+ """
+ refund_amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
+ """
+ refunds: NotRequired[List["CreditNotePreviewLinesListParamsRefund"]]
+ """
+ Refunds to link to this credit note.
+ """
+ shipping_cost: NotRequired["CreditNotePreviewLinesListParamsShippingCost"]
+ """
+ When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class CreditNotePreviewLinesListParamsLine(TypedDict):
+ amount: NotRequired[int]
+ """
+ The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
+ """
+ description: NotRequired[str]
+ """
+ The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
+ """
+ invoice_line_item: NotRequired[str]
+ """
+ The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
+ """
+ quantity: NotRequired[int]
+ """
+ The line item quantity to credit.
+ """
+ tax_amounts: NotRequired[
+ "Literal['']|List[CreditNotePreviewLinesListParamsLineTaxAmount]"
+ ]
+ """
+ A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
+ """
+ type: Literal["custom_line_item", "invoice_line_item"]
+ """
+ Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
+ """
+ unit_amount: NotRequired[int]
+ """
+ The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class CreditNotePreviewLinesListParamsLineTaxAmount(TypedDict):
+ amount: int
+ """
+ The amount, in cents (or local equivalent), of the tax.
+ """
+ tax_rate: str
+ """
+ The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
+ """
+ taxable_amount: int
+ """
+ The amount on which tax is calculated, in cents (or local equivalent).
+ """
+
+
+class CreditNotePreviewLinesListParamsRefund(TypedDict):
+ amount_refunded: NotRequired[int]
+ """
+ Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
+ """
+ refund: NotRequired[str]
+ """
+ ID of an existing refund to link this credit note to. Required when `type` is `refund`.
+ """
+
+
+class CreditNotePreviewLinesListParamsShippingCost(TypedDict):
+ shipping_rate: NotRequired[str]
+ """
+ The ID of the shipping rate to use for this order.
+ """
diff --git a/stripe/params/_credit_note_preview_lines_params.py b/stripe/params/_credit_note_preview_lines_params.py
new file mode 100644
index 000000000..570d75fa4
--- /dev/null
+++ b/stripe/params/_credit_note_preview_lines_params.py
@@ -0,0 +1,154 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CreditNotePreviewLinesParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the total amount of the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
+ """
+ credit_amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
+ """
+ effective_at: NotRequired[int]
+ """
+ The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
+ """
+ email_type: NotRequired[Literal["credit_note", "none"]]
+ """
+ Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice: str
+ """
+ ID of the invoice.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ lines: NotRequired[List["CreditNotePreviewLinesParamsLine"]]
+ """
+ Line items that make up the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
+ """
+ memo: NotRequired[str]
+ """
+ The credit note's memo appears on the credit note PDF.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ out_of_band_amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
+ """
+ reason: NotRequired[
+ Literal[
+ "duplicate", "fraudulent", "order_change", "product_unsatisfactory"
+ ]
+ ]
+ """
+ Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
+ """
+ refund_amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
+ """
+ refunds: NotRequired[List["CreditNotePreviewLinesParamsRefund"]]
+ """
+ Refunds to link to this credit note.
+ """
+ shipping_cost: NotRequired["CreditNotePreviewLinesParamsShippingCost"]
+ """
+ When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class CreditNotePreviewLinesParamsLine(TypedDict):
+ amount: NotRequired[int]
+ """
+ The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
+ """
+ description: NotRequired[str]
+ """
+ The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
+ """
+ invoice_line_item: NotRequired[str]
+ """
+ The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
+ """
+ quantity: NotRequired[int]
+ """
+ The line item quantity to credit.
+ """
+ tax_amounts: NotRequired[
+ "Literal['']|List[CreditNotePreviewLinesParamsLineTaxAmount]"
+ ]
+ """
+ A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
+ """
+ type: Literal["custom_line_item", "invoice_line_item"]
+ """
+ Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
+ """
+ unit_amount: NotRequired[int]
+ """
+ The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class CreditNotePreviewLinesParamsLineTaxAmount(TypedDict):
+ amount: int
+ """
+ The amount, in cents (or local equivalent), of the tax.
+ """
+ tax_rate: str
+ """
+ The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
+ """
+ taxable_amount: int
+ """
+ The amount on which tax is calculated, in cents (or local equivalent).
+ """
+
+
+class CreditNotePreviewLinesParamsRefund(TypedDict):
+ amount_refunded: NotRequired[int]
+ """
+ Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
+ """
+ refund: NotRequired[str]
+ """
+ ID of an existing refund to link this credit note to. Required when `type` is `refund`.
+ """
+
+
+class CreditNotePreviewLinesParamsShippingCost(TypedDict):
+ shipping_rate: NotRequired[str]
+ """
+ The ID of the shipping rate to use for this order.
+ """
diff --git a/stripe/params/_credit_note_preview_params.py b/stripe/params/_credit_note_preview_params.py
new file mode 100644
index 000000000..6814902ec
--- /dev/null
+++ b/stripe/params/_credit_note_preview_params.py
@@ -0,0 +1,142 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CreditNotePreviewParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the total amount of the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
+ """
+ credit_amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
+ """
+ effective_at: NotRequired[int]
+ """
+ The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
+ """
+ email_type: NotRequired[Literal["credit_note", "none"]]
+ """
+ Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice: str
+ """
+ ID of the invoice.
+ """
+ lines: NotRequired[List["CreditNotePreviewParamsLine"]]
+ """
+ Line items that make up the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
+ """
+ memo: NotRequired[str]
+ """
+ The credit note's memo appears on the credit note PDF.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ out_of_band_amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
+ """
+ reason: NotRequired[
+ Literal[
+ "duplicate", "fraudulent", "order_change", "product_unsatisfactory"
+ ]
+ ]
+ """
+ Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
+ """
+ refund_amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
+ """
+ refunds: NotRequired[List["CreditNotePreviewParamsRefund"]]
+ """
+ Refunds to link to this credit note.
+ """
+ shipping_cost: NotRequired["CreditNotePreviewParamsShippingCost"]
+ """
+ When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
+ """
+
+
+class CreditNotePreviewParamsLine(TypedDict):
+ amount: NotRequired[int]
+ """
+ The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
+ """
+ description: NotRequired[str]
+ """
+ The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
+ """
+ invoice_line_item: NotRequired[str]
+ """
+ The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
+ """
+ quantity: NotRequired[int]
+ """
+ The line item quantity to credit.
+ """
+ tax_amounts: NotRequired[
+ "Literal['']|List[CreditNotePreviewParamsLineTaxAmount]"
+ ]
+ """
+ A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
+ """
+ type: Literal["custom_line_item", "invoice_line_item"]
+ """
+ Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
+ """
+ unit_amount: NotRequired[int]
+ """
+ The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class CreditNotePreviewParamsLineTaxAmount(TypedDict):
+ amount: int
+ """
+ The amount, in cents (or local equivalent), of the tax.
+ """
+ tax_rate: str
+ """
+ The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
+ """
+ taxable_amount: int
+ """
+ The amount on which tax is calculated, in cents (or local equivalent).
+ """
+
+
+class CreditNotePreviewParamsRefund(TypedDict):
+ amount_refunded: NotRequired[int]
+ """
+ Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
+ """
+ refund: NotRequired[str]
+ """
+ ID of an existing refund to link this credit note to. Required when `type` is `refund`.
+ """
+
+
+class CreditNotePreviewParamsShippingCost(TypedDict):
+ shipping_rate: NotRequired[str]
+ """
+ The ID of the shipping rate to use for this order.
+ """
diff --git a/stripe/params/_credit_note_retrieve_params.py b/stripe/params/_credit_note_retrieve_params.py
new file mode 100644
index 000000000..0fabf9b71
--- /dev/null
+++ b/stripe/params/_credit_note_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CreditNoteRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_credit_note_update_params.py b/stripe/params/_credit_note_update_params.py
new file mode 100644
index 000000000..240ca2645
--- /dev/null
+++ b/stripe/params/_credit_note_update_params.py
@@ -0,0 +1,19 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CreditNoteUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ memo: NotRequired[str]
+ """
+ Credit note memo.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_credit_note_void_credit_note_params.py b/stripe/params/_credit_note_void_credit_note_params.py
new file mode 100644
index 000000000..5b9df8309
--- /dev/null
+++ b/stripe/params/_credit_note_void_credit_note_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CreditNoteVoidCreditNoteParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_balance_transaction_create_params.py b/stripe/params/_customer_balance_transaction_create_params.py
new file mode 100644
index 000000000..4795d1b73
--- /dev/null
+++ b/stripe/params/_customer_balance_transaction_create_params.py
@@ -0,0 +1,27 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CustomerBalanceTransactionCreateParams(TypedDict):
+ amount: int
+ """
+ The integer amount in **cents (or local equivalent)** to apply to the customer's credit balance.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Specifies the [`invoice_credit_balance`](https://stripe.com/docs/api/customers/object#customer_object-invoice_credit_balance) that this transaction will apply to. If the customer's `currency` is not set, it will be updated to this value.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_customer_balance_transaction_list_params.py b/stripe/params/_customer_balance_transaction_list_params.py
new file mode 100644
index 000000000..6ef239a18
--- /dev/null
+++ b/stripe/params/_customer_balance_transaction_list_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CustomerBalanceTransactionListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_customer_balance_transaction_retrieve_params.py b/stripe/params/_customer_balance_transaction_retrieve_params.py
new file mode 100644
index 000000000..bf34aed7d
--- /dev/null
+++ b/stripe/params/_customer_balance_transaction_retrieve_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CustomerBalanceTransactionRetrieveParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_balance_transaction_update_params.py b/stripe/params/_customer_balance_transaction_update_params.py
new file mode 100644
index 000000000..d4766b557
--- /dev/null
+++ b/stripe/params/_customer_balance_transaction_update_params.py
@@ -0,0 +1,19 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CustomerBalanceTransactionUpdateParams(TypedDict):
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_customer_cash_balance_retrieve_params.py b/stripe/params/_customer_cash_balance_retrieve_params.py
new file mode 100644
index 000000000..f94c43324
--- /dev/null
+++ b/stripe/params/_customer_cash_balance_retrieve_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CustomerCashBalanceRetrieveParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_cash_balance_transaction_list_params.py b/stripe/params/_customer_cash_balance_transaction_list_params.py
new file mode 100644
index 000000000..c0c9d4e7c
--- /dev/null
+++ b/stripe/params/_customer_cash_balance_transaction_list_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CustomerCashBalanceTransactionListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_customer_cash_balance_transaction_retrieve_params.py b/stripe/params/_customer_cash_balance_transaction_retrieve_params.py
new file mode 100644
index 000000000..c0d01026a
--- /dev/null
+++ b/stripe/params/_customer_cash_balance_transaction_retrieve_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CustomerCashBalanceTransactionRetrieveParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_cash_balance_update_params.py b/stripe/params/_customer_cash_balance_update_params.py
new file mode 100644
index 000000000..2f1bd2ced
--- /dev/null
+++ b/stripe/params/_customer_cash_balance_update_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CustomerCashBalanceUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ settings: NotRequired["CustomerCashBalanceUpdateParamsSettings"]
+ """
+ A hash of settings for this cash balance.
+ """
+
+
+class CustomerCashBalanceUpdateParamsSettings(TypedDict):
+ reconciliation_mode: NotRequired[
+ Literal["automatic", "manual", "merchant_default"]
+ ]
+ """
+ Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
+ """
diff --git a/stripe/params/_customer_create_balance_transaction_params.py b/stripe/params/_customer_create_balance_transaction_params.py
new file mode 100644
index 000000000..7d979c0a6
--- /dev/null
+++ b/stripe/params/_customer_create_balance_transaction_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class CustomerCreateBalanceTransactionParams(RequestOptions):
+ amount: int
+ """
+ The integer amount in **cents (or local equivalent)** to apply to the customer's credit balance.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Specifies the [`invoice_credit_balance`](https://stripe.com/docs/api/customers/object#customer_object-invoice_credit_balance) that this transaction will apply to. If the customer's `currency` is not set, it will be updated to this value.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_customer_create_funding_instructions_params.py b/stripe/params/_customer_create_funding_instructions_params.py
new file mode 100644
index 000000000..a2792948c
--- /dev/null
+++ b/stripe/params/_customer_create_funding_instructions_params.py
@@ -0,0 +1,60 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CustomerCreateFundingInstructionsParams(RequestOptions):
+ bank_transfer: "CustomerCreateFundingInstructionsParamsBankTransfer"
+ """
+ Additional parameters for `bank_transfer` funding types
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ funding_type: Literal["bank_transfer"]
+ """
+ The `funding_type` to get the instructions for.
+ """
+
+
+class CustomerCreateFundingInstructionsParamsBankTransfer(TypedDict):
+ eu_bank_transfer: NotRequired[
+ "CustomerCreateFundingInstructionsParamsBankTransferEuBankTransfer"
+ ]
+ """
+ Configuration for eu_bank_transfer funding type.
+ """
+ requested_address_types: NotRequired[
+ List[Literal["iban", "sort_code", "spei", "zengin"]]
+ ]
+ """
+ List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
+
+ Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
+ """
+ type: Literal[
+ "eu_bank_transfer",
+ "gb_bank_transfer",
+ "jp_bank_transfer",
+ "mx_bank_transfer",
+ "us_bank_transfer",
+ ]
+ """
+ The type of the `bank_transfer`
+ """
+
+
+class CustomerCreateFundingInstructionsParamsBankTransferEuBankTransfer(
+ TypedDict,
+):
+ country: str
+ """
+ The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
+ """
diff --git a/stripe/params/_customer_create_params.py b/stripe/params/_customer_create_params.py
new file mode 100644
index 000000000..3d7ae3df9
--- /dev/null
+++ b/stripe/params/_customer_create_params.py
@@ -0,0 +1,357 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CustomerCreateParams(RequestOptions):
+ address: NotRequired["Literal['']|CustomerCreateParamsAddress"]
+ """
+ The customer's address.
+ """
+ balance: NotRequired[int]
+ """
+ An integer amount in cents (or local equivalent) that represents the customer's current balance, which affect the customer's future invoices. A negative amount represents a credit that decreases the amount due on an invoice; a positive amount increases the amount due on an invoice.
+ """
+ business_name: NotRequired["Literal['']|str"]
+ """
+ The customer's business name. This may be up to *150 characters*.
+ """
+ cash_balance: NotRequired["CustomerCreateParamsCashBalance"]
+ """
+ Balance information and default balance settings for this customer.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string that you can attach to a customer object. It is displayed alongside the customer in the dashboard.
+ """
+ email: NotRequired[str]
+ """
+ Customer's email address. It's displayed alongside the customer in your dashboard and can be useful for searching and tracking. This may be up to *512 characters*.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ individual_name: NotRequired["Literal['']|str"]
+ """
+ The customer's full name. This may be up to *150 characters*.
+ """
+ invoice_prefix: NotRequired[str]
+ """
+ The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.
+ """
+ invoice_settings: NotRequired["CustomerCreateParamsInvoiceSettings"]
+ """
+ Default invoice settings for this customer.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired[str]
+ """
+ The customer's full name or business name.
+ """
+ next_invoice_sequence: NotRequired[int]
+ """
+ The sequence to be used on the customer's next invoice. Defaults to 1.
+ """
+ payment_method: NotRequired[str]
+ phone: NotRequired[str]
+ """
+ The customer's phone number.
+ """
+ preferred_locales: NotRequired[List[str]]
+ """
+ Customer's preferred languages, ordered by preference.
+ """
+ shipping: NotRequired["Literal['']|CustomerCreateParamsShipping"]
+ """
+ The customer's shipping information. Appears on invoices emailed to this customer.
+ """
+ source: NotRequired[str]
+ tax: NotRequired["CustomerCreateParamsTax"]
+ """
+ Tax details about the customer.
+ """
+ tax_exempt: NotRequired["Literal['']|Literal['exempt', 'none', 'reverse']"]
+ """
+ The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
+ """
+ tax_id_data: NotRequired[List["CustomerCreateParamsTaxIdDatum"]]
+ """
+ The customer's tax IDs.
+ """
+ test_clock: NotRequired[str]
+ """
+ ID of the test clock to attach to the customer.
+ """
+ validate: NotRequired[bool]
+
+
+class CustomerCreateParamsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class CustomerCreateParamsCashBalance(TypedDict):
+ settings: NotRequired["CustomerCreateParamsCashBalanceSettings"]
+ """
+ Settings controlling the behavior of the customer's cash balance,
+ such as reconciliation of funds received.
+ """
+
+
+class CustomerCreateParamsCashBalanceSettings(TypedDict):
+ reconciliation_mode: NotRequired[
+ Literal["automatic", "manual", "merchant_default"]
+ ]
+ """
+ Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
+ """
+
+
+class CustomerCreateParamsInvoiceSettings(TypedDict):
+ custom_fields: NotRequired[
+ "Literal['']|List[CustomerCreateParamsInvoiceSettingsCustomField]"
+ ]
+ """
+ The list of up to 4 default custom fields to be displayed on invoices for this customer. When updating, pass an empty string to remove previously-defined fields.
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of a payment method that's attached to the customer, to be used as the customer's default payment method for subscriptions and invoices.
+ """
+ footer: NotRequired[str]
+ """
+ Default footer to be displayed on invoices for this customer.
+ """
+ rendering_options: NotRequired[
+ "Literal['']|CustomerCreateParamsInvoiceSettingsRenderingOptions"
+ ]
+ """
+ Default options for invoice PDF rendering for this customer.
+ """
+
+
+class CustomerCreateParamsInvoiceSettingsCustomField(TypedDict):
+ name: str
+ """
+ The name of the custom field. This may be up to 40 characters.
+ """
+ value: str
+ """
+ The value of the custom field. This may be up to 140 characters.
+ """
+
+
+class CustomerCreateParamsInvoiceSettingsRenderingOptions(TypedDict):
+ amount_tax_display: NotRequired[
+ "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
+ ]
+ """
+ How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
+ """
+ template: NotRequired[str]
+ """
+ ID of the invoice rendering template to use for future invoices.
+ """
+
+
+class CustomerCreateParamsShipping(TypedDict):
+ address: "CustomerCreateParamsShippingAddress"
+ """
+ Customer shipping address.
+ """
+ name: str
+ """
+ Customer name.
+ """
+ phone: NotRequired[str]
+ """
+ Customer phone (including extension).
+ """
+
+
+class CustomerCreateParamsShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class CustomerCreateParamsTax(TypedDict):
+ ip_address: NotRequired["Literal['']|str"]
+ """
+ A recent IP address of the customer used for tax reporting and tax location inference. Stripe recommends updating the IP address when a new PaymentMethod is attached or the address field on the customer is updated. We recommend against updating this field more frequently since it could result in unexpected tax location/reporting outcomes.
+ """
+ validate_location: NotRequired[Literal["deferred", "immediately"]]
+ """
+ A flag that indicates when Stripe should validate the customer tax location. Defaults to `deferred`.
+ """
+
+
+class CustomerCreateParamsTaxIdDatum(TypedDict):
+ type: Literal[
+ "ad_nrt",
+ "ae_trn",
+ "al_tin",
+ "am_tin",
+ "ao_tin",
+ "ar_cuit",
+ "au_abn",
+ "au_arn",
+ "aw_tin",
+ "az_tin",
+ "ba_tin",
+ "bb_tin",
+ "bd_bin",
+ "bf_ifu",
+ "bg_uic",
+ "bh_vat",
+ "bj_ifu",
+ "bo_tin",
+ "br_cnpj",
+ "br_cpf",
+ "bs_tin",
+ "by_tin",
+ "ca_bn",
+ "ca_gst_hst",
+ "ca_pst_bc",
+ "ca_pst_mb",
+ "ca_pst_sk",
+ "ca_qst",
+ "cd_nif",
+ "ch_uid",
+ "ch_vat",
+ "cl_tin",
+ "cm_niu",
+ "cn_tin",
+ "co_nit",
+ "cr_tin",
+ "cv_nif",
+ "de_stn",
+ "do_rcn",
+ "ec_ruc",
+ "eg_tin",
+ "es_cif",
+ "et_tin",
+ "eu_oss_vat",
+ "eu_vat",
+ "gb_vat",
+ "ge_vat",
+ "gn_nif",
+ "hk_br",
+ "hr_oib",
+ "hu_tin",
+ "id_npwp",
+ "il_vat",
+ "in_gst",
+ "is_vat",
+ "jp_cn",
+ "jp_rn",
+ "jp_trn",
+ "ke_pin",
+ "kg_tin",
+ "kh_tin",
+ "kr_brn",
+ "kz_bin",
+ "la_tin",
+ "li_uid",
+ "li_vat",
+ "ma_vat",
+ "md_vat",
+ "me_pib",
+ "mk_vat",
+ "mr_nif",
+ "mx_rfc",
+ "my_frp",
+ "my_itn",
+ "my_sst",
+ "ng_tin",
+ "no_vat",
+ "no_voec",
+ "np_pan",
+ "nz_gst",
+ "om_vat",
+ "pe_ruc",
+ "ph_tin",
+ "ro_tin",
+ "rs_pib",
+ "ru_inn",
+ "ru_kpp",
+ "sa_vat",
+ "sg_gst",
+ "sg_uen",
+ "si_tin",
+ "sn_ninea",
+ "sr_fin",
+ "sv_nit",
+ "th_vat",
+ "tj_tin",
+ "tr_tin",
+ "tw_vat",
+ "tz_vat",
+ "ua_vat",
+ "ug_tin",
+ "us_ein",
+ "uy_ruc",
+ "uz_tin",
+ "uz_vat",
+ "ve_rif",
+ "vn_tin",
+ "za_vat",
+ "zm_tin",
+ "zw_tin",
+ ]
+ """
+ Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
+ """
+ value: str
+ """
+ Value of the tax ID.
+ """
diff --git a/stripe/params/_customer_create_source_params.py b/stripe/params/_customer_create_source_params.py
new file mode 100644
index 000000000..80318b03a
--- /dev/null
+++ b/stripe/params/_customer_create_source_params.py
@@ -0,0 +1,21 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import NotRequired
+
+
+class CustomerCreateSourceParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ source: str
+ """
+ Please refer to full [documentation](https://stripe.com/docs/api) instead.
+ """
+ validate: NotRequired[bool]
diff --git a/stripe/params/_customer_create_tax_id_params.py b/stripe/params/_customer_create_tax_id_params.py
new file mode 100644
index 000000000..ddaa0246d
--- /dev/null
+++ b/stripe/params/_customer_create_tax_id_params.py
@@ -0,0 +1,131 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class CustomerCreateTaxIdParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ type: Literal[
+ "ad_nrt",
+ "ae_trn",
+ "al_tin",
+ "am_tin",
+ "ao_tin",
+ "ar_cuit",
+ "au_abn",
+ "au_arn",
+ "aw_tin",
+ "az_tin",
+ "ba_tin",
+ "bb_tin",
+ "bd_bin",
+ "bf_ifu",
+ "bg_uic",
+ "bh_vat",
+ "bj_ifu",
+ "bo_tin",
+ "br_cnpj",
+ "br_cpf",
+ "bs_tin",
+ "by_tin",
+ "ca_bn",
+ "ca_gst_hst",
+ "ca_pst_bc",
+ "ca_pst_mb",
+ "ca_pst_sk",
+ "ca_qst",
+ "cd_nif",
+ "ch_uid",
+ "ch_vat",
+ "cl_tin",
+ "cm_niu",
+ "cn_tin",
+ "co_nit",
+ "cr_tin",
+ "cv_nif",
+ "de_stn",
+ "do_rcn",
+ "ec_ruc",
+ "eg_tin",
+ "es_cif",
+ "et_tin",
+ "eu_oss_vat",
+ "eu_vat",
+ "gb_vat",
+ "ge_vat",
+ "gn_nif",
+ "hk_br",
+ "hr_oib",
+ "hu_tin",
+ "id_npwp",
+ "il_vat",
+ "in_gst",
+ "is_vat",
+ "jp_cn",
+ "jp_rn",
+ "jp_trn",
+ "ke_pin",
+ "kg_tin",
+ "kh_tin",
+ "kr_brn",
+ "kz_bin",
+ "la_tin",
+ "li_uid",
+ "li_vat",
+ "ma_vat",
+ "md_vat",
+ "me_pib",
+ "mk_vat",
+ "mr_nif",
+ "mx_rfc",
+ "my_frp",
+ "my_itn",
+ "my_sst",
+ "ng_tin",
+ "no_vat",
+ "no_voec",
+ "np_pan",
+ "nz_gst",
+ "om_vat",
+ "pe_ruc",
+ "ph_tin",
+ "ro_tin",
+ "rs_pib",
+ "ru_inn",
+ "ru_kpp",
+ "sa_vat",
+ "sg_gst",
+ "sg_uen",
+ "si_tin",
+ "sn_ninea",
+ "sr_fin",
+ "sv_nit",
+ "th_vat",
+ "tj_tin",
+ "tr_tin",
+ "tw_vat",
+ "tz_vat",
+ "ua_vat",
+ "ug_tin",
+ "us_ein",
+ "uy_ruc",
+ "uz_tin",
+ "uz_vat",
+ "ve_rif",
+ "vn_tin",
+ "za_vat",
+ "zm_tin",
+ "zw_tin",
+ ]
+ """
+ Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
+ """
+ value: str
+ """
+ Value of the tax ID.
+ """
diff --git a/stripe/params/_customer_delete_discount_params.py b/stripe/params/_customer_delete_discount_params.py
new file mode 100644
index 000000000..5097006c3
--- /dev/null
+++ b/stripe/params/_customer_delete_discount_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class CustomerDeleteDiscountParams(RequestOptions):
+ pass
diff --git a/stripe/params/_customer_delete_params.py b/stripe/params/_customer_delete_params.py
new file mode 100644
index 000000000..ac50ae632
--- /dev/null
+++ b/stripe/params/_customer_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class CustomerDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/_customer_delete_source_params.py b/stripe/params/_customer_delete_source_params.py
new file mode 100644
index 000000000..b1bf34844
--- /dev/null
+++ b/stripe/params/_customer_delete_source_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CustomerDeleteSourceParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_delete_tax_id_params.py b/stripe/params/_customer_delete_tax_id_params.py
new file mode 100644
index 000000000..362ba6fe6
--- /dev/null
+++ b/stripe/params/_customer_delete_tax_id_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class CustomerDeleteTaxIdParams(RequestOptions):
+ pass
diff --git a/stripe/params/_customer_fund_cash_balance_params.py b/stripe/params/_customer_fund_cash_balance_params.py
new file mode 100644
index 000000000..50645a32f
--- /dev/null
+++ b/stripe/params/_customer_fund_cash_balance_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CustomerFundCashBalanceParams(RequestOptions):
+ amount: int
+ """
+ Amount to be used for this test cash balance transaction. A positive integer representing how much to fund in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to fund $1.00 or 100 to fund ¥100, a zero-decimal currency).
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ reference: NotRequired[str]
+ """
+ A description of the test funding. This simulates free-text references supplied by customers when making bank transfers to their cash balance. You can use this to test how Stripe's [reconciliation algorithm](https://stripe.com/docs/payments/customer-balance/reconciliation) applies to different user inputs.
+ """
diff --git a/stripe/params/_customer_funding_instructions_create_params.py b/stripe/params/_customer_funding_instructions_create_params.py
new file mode 100644
index 000000000..24d23ad43
--- /dev/null
+++ b/stripe/params/_customer_funding_instructions_create_params.py
@@ -0,0 +1,59 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CustomerFundingInstructionsCreateParams(TypedDict):
+ bank_transfer: "CustomerFundingInstructionsCreateParamsBankTransfer"
+ """
+ Additional parameters for `bank_transfer` funding types
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ funding_type: Literal["bank_transfer"]
+ """
+ The `funding_type` to get the instructions for.
+ """
+
+
+class CustomerFundingInstructionsCreateParamsBankTransfer(TypedDict):
+ eu_bank_transfer: NotRequired[
+ "CustomerFundingInstructionsCreateParamsBankTransferEuBankTransfer"
+ ]
+ """
+ Configuration for eu_bank_transfer funding type.
+ """
+ requested_address_types: NotRequired[
+ List[Literal["iban", "sort_code", "spei", "zengin"]]
+ ]
+ """
+ List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
+
+ Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
+ """
+ type: Literal[
+ "eu_bank_transfer",
+ "gb_bank_transfer",
+ "jp_bank_transfer",
+ "mx_bank_transfer",
+ "us_bank_transfer",
+ ]
+ """
+ The type of the `bank_transfer`
+ """
+
+
+class CustomerFundingInstructionsCreateParamsBankTransferEuBankTransfer(
+ TypedDict,
+):
+ country: str
+ """
+ The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
+ """
diff --git a/stripe/params/_customer_list_balance_transactions_params.py b/stripe/params/_customer_list_balance_transactions_params.py
new file mode 100644
index 000000000..258153525
--- /dev/null
+++ b/stripe/params/_customer_list_balance_transactions_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CustomerListBalanceTransactionsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_customer_list_cash_balance_transactions_params.py b/stripe/params/_customer_list_cash_balance_transactions_params.py
new file mode 100644
index 000000000..7b41fc856
--- /dev/null
+++ b/stripe/params/_customer_list_cash_balance_transactions_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CustomerListCashBalanceTransactionsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_customer_list_params.py b/stripe/params/_customer_list_params.py
new file mode 100644
index 000000000..84a76a03b
--- /dev/null
+++ b/stripe/params/_customer_list_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CustomerListParams(RequestOptions):
+ created: NotRequired["CustomerListParamsCreated|int"]
+ """
+ Only return customers that were created during the given date interval.
+ """
+ email: NotRequired[str]
+ """
+ A case-sensitive filter on the list based on the customer's `email` field. The value must be a string.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ test_clock: NotRequired[str]
+ """
+ Provides a list of customers that are associated with the specified test clock. The response will not include customers with test clocks if this parameter is not set.
+ """
+
+
+class CustomerListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_customer_list_payment_methods_params.py b/stripe/params/_customer_list_payment_methods_params.py
new file mode 100644
index 000000000..e7e880d92
--- /dev/null
+++ b/stripe/params/_customer_list_payment_methods_params.py
@@ -0,0 +1,84 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class CustomerListPaymentMethodsParams(RequestOptions):
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ type: NotRequired[
+ Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "card",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "link",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ ]
+ """
+ An optional filter on the list, based on the object `type` field. Without the filter, the list includes all current and future payment method types. If your integration expects only one type of payment method in the response, make sure to provide a type value in the request.
+ """
diff --git a/stripe/params/_customer_list_sources_params.py b/stripe/params/_customer_list_sources_params.py
new file mode 100644
index 000000000..8e372def6
--- /dev/null
+++ b/stripe/params/_customer_list_sources_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CustomerListSourcesParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ object: NotRequired[str]
+ """
+ Filter sources according to a particular object type.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_customer_list_tax_ids_params.py b/stripe/params/_customer_list_tax_ids_params.py
new file mode 100644
index 000000000..48e701b90
--- /dev/null
+++ b/stripe/params/_customer_list_tax_ids_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CustomerListTaxIdsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_customer_modify_balance_transaction_params.py b/stripe/params/_customer_modify_balance_transaction_params.py
new file mode 100644
index 000000000..9201b6263
--- /dev/null
+++ b/stripe/params/_customer_modify_balance_transaction_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class CustomerModifyBalanceTransactionParams(RequestOptions):
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_customer_modify_cash_balance_params.py b/stripe/params/_customer_modify_cash_balance_params.py
new file mode 100644
index 000000000..825733e11
--- /dev/null
+++ b/stripe/params/_customer_modify_cash_balance_params.py
@@ -0,0 +1,25 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CustomerModifyCashBalanceParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ settings: NotRequired["CustomerModifyCashBalanceParamsSettings"]
+ """
+ A hash of settings for this cash balance.
+ """
+
+
+class CustomerModifyCashBalanceParamsSettings(TypedDict):
+ reconciliation_mode: NotRequired[
+ Literal["automatic", "manual", "merchant_default"]
+ ]
+ """
+ Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
+ """
diff --git a/stripe/params/_customer_modify_params.py b/stripe/params/_customer_modify_params.py
new file mode 100644
index 000000000..4e1f5e8be
--- /dev/null
+++ b/stripe/params/_customer_modify_params.py
@@ -0,0 +1,234 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CustomerModifyParams(RequestOptions):
+ address: NotRequired["Literal['']|CustomerModifyParamsAddress"]
+ """
+ The customer's address.
+ """
+ balance: NotRequired[int]
+ """
+ An integer amount in cents (or local equivalent) that represents the customer's current balance, which affect the customer's future invoices. A negative amount represents a credit that decreases the amount due on an invoice; a positive amount increases the amount due on an invoice.
+ """
+ business_name: NotRequired["Literal['']|str"]
+ """
+ The customer's business name. This may be up to *150 characters*.
+ """
+ cash_balance: NotRequired["CustomerModifyParamsCashBalance"]
+ """
+ Balance information and default balance settings for this customer.
+ """
+ default_source: NotRequired[str]
+ """
+ If you are using payment methods created via the PaymentMethods API, see the [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method) parameter.
+
+ Provide the ID of a payment source already attached to this customer to make it this customer's default payment source.
+
+ If you want to add a new payment source and make it the default, see the [source](https://stripe.com/docs/api/customers/update#update_customer-source) property.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string that you can attach to a customer object. It is displayed alongside the customer in the dashboard.
+ """
+ email: NotRequired[str]
+ """
+ Customer's email address. It's displayed alongside the customer in your dashboard and can be useful for searching and tracking. This may be up to *512 characters*.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ individual_name: NotRequired["Literal['']|str"]
+ """
+ The customer's full name. This may be up to *150 characters*.
+ """
+ invoice_prefix: NotRequired[str]
+ """
+ The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.
+ """
+ invoice_settings: NotRequired["CustomerModifyParamsInvoiceSettings"]
+ """
+ Default invoice settings for this customer.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired[str]
+ """
+ The customer's full name or business name.
+ """
+ next_invoice_sequence: NotRequired[int]
+ """
+ The sequence to be used on the customer's next invoice. Defaults to 1.
+ """
+ phone: NotRequired[str]
+ """
+ The customer's phone number.
+ """
+ preferred_locales: NotRequired[List[str]]
+ """
+ Customer's preferred languages, ordered by preference.
+ """
+ shipping: NotRequired["Literal['']|CustomerModifyParamsShipping"]
+ """
+ The customer's shipping information. Appears on invoices emailed to this customer.
+ """
+ source: NotRequired[str]
+ tax: NotRequired["CustomerModifyParamsTax"]
+ """
+ Tax details about the customer.
+ """
+ tax_exempt: NotRequired["Literal['']|Literal['exempt', 'none', 'reverse']"]
+ """
+ The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
+ """
+ validate: NotRequired[bool]
+
+
+class CustomerModifyParamsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class CustomerModifyParamsCashBalance(TypedDict):
+ settings: NotRequired["CustomerModifyParamsCashBalanceSettings"]
+ """
+ Settings controlling the behavior of the customer's cash balance,
+ such as reconciliation of funds received.
+ """
+
+
+class CustomerModifyParamsCashBalanceSettings(TypedDict):
+ reconciliation_mode: NotRequired[
+ Literal["automatic", "manual", "merchant_default"]
+ ]
+ """
+ Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
+ """
+
+
+class CustomerModifyParamsInvoiceSettings(TypedDict):
+ custom_fields: NotRequired[
+ "Literal['']|List[CustomerModifyParamsInvoiceSettingsCustomField]"
+ ]
+ """
+ The list of up to 4 default custom fields to be displayed on invoices for this customer. When updating, pass an empty string to remove previously-defined fields.
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of a payment method that's attached to the customer, to be used as the customer's default payment method for subscriptions and invoices.
+ """
+ footer: NotRequired[str]
+ """
+ Default footer to be displayed on invoices for this customer.
+ """
+ rendering_options: NotRequired[
+ "Literal['']|CustomerModifyParamsInvoiceSettingsRenderingOptions"
+ ]
+ """
+ Default options for invoice PDF rendering for this customer.
+ """
+
+
+class CustomerModifyParamsInvoiceSettingsCustomField(TypedDict):
+ name: str
+ """
+ The name of the custom field. This may be up to 40 characters.
+ """
+ value: str
+ """
+ The value of the custom field. This may be up to 140 characters.
+ """
+
+
+class CustomerModifyParamsInvoiceSettingsRenderingOptions(TypedDict):
+ amount_tax_display: NotRequired[
+ "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
+ ]
+ """
+ How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
+ """
+ template: NotRequired[str]
+ """
+ ID of the invoice rendering template to use for future invoices.
+ """
+
+
+class CustomerModifyParamsShipping(TypedDict):
+ address: "CustomerModifyParamsShippingAddress"
+ """
+ Customer shipping address.
+ """
+ name: str
+ """
+ Customer name.
+ """
+ phone: NotRequired[str]
+ """
+ Customer phone (including extension).
+ """
+
+
+class CustomerModifyParamsShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class CustomerModifyParamsTax(TypedDict):
+ ip_address: NotRequired["Literal['']|str"]
+ """
+ A recent IP address of the customer used for tax reporting and tax location inference. Stripe recommends updating the IP address when a new PaymentMethod is attached or the address field on the customer is updated. We recommend against updating this field more frequently since it could result in unexpected tax location/reporting outcomes.
+ """
+ validate_location: NotRequired[Literal["auto", "deferred", "immediately"]]
+ """
+ A flag that indicates when Stripe should validate the customer tax location. Defaults to `auto`.
+ """
diff --git a/stripe/params/_customer_modify_source_params.py b/stripe/params/_customer_modify_source_params.py
new file mode 100644
index 000000000..844a6a70a
--- /dev/null
+++ b/stripe/params/_customer_modify_source_params.py
@@ -0,0 +1,107 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CustomerModifySourceParams(RequestOptions):
+ account_holder_name: NotRequired[str]
+ """
+ The name of the person or business that owns the bank account.
+ """
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ The type of entity that holds the account. This can be either `individual` or `company`.
+ """
+ address_city: NotRequired[str]
+ """
+ City/District/Suburb/Town/Village.
+ """
+ address_country: NotRequired[str]
+ """
+ Billing address country, if provided when creating card.
+ """
+ address_line1: NotRequired[str]
+ """
+ Address line 1 (Street address/PO Box/Company name).
+ """
+ address_line2: NotRequired[str]
+ """
+ Address line 2 (Apartment/Suite/Unit/Building).
+ """
+ address_state: NotRequired[str]
+ """
+ State/County/Province/Region.
+ """
+ address_zip: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ exp_month: NotRequired[str]
+ """
+ Two digit number representing the card's expiration month.
+ """
+ exp_year: NotRequired[str]
+ """
+ Four digit number representing the card's expiration year.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired[str]
+ """
+ Cardholder name.
+ """
+ owner: NotRequired["CustomerModifySourceParamsOwner"]
+
+
+class CustomerModifySourceParamsOwner(TypedDict):
+ address: NotRequired["CustomerModifySourceParamsOwnerAddress"]
+ """
+ Owner's address.
+ """
+ email: NotRequired[str]
+ """
+ Owner's email address.
+ """
+ name: NotRequired[str]
+ """
+ Owner's full name.
+ """
+ phone: NotRequired[str]
+ """
+ Owner's phone number.
+ """
+
+
+class CustomerModifySourceParamsOwnerAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
diff --git a/stripe/params/_customer_payment_method_list_params.py b/stripe/params/_customer_payment_method_list_params.py
new file mode 100644
index 000000000..9e9abe0e6
--- /dev/null
+++ b/stripe/params/_customer_payment_method_list_params.py
@@ -0,0 +1,83 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CustomerPaymentMethodListParams(TypedDict):
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ type: NotRequired[
+ Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "card",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "link",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ ]
+ """
+ An optional filter on the list, based on the object `type` field. Without the filter, the list includes all current and future payment method types. If your integration expects only one type of payment method in the response, make sure to provide a type value in the request.
+ """
diff --git a/stripe/params/_customer_payment_method_retrieve_params.py b/stripe/params/_customer_payment_method_retrieve_params.py
new file mode 100644
index 000000000..2be20f68b
--- /dev/null
+++ b/stripe/params/_customer_payment_method_retrieve_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CustomerPaymentMethodRetrieveParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_payment_source_create_params.py b/stripe/params/_customer_payment_source_create_params.py
new file mode 100644
index 000000000..20c45c9f8
--- /dev/null
+++ b/stripe/params/_customer_payment_source_create_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CustomerPaymentSourceCreateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ source: str
+ """
+ Please refer to full [documentation](https://stripe.com/docs/api) instead.
+ """
+ validate: NotRequired[bool]
diff --git a/stripe/params/_customer_payment_source_delete_params.py b/stripe/params/_customer_payment_source_delete_params.py
new file mode 100644
index 000000000..b7c9db285
--- /dev/null
+++ b/stripe/params/_customer_payment_source_delete_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CustomerPaymentSourceDeleteParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_payment_source_list_params.py b/stripe/params/_customer_payment_source_list_params.py
new file mode 100644
index 000000000..50e7d599f
--- /dev/null
+++ b/stripe/params/_customer_payment_source_list_params.py
@@ -0,0 +1,27 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CustomerPaymentSourceListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ object: NotRequired[str]
+ """
+ Filter sources according to a particular object type.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_customer_payment_source_retrieve_params.py b/stripe/params/_customer_payment_source_retrieve_params.py
new file mode 100644
index 000000000..20b7bc4df
--- /dev/null
+++ b/stripe/params/_customer_payment_source_retrieve_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CustomerPaymentSourceRetrieveParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_payment_source_update_params.py b/stripe/params/_customer_payment_source_update_params.py
new file mode 100644
index 000000000..33e5b3520
--- /dev/null
+++ b/stripe/params/_customer_payment_source_update_params.py
@@ -0,0 +1,106 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CustomerPaymentSourceUpdateParams(TypedDict):
+ account_holder_name: NotRequired[str]
+ """
+ The name of the person or business that owns the bank account.
+ """
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ The type of entity that holds the account. This can be either `individual` or `company`.
+ """
+ address_city: NotRequired[str]
+ """
+ City/District/Suburb/Town/Village.
+ """
+ address_country: NotRequired[str]
+ """
+ Billing address country, if provided when creating card.
+ """
+ address_line1: NotRequired[str]
+ """
+ Address line 1 (Street address/PO Box/Company name).
+ """
+ address_line2: NotRequired[str]
+ """
+ Address line 2 (Apartment/Suite/Unit/Building).
+ """
+ address_state: NotRequired[str]
+ """
+ State/County/Province/Region.
+ """
+ address_zip: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ exp_month: NotRequired[str]
+ """
+ Two digit number representing the card's expiration month.
+ """
+ exp_year: NotRequired[str]
+ """
+ Four digit number representing the card's expiration year.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired[str]
+ """
+ Cardholder name.
+ """
+ owner: NotRequired["CustomerPaymentSourceUpdateParamsOwner"]
+
+
+class CustomerPaymentSourceUpdateParamsOwner(TypedDict):
+ address: NotRequired["CustomerPaymentSourceUpdateParamsOwnerAddress"]
+ """
+ Owner's address.
+ """
+ email: NotRequired[str]
+ """
+ Owner's email address.
+ """
+ name: NotRequired[str]
+ """
+ Owner's full name.
+ """
+ phone: NotRequired[str]
+ """
+ Owner's phone number.
+ """
+
+
+class CustomerPaymentSourceUpdateParamsOwnerAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
diff --git a/stripe/params/_customer_payment_source_verify_params.py b/stripe/params/_customer_payment_source_verify_params.py
new file mode 100644
index 000000000..91b036c75
--- /dev/null
+++ b/stripe/params/_customer_payment_source_verify_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CustomerPaymentSourceVerifyParams(TypedDict):
+ amounts: NotRequired[List[int]]
+ """
+ Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_retrieve_balance_transaction_params.py b/stripe/params/_customer_retrieve_balance_transaction_params.py
new file mode 100644
index 000000000..c945e82db
--- /dev/null
+++ b/stripe/params/_customer_retrieve_balance_transaction_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CustomerRetrieveBalanceTransactionParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_retrieve_cash_balance_params.py b/stripe/params/_customer_retrieve_cash_balance_params.py
new file mode 100644
index 000000000..be8d5f6e0
--- /dev/null
+++ b/stripe/params/_customer_retrieve_cash_balance_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CustomerRetrieveCashBalanceParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_retrieve_cash_balance_transaction_params.py b/stripe/params/_customer_retrieve_cash_balance_transaction_params.py
new file mode 100644
index 000000000..9f175a328
--- /dev/null
+++ b/stripe/params/_customer_retrieve_cash_balance_transaction_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CustomerRetrieveCashBalanceTransactionParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_retrieve_params.py b/stripe/params/_customer_retrieve_params.py
new file mode 100644
index 000000000..17e5db37d
--- /dev/null
+++ b/stripe/params/_customer_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CustomerRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_retrieve_payment_method_params.py b/stripe/params/_customer_retrieve_payment_method_params.py
new file mode 100644
index 000000000..27ef7b927
--- /dev/null
+++ b/stripe/params/_customer_retrieve_payment_method_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CustomerRetrievePaymentMethodParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_retrieve_source_params.py b/stripe/params/_customer_retrieve_source_params.py
new file mode 100644
index 000000000..2a9969e44
--- /dev/null
+++ b/stripe/params/_customer_retrieve_source_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CustomerRetrieveSourceParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_retrieve_tax_id_params.py b/stripe/params/_customer_retrieve_tax_id_params.py
new file mode 100644
index 000000000..84b95c4b4
--- /dev/null
+++ b/stripe/params/_customer_retrieve_tax_id_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CustomerRetrieveTaxIdParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_search_params.py b/stripe/params/_customer_search_params.py
new file mode 100644
index 000000000..7cb556101
--- /dev/null
+++ b/stripe/params/_customer_search_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CustomerSearchParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ page: NotRequired[str]
+ """
+ A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
+ """
+ query: str
+ """
+ The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for customers](https://stripe.com/docs/search#query-fields-for-customers).
+ """
diff --git a/stripe/params/_customer_session_create_params.py b/stripe/params/_customer_session_create_params.py
new file mode 100644
index 000000000..23ad9daeb
--- /dev/null
+++ b/stripe/params/_customer_session_create_params.py
@@ -0,0 +1,105 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CustomerSessionCreateParams(RequestOptions):
+ components: "CustomerSessionCreateParamsComponents"
+ """
+ Configuration for each component. Exactly 1 component must be enabled.
+ """
+ customer: str
+ """
+ The ID of an existing customer for which to create the Customer Session.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+
+
+class CustomerSessionCreateParamsComponents(TypedDict):
+ buy_button: NotRequired["CustomerSessionCreateParamsComponentsBuyButton"]
+ """
+ Configuration for buy button.
+ """
+ payment_element: NotRequired[
+ "CustomerSessionCreateParamsComponentsPaymentElement"
+ ]
+ """
+ Configuration for the Payment Element.
+ """
+ pricing_table: NotRequired[
+ "CustomerSessionCreateParamsComponentsPricingTable"
+ ]
+ """
+ Configuration for the pricing table.
+ """
+
+
+class CustomerSessionCreateParamsComponentsBuyButton(TypedDict):
+ enabled: bool
+ """
+ Whether the buy button is enabled.
+ """
+
+
+class CustomerSessionCreateParamsComponentsPaymentElement(TypedDict):
+ enabled: bool
+ """
+ Whether the Payment Element is enabled.
+ """
+ features: NotRequired[
+ "CustomerSessionCreateParamsComponentsPaymentElementFeatures"
+ ]
+ """
+ This hash defines whether the Payment Element supports certain features.
+ """
+
+
+class CustomerSessionCreateParamsComponentsPaymentElementFeatures(TypedDict):
+ payment_method_allow_redisplay_filters: NotRequired[
+ List[Literal["always", "limited", "unspecified"]]
+ ]
+ """
+ A list of [`allow_redisplay`](https://docs.stripe.com/api/payment_methods/object#payment_method_object-allow_redisplay) values that controls which saved payment methods the Payment Element displays by filtering to only show payment methods with an `allow_redisplay` value that is present in this list.
+
+ If not specified, defaults to ["always"]. In order to display all saved payment methods, specify ["always", "limited", "unspecified"].
+ """
+ payment_method_redisplay: NotRequired[Literal["disabled", "enabled"]]
+ """
+ Controls whether or not the Payment Element shows saved payment methods. This parameter defaults to `disabled`.
+ """
+ payment_method_redisplay_limit: NotRequired[int]
+ """
+ Determines the max number of saved payment methods for the Payment Element to display. This parameter defaults to `3`. The maximum redisplay limit is `10`.
+ """
+ payment_method_remove: NotRequired[Literal["disabled", "enabled"]]
+ """
+ Controls whether the Payment Element displays the option to remove a saved payment method. This parameter defaults to `disabled`.
+
+ Allowing buyers to remove their saved payment methods impacts subscriptions that depend on that payment method. Removing the payment method detaches the [`customer` object](https://docs.stripe.com/api/payment_methods/object#payment_method_object-customer) from that [PaymentMethod](https://docs.stripe.com/api/payment_methods).
+ """
+ payment_method_save: NotRequired[Literal["disabled", "enabled"]]
+ """
+ Controls whether the Payment Element displays a checkbox offering to save a new payment method. This parameter defaults to `disabled`.
+
+ If a customer checks the box, the [`allow_redisplay`](https://docs.stripe.com/api/payment_methods/object#payment_method_object-allow_redisplay) value on the PaymentMethod is set to `'always'` at confirmation time. For PaymentIntents, the [`setup_future_usage`](https://docs.stripe.com/api/payment_intents/object#payment_intent_object-setup_future_usage) value is also set to the value defined in `payment_method_save_usage`.
+ """
+ payment_method_save_usage: NotRequired[
+ Literal["off_session", "on_session"]
+ ]
+ """
+ When using PaymentIntents and the customer checks the save checkbox, this field determines the [`setup_future_usage`](https://docs.stripe.com/api/payment_intents/object#payment_intent_object-setup_future_usage) value used to confirm the PaymentIntent.
+
+ When using SetupIntents, directly configure the [`usage`](https://docs.stripe.com/api/setup_intents/object#setup_intent_object-usage) value on SetupIntent creation.
+ """
+
+
+class CustomerSessionCreateParamsComponentsPricingTable(TypedDict):
+ enabled: bool
+ """
+ Whether the pricing table is enabled.
+ """
diff --git a/stripe/params/_customer_tax_id_create_params.py b/stripe/params/_customer_tax_id_create_params.py
new file mode 100644
index 000000000..f30e900c9
--- /dev/null
+++ b/stripe/params/_customer_tax_id_create_params.py
@@ -0,0 +1,130 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CustomerTaxIdCreateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ type: Literal[
+ "ad_nrt",
+ "ae_trn",
+ "al_tin",
+ "am_tin",
+ "ao_tin",
+ "ar_cuit",
+ "au_abn",
+ "au_arn",
+ "aw_tin",
+ "az_tin",
+ "ba_tin",
+ "bb_tin",
+ "bd_bin",
+ "bf_ifu",
+ "bg_uic",
+ "bh_vat",
+ "bj_ifu",
+ "bo_tin",
+ "br_cnpj",
+ "br_cpf",
+ "bs_tin",
+ "by_tin",
+ "ca_bn",
+ "ca_gst_hst",
+ "ca_pst_bc",
+ "ca_pst_mb",
+ "ca_pst_sk",
+ "ca_qst",
+ "cd_nif",
+ "ch_uid",
+ "ch_vat",
+ "cl_tin",
+ "cm_niu",
+ "cn_tin",
+ "co_nit",
+ "cr_tin",
+ "cv_nif",
+ "de_stn",
+ "do_rcn",
+ "ec_ruc",
+ "eg_tin",
+ "es_cif",
+ "et_tin",
+ "eu_oss_vat",
+ "eu_vat",
+ "gb_vat",
+ "ge_vat",
+ "gn_nif",
+ "hk_br",
+ "hr_oib",
+ "hu_tin",
+ "id_npwp",
+ "il_vat",
+ "in_gst",
+ "is_vat",
+ "jp_cn",
+ "jp_rn",
+ "jp_trn",
+ "ke_pin",
+ "kg_tin",
+ "kh_tin",
+ "kr_brn",
+ "kz_bin",
+ "la_tin",
+ "li_uid",
+ "li_vat",
+ "ma_vat",
+ "md_vat",
+ "me_pib",
+ "mk_vat",
+ "mr_nif",
+ "mx_rfc",
+ "my_frp",
+ "my_itn",
+ "my_sst",
+ "ng_tin",
+ "no_vat",
+ "no_voec",
+ "np_pan",
+ "nz_gst",
+ "om_vat",
+ "pe_ruc",
+ "ph_tin",
+ "ro_tin",
+ "rs_pib",
+ "ru_inn",
+ "ru_kpp",
+ "sa_vat",
+ "sg_gst",
+ "sg_uen",
+ "si_tin",
+ "sn_ninea",
+ "sr_fin",
+ "sv_nit",
+ "th_vat",
+ "tj_tin",
+ "tr_tin",
+ "tw_vat",
+ "tz_vat",
+ "ua_vat",
+ "ug_tin",
+ "us_ein",
+ "uy_ruc",
+ "uz_tin",
+ "uz_vat",
+ "ve_rif",
+ "vn_tin",
+ "za_vat",
+ "zm_tin",
+ "zw_tin",
+ ]
+ """
+ Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
+ """
+ value: str
+ """
+ Value of the tax ID.
+ """
diff --git a/stripe/params/_customer_tax_id_delete_params.py b/stripe/params/_customer_tax_id_delete_params.py
new file mode 100644
index 000000000..e301b4e49
--- /dev/null
+++ b/stripe/params/_customer_tax_id_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing_extensions import TypedDict
+
+
+class CustomerTaxIdDeleteParams(TypedDict):
+ pass
diff --git a/stripe/params/_customer_tax_id_list_params.py b/stripe/params/_customer_tax_id_list_params.py
new file mode 100644
index 000000000..cf87ac1c0
--- /dev/null
+++ b/stripe/params/_customer_tax_id_list_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CustomerTaxIdListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_customer_tax_id_retrieve_params.py b/stripe/params/_customer_tax_id_retrieve_params.py
new file mode 100644
index 000000000..8f5adeff6
--- /dev/null
+++ b/stripe/params/_customer_tax_id_retrieve_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CustomerTaxIdRetrieveParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_customer_update_params.py b/stripe/params/_customer_update_params.py
new file mode 100644
index 000000000..b325846dc
--- /dev/null
+++ b/stripe/params/_customer_update_params.py
@@ -0,0 +1,233 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CustomerUpdateParams(TypedDict):
+ address: NotRequired["Literal['']|CustomerUpdateParamsAddress"]
+ """
+ The customer's address.
+ """
+ balance: NotRequired[int]
+ """
+ An integer amount in cents (or local equivalent) that represents the customer's current balance, which affect the customer's future invoices. A negative amount represents a credit that decreases the amount due on an invoice; a positive amount increases the amount due on an invoice.
+ """
+ business_name: NotRequired["Literal['']|str"]
+ """
+ The customer's business name. This may be up to *150 characters*.
+ """
+ cash_balance: NotRequired["CustomerUpdateParamsCashBalance"]
+ """
+ Balance information and default balance settings for this customer.
+ """
+ default_source: NotRequired[str]
+ """
+ If you are using payment methods created via the PaymentMethods API, see the [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method) parameter.
+
+ Provide the ID of a payment source already attached to this customer to make it this customer's default payment source.
+
+ If you want to add a new payment source and make it the default, see the [source](https://stripe.com/docs/api/customers/update#update_customer-source) property.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string that you can attach to a customer object. It is displayed alongside the customer in the dashboard.
+ """
+ email: NotRequired[str]
+ """
+ Customer's email address. It's displayed alongside the customer in your dashboard and can be useful for searching and tracking. This may be up to *512 characters*.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ individual_name: NotRequired["Literal['']|str"]
+ """
+ The customer's full name. This may be up to *150 characters*.
+ """
+ invoice_prefix: NotRequired[str]
+ """
+ The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.
+ """
+ invoice_settings: NotRequired["CustomerUpdateParamsInvoiceSettings"]
+ """
+ Default invoice settings for this customer.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired[str]
+ """
+ The customer's full name or business name.
+ """
+ next_invoice_sequence: NotRequired[int]
+ """
+ The sequence to be used on the customer's next invoice. Defaults to 1.
+ """
+ phone: NotRequired[str]
+ """
+ The customer's phone number.
+ """
+ preferred_locales: NotRequired[List[str]]
+ """
+ Customer's preferred languages, ordered by preference.
+ """
+ shipping: NotRequired["Literal['']|CustomerUpdateParamsShipping"]
+ """
+ The customer's shipping information. Appears on invoices emailed to this customer.
+ """
+ source: NotRequired[str]
+ tax: NotRequired["CustomerUpdateParamsTax"]
+ """
+ Tax details about the customer.
+ """
+ tax_exempt: NotRequired["Literal['']|Literal['exempt', 'none', 'reverse']"]
+ """
+ The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
+ """
+ validate: NotRequired[bool]
+
+
+class CustomerUpdateParamsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class CustomerUpdateParamsCashBalance(TypedDict):
+ settings: NotRequired["CustomerUpdateParamsCashBalanceSettings"]
+ """
+ Settings controlling the behavior of the customer's cash balance,
+ such as reconciliation of funds received.
+ """
+
+
+class CustomerUpdateParamsCashBalanceSettings(TypedDict):
+ reconciliation_mode: NotRequired[
+ Literal["automatic", "manual", "merchant_default"]
+ ]
+ """
+ Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
+ """
+
+
+class CustomerUpdateParamsInvoiceSettings(TypedDict):
+ custom_fields: NotRequired[
+ "Literal['']|List[CustomerUpdateParamsInvoiceSettingsCustomField]"
+ ]
+ """
+ The list of up to 4 default custom fields to be displayed on invoices for this customer. When updating, pass an empty string to remove previously-defined fields.
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of a payment method that's attached to the customer, to be used as the customer's default payment method for subscriptions and invoices.
+ """
+ footer: NotRequired[str]
+ """
+ Default footer to be displayed on invoices for this customer.
+ """
+ rendering_options: NotRequired[
+ "Literal['']|CustomerUpdateParamsInvoiceSettingsRenderingOptions"
+ ]
+ """
+ Default options for invoice PDF rendering for this customer.
+ """
+
+
+class CustomerUpdateParamsInvoiceSettingsCustomField(TypedDict):
+ name: str
+ """
+ The name of the custom field. This may be up to 40 characters.
+ """
+ value: str
+ """
+ The value of the custom field. This may be up to 140 characters.
+ """
+
+
+class CustomerUpdateParamsInvoiceSettingsRenderingOptions(TypedDict):
+ amount_tax_display: NotRequired[
+ "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
+ ]
+ """
+ How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
+ """
+ template: NotRequired[str]
+ """
+ ID of the invoice rendering template to use for future invoices.
+ """
+
+
+class CustomerUpdateParamsShipping(TypedDict):
+ address: "CustomerUpdateParamsShippingAddress"
+ """
+ Customer shipping address.
+ """
+ name: str
+ """
+ Customer name.
+ """
+ phone: NotRequired[str]
+ """
+ Customer phone (including extension).
+ """
+
+
+class CustomerUpdateParamsShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class CustomerUpdateParamsTax(TypedDict):
+ ip_address: NotRequired["Literal['']|str"]
+ """
+ A recent IP address of the customer used for tax reporting and tax location inference. Stripe recommends updating the IP address when a new PaymentMethod is attached or the address field on the customer is updated. We recommend against updating this field more frequently since it could result in unexpected tax location/reporting outcomes.
+ """
+ validate_location: NotRequired[Literal["auto", "deferred", "immediately"]]
+ """
+ A flag that indicates when Stripe should validate the customer tax location. Defaults to `auto`.
+ """
diff --git a/stripe/params/_dispute_close_params.py b/stripe/params/_dispute_close_params.py
new file mode 100644
index 000000000..41118c009
--- /dev/null
+++ b/stripe/params/_dispute_close_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class DisputeCloseParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_dispute_list_params.py b/stripe/params/_dispute_list_params.py
new file mode 100644
index 000000000..e70d16e7f
--- /dev/null
+++ b/stripe/params/_dispute_list_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class DisputeListParams(RequestOptions):
+ charge: NotRequired[str]
+ """
+ Only return disputes associated to the charge specified by this charge ID.
+ """
+ created: NotRequired["DisputeListParamsCreated|int"]
+ """
+ Only return disputes that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ payment_intent: NotRequired[str]
+ """
+ Only return disputes associated to the PaymentIntent specified by this PaymentIntent ID.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class DisputeListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_dispute_modify_params.py b/stripe/params/_dispute_modify_params.py
new file mode 100644
index 000000000..5f8f30a57
--- /dev/null
+++ b/stripe/params/_dispute_modify_params.py
@@ -0,0 +1,318 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class DisputeModifyParams(RequestOptions):
+ evidence: NotRequired["DisputeModifyParamsEvidence"]
+ """
+ Evidence to upload, to respond to a dispute. Updating any field in the hash will submit all fields in the hash for review. The combined character count of all fields is limited to 150,000.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ submit: NotRequired[bool]
+ """
+ Whether to immediately submit evidence to the bank. If `false`, evidence is staged on the dispute. Staged evidence is visible in the API and Dashboard, and can be submitted to the bank by making another request with this attribute set to `true` (the default).
+ """
+
+
+class DisputeModifyParamsEvidence(TypedDict):
+ access_activity_log: NotRequired[str]
+ """
+ Any server or activity logs showing proof that the customer accessed or downloaded the purchased digital product. This information should include IP addresses, corresponding timestamps, and any detailed recorded activity. Has a maximum character count of 20,000.
+ """
+ billing_address: NotRequired[str]
+ """
+ The billing address provided by the customer.
+ """
+ cancellation_policy: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your subscription cancellation policy, as shown to the customer.
+ """
+ cancellation_policy_disclosure: NotRequired[str]
+ """
+ An explanation of how and when the customer was shown your refund policy prior to purchase. Has a maximum character count of 20,000.
+ """
+ cancellation_rebuttal: NotRequired[str]
+ """
+ A justification for why the customer's subscription was not canceled. Has a maximum character count of 20,000.
+ """
+ customer_communication: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any communication with the customer that you feel is relevant to your case. Examples include emails proving that the customer received the product or service, or demonstrating their use of or satisfaction with the product or service.
+ """
+ customer_email_address: NotRequired[str]
+ """
+ The email address of the customer.
+ """
+ customer_name: NotRequired[str]
+ """
+ The name of the customer.
+ """
+ customer_purchase_ip: NotRequired[str]
+ """
+ The IP address that the customer used when making the purchase.
+ """
+ customer_signature: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A relevant document or contract showing the customer's signature.
+ """
+ duplicate_charge_documentation: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation for the prior charge that can uniquely identify the charge, such as a receipt, shipping label, work order, etc. This document should be paired with a similar document from the disputed payment that proves the two payments are separate.
+ """
+ duplicate_charge_explanation: NotRequired[str]
+ """
+ An explanation of the difference between the disputed charge versus the prior charge that appears to be a duplicate. Has a maximum character count of 20,000.
+ """
+ duplicate_charge_id: NotRequired[str]
+ """
+ The Stripe ID for the prior charge which appears to be a duplicate of the disputed charge.
+ """
+ enhanced_evidence: NotRequired[
+ "Literal['']|DisputeModifyParamsEvidenceEnhancedEvidence"
+ ]
+ """
+ Additional evidence for qualifying evidence programs.
+ """
+ product_description: NotRequired[str]
+ """
+ A description of the product or service that was sold. Has a maximum character count of 20,000.
+ """
+ receipt: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any receipt or message sent to the customer notifying them of the charge.
+ """
+ refund_policy: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your refund policy, as shown to the customer.
+ """
+ refund_policy_disclosure: NotRequired[str]
+ """
+ Documentation demonstrating that the customer was shown your refund policy prior to purchase. Has a maximum character count of 20,000.
+ """
+ refund_refusal_explanation: NotRequired[str]
+ """
+ A justification for why the customer is not entitled to a refund. Has a maximum character count of 20,000.
+ """
+ service_date: NotRequired[str]
+ """
+ The date on which the customer received or began receiving the purchased service, in a clear human-readable format.
+ """
+ service_documentation: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a service was provided to the customer. This could include a copy of a signed contract, work order, or other form of written agreement.
+ """
+ shipping_address: NotRequired[str]
+ """
+ The address to which a physical product was shipped. You should try to include as complete address information as possible.
+ """
+ shipping_carrier: NotRequired[str]
+ """
+ The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc. If multiple carriers were used for this purchase, please separate them with commas.
+ """
+ shipping_date: NotRequired[str]
+ """
+ The date on which a physical product began its route to the shipping address, in a clear human-readable format.
+ """
+ shipping_documentation: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a product was shipped to the customer at the same address the customer provided to you. This could include a copy of the shipment receipt, shipping label, etc. It should show the customer's full shipping address, if possible.
+ """
+ shipping_tracking_number: NotRequired[str]
+ """
+ The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
+ """
+ uncategorized_file: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any additional evidence or statements.
+ """
+ uncategorized_text: NotRequired[str]
+ """
+ Any additional evidence or statements. Has a maximum character count of 20,000.
+ """
+
+
+class DisputeModifyParamsEvidenceEnhancedEvidence(TypedDict):
+ visa_compelling_evidence_3: NotRequired[
+ "DisputeModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3"
+ ]
+ """
+ Evidence provided for Visa Compelling Evidence 3.0 evidence submission.
+ """
+ visa_compliance: NotRequired[
+ "DisputeModifyParamsEvidenceEnhancedEvidenceVisaCompliance"
+ ]
+ """
+ Evidence provided for Visa compliance evidence submission.
+ """
+
+
+class DisputeModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3(
+ TypedDict,
+):
+ disputed_transaction: NotRequired[
+ "DisputeModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransaction"
+ ]
+ """
+ Disputed transaction details for Visa Compelling Evidence 3.0 evidence submission.
+ """
+ prior_undisputed_transactions: NotRequired[
+ List[
+ "DisputeModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransaction"
+ ]
+ ]
+ """
+ List of exactly two prior undisputed transaction objects for Visa Compelling Evidence 3.0 evidence submission.
+ """
+
+
+class DisputeModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransaction(
+ TypedDict,
+):
+ customer_account_id: NotRequired["Literal['']|str"]
+ """
+ User Account ID used to log into business platform. Must be recognizable by the user.
+ """
+ customer_device_fingerprint: NotRequired["Literal['']|str"]
+ """
+ Unique identifier of the cardholder's device derived from a combination of at least two hardware and software attributes. Must be at least 20 characters.
+ """
+ customer_device_id: NotRequired["Literal['']|str"]
+ """
+ Unique identifier of the cardholder's device such as a device serial number (e.g., International Mobile Equipment Identity [IMEI]). Must be at least 15 characters.
+ """
+ customer_email_address: NotRequired["Literal['']|str"]
+ """
+ The email address of the customer.
+ """
+ customer_purchase_ip: NotRequired["Literal['']|str"]
+ """
+ The IP address that the customer used when making the purchase.
+ """
+ merchandise_or_services: NotRequired[Literal["merchandise", "services"]]
+ """
+ Categorization of disputed payment.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ A description of the product or service that was sold.
+ """
+ shipping_address: NotRequired[
+ "DisputeModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransactionShippingAddress"
+ ]
+ """
+ The address to which a physical product was shipped. All fields are required for Visa Compelling Evidence 3.0 evidence submission.
+ """
+
+
+class DisputeModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransactionShippingAddress(
+ TypedDict,
+):
+ city: NotRequired["Literal['']|str"]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired["Literal['']|str"]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired["Literal['']|str"]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired["Literal['']|str"]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired["Literal['']|str"]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired["Literal['']|str"]
+ """
+ State, county, province, or region.
+ """
+
+
+class DisputeModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransaction(
+ TypedDict,
+):
+ charge: str
+ """
+ Stripe charge ID for the Visa Compelling Evidence 3.0 eligible prior charge.
+ """
+ customer_account_id: NotRequired["Literal['']|str"]
+ """
+ User Account ID used to log into business platform. Must be recognizable by the user.
+ """
+ customer_device_fingerprint: NotRequired["Literal['']|str"]
+ """
+ Unique identifier of the cardholder's device derived from a combination of at least two hardware and software attributes. Must be at least 20 characters.
+ """
+ customer_device_id: NotRequired["Literal['']|str"]
+ """
+ Unique identifier of the cardholder's device such as a device serial number (e.g., International Mobile Equipment Identity [IMEI]). Must be at least 15 characters.
+ """
+ customer_email_address: NotRequired["Literal['']|str"]
+ """
+ The email address of the customer.
+ """
+ customer_purchase_ip: NotRequired["Literal['']|str"]
+ """
+ The IP address that the customer used when making the purchase.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ A description of the product or service that was sold.
+ """
+ shipping_address: NotRequired[
+ "DisputeModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransactionShippingAddress"
+ ]
+ """
+ The address to which a physical product was shipped. All fields are required for Visa Compelling Evidence 3.0 evidence submission.
+ """
+
+
+class DisputeModifyParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransactionShippingAddress(
+ TypedDict,
+):
+ city: NotRequired["Literal['']|str"]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired["Literal['']|str"]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired["Literal['']|str"]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired["Literal['']|str"]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired["Literal['']|str"]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired["Literal['']|str"]
+ """
+ State, county, province, or region.
+ """
+
+
+class DisputeModifyParamsEvidenceEnhancedEvidenceVisaCompliance(TypedDict):
+ fee_acknowledged: NotRequired[bool]
+ """
+ A field acknowledging the fee incurred when countering a Visa compliance dispute. If this field is set to true, evidence can be submitted for the compliance dispute. Stripe collects a 500 USD (or local equivalent) amount to cover the network costs associated with resolving compliance disputes. Stripe refunds the 500 USD network fee if you win the dispute.
+ """
diff --git a/stripe/params/_dispute_retrieve_params.py b/stripe/params/_dispute_retrieve_params.py
new file mode 100644
index 000000000..5d350dc83
--- /dev/null
+++ b/stripe/params/_dispute_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class DisputeRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_dispute_update_params.py b/stripe/params/_dispute_update_params.py
new file mode 100644
index 000000000..b09f6f5f3
--- /dev/null
+++ b/stripe/params/_dispute_update_params.py
@@ -0,0 +1,317 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class DisputeUpdateParams(TypedDict):
+ evidence: NotRequired["DisputeUpdateParamsEvidence"]
+ """
+ Evidence to upload, to respond to a dispute. Updating any field in the hash will submit all fields in the hash for review. The combined character count of all fields is limited to 150,000.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ submit: NotRequired[bool]
+ """
+ Whether to immediately submit evidence to the bank. If `false`, evidence is staged on the dispute. Staged evidence is visible in the API and Dashboard, and can be submitted to the bank by making another request with this attribute set to `true` (the default).
+ """
+
+
+class DisputeUpdateParamsEvidence(TypedDict):
+ access_activity_log: NotRequired[str]
+ """
+ Any server or activity logs showing proof that the customer accessed or downloaded the purchased digital product. This information should include IP addresses, corresponding timestamps, and any detailed recorded activity. Has a maximum character count of 20,000.
+ """
+ billing_address: NotRequired[str]
+ """
+ The billing address provided by the customer.
+ """
+ cancellation_policy: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your subscription cancellation policy, as shown to the customer.
+ """
+ cancellation_policy_disclosure: NotRequired[str]
+ """
+ An explanation of how and when the customer was shown your refund policy prior to purchase. Has a maximum character count of 20,000.
+ """
+ cancellation_rebuttal: NotRequired[str]
+ """
+ A justification for why the customer's subscription was not canceled. Has a maximum character count of 20,000.
+ """
+ customer_communication: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any communication with the customer that you feel is relevant to your case. Examples include emails proving that the customer received the product or service, or demonstrating their use of or satisfaction with the product or service.
+ """
+ customer_email_address: NotRequired[str]
+ """
+ The email address of the customer.
+ """
+ customer_name: NotRequired[str]
+ """
+ The name of the customer.
+ """
+ customer_purchase_ip: NotRequired[str]
+ """
+ The IP address that the customer used when making the purchase.
+ """
+ customer_signature: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A relevant document or contract showing the customer's signature.
+ """
+ duplicate_charge_documentation: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation for the prior charge that can uniquely identify the charge, such as a receipt, shipping label, work order, etc. This document should be paired with a similar document from the disputed payment that proves the two payments are separate.
+ """
+ duplicate_charge_explanation: NotRequired[str]
+ """
+ An explanation of the difference between the disputed charge versus the prior charge that appears to be a duplicate. Has a maximum character count of 20,000.
+ """
+ duplicate_charge_id: NotRequired[str]
+ """
+ The Stripe ID for the prior charge which appears to be a duplicate of the disputed charge.
+ """
+ enhanced_evidence: NotRequired[
+ "Literal['']|DisputeUpdateParamsEvidenceEnhancedEvidence"
+ ]
+ """
+ Additional evidence for qualifying evidence programs.
+ """
+ product_description: NotRequired[str]
+ """
+ A description of the product or service that was sold. Has a maximum character count of 20,000.
+ """
+ receipt: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any receipt or message sent to the customer notifying them of the charge.
+ """
+ refund_policy: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your refund policy, as shown to the customer.
+ """
+ refund_policy_disclosure: NotRequired[str]
+ """
+ Documentation demonstrating that the customer was shown your refund policy prior to purchase. Has a maximum character count of 20,000.
+ """
+ refund_refusal_explanation: NotRequired[str]
+ """
+ A justification for why the customer is not entitled to a refund. Has a maximum character count of 20,000.
+ """
+ service_date: NotRequired[str]
+ """
+ The date on which the customer received or began receiving the purchased service, in a clear human-readable format.
+ """
+ service_documentation: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a service was provided to the customer. This could include a copy of a signed contract, work order, or other form of written agreement.
+ """
+ shipping_address: NotRequired[str]
+ """
+ The address to which a physical product was shipped. You should try to include as complete address information as possible.
+ """
+ shipping_carrier: NotRequired[str]
+ """
+ The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc. If multiple carriers were used for this purchase, please separate them with commas.
+ """
+ shipping_date: NotRequired[str]
+ """
+ The date on which a physical product began its route to the shipping address, in a clear human-readable format.
+ """
+ shipping_documentation: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a product was shipped to the customer at the same address the customer provided to you. This could include a copy of the shipment receipt, shipping label, etc. It should show the customer's full shipping address, if possible.
+ """
+ shipping_tracking_number: NotRequired[str]
+ """
+ The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
+ """
+ uncategorized_file: NotRequired[str]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any additional evidence or statements.
+ """
+ uncategorized_text: NotRequired[str]
+ """
+ Any additional evidence or statements. Has a maximum character count of 20,000.
+ """
+
+
+class DisputeUpdateParamsEvidenceEnhancedEvidence(TypedDict):
+ visa_compelling_evidence_3: NotRequired[
+ "DisputeUpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3"
+ ]
+ """
+ Evidence provided for Visa Compelling Evidence 3.0 evidence submission.
+ """
+ visa_compliance: NotRequired[
+ "DisputeUpdateParamsEvidenceEnhancedEvidenceVisaCompliance"
+ ]
+ """
+ Evidence provided for Visa compliance evidence submission.
+ """
+
+
+class DisputeUpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3(
+ TypedDict,
+):
+ disputed_transaction: NotRequired[
+ "DisputeUpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransaction"
+ ]
+ """
+ Disputed transaction details for Visa Compelling Evidence 3.0 evidence submission.
+ """
+ prior_undisputed_transactions: NotRequired[
+ List[
+ "DisputeUpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransaction"
+ ]
+ ]
+ """
+ List of exactly two prior undisputed transaction objects for Visa Compelling Evidence 3.0 evidence submission.
+ """
+
+
+class DisputeUpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransaction(
+ TypedDict,
+):
+ customer_account_id: NotRequired["Literal['']|str"]
+ """
+ User Account ID used to log into business platform. Must be recognizable by the user.
+ """
+ customer_device_fingerprint: NotRequired["Literal['']|str"]
+ """
+ Unique identifier of the cardholder's device derived from a combination of at least two hardware and software attributes. Must be at least 20 characters.
+ """
+ customer_device_id: NotRequired["Literal['']|str"]
+ """
+ Unique identifier of the cardholder's device such as a device serial number (e.g., International Mobile Equipment Identity [IMEI]). Must be at least 15 characters.
+ """
+ customer_email_address: NotRequired["Literal['']|str"]
+ """
+ The email address of the customer.
+ """
+ customer_purchase_ip: NotRequired["Literal['']|str"]
+ """
+ The IP address that the customer used when making the purchase.
+ """
+ merchandise_or_services: NotRequired[Literal["merchandise", "services"]]
+ """
+ Categorization of disputed payment.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ A description of the product or service that was sold.
+ """
+ shipping_address: NotRequired[
+ "DisputeUpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransactionShippingAddress"
+ ]
+ """
+ The address to which a physical product was shipped. All fields are required for Visa Compelling Evidence 3.0 evidence submission.
+ """
+
+
+class DisputeUpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3DisputedTransactionShippingAddress(
+ TypedDict,
+):
+ city: NotRequired["Literal['']|str"]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired["Literal['']|str"]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired["Literal['']|str"]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired["Literal['']|str"]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired["Literal['']|str"]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired["Literal['']|str"]
+ """
+ State, county, province, or region.
+ """
+
+
+class DisputeUpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransaction(
+ TypedDict,
+):
+ charge: str
+ """
+ Stripe charge ID for the Visa Compelling Evidence 3.0 eligible prior charge.
+ """
+ customer_account_id: NotRequired["Literal['']|str"]
+ """
+ User Account ID used to log into business platform. Must be recognizable by the user.
+ """
+ customer_device_fingerprint: NotRequired["Literal['']|str"]
+ """
+ Unique identifier of the cardholder's device derived from a combination of at least two hardware and software attributes. Must be at least 20 characters.
+ """
+ customer_device_id: NotRequired["Literal['']|str"]
+ """
+ Unique identifier of the cardholder's device such as a device serial number (e.g., International Mobile Equipment Identity [IMEI]). Must be at least 15 characters.
+ """
+ customer_email_address: NotRequired["Literal['']|str"]
+ """
+ The email address of the customer.
+ """
+ customer_purchase_ip: NotRequired["Literal['']|str"]
+ """
+ The IP address that the customer used when making the purchase.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ A description of the product or service that was sold.
+ """
+ shipping_address: NotRequired[
+ "DisputeUpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransactionShippingAddress"
+ ]
+ """
+ The address to which a physical product was shipped. All fields are required for Visa Compelling Evidence 3.0 evidence submission.
+ """
+
+
+class DisputeUpdateParamsEvidenceEnhancedEvidenceVisaCompellingEvidence3PriorUndisputedTransactionShippingAddress(
+ TypedDict,
+):
+ city: NotRequired["Literal['']|str"]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired["Literal['']|str"]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired["Literal['']|str"]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired["Literal['']|str"]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired["Literal['']|str"]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired["Literal['']|str"]
+ """
+ State, county, province, or region.
+ """
+
+
+class DisputeUpdateParamsEvidenceEnhancedEvidenceVisaCompliance(TypedDict):
+ fee_acknowledged: NotRequired[bool]
+ """
+ A field acknowledging the fee incurred when countering a Visa compliance dispute. If this field is set to true, evidence can be submitted for the compliance dispute. Stripe collects a 500 USD (or local equivalent) amount to cover the network costs associated with resolving compliance disputes. Stripe refunds the 500 USD network fee if you win the dispute.
+ """
diff --git a/stripe/params/_ephemeral_key_create_params.py b/stripe/params/_ephemeral_key_create_params.py
new file mode 100644
index 000000000..6272d6182
--- /dev/null
+++ b/stripe/params/_ephemeral_key_create_params.py
@@ -0,0 +1,27 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class EphemeralKeyCreateParams(TypedDict):
+ customer: NotRequired[str]
+ """
+ The ID of the Customer you'd like to modify using the resulting ephemeral key.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ issuing_card: NotRequired[str]
+ """
+ The ID of the Issuing Card you'd like to access using the resulting ephemeral key.
+ """
+ nonce: NotRequired[str]
+ """
+ A single-use token, created by Stripe.js, used for creating ephemeral keys for Issuing Cards without exchanging sensitive information.
+ """
+ verification_session: NotRequired[str]
+ """
+ The ID of the Identity VerificationSession you'd like to access using the resulting ephemeral key
+ """
diff --git a/stripe/params/_ephemeral_key_delete_params.py b/stripe/params/_ephemeral_key_delete_params.py
new file mode 100644
index 000000000..d2381956f
--- /dev/null
+++ b/stripe/params/_ephemeral_key_delete_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class EphemeralKeyDeleteParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_event_list_params.py b/stripe/params/_event_list_params.py
new file mode 100644
index 000000000..5d77d5dee
--- /dev/null
+++ b/stripe/params/_event_list_params.py
@@ -0,0 +1,59 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class EventListParams(RequestOptions):
+ created: NotRequired["EventListParamsCreated|int"]
+ """
+ Only return events that were created during the given date interval.
+ """
+ delivery_success: NotRequired[bool]
+ """
+ Filter events by whether all webhooks were successfully delivered. If false, events which are still pending or have failed all delivery attempts to a webhook endpoint will be returned.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ type: NotRequired[str]
+ """
+ A string containing a specific event name, or group of events using * as a wildcard. The list will be filtered to include only events with a matching event property.
+ """
+ types: NotRequired[List[str]]
+ """
+ An array of up to 20 strings containing specific event names. The list will be filtered to include only events with a matching event property. You may pass either `type` or `types`, but not both.
+ """
+
+
+class EventListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_event_retrieve_params.py b/stripe/params/_event_retrieve_params.py
new file mode 100644
index 000000000..230d7aaa5
--- /dev/null
+++ b/stripe/params/_event_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class EventRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_exchange_rate_list_params.py b/stripe/params/_exchange_rate_list_params.py
new file mode 100644
index 000000000..831dc8da5
--- /dev/null
+++ b/stripe/params/_exchange_rate_list_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ExchangeRateListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is the currency that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with the exchange rate for currency X your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and total number of supported payout currencies, and the default is the max.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is the currency that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with the exchange rate for currency X, your subsequent call can include `starting_after=X` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_exchange_rate_retrieve_params.py b/stripe/params/_exchange_rate_retrieve_params.py
new file mode 100644
index 000000000..01b55a219
--- /dev/null
+++ b/stripe/params/_exchange_rate_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ExchangeRateRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_file_create_params.py b/stripe/params/_file_create_params.py
new file mode 100644
index 000000000..3309e4b51
--- /dev/null
+++ b/stripe/params/_file_create_params.py
@@ -0,0 +1,52 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Any, Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class FileCreateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ file: Any
+ """
+ A file to upload. Make sure that the specifications follow RFC 2388, which defines file transfers for the `multipart/form-data` protocol.
+ """
+ file_link_data: NotRequired["FileCreateParamsFileLinkData"]
+ """
+ Optional parameters that automatically create a [file link](https://stripe.com/docs/api#file_links) for the newly created file.
+ """
+ purpose: Literal[
+ "account_requirement",
+ "additional_verification",
+ "business_icon",
+ "business_logo",
+ "customer_signature",
+ "dispute_evidence",
+ "identity_document",
+ "issuing_regulatory_reporting",
+ "pci_document",
+ "tax_document_user_upload",
+ "terminal_android_apk",
+ "terminal_reader_splashscreen",
+ ]
+ """
+ The [purpose](https://stripe.com/docs/file-upload#uploading-a-file) of the uploaded file.
+ """
+
+
+class FileCreateParamsFileLinkData(TypedDict):
+ create: bool
+ """
+ Set this to `true` to create a file link for the newly created file. Creating a link is only possible when the file's `purpose` is one of the following: `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `issuing_regulatory_reporting`, `pci_document`, `tax_document_user_upload`, `terminal_android_apk`, or `terminal_reader_splashscreen`.
+ """
+ expires_at: NotRequired[int]
+ """
+ The link isn't available after this future timestamp.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_file_link_create_params.py b/stripe/params/_file_link_create_params.py
new file mode 100644
index 000000000..08c6e4489
--- /dev/null
+++ b/stripe/params/_file_link_create_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class FileLinkCreateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired[int]
+ """
+ The link isn't usable after this future timestamp.
+ """
+ file: str
+ """
+ The ID of the file. The file's `purpose` must be one of the following: `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `finance_report_run`, `financial_account_statement`, `identity_document_downloadable`, `issuing_regulatory_reporting`, `pci_document`, `selfie`, `sigma_scheduled_query`, `tax_document_user_upload`, `terminal_android_apk`, or `terminal_reader_splashscreen`.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_file_link_list_params.py b/stripe/params/_file_link_list_params.py
new file mode 100644
index 000000000..4f1e83545
--- /dev/null
+++ b/stripe/params/_file_link_list_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class FileLinkListParams(RequestOptions):
+ created: NotRequired["FileLinkListParamsCreated|int"]
+ """
+ Only return links that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expired: NotRequired[bool]
+ """
+ Filter links by their expiration status. By default, Stripe returns all links.
+ """
+ file: NotRequired[str]
+ """
+ Only return links for the given file.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class FileLinkListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_file_link_modify_params.py b/stripe/params/_file_link_modify_params.py
new file mode 100644
index 000000000..2dda56a17
--- /dev/null
+++ b/stripe/params/_file_link_modify_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class FileLinkModifyParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired["Literal['']|Literal['now']|int"]
+ """
+ A future timestamp after which the link will no longer be usable, or `now` to expire the link immediately.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_file_link_retrieve_params.py b/stripe/params/_file_link_retrieve_params.py
new file mode 100644
index 000000000..5dc4880e4
--- /dev/null
+++ b/stripe/params/_file_link_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class FileLinkRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_file_link_update_params.py b/stripe/params/_file_link_update_params.py
new file mode 100644
index 000000000..0c5ee8a36
--- /dev/null
+++ b/stripe/params/_file_link_update_params.py
@@ -0,0 +1,19 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class FileLinkUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired["Literal['']|Literal['now']|int"]
+ """
+ A future timestamp after which the link will no longer be usable, or `now` to expire the link immediately.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_file_list_params.py b/stripe/params/_file_list_params.py
new file mode 100644
index 000000000..527f12cbe
--- /dev/null
+++ b/stripe/params/_file_list_params.py
@@ -0,0 +1,72 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class FileListParams(RequestOptions):
+ created: NotRequired["FileListParamsCreated|int"]
+ """
+ Only return files that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ purpose: NotRequired[
+ Literal[
+ "account_requirement",
+ "additional_verification",
+ "business_icon",
+ "business_logo",
+ "customer_signature",
+ "dispute_evidence",
+ "document_provider_identity_document",
+ "finance_report_run",
+ "financial_account_statement",
+ "identity_document",
+ "identity_document_downloadable",
+ "issuing_regulatory_reporting",
+ "pci_document",
+ "selfie",
+ "sigma_scheduled_query",
+ "tax_document_user_upload",
+ "terminal_android_apk",
+ "terminal_reader_splashscreen",
+ ]
+ ]
+ """
+ Filter queries by the file purpose. If you don't provide a purpose, the queries return unfiltered files.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class FileListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_file_retrieve_params.py b/stripe/params/_file_retrieve_params.py
new file mode 100644
index 000000000..a973a3521
--- /dev/null
+++ b/stripe/params/_file_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class FileRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_invoice_add_lines_params.py b/stripe/params/_invoice_add_lines_params.py
new file mode 100644
index 000000000..3104b23fd
--- /dev/null
+++ b/stripe/params/_invoice_add_lines_params.py
@@ -0,0 +1,259 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class InvoiceAddLinesParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice_metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ lines: List["InvoiceAddLinesParamsLine"]
+ """
+ The line items to add.
+ """
+
+
+class InvoiceAddLinesParamsLine(TypedDict):
+ amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
+ """
+ discountable: NotRequired[bool]
+ """
+ Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[InvoiceAddLinesParamsLineDiscount]"
+ ]
+ """
+ The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
+ """
+ invoice_item: NotRequired[str]
+ """
+ ID of an unassigned invoice item to assign to this invoice. If not provided, a new item will be created.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ period: NotRequired["InvoiceAddLinesParamsLinePeriod"]
+ """
+ The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
+ """
+ price_data: NotRequired["InvoiceAddLinesParamsLinePriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
+ """
+ pricing: NotRequired["InvoiceAddLinesParamsLinePricing"]
+ """
+ The pricing information for the invoice item.
+ """
+ quantity: NotRequired[int]
+ """
+ Non-negative integer. The quantity of units for the line item.
+ """
+ tax_amounts: NotRequired[
+ "Literal['']|List[InvoiceAddLinesParamsLineTaxAmount]"
+ ]
+ """
+ A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has [tax_rates](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-tax_rates) or if the invoice has [default_tax_rates](https://stripe.com/docs/api/invoices/object#invoice_object-default_tax_rates) or uses [automatic tax](https://stripe.com/docs/tax/invoicing). Pass an empty string to remove previously defined tax amounts.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the line item. When set, the `default_tax_rates` on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.
+ """
+
+
+class InvoiceAddLinesParamsLineDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class InvoiceAddLinesParamsLinePeriod(TypedDict):
+ end: int
+ """
+ The end of the period, which must be greater than or equal to the start. This value is inclusive.
+ """
+ start: int
+ """
+ The start of the period. This value is inclusive.
+ """
+
+
+class InvoiceAddLinesParamsLinePriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: NotRequired[str]
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
+ """
+ product_data: NotRequired["InvoiceAddLinesParamsLinePriceDataProductData"]
+ """
+ Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class InvoiceAddLinesParamsLinePriceDataProductData(TypedDict):
+ description: NotRequired[str]
+ """
+ The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
+ """
+ images: NotRequired[List[str]]
+ """
+ A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: str
+ """
+ The product's name, meant to be displayable to the customer.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+ unit_label: NotRequired[str]
+ """
+ A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
+ """
+
+
+class InvoiceAddLinesParamsLinePricing(TypedDict):
+ price: NotRequired[str]
+ """
+ The ID of the price object.
+ """
+
+
+class InvoiceAddLinesParamsLineTaxAmount(TypedDict):
+ amount: int
+ """
+ The amount, in cents (or local equivalent), of the tax.
+ """
+ tax_rate_data: "InvoiceAddLinesParamsLineTaxAmountTaxRateData"
+ """
+ Data to find or create a TaxRate object.
+
+ Stripe automatically creates or reuses a TaxRate object for each tax amount. If the `tax_rate_data` exactly matches a previous value, Stripe will reuse the TaxRate object. TaxRate objects created automatically by Stripe are immediately archived, do not appear in the line item's `tax_rates`, and cannot be directly added to invoices, payments, or line items.
+ """
+ taxability_reason: NotRequired[
+ Literal[
+ "customer_exempt",
+ "not_collecting",
+ "not_subject_to_tax",
+ "not_supported",
+ "portion_product_exempt",
+ "portion_reduced_rated",
+ "portion_standard_rated",
+ "product_exempt",
+ "product_exempt_holiday",
+ "proportionally_rated",
+ "reduced_rated",
+ "reverse_charge",
+ "standard_rated",
+ "taxable_basis_reduced",
+ "zero_rated",
+ ]
+ ]
+ """
+ The reasoning behind this tax, for example, if the product is tax exempt.
+ """
+ taxable_amount: int
+ """
+ The amount on which tax is calculated, in cents (or local equivalent).
+ """
+
+
+class InvoiceAddLinesParamsLineTaxAmountTaxRateData(TypedDict):
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
+ """
+ display_name: str
+ """
+ The display name of the tax rate, which will be shown to users.
+ """
+ inclusive: bool
+ """
+ This specifies if the tax rate is inclusive or exclusive.
+ """
+ jurisdiction: NotRequired[str]
+ """
+ The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer's invoice.
+ """
+ jurisdiction_level: NotRequired[
+ Literal["city", "country", "county", "district", "multiple", "state"]
+ ]
+ """
+ The level of the jurisdiction that imposes this tax rate.
+ """
+ percentage: float
+ """
+ The statutory tax rate percent. This field accepts decimal values between 0 and 100 inclusive with at most 4 decimal places. To accommodate fixed-amount taxes, set the percentage to zero. Stripe will not display zero percentages on the invoice unless the `amount` of the tax is also zero.
+ """
+ state: NotRequired[str]
+ """
+ [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, "NY" for New York, United States.
+ """
+ tax_type: NotRequired[
+ Literal[
+ "amusement_tax",
+ "communications_tax",
+ "gst",
+ "hst",
+ "igst",
+ "jct",
+ "lease_tax",
+ "pst",
+ "qst",
+ "retail_delivery_fee",
+ "rst",
+ "sales_tax",
+ "service_tax",
+ "vat",
+ ]
+ ]
+ """
+ The high-level tax type, such as `vat` or `sales_tax`.
+ """
diff --git a/stripe/params/_invoice_attach_payment_params.py b/stripe/params/_invoice_attach_payment_params.py
new file mode 100644
index 000000000..0598d30cb
--- /dev/null
+++ b/stripe/params/_invoice_attach_payment_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InvoiceAttachPaymentParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ payment_intent: NotRequired[str]
+ """
+ The ID of the PaymentIntent to attach to the invoice.
+ """
diff --git a/stripe/params/_invoice_create_params.py b/stripe/params/_invoice_create_params.py
new file mode 100644
index 000000000..13aef1d59
--- /dev/null
+++ b/stripe/params/_invoice_create_params.py
@@ -0,0 +1,667 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class InvoiceCreateParams(RequestOptions):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
+ """
+ application_fee_amount: NotRequired[int]
+ """
+ A fee in cents (or local equivalent) that will be applied to the invoice and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the Stripe-Account header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/billing/invoices/connect#collecting-fees).
+ """
+ auto_advance: NotRequired[bool]
+ """
+ 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. Defaults to false.
+ """
+ automatic_tax: NotRequired["InvoiceCreateParamsAutomaticTax"]
+ """
+ Settings for automatic tax lookup for this invoice.
+ """
+ automatically_finalizes_at: NotRequired[int]
+ """
+ The time when this invoice should be scheduled to finalize (up to 5 years in the future). The invoice is finalized at this time if it's still in draft state.
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`.
+ """
+ currency: NotRequired[str]
+ """
+ The currency to create this invoice in. Defaults to that of `customer` if not specified.
+ """
+ custom_fields: NotRequired[
+ "Literal['']|List[InvoiceCreateParamsCustomField]"
+ ]
+ """
+ A list of up to 4 custom fields to be displayed on the invoice.
+ """
+ customer: NotRequired[str]
+ """
+ The ID of the customer who will be billed.
+ """
+ days_until_due: NotRequired[int]
+ """
+ The number of days from when the invoice is created until it is due. Valid only for invoices where `collection_method=send_invoice`.
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.
+ """
+ default_source: NotRequired[str]
+ """
+ ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.
+ """
+ default_tax_rates: NotRequired[List[str]]
+ """
+ The tax rates that will apply to any line item that does not have `tax_rates` set.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.
+ """
+ discounts: NotRequired["Literal['']|List[InvoiceCreateParamsDiscount]"]
+ """
+ The coupons and promotion codes to redeem into discounts for the invoice. If not specified, inherits the discount from the invoice's customer. Pass an empty string to avoid inheriting any discounts.
+ """
+ due_date: NotRequired[int]
+ """
+ The date on which payment for this invoice is due. Valid only for invoices where `collection_method=send_invoice`.
+ """
+ effective_at: NotRequired[int]
+ """
+ The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ footer: NotRequired[str]
+ """
+ Footer to be displayed on the invoice.
+ """
+ from_invoice: NotRequired["InvoiceCreateParamsFromInvoice"]
+ """
+ Revise an existing invoice. The new invoice will be created in `status=draft`. See the [revision documentation](https://stripe.com/docs/invoicing/invoice-revisions) for more details.
+ """
+ issuer: NotRequired["InvoiceCreateParamsIssuer"]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ number: NotRequired[str]
+ """
+ Set the number for this invoice. If no number is present then a number will be assigned automatically when the invoice is finalized. In many markets, regulations require invoices to be unique, sequential and / or gapless. You are responsible for ensuring this is true across all your different invoicing systems in the event that you edit the invoice number using our API. If you use only Stripe for your invoices and do not change invoice numbers, Stripe handles this aspect of compliance for you automatically.
+ """
+ on_behalf_of: NotRequired[str]
+ """
+ The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
+ """
+ payment_settings: NotRequired["InvoiceCreateParamsPaymentSettings"]
+ """
+ Configuration settings for the PaymentIntent that is generated when the invoice is finalized.
+ """
+ pending_invoice_items_behavior: NotRequired[Literal["exclude", "include"]]
+ """
+ How to handle pending invoice items on invoice creation. Defaults to `exclude` if the parameter is omitted.
+ """
+ rendering: NotRequired["InvoiceCreateParamsRendering"]
+ """
+ The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.
+ """
+ shipping_cost: NotRequired["InvoiceCreateParamsShippingCost"]
+ """
+ Settings for the cost of shipping for this invoice.
+ """
+ shipping_details: NotRequired["InvoiceCreateParamsShippingDetails"]
+ """
+ Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ Extra information about a charge for the customer's credit card statement. It must contain at least one letter. If not specified and this invoice is part of a subscription, the default `statement_descriptor` will be set to the first subscription item's product's `statement_descriptor`.
+ """
+ subscription: NotRequired[str]
+ """
+ The ID of the subscription to invoice, if any. If set, the created invoice will only include pending invoice items for that subscription. The subscription's billing cycle and regular subscription events won't be affected.
+ """
+ transfer_data: NotRequired["InvoiceCreateParamsTransferData"]
+ """
+ If specified, the funds from the invoice will be transferred to the destination and the ID of the resulting transfer will be found on the invoice's charge.
+ """
+
+
+class InvoiceCreateParamsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Whether Stripe automatically computes tax on this invoice. Note that incompatible invoice items (invoice items with manually specified [tax rates](https://stripe.com/docs/api/tax_rates), negative amounts, or `tax_behavior=unspecified`) cannot be added to automatic tax invoices.
+ """
+ liability: NotRequired["InvoiceCreateParamsAutomaticTaxLiability"]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class InvoiceCreateParamsAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class InvoiceCreateParamsCustomField(TypedDict):
+ name: str
+ """
+ The name of the custom field. This may be up to 40 characters.
+ """
+ value: str
+ """
+ The value of the custom field. This may be up to 140 characters.
+ """
+
+
+class InvoiceCreateParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class InvoiceCreateParamsFromInvoice(TypedDict):
+ action: Literal["revision"]
+ """
+ The relation between the new invoice and the original invoice. Currently, only 'revision' is permitted
+ """
+ invoice: str
+ """
+ The `id` of the invoice that will be cloned.
+ """
+
+
+class InvoiceCreateParamsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class InvoiceCreateParamsPaymentSettings(TypedDict):
+ default_mandate: NotRequired["Literal['']|str"]
+ """
+ ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the invoice's default_payment_method or default_source, if set.
+ """
+ payment_method_options: NotRequired[
+ "InvoiceCreateParamsPaymentSettingsPaymentMethodOptions"
+ ]
+ """
+ Payment-method-specific configuration to provide to the invoice's PaymentIntent.
+ """
+ payment_method_types: NotRequired[
+ "Literal['']|List[Literal['ach_credit_transfer', 'ach_debit', 'acss_debit', 'affirm', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'jp_credit_transfer', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'link', 'multibanco', 'naver_pay', 'nz_bank_account', 'p24', 'payco', 'paynow', 'paypal', 'promptpay', 'revolut_pay', 'sepa_credit_transfer', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
+ ]
+ """
+ The list of payment method types (e.g. card) to provide to the invoice's PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice's default payment method, the subscription's default payment method, the customer's default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice).
+ """
+
+
+class InvoiceCreateParamsPaymentSettingsPaymentMethodOptions(TypedDict):
+ acss_debit: NotRequired[
+ "Literal['']|InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsAcssDebit"
+ ]
+ """
+ If paying by `acss_debit`, this sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice's PaymentIntent.
+ """
+ bancontact: NotRequired[
+ "Literal['']|InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsBancontact"
+ ]
+ """
+ If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the invoice's PaymentIntent.
+ """
+ card: NotRequired[
+ "Literal['']|InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsCard"
+ ]
+ """
+ If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the invoice's PaymentIntent.
+ """
+ customer_balance: NotRequired[
+ "Literal['']|InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance"
+ ]
+ """
+ If paying by `customer_balance`, this sub-hash contains details about the Bank transfer payment method options to pass to the invoice's PaymentIntent.
+ """
+ konbini: NotRequired[
+ "Literal['']|InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsKonbini"
+ ]
+ """
+ If paying by `konbini`, this sub-hash contains details about the Konbini payment method options to pass to the invoice's PaymentIntent.
+ """
+ sepa_debit: NotRequired[
+ "Literal['']|InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsSepaDebit"
+ ]
+ """
+ If paying by `sepa_debit`, this sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice's PaymentIntent.
+ """
+ us_bank_account: NotRequired[
+ "Literal['']|InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ If paying by `us_bank_account`, this sub-hash contains details about the ACH direct debit payment method options to pass to the invoice's PaymentIntent.
+ """
+
+
+class InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsAcssDebit(
+ TypedDict,
+):
+ mandate_options: NotRequired[
+ "InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Verification method for the intent
+ """
+
+
+class InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions(
+ TypedDict,
+):
+ transaction_type: NotRequired[Literal["business", "personal"]]
+ """
+ Transaction type of the mandate.
+ """
+
+
+class InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsBancontact(
+ TypedDict,
+):
+ preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
+ """
+ Preferred language of the Bancontact authorization page that the customer is redirected to.
+ """
+
+
+class InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsCard(TypedDict):
+ installments: NotRequired[
+ "InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsCardInstallments"
+ ]
+ """
+ Installment configuration for payments attempted on this invoice.
+
+ For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
+ """
+ request_three_d_secure: NotRequired[
+ Literal["any", "automatic", "challenge"]
+ ]
+ """
+ We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
+ """
+
+
+class InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsCardInstallments(
+ TypedDict,
+):
+ enabled: NotRequired[bool]
+ """
+ Setting to true enables installments for this invoice.
+ Setting to false will prevent any selected plan from applying to a payment.
+ """
+ plan: NotRequired[
+ "Literal['']|InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsCardInstallmentsPlan"
+ ]
+ """
+ The selected installment plan to use for this invoice.
+ """
+
+
+class InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsCardInstallmentsPlan(
+ TypedDict,
+):
+ count: NotRequired[int]
+ """
+ For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
+ """
+ interval: NotRequired[Literal["month"]]
+ """
+ For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
+ One of `month`.
+ """
+ type: Literal["bonus", "fixed_count", "revolving"]
+ """
+ Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
+ """
+
+
+class InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance(
+ TypedDict,
+):
+ bank_transfer: NotRequired[
+ "InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer"
+ ]
+ """
+ Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
+ """
+ funding_type: NotRequired[str]
+ """
+ The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
+ """
+
+
+class InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer(
+ TypedDict,
+):
+ eu_bank_transfer: NotRequired[
+ "InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
+ ]
+ """
+ Configuration for eu_bank_transfer funding type.
+ """
+ type: NotRequired[str]
+ """
+ The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
+ """
+
+
+class InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
+ TypedDict,
+):
+ country: str
+ """
+ The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
+ """
+
+
+class InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsKonbini(TypedDict):
+ pass
+
+
+class InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsSepaDebit(
+ TypedDict,
+):
+ pass
+
+
+class InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount(
+ TypedDict,
+):
+ financial_connections: NotRequired[
+ "InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections"
+ ]
+ """
+ Additional fields for Financial Connections Session creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Verification method for the intent
+ """
+
+
+class InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections(
+ TypedDict,
+):
+ filters: NotRequired[
+ "InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
+ ]
+ """
+ Provide filters for the linked accounts that the customer can select for the payment method.
+ """
+ permissions: NotRequired[
+ List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ ]
+ """
+ The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+
+
+class InvoiceCreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
+ TypedDict,
+):
+ account_subcategories: NotRequired[List[Literal["checking", "savings"]]]
+ """
+ The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
+ """
+
+
+class InvoiceCreateParamsRendering(TypedDict):
+ amount_tax_display: NotRequired[
+ "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
+ ]
+ """
+ How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
+ """
+ pdf: NotRequired["InvoiceCreateParamsRenderingPdf"]
+ """
+ Invoice pdf rendering options
+ """
+ template: NotRequired[str]
+ """
+ ID of the invoice rendering template to use for this invoice.
+ """
+ template_version: NotRequired["Literal['']|int"]
+ """
+ The specific version of invoice rendering template to use for this invoice.
+ """
+
+
+class InvoiceCreateParamsRenderingPdf(TypedDict):
+ page_size: NotRequired[Literal["a4", "auto", "letter"]]
+ """
+ Page size for invoice PDF. Can be set to `a4`, `letter`, or `auto`.
+ If set to `auto`, invoice PDF page size defaults to `a4` for customers with
+ Japanese locale and `letter` for customers with other locales.
+ """
+
+
+class InvoiceCreateParamsShippingCost(TypedDict):
+ shipping_rate: NotRequired[str]
+ """
+ The ID of the shipping rate to use for this order.
+ """
+ shipping_rate_data: NotRequired[
+ "InvoiceCreateParamsShippingCostShippingRateData"
+ ]
+ """
+ Parameters to create a new ad-hoc shipping rate for this order.
+ """
+
+
+class InvoiceCreateParamsShippingCostShippingRateData(TypedDict):
+ delivery_estimate: NotRequired[
+ "InvoiceCreateParamsShippingCostShippingRateDataDeliveryEstimate"
+ ]
+ """
+ The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
+ """
+ display_name: str
+ """
+ The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
+ """
+ fixed_amount: NotRequired[
+ "InvoiceCreateParamsShippingCostShippingRateDataFixedAmount"
+ ]
+ """
+ Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
+ """
+ type: NotRequired[Literal["fixed_amount"]]
+ """
+ The type of calculation to use on the shipping rate.
+ """
+
+
+class InvoiceCreateParamsShippingCostShippingRateDataDeliveryEstimate(
+ TypedDict,
+):
+ maximum: NotRequired[
+ "InvoiceCreateParamsShippingCostShippingRateDataDeliveryEstimateMaximum"
+ ]
+ """
+ The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
+ """
+ minimum: NotRequired[
+ "InvoiceCreateParamsShippingCostShippingRateDataDeliveryEstimateMinimum"
+ ]
+ """
+ The lower bound of the estimated range. If empty, represents no lower bound.
+ """
+
+
+class InvoiceCreateParamsShippingCostShippingRateDataDeliveryEstimateMaximum(
+ TypedDict,
+):
+ unit: Literal["business_day", "day", "hour", "month", "week"]
+ """
+ A unit of time.
+ """
+ value: int
+ """
+ Must be greater than 0.
+ """
+
+
+class InvoiceCreateParamsShippingCostShippingRateDataDeliveryEstimateMinimum(
+ TypedDict,
+):
+ unit: Literal["business_day", "day", "hour", "month", "week"]
+ """
+ A unit of time.
+ """
+ value: int
+ """
+ Must be greater than 0.
+ """
+
+
+class InvoiceCreateParamsShippingCostShippingRateDataFixedAmount(TypedDict):
+ amount: int
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ currency_options: NotRequired[
+ Dict[
+ str,
+ "InvoiceCreateParamsShippingCostShippingRateDataFixedAmountCurrencyOptions",
+ ]
+ ]
+ """
+ Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+
+
+class InvoiceCreateParamsShippingCostShippingRateDataFixedAmountCurrencyOptions(
+ TypedDict,
+):
+ amount: int
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
+
+
+class InvoiceCreateParamsShippingDetails(TypedDict):
+ address: "InvoiceCreateParamsShippingDetailsAddress"
+ """
+ Shipping address
+ """
+ name: str
+ """
+ Recipient name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Recipient phone (including extension)
+ """
+
+
+class InvoiceCreateParamsShippingDetailsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class InvoiceCreateParamsTransferData(TypedDict):
+ amount: NotRequired[int]
+ """
+ The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
diff --git a/stripe/params/_invoice_create_preview_params.py b/stripe/params/_invoice_create_preview_params.py
new file mode 100644
index 000000000..c6a803455
--- /dev/null
+++ b/stripe/params/_invoice_create_preview_params.py
@@ -0,0 +1,1148 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class InvoiceCreatePreviewParams(RequestOptions):
+ automatic_tax: NotRequired["InvoiceCreatePreviewParamsAutomaticTax"]
+ """
+ Settings for automatic tax lookup for this invoice preview.
+ """
+ currency: NotRequired[str]
+ """
+ The currency to preview this invoice in. Defaults to that of `customer` if not specified.
+ """
+ customer: NotRequired[str]
+ """
+ The identifier of the customer whose upcoming invoice you'd like to retrieve. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.
+ """
+ customer_details: NotRequired["InvoiceCreatePreviewParamsCustomerDetails"]
+ """
+ Details about the customer you want to invoice or overrides for an existing customer. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[InvoiceCreatePreviewParamsDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the invoice preview. If not specified, inherits the discount from the subscription or customer. This works for both coupons directly applied to an invoice and coupons applied to a subscription. Pass an empty string to avoid inheriting any discounts.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice_items: NotRequired[List["InvoiceCreatePreviewParamsInvoiceItem"]]
+ """
+ List of invoice items to add or update in the upcoming invoice preview (up to 250).
+ """
+ issuer: NotRequired["InvoiceCreatePreviewParamsIssuer"]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+ on_behalf_of: NotRequired["Literal['']|str"]
+ """
+ The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
+ """
+ preview_mode: NotRequired[Literal["next", "recurring"]]
+ """
+ Customizes the types of values to include when calculating the invoice. Defaults to `next` if unspecified.
+ """
+ schedule: NotRequired[str]
+ """
+ The identifier of the schedule whose upcoming invoice you'd like to retrieve. Cannot be used with subscription or subscription fields.
+ """
+ schedule_details: NotRequired["InvoiceCreatePreviewParamsScheduleDetails"]
+ """
+ The schedule creation or modification params to apply as a preview. Cannot be used with `subscription` or `subscription_` prefixed fields.
+ """
+ subscription: NotRequired[str]
+ """
+ The identifier of the subscription for which you'd like to retrieve the upcoming invoice. If not provided, but a `subscription_details.items` is provided, you will preview creating a subscription with those items. If neither `subscription` nor `subscription_details.items` is provided, you will retrieve the next upcoming invoice from among the customer's subscriptions.
+ """
+ subscription_details: NotRequired[
+ "InvoiceCreatePreviewParamsSubscriptionDetails"
+ ]
+ """
+ The subscription creation or modification params to apply as a preview. Cannot be used with `schedule` or `schedule_details` fields.
+ """
+
+
+class InvoiceCreatePreviewParamsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Whether Stripe automatically computes tax on this invoice. Note that incompatible invoice items (invoice items with manually specified [tax rates](https://stripe.com/docs/api/tax_rates), negative amounts, or `tax_behavior=unspecified`) cannot be added to automatic tax invoices.
+ """
+ liability: NotRequired["InvoiceCreatePreviewParamsAutomaticTaxLiability"]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class InvoiceCreatePreviewParamsAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class InvoiceCreatePreviewParamsCustomerDetails(TypedDict):
+ address: NotRequired[
+ "Literal['']|InvoiceCreatePreviewParamsCustomerDetailsAddress"
+ ]
+ """
+ The customer's address.
+ """
+ shipping: NotRequired[
+ "Literal['']|InvoiceCreatePreviewParamsCustomerDetailsShipping"
+ ]
+ """
+ The customer's shipping information. Appears on invoices emailed to this customer.
+ """
+ tax: NotRequired["InvoiceCreatePreviewParamsCustomerDetailsTax"]
+ """
+ Tax details about the customer.
+ """
+ tax_exempt: NotRequired["Literal['']|Literal['exempt', 'none', 'reverse']"]
+ """
+ The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
+ """
+ tax_ids: NotRequired[
+ List["InvoiceCreatePreviewParamsCustomerDetailsTaxId"]
+ ]
+ """
+ The customer's tax IDs.
+ """
+
+
+class InvoiceCreatePreviewParamsCustomerDetailsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class InvoiceCreatePreviewParamsCustomerDetailsShipping(TypedDict):
+ address: "InvoiceCreatePreviewParamsCustomerDetailsShippingAddress"
+ """
+ Customer shipping address.
+ """
+ name: str
+ """
+ Customer name.
+ """
+ phone: NotRequired[str]
+ """
+ Customer phone (including extension).
+ """
+
+
+class InvoiceCreatePreviewParamsCustomerDetailsShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class InvoiceCreatePreviewParamsCustomerDetailsTax(TypedDict):
+ ip_address: NotRequired["Literal['']|str"]
+ """
+ A recent IP address of the customer used for tax reporting and tax location inference. Stripe recommends updating the IP address when a new PaymentMethod is attached or the address field on the customer is updated. We recommend against updating this field more frequently since it could result in unexpected tax location/reporting outcomes.
+ """
+
+
+class InvoiceCreatePreviewParamsCustomerDetailsTaxId(TypedDict):
+ type: Literal[
+ "ad_nrt",
+ "ae_trn",
+ "al_tin",
+ "am_tin",
+ "ao_tin",
+ "ar_cuit",
+ "au_abn",
+ "au_arn",
+ "aw_tin",
+ "az_tin",
+ "ba_tin",
+ "bb_tin",
+ "bd_bin",
+ "bf_ifu",
+ "bg_uic",
+ "bh_vat",
+ "bj_ifu",
+ "bo_tin",
+ "br_cnpj",
+ "br_cpf",
+ "bs_tin",
+ "by_tin",
+ "ca_bn",
+ "ca_gst_hst",
+ "ca_pst_bc",
+ "ca_pst_mb",
+ "ca_pst_sk",
+ "ca_qst",
+ "cd_nif",
+ "ch_uid",
+ "ch_vat",
+ "cl_tin",
+ "cm_niu",
+ "cn_tin",
+ "co_nit",
+ "cr_tin",
+ "cv_nif",
+ "de_stn",
+ "do_rcn",
+ "ec_ruc",
+ "eg_tin",
+ "es_cif",
+ "et_tin",
+ "eu_oss_vat",
+ "eu_vat",
+ "gb_vat",
+ "ge_vat",
+ "gn_nif",
+ "hk_br",
+ "hr_oib",
+ "hu_tin",
+ "id_npwp",
+ "il_vat",
+ "in_gst",
+ "is_vat",
+ "jp_cn",
+ "jp_rn",
+ "jp_trn",
+ "ke_pin",
+ "kg_tin",
+ "kh_tin",
+ "kr_brn",
+ "kz_bin",
+ "la_tin",
+ "li_uid",
+ "li_vat",
+ "ma_vat",
+ "md_vat",
+ "me_pib",
+ "mk_vat",
+ "mr_nif",
+ "mx_rfc",
+ "my_frp",
+ "my_itn",
+ "my_sst",
+ "ng_tin",
+ "no_vat",
+ "no_voec",
+ "np_pan",
+ "nz_gst",
+ "om_vat",
+ "pe_ruc",
+ "ph_tin",
+ "ro_tin",
+ "rs_pib",
+ "ru_inn",
+ "ru_kpp",
+ "sa_vat",
+ "sg_gst",
+ "sg_uen",
+ "si_tin",
+ "sn_ninea",
+ "sr_fin",
+ "sv_nit",
+ "th_vat",
+ "tj_tin",
+ "tr_tin",
+ "tw_vat",
+ "tz_vat",
+ "ua_vat",
+ "ug_tin",
+ "us_ein",
+ "uy_ruc",
+ "uz_tin",
+ "uz_vat",
+ "ve_rif",
+ "vn_tin",
+ "za_vat",
+ "zm_tin",
+ "zw_tin",
+ ]
+ """
+ Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
+ """
+ value: str
+ """
+ Value of the tax ID.
+ """
+
+
+class InvoiceCreatePreviewParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class InvoiceCreatePreviewParamsInvoiceItem(TypedDict):
+ amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) of previewed invoice item.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Only applicable to new invoice items.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
+ """
+ discountable: NotRequired[bool]
+ """
+ Explicitly controls whether discounts apply to this invoice item. Defaults to true, except for negative invoice items.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[InvoiceCreatePreviewParamsInvoiceItemDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the invoice item in the preview.
+ """
+ invoiceitem: NotRequired[str]
+ """
+ The ID of the invoice item to update in preview. If not specified, a new invoice item will be added to the preview of the upcoming invoice.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ period: NotRequired["InvoiceCreatePreviewParamsInvoiceItemPeriod"]
+ """
+ The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required.
+ """
+ price_data: NotRequired["InvoiceCreatePreviewParamsInvoiceItemPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: NotRequired[int]
+ """
+ Non-negative integer. The quantity of units for the invoice item.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ tax_code: NotRequired["Literal['']|str"]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates that apply to the item. When set, any `default_tax_rates` do not apply to this item.
+ """
+ unit_amount: NotRequired[int]
+ """
+ The integer unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This unit_amount will be multiplied by the quantity to get the full amount. If you want to apply a credit to the customer's account, pass a negative unit_amount.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class InvoiceCreatePreviewParamsInvoiceItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class InvoiceCreatePreviewParamsInvoiceItemPeriod(TypedDict):
+ end: int
+ """
+ The end of the period, which must be greater than or equal to the start. This value is inclusive.
+ """
+ start: int
+ """
+ The start of the period. This value is inclusive.
+ """
+
+
+class InvoiceCreatePreviewParamsInvoiceItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class InvoiceCreatePreviewParamsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetails(TypedDict):
+ billing_mode: NotRequired[
+ "InvoiceCreatePreviewParamsScheduleDetailsBillingMode"
+ ]
+ """
+ Controls how prorations and invoices for subscriptions are calculated and orchestrated.
+ """
+ end_behavior: NotRequired[Literal["cancel", "release"]]
+ """
+ Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
+ """
+ phases: NotRequired[List["InvoiceCreatePreviewParamsScheduleDetailsPhase"]]
+ """
+ List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ In cases where the `schedule_details` params update the currently active phase, specifies if and how to prorate at the time of the request.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsBillingMode(TypedDict):
+ flexible: NotRequired[
+ "InvoiceCreatePreviewParamsScheduleDetailsBillingModeFlexible"
+ ]
+ """
+ Configure behavior for flexible billing mode.
+ """
+ type: Literal["classic", "flexible"]
+ """
+ Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsBillingModeFlexible(TypedDict):
+ proration_discounts: NotRequired[Literal["included", "itemized"]]
+ """
+ Controls how invoices and invoice items display proration amounts and discount amounts.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhase(TypedDict):
+ add_invoice_items: NotRequired[
+ List["InvoiceCreatePreviewParamsScheduleDetailsPhaseAddInvoiceItem"]
+ ]
+ """
+ A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
+ """
+ application_fee_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
+ """
+ automatic_tax: NotRequired[
+ "InvoiceCreatePreviewParamsScheduleDetailsPhaseAutomaticTax"
+ ]
+ """
+ Automatic tax settings for this phase.
+ """
+ billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
+ """
+ Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
+ """
+ billing_thresholds: NotRequired[
+ "Literal['']|InvoiceCreatePreviewParamsScheduleDetailsPhaseBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
+ """
+ default_tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
+ """
+ description: NotRequired["Literal['']|str"]
+ """
+ Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[InvoiceCreatePreviewParamsScheduleDetailsPhaseDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
+ """
+ duration: NotRequired[
+ "InvoiceCreatePreviewParamsScheduleDetailsPhaseDuration"
+ ]
+ """
+ The number of intervals the phase should last. If set, `end_date` must not be set.
+ """
+ end_date: NotRequired["int|Literal['now']"]
+ """
+ The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
+ """
+ invoice_settings: NotRequired[
+ "InvoiceCreatePreviewParamsScheduleDetailsPhaseInvoiceSettings"
+ ]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ items: List["InvoiceCreatePreviewParamsScheduleDetailsPhaseItem"]
+ """
+ List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
+ """
+ on_behalf_of: NotRequired[str]
+ """
+ The account on behalf of which to charge, for each of the associated subscription's invoices.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. It's different from the request-level [proration_behavior](https://stripe.com/docs/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration (item price, quantity, etc.) of the current phase.
+ """
+ start_date: NotRequired["int|Literal['now']"]
+ """
+ The date at which this phase of the subscription schedule starts or `now`. Must be set on the first phase.
+ """
+ transfer_data: NotRequired[
+ "InvoiceCreatePreviewParamsScheduleDetailsPhaseTransferData"
+ ]
+ """
+ The data with which to automatically create a Transfer for each of the associated subscription's invoices.
+ """
+ trial: NotRequired[bool]
+ """
+ If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
+ """
+ trial_end: NotRequired["int|Literal['now']"]
+ """
+ Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseAddInvoiceItem(TypedDict):
+ discounts: NotRequired[
+ List[
+ "InvoiceCreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemDiscount"
+ ]
+ ]
+ """
+ The coupons to redeem into discounts for the item.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ period: NotRequired[
+ "InvoiceCreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriod"
+ ]
+ """
+ The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required.
+ """
+ price_data: NotRequired[
+ "InvoiceCreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPriceData"
+ ]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: NotRequired[int]
+ """
+ Quantity for this item. Defaults to 1.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemDiscount(
+ TypedDict,
+):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriod(
+ TypedDict,
+):
+ end: (
+ "InvoiceCreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriodEnd"
+ )
+ """
+ End of the invoice item period.
+ """
+ start: "InvoiceCreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriodStart"
+ """
+ Start of the invoice item period.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriodEnd(
+ TypedDict,
+):
+ timestamp: NotRequired[int]
+ """
+ A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
+ """
+ type: Literal["min_item_period_end", "phase_end", "timestamp"]
+ """
+ Select how to calculate the end of the invoice item period.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPeriodStart(
+ TypedDict,
+):
+ timestamp: NotRequired[int]
+ """
+ A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
+ """
+ type: Literal["max_item_period_start", "phase_start", "timestamp"]
+ """
+ Select how to calculate the start of the invoice item period.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseAddInvoiceItemPriceData(
+ TypedDict,
+):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
+ """
+ liability: NotRequired[
+ "InvoiceCreatePreviewParamsScheduleDetailsPhaseAutomaticTaxLiability"
+ ]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseAutomaticTaxLiability(
+ TypedDict,
+):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseBillingThresholds(
+ TypedDict,
+):
+ amount_gte: NotRequired[int]
+ """
+ Monetary threshold that triggers the subscription to advance to a new billing period
+ """
+ reset_billing_cycle_anchor: NotRequired[bool]
+ """
+ Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseDuration(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies phase duration. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The multiplier applied to the interval.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseInvoiceSettings(TypedDict):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
+ """
+ days_until_due: NotRequired[int]
+ """
+ Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
+ """
+ issuer: NotRequired[
+ "InvoiceCreatePreviewParamsScheduleDetailsPhaseInvoiceSettingsIssuer"
+ ]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseInvoiceSettingsIssuer(
+ TypedDict,
+):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseItem(TypedDict):
+ billing_thresholds: NotRequired[
+ "Literal['']|InvoiceCreatePreviewParamsScheduleDetailsPhaseItemBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[InvoiceCreatePreviewParamsScheduleDetailsPhaseItemDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the subscription item.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
+ """
+ plan: NotRequired[str]
+ """
+ The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object.
+ """
+ price_data: NotRequired[
+ "InvoiceCreatePreviewParamsScheduleDetailsPhaseItemPriceData"
+ ]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
+ """
+ quantity: NotRequired[int]
+ """
+ Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseItemBillingThresholds(
+ TypedDict,
+):
+ usage_gte: int
+ """
+ Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ recurring: (
+ "InvoiceCreatePreviewParamsScheduleDetailsPhaseItemPriceDataRecurring"
+ )
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseItemPriceDataRecurring(
+ TypedDict,
+):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
+
+
+class InvoiceCreatePreviewParamsScheduleDetailsPhaseTransferData(TypedDict):
+ amount_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
+
+
+class InvoiceCreatePreviewParamsSubscriptionDetails(TypedDict):
+ billing_cycle_anchor: NotRequired["Literal['now', 'unchanged']|int"]
+ """
+ For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`.
+ """
+ billing_mode: NotRequired[
+ "InvoiceCreatePreviewParamsSubscriptionDetailsBillingMode"
+ ]
+ """
+ Controls how prorations and invoices for subscriptions are calculated and orchestrated.
+ """
+ cancel_at: NotRequired[
+ "Literal['']|int|Literal['max_period_end', 'min_period_end']"
+ ]
+ """
+ A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
+ """
+ cancel_at_period_end: NotRequired[bool]
+ """
+ Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`.
+ """
+ cancel_now: NotRequired[bool]
+ """
+ This simulates the subscription being canceled or expired immediately.
+ """
+ default_tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set.
+ """
+ items: NotRequired[
+ List["InvoiceCreatePreviewParamsSubscriptionDetailsItem"]
+ ]
+ """
+ A list of up to 20 subscription items, each with an attached price.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
+ """
+ proration_date: NotRequired[int]
+ """
+ If previewing an update to a subscription, and doing proration, `subscription_details.proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period and within the current phase of the schedule backing this subscription, if the schedule exists. If set, `subscription`, and one of `subscription_details.items`, or `subscription_details.trial_end` are required. Also, `subscription_details.proration_behavior` cannot be set to 'none'.
+ """
+ resume_at: NotRequired[Literal["now"]]
+ """
+ For paused subscriptions, setting `subscription_details.resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed.
+ """
+ start_date: NotRequired[int]
+ """
+ Date a subscription is intended to start (can be future or past).
+ """
+ trial_end: NotRequired["Literal['now']|int"]
+ """
+ If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_details.items` or `subscription` is required.
+ """
+
+
+class InvoiceCreatePreviewParamsSubscriptionDetailsBillingMode(TypedDict):
+ flexible: NotRequired[
+ "InvoiceCreatePreviewParamsSubscriptionDetailsBillingModeFlexible"
+ ]
+ """
+ Configure behavior for flexible billing mode.
+ """
+ type: Literal["classic", "flexible"]
+ """
+ Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
+ """
+
+
+class InvoiceCreatePreviewParamsSubscriptionDetailsBillingModeFlexible(
+ TypedDict,
+):
+ proration_discounts: NotRequired[Literal["included", "itemized"]]
+ """
+ Controls how invoices and invoice items display proration amounts and discount amounts.
+ """
+
+
+class InvoiceCreatePreviewParamsSubscriptionDetailsItem(TypedDict):
+ billing_thresholds: NotRequired[
+ "Literal['']|InvoiceCreatePreviewParamsSubscriptionDetailsItemBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ clear_usage: NotRequired[bool]
+ """
+ Delete all usage for a given subscription item. You must pass this when deleting a usage records subscription item. `clear_usage` has no effect if the plan has a billing meter attached.
+ """
+ deleted: NotRequired[bool]
+ """
+ A flag that, if set to `true`, will delete the specified item.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[InvoiceCreatePreviewParamsSubscriptionDetailsItemDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the subscription item.
+ """
+ id: NotRequired[str]
+ """
+ Subscription item to update.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ plan: NotRequired[str]
+ """
+ Plan ID for this item, as a string.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
+ """
+ price_data: NotRequired[
+ "InvoiceCreatePreviewParamsSubscriptionDetailsItemPriceData"
+ ]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: NotRequired[int]
+ """
+ Quantity for this item.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
+ """
+
+
+class InvoiceCreatePreviewParamsSubscriptionDetailsItemBillingThresholds(
+ TypedDict,
+):
+ usage_gte: int
+ """
+ Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
+ """
+
+
+class InvoiceCreatePreviewParamsSubscriptionDetailsItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class InvoiceCreatePreviewParamsSubscriptionDetailsItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ recurring: (
+ "InvoiceCreatePreviewParamsSubscriptionDetailsItemPriceDataRecurring"
+ )
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class InvoiceCreatePreviewParamsSubscriptionDetailsItemPriceDataRecurring(
+ TypedDict,
+):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
diff --git a/stripe/params/_invoice_delete_params.py b/stripe/params/_invoice_delete_params.py
new file mode 100644
index 000000000..b619378c0
--- /dev/null
+++ b/stripe/params/_invoice_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class InvoiceDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/_invoice_finalize_invoice_params.py b/stripe/params/_invoice_finalize_invoice_params.py
new file mode 100644
index 000000000..14613f6eb
--- /dev/null
+++ b/stripe/params/_invoice_finalize_invoice_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InvoiceFinalizeInvoiceParams(RequestOptions):
+ auto_advance: NotRequired[bool]
+ """
+ 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.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_invoice_item_create_params.py b/stripe/params/_invoice_item_create_params.py
new file mode 100644
index 000000000..84e9f4cb3
--- /dev/null
+++ b/stripe/params/_invoice_item_create_params.py
@@ -0,0 +1,136 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class InvoiceItemCreateParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. Passing in a negative `amount` will reduce the `amount_due` on the invoice.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ customer: str
+ """
+ The ID of the customer who will be billed when this invoice item is billed.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
+ """
+ discountable: NotRequired[bool]
+ """
+ Controls whether discounts apply to this invoice item. Defaults to false for prorations or negative invoice items, and true for all other invoice items.
+ """
+ discounts: NotRequired["Literal['']|List[InvoiceItemCreateParamsDiscount]"]
+ """
+ The coupons and promotion codes to redeem into discounts for the invoice item or invoice line item.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice: NotRequired[str]
+ """
+ The ID of an existing invoice to add this invoice item to. For subscription invoices, when left blank, the invoice item will be added to the next upcoming scheduled invoice. For standalone invoices, the invoice item won't be automatically added unless you pass `pending_invoice_item_behavior: 'include'` when creating the invoice. This is useful when adding invoice items in response to an invoice.created webhook. You can only add invoice items to draft invoices and there is a maximum of 250 items per invoice.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ period: NotRequired["InvoiceItemCreateParamsPeriod"]
+ """
+ The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
+ """
+ price_data: NotRequired["InvoiceItemCreateParamsPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
+ """
+ pricing: NotRequired["InvoiceItemCreateParamsPricing"]
+ """
+ The pricing information for the invoice item.
+ """
+ quantity: NotRequired[int]
+ """
+ Non-negative integer. The quantity of units for the invoice item.
+ """
+ subscription: NotRequired[str]
+ """
+ The ID of a subscription to add this invoice item to. When left blank, the invoice item is added to the next upcoming scheduled invoice. When set, scheduled invoices for subscriptions other than the specified subscription will ignore the invoice item. Use this when you want to express that an invoice item has been accrued within the context of a particular subscription.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ tax_code: NotRequired["Literal['']|str"]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+ tax_rates: NotRequired[List[str]]
+ """
+ The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ The decimal unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This `unit_amount_decimal` will be multiplied by the quantity to get the full amount. Passing in a negative `unit_amount_decimal` will reduce the `amount_due` on the invoice. Accepts at most 12 decimal places.
+ """
+
+
+class InvoiceItemCreateParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class InvoiceItemCreateParamsPeriod(TypedDict):
+ end: int
+ """
+ The end of the period, which must be greater than or equal to the start. This value is inclusive.
+ """
+ start: int
+ """
+ The start of the period. This value is inclusive.
+ """
+
+
+class InvoiceItemCreateParamsPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class InvoiceItemCreateParamsPricing(TypedDict):
+ price: NotRequired[str]
+ """
+ The ID of the price object.
+ """
diff --git a/stripe/params/_invoice_item_delete_params.py b/stripe/params/_invoice_item_delete_params.py
new file mode 100644
index 000000000..9a5e9f0ce
--- /dev/null
+++ b/stripe/params/_invoice_item_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class InvoiceItemDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/_invoice_item_list_params.py b/stripe/params/_invoice_item_list_params.py
new file mode 100644
index 000000000..d5bd75a37
--- /dev/null
+++ b/stripe/params/_invoice_item_list_params.py
@@ -0,0 +1,59 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class InvoiceItemListParams(RequestOptions):
+ created: NotRequired["InvoiceItemListParamsCreated|int"]
+ """
+ Only return invoice items that were created during the given date interval.
+ """
+ customer: NotRequired[str]
+ """
+ The identifier of the customer whose invoice items to return. If none is provided, all invoice items will be returned.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice: NotRequired[str]
+ """
+ Only return invoice items belonging to this invoice. If none is provided, all invoice items will be returned. If specifying an invoice, no customer identifier is needed.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ pending: NotRequired[bool]
+ """
+ Set to `true` to only show pending invoice items, which are not yet attached to any invoices. Set to `false` to only show invoice items already attached to invoices. If unspecified, no filter is applied.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class InvoiceItemListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_invoice_item_modify_params.py b/stripe/params/_invoice_item_modify_params.py
new file mode 100644
index 000000000..eadfca4c7
--- /dev/null
+++ b/stripe/params/_invoice_item_modify_params.py
@@ -0,0 +1,120 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class InvoiceItemModifyParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
+ """
+ discountable: NotRequired[bool]
+ """
+ Controls whether discounts apply to this invoice item. Defaults to false for prorations or negative invoice items, and true for all other invoice items. Cannot be set to true for prorations.
+ """
+ discounts: NotRequired["Literal['']|List[InvoiceItemModifyParamsDiscount]"]
+ """
+ The coupons, promotion codes & existing discounts which apply to the invoice item or invoice line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ period: NotRequired["InvoiceItemModifyParamsPeriod"]
+ """
+ The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
+ """
+ price_data: NotRequired["InvoiceItemModifyParamsPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
+ """
+ pricing: NotRequired["InvoiceItemModifyParamsPricing"]
+ """
+ The pricing information for the invoice item.
+ """
+ quantity: NotRequired[int]
+ """
+ Non-negative integer. The quantity of units for the invoice item.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ tax_code: NotRequired["Literal['']|str"]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item. Pass an empty string to remove previously-defined tax rates.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ The decimal unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This `unit_amount_decimal` will be multiplied by the quantity to get the full amount. Passing in a negative `unit_amount_decimal` will reduce the `amount_due` on the invoice. Accepts at most 12 decimal places.
+ """
+
+
+class InvoiceItemModifyParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class InvoiceItemModifyParamsPeriod(TypedDict):
+ end: int
+ """
+ The end of the period, which must be greater than or equal to the start. This value is inclusive.
+ """
+ start: int
+ """
+ The start of the period. This value is inclusive.
+ """
+
+
+class InvoiceItemModifyParamsPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class InvoiceItemModifyParamsPricing(TypedDict):
+ price: NotRequired[str]
+ """
+ The ID of the price object.
+ """
diff --git a/stripe/params/_invoice_item_retrieve_params.py b/stripe/params/_invoice_item_retrieve_params.py
new file mode 100644
index 000000000..122342c65
--- /dev/null
+++ b/stripe/params/_invoice_item_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InvoiceItemRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_invoice_item_update_params.py b/stripe/params/_invoice_item_update_params.py
new file mode 100644
index 000000000..5bb3e0fd5
--- /dev/null
+++ b/stripe/params/_invoice_item_update_params.py
@@ -0,0 +1,119 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class InvoiceItemUpdateParams(TypedDict):
+ amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
+ """
+ discountable: NotRequired[bool]
+ """
+ Controls whether discounts apply to this invoice item. Defaults to false for prorations or negative invoice items, and true for all other invoice items. Cannot be set to true for prorations.
+ """
+ discounts: NotRequired["Literal['']|List[InvoiceItemUpdateParamsDiscount]"]
+ """
+ The coupons, promotion codes & existing discounts which apply to the invoice item or invoice line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ period: NotRequired["InvoiceItemUpdateParamsPeriod"]
+ """
+ The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
+ """
+ price_data: NotRequired["InvoiceItemUpdateParamsPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
+ """
+ pricing: NotRequired["InvoiceItemUpdateParamsPricing"]
+ """
+ The pricing information for the invoice item.
+ """
+ quantity: NotRequired[int]
+ """
+ Non-negative integer. The quantity of units for the invoice item.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ tax_code: NotRequired["Literal['']|str"]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item. Pass an empty string to remove previously-defined tax rates.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ The decimal unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This `unit_amount_decimal` will be multiplied by the quantity to get the full amount. Passing in a negative `unit_amount_decimal` will reduce the `amount_due` on the invoice. Accepts at most 12 decimal places.
+ """
+
+
+class InvoiceItemUpdateParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class InvoiceItemUpdateParamsPeriod(TypedDict):
+ end: int
+ """
+ The end of the period, which must be greater than or equal to the start. This value is inclusive.
+ """
+ start: int
+ """
+ The start of the period. This value is inclusive.
+ """
+
+
+class InvoiceItemUpdateParamsPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class InvoiceItemUpdateParamsPricing(TypedDict):
+ price: NotRequired[str]
+ """
+ The ID of the price object.
+ """
diff --git a/stripe/params/_invoice_line_item_list_params.py b/stripe/params/_invoice_line_item_list_params.py
new file mode 100644
index 000000000..c7800702b
--- /dev/null
+++ b/stripe/params/_invoice_line_item_list_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class InvoiceLineItemListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_invoice_line_item_update_params.py b/stripe/params/_invoice_line_item_update_params.py
new file mode 100644
index 000000000..49335ed80
--- /dev/null
+++ b/stripe/params/_invoice_line_item_update_params.py
@@ -0,0 +1,245 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class InvoiceLineItemUpdateParams(TypedDict):
+ amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
+ """
+ discountable: NotRequired[bool]
+ """
+ Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[InvoiceLineItemUpdateParamsDiscount]"
+ ]
+ """
+ The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data.
+ """
+ period: NotRequired["InvoiceLineItemUpdateParamsPeriod"]
+ """
+ The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
+ """
+ price_data: NotRequired["InvoiceLineItemUpdateParamsPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
+ """
+ pricing: NotRequired["InvoiceLineItemUpdateParamsPricing"]
+ """
+ The pricing information for the invoice item.
+ """
+ quantity: NotRequired[int]
+ """
+ Non-negative integer. The quantity of units for the line item.
+ """
+ tax_amounts: NotRequired[
+ "Literal['']|List[InvoiceLineItemUpdateParamsTaxAmount]"
+ ]
+ """
+ A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has [tax_rates](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-tax_rates) or if the invoice has [default_tax_rates](https://stripe.com/docs/api/invoices/object#invoice_object-default_tax_rates) or uses [automatic tax](https://stripe.com/docs/tax/invoicing). Pass an empty string to remove previously defined tax amounts.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the line item. When set, the `default_tax_rates` on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.
+ """
+
+
+class InvoiceLineItemUpdateParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class InvoiceLineItemUpdateParamsPeriod(TypedDict):
+ end: int
+ """
+ The end of the period, which must be greater than or equal to the start. This value is inclusive.
+ """
+ start: int
+ """
+ The start of the period. This value is inclusive.
+ """
+
+
+class InvoiceLineItemUpdateParamsPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: NotRequired[str]
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
+ """
+ product_data: NotRequired[
+ "InvoiceLineItemUpdateParamsPriceDataProductData"
+ ]
+ """
+ Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class InvoiceLineItemUpdateParamsPriceDataProductData(TypedDict):
+ description: NotRequired[str]
+ """
+ The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
+ """
+ images: NotRequired[List[str]]
+ """
+ A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: str
+ """
+ The product's name, meant to be displayable to the customer.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+ unit_label: NotRequired[str]
+ """
+ A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
+ """
+
+
+class InvoiceLineItemUpdateParamsPricing(TypedDict):
+ price: NotRequired[str]
+ """
+ The ID of the price object.
+ """
+
+
+class InvoiceLineItemUpdateParamsTaxAmount(TypedDict):
+ amount: int
+ """
+ The amount, in cents (or local equivalent), of the tax.
+ """
+ tax_rate_data: "InvoiceLineItemUpdateParamsTaxAmountTaxRateData"
+ """
+ Data to find or create a TaxRate object.
+
+ Stripe automatically creates or reuses a TaxRate object for each tax amount. If the `tax_rate_data` exactly matches a previous value, Stripe will reuse the TaxRate object. TaxRate objects created automatically by Stripe are immediately archived, do not appear in the line item's `tax_rates`, and cannot be directly added to invoices, payments, or line items.
+ """
+ taxability_reason: NotRequired[
+ Literal[
+ "customer_exempt",
+ "not_collecting",
+ "not_subject_to_tax",
+ "not_supported",
+ "portion_product_exempt",
+ "portion_reduced_rated",
+ "portion_standard_rated",
+ "product_exempt",
+ "product_exempt_holiday",
+ "proportionally_rated",
+ "reduced_rated",
+ "reverse_charge",
+ "standard_rated",
+ "taxable_basis_reduced",
+ "zero_rated",
+ ]
+ ]
+ """
+ The reasoning behind this tax, for example, if the product is tax exempt.
+ """
+ taxable_amount: int
+ """
+ The amount on which tax is calculated, in cents (or local equivalent).
+ """
+
+
+class InvoiceLineItemUpdateParamsTaxAmountTaxRateData(TypedDict):
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
+ """
+ display_name: str
+ """
+ The display name of the tax rate, which will be shown to users.
+ """
+ inclusive: bool
+ """
+ This specifies if the tax rate is inclusive or exclusive.
+ """
+ jurisdiction: NotRequired[str]
+ """
+ The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer's invoice.
+ """
+ jurisdiction_level: NotRequired[
+ Literal["city", "country", "county", "district", "multiple", "state"]
+ ]
+ """
+ The level of the jurisdiction that imposes this tax rate.
+ """
+ percentage: float
+ """
+ The statutory tax rate percent. This field accepts decimal values between 0 and 100 inclusive with at most 4 decimal places. To accommodate fixed-amount taxes, set the percentage to zero. Stripe will not display zero percentages on the invoice unless the `amount` of the tax is also zero.
+ """
+ state: NotRequired[str]
+ """
+ [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, "NY" for New York, United States.
+ """
+ tax_type: NotRequired[
+ Literal[
+ "amusement_tax",
+ "communications_tax",
+ "gst",
+ "hst",
+ "igst",
+ "jct",
+ "lease_tax",
+ "pst",
+ "qst",
+ "retail_delivery_fee",
+ "rst",
+ "sales_tax",
+ "service_tax",
+ "vat",
+ ]
+ ]
+ """
+ The high-level tax type, such as `vat` or `sales_tax`.
+ """
diff --git a/stripe/params/_invoice_list_lines_params.py b/stripe/params/_invoice_list_lines_params.py
new file mode 100644
index 000000000..2139c9a74
--- /dev/null
+++ b/stripe/params/_invoice_list_lines_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InvoiceListLinesParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_invoice_list_params.py b/stripe/params/_invoice_list_params.py
new file mode 100644
index 000000000..e3d159c09
--- /dev/null
+++ b/stripe/params/_invoice_list_params.py
@@ -0,0 +1,87 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class InvoiceListParams(RequestOptions):
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ The collection method of the invoice to retrieve. Either `charge_automatically` or `send_invoice`.
+ """
+ created: NotRequired["InvoiceListParamsCreated|int"]
+ """
+ Only return invoices that were created during the given date interval.
+ """
+ customer: NotRequired[str]
+ """
+ Only return invoices for the customer specified by this customer ID.
+ """
+ due_date: NotRequired["InvoiceListParamsDueDate|int"]
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[
+ Literal["draft", "open", "paid", "uncollectible", "void"]
+ ]
+ """
+ The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview)
+ """
+ subscription: NotRequired[str]
+ """
+ Only return invoices for the subscription specified by this subscription ID.
+ """
+
+
+class InvoiceListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
+
+
+class InvoiceListParamsDueDate(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_invoice_mark_uncollectible_params.py b/stripe/params/_invoice_mark_uncollectible_params.py
new file mode 100644
index 000000000..c9aa57443
--- /dev/null
+++ b/stripe/params/_invoice_mark_uncollectible_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InvoiceMarkUncollectibleParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_invoice_modify_params.py b/stripe/params/_invoice_modify_params.py
new file mode 100644
index 000000000..dc630e7c5
--- /dev/null
+++ b/stripe/params/_invoice_modify_params.py
@@ -0,0 +1,638 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class InvoiceModifyParams(RequestOptions):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
+ """
+ application_fee_amount: NotRequired[int]
+ """
+ A fee in cents (or local equivalent) that will be applied to the invoice and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the Stripe-Account header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/billing/invoices/connect#collecting-fees).
+ """
+ auto_advance: NotRequired[bool]
+ """
+ Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice.
+ """
+ automatic_tax: NotRequired["InvoiceModifyParamsAutomaticTax"]
+ """
+ Settings for automatic tax lookup for this invoice.
+ """
+ automatically_finalizes_at: NotRequired[int]
+ """
+ The time when this invoice should be scheduled to finalize (up to 5 years in the future). The invoice is finalized at this time if it's still in draft state. To turn off automatic finalization, set `auto_advance` to false.
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices.
+ """
+ custom_fields: NotRequired[
+ "Literal['']|List[InvoiceModifyParamsCustomField]"
+ ]
+ """
+ A list of up to 4 custom fields to be displayed on the invoice. If a value for `custom_fields` is specified, the list specified will replace the existing custom field list on this invoice. Pass an empty string to remove previously-defined fields.
+ """
+ days_until_due: NotRequired[int]
+ """
+ The number of days from which the invoice is created until it is due. Only valid for invoices where `collection_method=send_invoice`. This field can only be updated on `draft` invoices.
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.
+ """
+ default_source: NotRequired["Literal['']|str"]
+ """
+ ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.
+ """
+ default_tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates that will apply to any line item that does not have `tax_rates` set. Pass an empty string to remove previously-defined tax rates.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.
+ """
+ discounts: NotRequired["Literal['']|List[InvoiceModifyParamsDiscount]"]
+ """
+ The discounts that will apply to the invoice. Pass an empty string to remove previously-defined discounts.
+ """
+ due_date: NotRequired[int]
+ """
+ The date on which payment for this invoice is due. Only valid for invoices where `collection_method=send_invoice`. This field can only be updated on `draft` invoices.
+ """
+ effective_at: NotRequired["Literal['']|int"]
+ """
+ The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ footer: NotRequired[str]
+ """
+ Footer to be displayed on the invoice.
+ """
+ issuer: NotRequired["InvoiceModifyParamsIssuer"]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ number: NotRequired["Literal['']|str"]
+ """
+ Set the number for this invoice. If no number is present then a number will be assigned automatically when the invoice is finalized. In many markets, regulations require invoices to be unique, sequential and / or gapless. You are responsible for ensuring this is true across all your different invoicing systems in the event that you edit the invoice number using our API. If you use only Stripe for your invoices and do not change invoice numbers, Stripe handles this aspect of compliance for you automatically.
+ """
+ on_behalf_of: NotRequired["Literal['']|str"]
+ """
+ The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
+ """
+ payment_settings: NotRequired["InvoiceModifyParamsPaymentSettings"]
+ """
+ Configuration settings for the PaymentIntent that is generated when the invoice is finalized.
+ """
+ rendering: NotRequired["InvoiceModifyParamsRendering"]
+ """
+ The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.
+ """
+ shipping_cost: NotRequired["Literal['']|InvoiceModifyParamsShippingCost"]
+ """
+ Settings for the cost of shipping for this invoice.
+ """
+ shipping_details: NotRequired[
+ "Literal['']|InvoiceModifyParamsShippingDetails"
+ ]
+ """
+ Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ Extra information about a charge for the customer's credit card statement. It must contain at least one letter. If not specified and this invoice is part of a subscription, the default `statement_descriptor` will be set to the first subscription item's product's `statement_descriptor`.
+ """
+ transfer_data: NotRequired["Literal['']|InvoiceModifyParamsTransferData"]
+ """
+ If specified, the funds from the invoice will be transferred to the destination and the ID of the resulting transfer will be found on the invoice's charge. This will be unset if you POST an empty value.
+ """
+
+
+class InvoiceModifyParamsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Whether Stripe automatically computes tax on this invoice. Note that incompatible invoice items (invoice items with manually specified [tax rates](https://stripe.com/docs/api/tax_rates), negative amounts, or `tax_behavior=unspecified`) cannot be added to automatic tax invoices.
+ """
+ liability: NotRequired["InvoiceModifyParamsAutomaticTaxLiability"]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class InvoiceModifyParamsAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class InvoiceModifyParamsCustomField(TypedDict):
+ name: str
+ """
+ The name of the custom field. This may be up to 40 characters.
+ """
+ value: str
+ """
+ The value of the custom field. This may be up to 140 characters.
+ """
+
+
+class InvoiceModifyParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class InvoiceModifyParamsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class InvoiceModifyParamsPaymentSettings(TypedDict):
+ default_mandate: NotRequired["Literal['']|str"]
+ """
+ ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the invoice's default_payment_method or default_source, if set.
+ """
+ payment_method_options: NotRequired[
+ "InvoiceModifyParamsPaymentSettingsPaymentMethodOptions"
+ ]
+ """
+ Payment-method-specific configuration to provide to the invoice's PaymentIntent.
+ """
+ payment_method_types: NotRequired[
+ "Literal['']|List[Literal['ach_credit_transfer', 'ach_debit', 'acss_debit', 'affirm', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'jp_credit_transfer', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'link', 'multibanco', 'naver_pay', 'nz_bank_account', 'p24', 'payco', 'paynow', 'paypal', 'promptpay', 'revolut_pay', 'sepa_credit_transfer', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
+ ]
+ """
+ The list of payment method types (e.g. card) to provide to the invoice's PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice's default payment method, the subscription's default payment method, the customer's default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice).
+ """
+
+
+class InvoiceModifyParamsPaymentSettingsPaymentMethodOptions(TypedDict):
+ acss_debit: NotRequired[
+ "Literal['']|InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebit"
+ ]
+ """
+ If paying by `acss_debit`, this sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice's PaymentIntent.
+ """
+ bancontact: NotRequired[
+ "Literal['']|InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsBancontact"
+ ]
+ """
+ If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the invoice's PaymentIntent.
+ """
+ card: NotRequired[
+ "Literal['']|InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsCard"
+ ]
+ """
+ If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the invoice's PaymentIntent.
+ """
+ customer_balance: NotRequired[
+ "Literal['']|InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalance"
+ ]
+ """
+ If paying by `customer_balance`, this sub-hash contains details about the Bank transfer payment method options to pass to the invoice's PaymentIntent.
+ """
+ konbini: NotRequired[
+ "Literal['']|InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsKonbini"
+ ]
+ """
+ If paying by `konbini`, this sub-hash contains details about the Konbini payment method options to pass to the invoice's PaymentIntent.
+ """
+ sepa_debit: NotRequired[
+ "Literal['']|InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsSepaDebit"
+ ]
+ """
+ If paying by `sepa_debit`, this sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice's PaymentIntent.
+ """
+ us_bank_account: NotRequired[
+ "Literal['']|InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ If paying by `us_bank_account`, this sub-hash contains details about the ACH direct debit payment method options to pass to the invoice's PaymentIntent.
+ """
+
+
+class InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebit(
+ TypedDict,
+):
+ mandate_options: NotRequired[
+ "InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Verification method for the intent
+ """
+
+
+class InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions(
+ TypedDict,
+):
+ transaction_type: NotRequired[Literal["business", "personal"]]
+ """
+ Transaction type of the mandate.
+ """
+
+
+class InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsBancontact(
+ TypedDict,
+):
+ preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
+ """
+ Preferred language of the Bancontact authorization page that the customer is redirected to.
+ """
+
+
+class InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsCard(TypedDict):
+ installments: NotRequired[
+ "InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsCardInstallments"
+ ]
+ """
+ Installment configuration for payments attempted on this invoice.
+
+ For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
+ """
+ request_three_d_secure: NotRequired[
+ Literal["any", "automatic", "challenge"]
+ ]
+ """
+ We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
+ """
+
+
+class InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsCardInstallments(
+ TypedDict,
+):
+ enabled: NotRequired[bool]
+ """
+ Setting to true enables installments for this invoice.
+ Setting to false will prevent any selected plan from applying to a payment.
+ """
+ plan: NotRequired[
+ "Literal['']|InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsCardInstallmentsPlan"
+ ]
+ """
+ The selected installment plan to use for this invoice.
+ """
+
+
+class InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsCardInstallmentsPlan(
+ TypedDict,
+):
+ count: NotRequired[int]
+ """
+ For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
+ """
+ interval: NotRequired[Literal["month"]]
+ """
+ For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
+ One of `month`.
+ """
+ type: Literal["bonus", "fixed_count", "revolving"]
+ """
+ Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
+ """
+
+
+class InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalance(
+ TypedDict,
+):
+ bank_transfer: NotRequired[
+ "InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer"
+ ]
+ """
+ Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
+ """
+ funding_type: NotRequired[str]
+ """
+ The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
+ """
+
+
+class InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer(
+ TypedDict,
+):
+ eu_bank_transfer: NotRequired[
+ "InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
+ ]
+ """
+ Configuration for eu_bank_transfer funding type.
+ """
+ type: NotRequired[str]
+ """
+ The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
+ """
+
+
+class InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
+ TypedDict,
+):
+ country: str
+ """
+ The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
+ """
+
+
+class InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsKonbini(TypedDict):
+ pass
+
+
+class InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsSepaDebit(
+ TypedDict,
+):
+ pass
+
+
+class InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccount(
+ TypedDict,
+):
+ financial_connections: NotRequired[
+ "InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections"
+ ]
+ """
+ Additional fields for Financial Connections Session creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Verification method for the intent
+ """
+
+
+class InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections(
+ TypedDict,
+):
+ filters: NotRequired[
+ "InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
+ ]
+ """
+ Provide filters for the linked accounts that the customer can select for the payment method.
+ """
+ permissions: NotRequired[
+ List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ ]
+ """
+ The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+
+
+class InvoiceModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
+ TypedDict,
+):
+ account_subcategories: NotRequired[List[Literal["checking", "savings"]]]
+ """
+ The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
+ """
+
+
+class InvoiceModifyParamsRendering(TypedDict):
+ amount_tax_display: NotRequired[
+ "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
+ ]
+ """
+ How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
+ """
+ pdf: NotRequired["InvoiceModifyParamsRenderingPdf"]
+ """
+ Invoice pdf rendering options
+ """
+ template: NotRequired[str]
+ """
+ ID of the invoice rendering template to use for this invoice.
+ """
+ template_version: NotRequired["Literal['']|int"]
+ """
+ The specific version of invoice rendering template to use for this invoice.
+ """
+
+
+class InvoiceModifyParamsRenderingPdf(TypedDict):
+ page_size: NotRequired[Literal["a4", "auto", "letter"]]
+ """
+ Page size for invoice PDF. Can be set to `a4`, `letter`, or `auto`.
+ If set to `auto`, invoice PDF page size defaults to `a4` for customers with
+ Japanese locale and `letter` for customers with other locales.
+ """
+
+
+class InvoiceModifyParamsShippingCost(TypedDict):
+ shipping_rate: NotRequired[str]
+ """
+ The ID of the shipping rate to use for this order.
+ """
+ shipping_rate_data: NotRequired[
+ "InvoiceModifyParamsShippingCostShippingRateData"
+ ]
+ """
+ Parameters to create a new ad-hoc shipping rate for this order.
+ """
+
+
+class InvoiceModifyParamsShippingCostShippingRateData(TypedDict):
+ delivery_estimate: NotRequired[
+ "InvoiceModifyParamsShippingCostShippingRateDataDeliveryEstimate"
+ ]
+ """
+ The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
+ """
+ display_name: str
+ """
+ The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
+ """
+ fixed_amount: NotRequired[
+ "InvoiceModifyParamsShippingCostShippingRateDataFixedAmount"
+ ]
+ """
+ Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
+ """
+ type: NotRequired[Literal["fixed_amount"]]
+ """
+ The type of calculation to use on the shipping rate.
+ """
+
+
+class InvoiceModifyParamsShippingCostShippingRateDataDeliveryEstimate(
+ TypedDict,
+):
+ maximum: NotRequired[
+ "InvoiceModifyParamsShippingCostShippingRateDataDeliveryEstimateMaximum"
+ ]
+ """
+ The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
+ """
+ minimum: NotRequired[
+ "InvoiceModifyParamsShippingCostShippingRateDataDeliveryEstimateMinimum"
+ ]
+ """
+ The lower bound of the estimated range. If empty, represents no lower bound.
+ """
+
+
+class InvoiceModifyParamsShippingCostShippingRateDataDeliveryEstimateMaximum(
+ TypedDict,
+):
+ unit: Literal["business_day", "day", "hour", "month", "week"]
+ """
+ A unit of time.
+ """
+ value: int
+ """
+ Must be greater than 0.
+ """
+
+
+class InvoiceModifyParamsShippingCostShippingRateDataDeliveryEstimateMinimum(
+ TypedDict,
+):
+ unit: Literal["business_day", "day", "hour", "month", "week"]
+ """
+ A unit of time.
+ """
+ value: int
+ """
+ Must be greater than 0.
+ """
+
+
+class InvoiceModifyParamsShippingCostShippingRateDataFixedAmount(TypedDict):
+ amount: int
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ currency_options: NotRequired[
+ Dict[
+ str,
+ "InvoiceModifyParamsShippingCostShippingRateDataFixedAmountCurrencyOptions",
+ ]
+ ]
+ """
+ Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+
+
+class InvoiceModifyParamsShippingCostShippingRateDataFixedAmountCurrencyOptions(
+ TypedDict,
+):
+ amount: int
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
+
+
+class InvoiceModifyParamsShippingDetails(TypedDict):
+ address: "InvoiceModifyParamsShippingDetailsAddress"
+ """
+ Shipping address
+ """
+ name: str
+ """
+ Recipient name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Recipient phone (including extension)
+ """
+
+
+class InvoiceModifyParamsShippingDetailsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class InvoiceModifyParamsTransferData(TypedDict):
+ amount: NotRequired[int]
+ """
+ The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
diff --git a/stripe/params/_invoice_pay_params.py b/stripe/params/_invoice_pay_params.py
new file mode 100644
index 000000000..2e7735a37
--- /dev/null
+++ b/stripe/params/_invoice_pay_params.py
@@ -0,0 +1,38 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class InvoicePayParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ forgive: NotRequired[bool]
+ """
+ In cases where the source used to pay the invoice has insufficient funds, passing `forgive=true` controls whether a charge should be attempted for the full amount available on the source, up to the amount to fully pay the invoice. This effectively forgives the difference between the amount available on the source and the amount due.
+
+ Passing `forgive=false` will fail the charge if the source hasn't been pre-funded with the right amount. An example for this case is with ACH Credit Transfers and wires: if the amount wired is less than the amount due by a small amount, you might want to forgive the difference. Defaults to `false`.
+ """
+ mandate: NotRequired["Literal['']|str"]
+ """
+ ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the payment_method param or the invoice's default_payment_method or default_source, if set.
+ """
+ off_session: NotRequired[bool]
+ """
+ Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `true` (off-session).
+ """
+ paid_out_of_band: NotRequired[bool]
+ """
+ Boolean representing whether an invoice is paid outside of Stripe. This will result in no charge being made. Defaults to `false`.
+ """
+ payment_method: NotRequired[str]
+ """
+ A PaymentMethod to be charged. The PaymentMethod must be the ID of a PaymentMethod belonging to the customer associated with the invoice being paid.
+ """
+ source: NotRequired[str]
+ """
+ A payment source to be charged. The source must be the ID of a source belonging to the customer associated with the invoice being paid.
+ """
diff --git a/stripe/params/_invoice_payment_list_params.py b/stripe/params/_invoice_payment_list_params.py
new file mode 100644
index 000000000..ae9ed3ec1
--- /dev/null
+++ b/stripe/params/_invoice_payment_list_params.py
@@ -0,0 +1,47 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class InvoicePaymentListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice: NotRequired[str]
+ """
+ The identifier of the invoice whose payments to return.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ payment: NotRequired["InvoicePaymentListParamsPayment"]
+ """
+ The payment details of the invoice payments to return.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["canceled", "open", "paid"]]
+ """
+ The status of the invoice payments to return.
+ """
+
+
+class InvoicePaymentListParamsPayment(TypedDict):
+ payment_intent: NotRequired[str]
+ """
+ Only return invoice payments associated by this payment intent ID.
+ """
+ type: Literal["payment_intent"]
+ """
+ Only return invoice payments associated by this payment type.
+ """
diff --git a/stripe/params/_invoice_payment_retrieve_params.py b/stripe/params/_invoice_payment_retrieve_params.py
new file mode 100644
index 000000000..c0096c5a2
--- /dev/null
+++ b/stripe/params/_invoice_payment_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InvoicePaymentRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_invoice_remove_lines_params.py b/stripe/params/_invoice_remove_lines_params.py
new file mode 100644
index 000000000..b6796164e
--- /dev/null
+++ b/stripe/params/_invoice_remove_lines_params.py
@@ -0,0 +1,31 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class InvoiceRemoveLinesParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice_metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ lines: List["InvoiceRemoveLinesParamsLine"]
+ """
+ The line items to remove.
+ """
+
+
+class InvoiceRemoveLinesParamsLine(TypedDict):
+ behavior: Literal["delete", "unassign"]
+ """
+ Either `delete` or `unassign`. Deleted line items are permanently deleted. Unassigned line items can be reassigned to an invoice.
+ """
+ id: str
+ """
+ ID of an existing line item to remove from this invoice.
+ """
diff --git a/stripe/params/_invoice_rendering_template_archive_params.py b/stripe/params/_invoice_rendering_template_archive_params.py
new file mode 100644
index 000000000..cdcf6bd91
--- /dev/null
+++ b/stripe/params/_invoice_rendering_template_archive_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InvoiceRenderingTemplateArchiveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_invoice_rendering_template_list_params.py b/stripe/params/_invoice_rendering_template_list_params.py
new file mode 100644
index 000000000..b50b24c5c
--- /dev/null
+++ b/stripe/params/_invoice_rendering_template_list_params.py
@@ -0,0 +1,25 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class InvoiceRenderingTemplateListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["active", "archived"]]
diff --git a/stripe/params/_invoice_rendering_template_retrieve_params.py b/stripe/params/_invoice_rendering_template_retrieve_params.py
new file mode 100644
index 000000000..20692e768
--- /dev/null
+++ b/stripe/params/_invoice_rendering_template_retrieve_params.py
@@ -0,0 +1,13 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InvoiceRenderingTemplateRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ version: NotRequired[int]
diff --git a/stripe/params/_invoice_rendering_template_unarchive_params.py b/stripe/params/_invoice_rendering_template_unarchive_params.py
new file mode 100644
index 000000000..3408ed102
--- /dev/null
+++ b/stripe/params/_invoice_rendering_template_unarchive_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InvoiceRenderingTemplateUnarchiveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_invoice_retrieve_params.py b/stripe/params/_invoice_retrieve_params.py
new file mode 100644
index 000000000..fe75326cd
--- /dev/null
+++ b/stripe/params/_invoice_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InvoiceRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_invoice_search_params.py b/stripe/params/_invoice_search_params.py
new file mode 100644
index 000000000..1ee516f8f
--- /dev/null
+++ b/stripe/params/_invoice_search_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InvoiceSearchParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ page: NotRequired[str]
+ """
+ A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
+ """
+ query: str
+ """
+ The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for invoices](https://stripe.com/docs/search#query-fields-for-invoices).
+ """
diff --git a/stripe/params/_invoice_send_invoice_params.py b/stripe/params/_invoice_send_invoice_params.py
new file mode 100644
index 000000000..e830d69c4
--- /dev/null
+++ b/stripe/params/_invoice_send_invoice_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InvoiceSendInvoiceParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_invoice_update_lines_params.py b/stripe/params/_invoice_update_lines_params.py
new file mode 100644
index 000000000..7e8fa6f1f
--- /dev/null
+++ b/stripe/params/_invoice_update_lines_params.py
@@ -0,0 +1,261 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class InvoiceUpdateLinesParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice_metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data.
+ """
+ lines: List["InvoiceUpdateLinesParamsLine"]
+ """
+ The line items to update.
+ """
+
+
+class InvoiceUpdateLinesParamsLine(TypedDict):
+ amount: NotRequired[int]
+ """
+ The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
+ """
+ discountable: NotRequired[bool]
+ """
+ Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[InvoiceUpdateLinesParamsLineDiscount]"
+ ]
+ """
+ The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
+ """
+ id: str
+ """
+ ID of an existing line item on the invoice.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data.
+ """
+ period: NotRequired["InvoiceUpdateLinesParamsLinePeriod"]
+ """
+ The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.
+ """
+ price_data: NotRequired["InvoiceUpdateLinesParamsLinePriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
+ """
+ pricing: NotRequired["InvoiceUpdateLinesParamsLinePricing"]
+ """
+ The pricing information for the invoice item.
+ """
+ quantity: NotRequired[int]
+ """
+ Non-negative integer. The quantity of units for the line item.
+ """
+ tax_amounts: NotRequired[
+ "Literal['']|List[InvoiceUpdateLinesParamsLineTaxAmount]"
+ ]
+ """
+ A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has [tax_rates](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-tax_rates) or if the invoice has [default_tax_rates](https://stripe.com/docs/api/invoices/object#invoice_object-default_tax_rates) or uses [automatic tax](https://stripe.com/docs/tax/invoicing). Pass an empty string to remove previously defined tax amounts.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the line item. When set, the `default_tax_rates` on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.
+ """
+
+
+class InvoiceUpdateLinesParamsLineDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class InvoiceUpdateLinesParamsLinePeriod(TypedDict):
+ end: int
+ """
+ The end of the period, which must be greater than or equal to the start. This value is inclusive.
+ """
+ start: int
+ """
+ The start of the period. This value is inclusive.
+ """
+
+
+class InvoiceUpdateLinesParamsLinePriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: NotRequired[str]
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
+ """
+ product_data: NotRequired[
+ "InvoiceUpdateLinesParamsLinePriceDataProductData"
+ ]
+ """
+ Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class InvoiceUpdateLinesParamsLinePriceDataProductData(TypedDict):
+ description: NotRequired[str]
+ """
+ The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
+ """
+ images: NotRequired[List[str]]
+ """
+ A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: str
+ """
+ The product's name, meant to be displayable to the customer.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+ unit_label: NotRequired[str]
+ """
+ A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
+ """
+
+
+class InvoiceUpdateLinesParamsLinePricing(TypedDict):
+ price: NotRequired[str]
+ """
+ The ID of the price object.
+ """
+
+
+class InvoiceUpdateLinesParamsLineTaxAmount(TypedDict):
+ amount: int
+ """
+ The amount, in cents (or local equivalent), of the tax.
+ """
+ tax_rate_data: "InvoiceUpdateLinesParamsLineTaxAmountTaxRateData"
+ """
+ Data to find or create a TaxRate object.
+
+ Stripe automatically creates or reuses a TaxRate object for each tax amount. If the `tax_rate_data` exactly matches a previous value, Stripe will reuse the TaxRate object. TaxRate objects created automatically by Stripe are immediately archived, do not appear in the line item's `tax_rates`, and cannot be directly added to invoices, payments, or line items.
+ """
+ taxability_reason: NotRequired[
+ Literal[
+ "customer_exempt",
+ "not_collecting",
+ "not_subject_to_tax",
+ "not_supported",
+ "portion_product_exempt",
+ "portion_reduced_rated",
+ "portion_standard_rated",
+ "product_exempt",
+ "product_exempt_holiday",
+ "proportionally_rated",
+ "reduced_rated",
+ "reverse_charge",
+ "standard_rated",
+ "taxable_basis_reduced",
+ "zero_rated",
+ ]
+ ]
+ """
+ The reasoning behind this tax, for example, if the product is tax exempt.
+ """
+ taxable_amount: int
+ """
+ The amount on which tax is calculated, in cents (or local equivalent).
+ """
+
+
+class InvoiceUpdateLinesParamsLineTaxAmountTaxRateData(TypedDict):
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
+ """
+ display_name: str
+ """
+ The display name of the tax rate, which will be shown to users.
+ """
+ inclusive: bool
+ """
+ This specifies if the tax rate is inclusive or exclusive.
+ """
+ jurisdiction: NotRequired[str]
+ """
+ The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer's invoice.
+ """
+ jurisdiction_level: NotRequired[
+ Literal["city", "country", "county", "district", "multiple", "state"]
+ ]
+ """
+ The level of the jurisdiction that imposes this tax rate.
+ """
+ percentage: float
+ """
+ The statutory tax rate percent. This field accepts decimal values between 0 and 100 inclusive with at most 4 decimal places. To accommodate fixed-amount taxes, set the percentage to zero. Stripe will not display zero percentages on the invoice unless the `amount` of the tax is also zero.
+ """
+ state: NotRequired[str]
+ """
+ [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, "NY" for New York, United States.
+ """
+ tax_type: NotRequired[
+ Literal[
+ "amusement_tax",
+ "communications_tax",
+ "gst",
+ "hst",
+ "igst",
+ "jct",
+ "lease_tax",
+ "pst",
+ "qst",
+ "retail_delivery_fee",
+ "rst",
+ "sales_tax",
+ "service_tax",
+ "vat",
+ ]
+ ]
+ """
+ The high-level tax type, such as `vat` or `sales_tax`.
+ """
diff --git a/stripe/params/_invoice_update_params.py b/stripe/params/_invoice_update_params.py
new file mode 100644
index 000000000..5fc729cd6
--- /dev/null
+++ b/stripe/params/_invoice_update_params.py
@@ -0,0 +1,637 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class InvoiceUpdateParams(TypedDict):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
+ """
+ application_fee_amount: NotRequired[int]
+ """
+ A fee in cents (or local equivalent) that will be applied to the invoice and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the Stripe-Account header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/billing/invoices/connect#collecting-fees).
+ """
+ auto_advance: NotRequired[bool]
+ """
+ Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice.
+ """
+ automatic_tax: NotRequired["InvoiceUpdateParamsAutomaticTax"]
+ """
+ Settings for automatic tax lookup for this invoice.
+ """
+ automatically_finalizes_at: NotRequired[int]
+ """
+ The time when this invoice should be scheduled to finalize (up to 5 years in the future). The invoice is finalized at this time if it's still in draft state. To turn off automatic finalization, set `auto_advance` to false.
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices.
+ """
+ custom_fields: NotRequired[
+ "Literal['']|List[InvoiceUpdateParamsCustomField]"
+ ]
+ """
+ A list of up to 4 custom fields to be displayed on the invoice. If a value for `custom_fields` is specified, the list specified will replace the existing custom field list on this invoice. Pass an empty string to remove previously-defined fields.
+ """
+ days_until_due: NotRequired[int]
+ """
+ The number of days from which the invoice is created until it is due. Only valid for invoices where `collection_method=send_invoice`. This field can only be updated on `draft` invoices.
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.
+ """
+ default_source: NotRequired["Literal['']|str"]
+ """
+ ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.
+ """
+ default_tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates that will apply to any line item that does not have `tax_rates` set. Pass an empty string to remove previously-defined tax rates.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.
+ """
+ discounts: NotRequired["Literal['']|List[InvoiceUpdateParamsDiscount]"]
+ """
+ The discounts that will apply to the invoice. Pass an empty string to remove previously-defined discounts.
+ """
+ due_date: NotRequired[int]
+ """
+ The date on which payment for this invoice is due. Only valid for invoices where `collection_method=send_invoice`. This field can only be updated on `draft` invoices.
+ """
+ effective_at: NotRequired["Literal['']|int"]
+ """
+ The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ footer: NotRequired[str]
+ """
+ Footer to be displayed on the invoice.
+ """
+ issuer: NotRequired["InvoiceUpdateParamsIssuer"]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ number: NotRequired["Literal['']|str"]
+ """
+ Set the number for this invoice. If no number is present then a number will be assigned automatically when the invoice is finalized. In many markets, regulations require invoices to be unique, sequential and / or gapless. You are responsible for ensuring this is true across all your different invoicing systems in the event that you edit the invoice number using our API. If you use only Stripe for your invoices and do not change invoice numbers, Stripe handles this aspect of compliance for you automatically.
+ """
+ on_behalf_of: NotRequired["Literal['']|str"]
+ """
+ The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
+ """
+ payment_settings: NotRequired["InvoiceUpdateParamsPaymentSettings"]
+ """
+ Configuration settings for the PaymentIntent that is generated when the invoice is finalized.
+ """
+ rendering: NotRequired["InvoiceUpdateParamsRendering"]
+ """
+ The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.
+ """
+ shipping_cost: NotRequired["Literal['']|InvoiceUpdateParamsShippingCost"]
+ """
+ Settings for the cost of shipping for this invoice.
+ """
+ shipping_details: NotRequired[
+ "Literal['']|InvoiceUpdateParamsShippingDetails"
+ ]
+ """
+ Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ Extra information about a charge for the customer's credit card statement. It must contain at least one letter. If not specified and this invoice is part of a subscription, the default `statement_descriptor` will be set to the first subscription item's product's `statement_descriptor`.
+ """
+ transfer_data: NotRequired["Literal['']|InvoiceUpdateParamsTransferData"]
+ """
+ If specified, the funds from the invoice will be transferred to the destination and the ID of the resulting transfer will be found on the invoice's charge. This will be unset if you POST an empty value.
+ """
+
+
+class InvoiceUpdateParamsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Whether Stripe automatically computes tax on this invoice. Note that incompatible invoice items (invoice items with manually specified [tax rates](https://stripe.com/docs/api/tax_rates), negative amounts, or `tax_behavior=unspecified`) cannot be added to automatic tax invoices.
+ """
+ liability: NotRequired["InvoiceUpdateParamsAutomaticTaxLiability"]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class InvoiceUpdateParamsAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class InvoiceUpdateParamsCustomField(TypedDict):
+ name: str
+ """
+ The name of the custom field. This may be up to 40 characters.
+ """
+ value: str
+ """
+ The value of the custom field. This may be up to 140 characters.
+ """
+
+
+class InvoiceUpdateParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class InvoiceUpdateParamsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class InvoiceUpdateParamsPaymentSettings(TypedDict):
+ default_mandate: NotRequired["Literal['']|str"]
+ """
+ ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the invoice's default_payment_method or default_source, if set.
+ """
+ payment_method_options: NotRequired[
+ "InvoiceUpdateParamsPaymentSettingsPaymentMethodOptions"
+ ]
+ """
+ Payment-method-specific configuration to provide to the invoice's PaymentIntent.
+ """
+ payment_method_types: NotRequired[
+ "Literal['']|List[Literal['ach_credit_transfer', 'ach_debit', 'acss_debit', 'affirm', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'jp_credit_transfer', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'link', 'multibanco', 'naver_pay', 'nz_bank_account', 'p24', 'payco', 'paynow', 'paypal', 'promptpay', 'revolut_pay', 'sepa_credit_transfer', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
+ ]
+ """
+ The list of payment method types (e.g. card) to provide to the invoice's PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice's default payment method, the subscription's default payment method, the customer's default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice).
+ """
+
+
+class InvoiceUpdateParamsPaymentSettingsPaymentMethodOptions(TypedDict):
+ acss_debit: NotRequired[
+ "Literal['']|InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebit"
+ ]
+ """
+ If paying by `acss_debit`, this sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice's PaymentIntent.
+ """
+ bancontact: NotRequired[
+ "Literal['']|InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsBancontact"
+ ]
+ """
+ If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the invoice's PaymentIntent.
+ """
+ card: NotRequired[
+ "Literal['']|InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsCard"
+ ]
+ """
+ If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the invoice's PaymentIntent.
+ """
+ customer_balance: NotRequired[
+ "Literal['']|InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance"
+ ]
+ """
+ If paying by `customer_balance`, this sub-hash contains details about the Bank transfer payment method options to pass to the invoice's PaymentIntent.
+ """
+ konbini: NotRequired[
+ "Literal['']|InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsKonbini"
+ ]
+ """
+ If paying by `konbini`, this sub-hash contains details about the Konbini payment method options to pass to the invoice's PaymentIntent.
+ """
+ sepa_debit: NotRequired[
+ "Literal['']|InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsSepaDebit"
+ ]
+ """
+ If paying by `sepa_debit`, this sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice's PaymentIntent.
+ """
+ us_bank_account: NotRequired[
+ "Literal['']|InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ If paying by `us_bank_account`, this sub-hash contains details about the ACH direct debit payment method options to pass to the invoice's PaymentIntent.
+ """
+
+
+class InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebit(
+ TypedDict,
+):
+ mandate_options: NotRequired[
+ "InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Verification method for the intent
+ """
+
+
+class InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions(
+ TypedDict,
+):
+ transaction_type: NotRequired[Literal["business", "personal"]]
+ """
+ Transaction type of the mandate.
+ """
+
+
+class InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsBancontact(
+ TypedDict,
+):
+ preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
+ """
+ Preferred language of the Bancontact authorization page that the customer is redirected to.
+ """
+
+
+class InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsCard(TypedDict):
+ installments: NotRequired[
+ "InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsCardInstallments"
+ ]
+ """
+ Installment configuration for payments attempted on this invoice.
+
+ For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
+ """
+ request_three_d_secure: NotRequired[
+ Literal["any", "automatic", "challenge"]
+ ]
+ """
+ We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
+ """
+
+
+class InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsCardInstallments(
+ TypedDict,
+):
+ enabled: NotRequired[bool]
+ """
+ Setting to true enables installments for this invoice.
+ Setting to false will prevent any selected plan from applying to a payment.
+ """
+ plan: NotRequired[
+ "Literal['']|InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsCardInstallmentsPlan"
+ ]
+ """
+ The selected installment plan to use for this invoice.
+ """
+
+
+class InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsCardInstallmentsPlan(
+ TypedDict,
+):
+ count: NotRequired[int]
+ """
+ For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
+ """
+ interval: NotRequired[Literal["month"]]
+ """
+ For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
+ One of `month`.
+ """
+ type: Literal["bonus", "fixed_count", "revolving"]
+ """
+ Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
+ """
+
+
+class InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance(
+ TypedDict,
+):
+ bank_transfer: NotRequired[
+ "InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer"
+ ]
+ """
+ Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
+ """
+ funding_type: NotRequired[str]
+ """
+ The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
+ """
+
+
+class InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer(
+ TypedDict,
+):
+ eu_bank_transfer: NotRequired[
+ "InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
+ ]
+ """
+ Configuration for eu_bank_transfer funding type.
+ """
+ type: NotRequired[str]
+ """
+ The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
+ """
+
+
+class InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
+ TypedDict,
+):
+ country: str
+ """
+ The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
+ """
+
+
+class InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsKonbini(TypedDict):
+ pass
+
+
+class InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsSepaDebit(
+ TypedDict,
+):
+ pass
+
+
+class InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount(
+ TypedDict,
+):
+ financial_connections: NotRequired[
+ "InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections"
+ ]
+ """
+ Additional fields for Financial Connections Session creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Verification method for the intent
+ """
+
+
+class InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections(
+ TypedDict,
+):
+ filters: NotRequired[
+ "InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
+ ]
+ """
+ Provide filters for the linked accounts that the customer can select for the payment method.
+ """
+ permissions: NotRequired[
+ List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ ]
+ """
+ The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+
+
+class InvoiceUpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
+ TypedDict,
+):
+ account_subcategories: NotRequired[List[Literal["checking", "savings"]]]
+ """
+ The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
+ """
+
+
+class InvoiceUpdateParamsRendering(TypedDict):
+ amount_tax_display: NotRequired[
+ "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
+ ]
+ """
+ How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
+ """
+ pdf: NotRequired["InvoiceUpdateParamsRenderingPdf"]
+ """
+ Invoice pdf rendering options
+ """
+ template: NotRequired[str]
+ """
+ ID of the invoice rendering template to use for this invoice.
+ """
+ template_version: NotRequired["Literal['']|int"]
+ """
+ The specific version of invoice rendering template to use for this invoice.
+ """
+
+
+class InvoiceUpdateParamsRenderingPdf(TypedDict):
+ page_size: NotRequired[Literal["a4", "auto", "letter"]]
+ """
+ Page size for invoice PDF. Can be set to `a4`, `letter`, or `auto`.
+ If set to `auto`, invoice PDF page size defaults to `a4` for customers with
+ Japanese locale and `letter` for customers with other locales.
+ """
+
+
+class InvoiceUpdateParamsShippingCost(TypedDict):
+ shipping_rate: NotRequired[str]
+ """
+ The ID of the shipping rate to use for this order.
+ """
+ shipping_rate_data: NotRequired[
+ "InvoiceUpdateParamsShippingCostShippingRateData"
+ ]
+ """
+ Parameters to create a new ad-hoc shipping rate for this order.
+ """
+
+
+class InvoiceUpdateParamsShippingCostShippingRateData(TypedDict):
+ delivery_estimate: NotRequired[
+ "InvoiceUpdateParamsShippingCostShippingRateDataDeliveryEstimate"
+ ]
+ """
+ The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
+ """
+ display_name: str
+ """
+ The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
+ """
+ fixed_amount: NotRequired[
+ "InvoiceUpdateParamsShippingCostShippingRateDataFixedAmount"
+ ]
+ """
+ Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
+ """
+ type: NotRequired[Literal["fixed_amount"]]
+ """
+ The type of calculation to use on the shipping rate.
+ """
+
+
+class InvoiceUpdateParamsShippingCostShippingRateDataDeliveryEstimate(
+ TypedDict,
+):
+ maximum: NotRequired[
+ "InvoiceUpdateParamsShippingCostShippingRateDataDeliveryEstimateMaximum"
+ ]
+ """
+ The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
+ """
+ minimum: NotRequired[
+ "InvoiceUpdateParamsShippingCostShippingRateDataDeliveryEstimateMinimum"
+ ]
+ """
+ The lower bound of the estimated range. If empty, represents no lower bound.
+ """
+
+
+class InvoiceUpdateParamsShippingCostShippingRateDataDeliveryEstimateMaximum(
+ TypedDict,
+):
+ unit: Literal["business_day", "day", "hour", "month", "week"]
+ """
+ A unit of time.
+ """
+ value: int
+ """
+ Must be greater than 0.
+ """
+
+
+class InvoiceUpdateParamsShippingCostShippingRateDataDeliveryEstimateMinimum(
+ TypedDict,
+):
+ unit: Literal["business_day", "day", "hour", "month", "week"]
+ """
+ A unit of time.
+ """
+ value: int
+ """
+ Must be greater than 0.
+ """
+
+
+class InvoiceUpdateParamsShippingCostShippingRateDataFixedAmount(TypedDict):
+ amount: int
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ currency_options: NotRequired[
+ Dict[
+ str,
+ "InvoiceUpdateParamsShippingCostShippingRateDataFixedAmountCurrencyOptions",
+ ]
+ ]
+ """
+ Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+
+
+class InvoiceUpdateParamsShippingCostShippingRateDataFixedAmountCurrencyOptions(
+ TypedDict,
+):
+ amount: int
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
+
+
+class InvoiceUpdateParamsShippingDetails(TypedDict):
+ address: "InvoiceUpdateParamsShippingDetailsAddress"
+ """
+ Shipping address
+ """
+ name: str
+ """
+ Recipient name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Recipient phone (including extension)
+ """
+
+
+class InvoiceUpdateParamsShippingDetailsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class InvoiceUpdateParamsTransferData(TypedDict):
+ amount: NotRequired[int]
+ """
+ The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
diff --git a/stripe/params/_invoice_void_invoice_params.py b/stripe/params/_invoice_void_invoice_params.py
new file mode 100644
index 000000000..d909a51ec
--- /dev/null
+++ b/stripe/params/_invoice_void_invoice_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InvoiceVoidInvoiceParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_mandate_retrieve_params.py b/stripe/params/_mandate_retrieve_params.py
new file mode 100644
index 000000000..5fafa6630
--- /dev/null
+++ b/stripe/params/_mandate_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class MandateRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payment_intent_apply_customer_balance_params.py b/stripe/params/_payment_intent_apply_customer_balance_params.py
new file mode 100644
index 000000000..f3f3b05cc
--- /dev/null
+++ b/stripe/params/_payment_intent_apply_customer_balance_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentIntentApplyCustomerBalanceParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ Amount that you intend to apply to this PaymentIntent from the customer's cash balance. If the PaymentIntent was created by an Invoice, the full amount of the PaymentIntent is applied regardless of this parameter.
+
+ A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (for example, 100 cents to charge 1 USD or 100 to charge 100 JPY, a zero-decimal currency). The maximum amount is the amount of the PaymentIntent.
+
+ When you omit the amount, it defaults to the remaining amount requested on the PaymentIntent.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payment_intent_cancel_params.py b/stripe/params/_payment_intent_cancel_params.py
new file mode 100644
index 000000000..427711c1d
--- /dev/null
+++ b/stripe/params/_payment_intent_cancel_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class PaymentIntentCancelParams(RequestOptions):
+ cancellation_reason: NotRequired[
+ Literal[
+ "abandoned", "duplicate", "fraudulent", "requested_by_customer"
+ ]
+ ]
+ """
+ Reason for canceling this PaymentIntent. Possible values are: `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payment_intent_capture_params.py b/stripe/params/_payment_intent_capture_params.py
new file mode 100644
index 000000000..500390e05
--- /dev/null
+++ b/stripe/params/_payment_intent_capture_params.py
@@ -0,0 +1,50 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PaymentIntentCaptureParams(RequestOptions):
+ amount_to_capture: NotRequired[int]
+ """
+ The amount to capture from the PaymentIntent, which must be less than or equal to the original amount. Defaults to the full `amount_capturable` if it's not provided.
+ """
+ application_fee_amount: NotRequired[int]
+ """
+ The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ final_capture: NotRequired[bool]
+ """
+ Defaults to `true`. When capturing a PaymentIntent, setting `final_capture` to `false` notifies Stripe to not release the remaining uncaptured funds to make sure that they're captured in future requests. You can only use this setting when [multicapture](https://stripe.com/docs/payments/multicapture) is available for PaymentIntents.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
+
+ Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
+ """
+ statement_descriptor_suffix: NotRequired[str]
+ """
+ Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
+ """
+ transfer_data: NotRequired["PaymentIntentCaptureParamsTransferData"]
+ """
+ The parameters that you can use to automatically create a transfer after the payment
+ is captured. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+
+
+class PaymentIntentCaptureParamsTransferData(TypedDict):
+ amount: NotRequired[int]
+ """
+ The amount that will be transferred automatically when a charge succeeds.
+ """
diff --git a/stripe/params/_payment_intent_confirm_params.py b/stripe/params/_payment_intent_confirm_params.py
new file mode 100644
index 000000000..c1b274cf1
--- /dev/null
+++ b/stripe/params/_payment_intent_confirm_params.py
@@ -0,0 +1,2890 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PaymentIntentConfirmParams(RequestOptions):
+ capture_method: NotRequired[
+ Literal["automatic", "automatic_async", "manual"]
+ ]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ confirmation_token: NotRequired[str]
+ """
+ ID of the ConfirmationToken used to confirm this PaymentIntent.
+
+ If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
+ """
+ error_on_requires_action: NotRequired[bool]
+ """
+ Set to `true` to fail the payment attempt if the PaymentIntent transitions into `requires_action`. This parameter is intended for simpler integrations that do not handle customer actions, like [saving cards without authentication](https://stripe.com/docs/payments/save-card-without-authentication).
+ """
+ excluded_payment_method_types: NotRequired[
+ "Literal['']|List[Literal['acss_debit', 'affirm', 'afterpay_clearpay', 'alipay', 'alma', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'billie', 'blik', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'mb_way', 'mobilepay', 'multibanco', 'naver_pay', 'nz_bank_account', 'oxxo', 'p24', 'pay_by_bank', 'payco', 'paynow', 'paypal', 'pix', 'promptpay', 'revolut_pay', 'samsung_pay', 'satispay', 'sepa_debit', 'sofort', 'swish', 'twint', 'us_bank_account', 'wechat_pay', 'zip']]"
+ ]
+ """
+ The list of payment method types to exclude from use with this payment.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ mandate: NotRequired[str]
+ """
+ ID of the mandate that's used for this payment.
+ """
+ mandate_data: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsMandateData"
+ ]
+ off_session: NotRequired["bool|Literal['one_off', 'recurring']"]
+ """
+ Set to `true` to indicate that the customer isn't in your checkout flow during this payment attempt and can't authenticate. Use this parameter in scenarios where you collect card details and [charge them later](https://stripe.com/docs/payments/cards/charging-saved-cards).
+ """
+ payment_method: NotRequired[str]
+ """
+ ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods/transitioning#compatibility) object) to attach to this PaymentIntent.
+ If the payment method is attached to a Customer, it must match the [customer](https://stripe.com/docs/api#create_payment_intent-customer) that is set on this PaymentIntent.
+ """
+ payment_method_data: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodData"
+ ]
+ """
+ If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
+ in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
+ property on the PaymentIntent.
+ """
+ payment_method_options: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptions"
+ ]
+ """
+ Payment method-specific configuration for this PaymentIntent.
+ """
+ payment_method_types: NotRequired[List[str]]
+ """
+ The list of payment method types (for example, a card) that this PaymentIntent can use. Use `automatic_payment_methods` to manage payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
+ """
+ radar_options: NotRequired["PaymentIntentConfirmParamsRadarOptions"]
+ """
+ Options to configure Radar. Learn more about [Radar Sessions](https://stripe.com/docs/radar/radar-session).
+ """
+ receipt_email: NotRequired["Literal['']|str"]
+ """
+ Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
+ """
+ return_url: NotRequired[str]
+ """
+ The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site.
+ If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
+ This parameter is only used for cards and other redirect-based payment methods.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ shipping: NotRequired["Literal['']|PaymentIntentConfirmParamsShipping"]
+ """
+ Shipping information for this PaymentIntent.
+ """
+ use_stripe_sdk: NotRequired[bool]
+ """
+ Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
+ """
+
+
+class PaymentIntentConfirmParamsMandateData(TypedDict):
+ customer_acceptance: NotRequired[
+ "PaymentIntentConfirmParamsMandateDataCustomerAcceptance"
+ ]
+ """
+ This hash contains details about the customer acceptance of the Mandate.
+ """
+
+
+class PaymentIntentConfirmParamsMandateDataCustomerAcceptance(TypedDict):
+ accepted_at: NotRequired[int]
+ """
+ The time at which the customer accepted the Mandate.
+ """
+ offline: NotRequired[
+ "PaymentIntentConfirmParamsMandateDataCustomerAcceptanceOffline"
+ ]
+ """
+ If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
+ """
+ online: NotRequired[
+ "PaymentIntentConfirmParamsMandateDataCustomerAcceptanceOnline"
+ ]
+ """
+ If this is a Mandate accepted online, this hash contains details about the online acceptance.
+ """
+ type: Literal["offline", "online"]
+ """
+ The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
+ """
+
+
+class PaymentIntentConfirmParamsMandateDataCustomerAcceptanceOffline(
+ TypedDict
+):
+ pass
+
+
+class PaymentIntentConfirmParamsMandateDataCustomerAcceptanceOnline(TypedDict):
+ ip_address: NotRequired[str]
+ """
+ The IP address from which the Mandate was accepted by the customer.
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the Mandate was accepted by the customer.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodData(TypedDict):
+ acss_debit: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataAcssDebit"
+ ]
+ """
+ If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
+ """
+ affirm: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataAffirm"]
+ """
+ If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
+ """
+ afterpay_clearpay: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataAfterpayClearpay"
+ ]
+ """
+ If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
+ """
+ alipay: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataAlipay"]
+ """
+ If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
+ """
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
+ """
+ alma: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataAlma"]
+ """
+ If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
+ """
+ amazon_pay: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataAmazonPay"
+ ]
+ """
+ If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
+ """
+ au_becs_debit: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataAuBecsDebit"
+ ]
+ """
+ If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
+ """
+ bacs_debit: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
+ """
+ bancontact: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataBancontact"
+ ]
+ """
+ If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
+ """
+ billie: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataBillie"]
+ """
+ If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
+ """
+ billing_details: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataBillingDetails"
+ ]
+ """
+ Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+ """
+ blik: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataBlik"]
+ """
+ If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
+ """
+ boleto: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataBoleto"]
+ """
+ If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
+ """
+ cashapp: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataCashapp"]
+ """
+ If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
+ """
+ crypto: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataCrypto"]
+ """
+ If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
+ """
+ customer_balance: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataCustomerBalance"
+ ]
+ """
+ If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
+ """
+ eps: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataEps"]
+ """
+ If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
+ """
+ fpx: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataFpx"]
+ """
+ If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
+ """
+ giropay: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataGiropay"]
+ """
+ If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
+ """
+ grabpay: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataGrabpay"]
+ """
+ If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
+ """
+ ideal: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataIdeal"]
+ """
+ If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
+ """
+ interac_present: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataInteracPresent"
+ ]
+ """
+ If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
+ """
+ kakao_pay: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataKakaoPay"
+ ]
+ """
+ If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
+ """
+ klarna: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataKlarna"]
+ """
+ If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
+ """
+ konbini: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataKonbini"]
+ """
+ If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
+ """
+ kr_card: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataKrCard"]
+ """
+ If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
+ """
+ link: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataLink"]
+ """
+ If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
+ """
+ mb_way: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataMbWay"]
+ """
+ If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ mobilepay: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataMobilepay"
+ ]
+ """
+ If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
+ """
+ multibanco: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataMultibanco"
+ ]
+ """
+ If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
+ """
+ naver_pay: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataNaverPay"
+ ]
+ """
+ If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
+ """
+ nz_bank_account: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataNzBankAccount"
+ ]
+ """
+ If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
+ """
+ oxxo: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataOxxo"]
+ """
+ If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
+ """
+ p24: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataP24"]
+ """
+ If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
+ """
+ pay_by_bank: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataPayByBank"
+ ]
+ """
+ If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
+ """
+ payco: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataPayco"]
+ """
+ If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
+ """
+ paynow: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataPaynow"]
+ """
+ If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
+ """
+ paypal: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataPaypal"]
+ """
+ If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
+ """
+ pix: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataPix"]
+ """
+ If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
+ """
+ promptpay: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataPromptpay"
+ ]
+ """
+ If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
+ """
+ radar_options: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataRadarOptions"
+ ]
+ """
+ Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
+ """
+ revolut_pay: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataRevolutPay"
+ ]
+ """
+ If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
+ """
+ samsung_pay: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataSamsungPay"
+ ]
+ """
+ If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
+ """
+ satispay: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataSatispay"
+ ]
+ """
+ If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
+ """
+ sepa_debit: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
+ """
+ sofort: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataSofort"]
+ """
+ If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
+ """
+ swish: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataSwish"]
+ """
+ If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
+ """
+ twint: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataTwint"]
+ """
+ If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
+ """
+ type: Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "link",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ """
+ The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
+ """
+ us_bank_account: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataUsBankAccount"
+ ]
+ """
+ If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
+ """
+ wechat_pay: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodDataWechatPay"
+ ]
+ """
+ If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
+ """
+ zip: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataZip"]
+ """
+ If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataAcssDebit(TypedDict):
+ account_number: str
+ """
+ Customer's bank account number.
+ """
+ institution_number: str
+ """
+ Institution number of the customer's bank.
+ """
+ transit_number: str
+ """
+ Transit number of the customer's bank.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataAffirm(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataAfterpayClearpay(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataAlipay(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataAlma(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataAmazonPay(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataAuBecsDebit(TypedDict):
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bsb_number: str
+ """
+ Bank-State-Branch number of the bank account.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataBacsDebit(TypedDict):
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account that the funds will be debited from.
+ """
+ sort_code: NotRequired[str]
+ """
+ Sort code of the bank account. (e.g., `10-20-30`)
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataBancontact(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataBillie(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataBillingDetails(TypedDict):
+ address: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodDataBillingDetailsAddress"
+ ]
+ """
+ Billing address.
+ """
+ email: NotRequired["Literal['']|str"]
+ """
+ Email address.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Full name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Billing phone number (including extension).
+ """
+ tax_id: NotRequired[str]
+ """
+ Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataBillingDetailsAddress(
+ TypedDict,
+):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataBlik(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataBoleto(TypedDict):
+ tax_id: str
+ """
+ The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataCashapp(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataCrypto(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataCustomerBalance(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataEps(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "arzte_und_apotheker_bank",
+ "austrian_anadi_bank_ag",
+ "bank_austria",
+ "bankhaus_carl_spangler",
+ "bankhaus_schelhammer_und_schattera_ag",
+ "bawag_psk_ag",
+ "bks_bank_ag",
+ "brull_kallmus_bank_ag",
+ "btv_vier_lander_bank",
+ "capital_bank_grawe_gruppe_ag",
+ "deutsche_bank_ag",
+ "dolomitenbank",
+ "easybank_ag",
+ "erste_bank_und_sparkassen",
+ "hypo_alpeadriabank_international_ag",
+ "hypo_bank_burgenland_aktiengesellschaft",
+ "hypo_noe_lb_fur_niederosterreich_u_wien",
+ "hypo_oberosterreich_salzburg_steiermark",
+ "hypo_tirol_bank_ag",
+ "hypo_vorarlberg_bank_ag",
+ "marchfelder_bank",
+ "oberbank_ag",
+ "raiffeisen_bankengruppe_osterreich",
+ "schoellerbank_ag",
+ "sparda_bank_wien",
+ "volksbank_gruppe",
+ "volkskreditbank_ag",
+ "vr_bank_braunau",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataFpx(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type for FPX transaction
+ """
+ bank: Literal[
+ "affin_bank",
+ "agrobank",
+ "alliance_bank",
+ "ambank",
+ "bank_islam",
+ "bank_muamalat",
+ "bank_of_china",
+ "bank_rakyat",
+ "bsn",
+ "cimb",
+ "deutsche_bank",
+ "hong_leong_bank",
+ "hsbc",
+ "kfh",
+ "maybank2e",
+ "maybank2u",
+ "ocbc",
+ "pb_enterprise",
+ "public_bank",
+ "rhb",
+ "standard_chartered",
+ "uob",
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataGiropay(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataGrabpay(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataIdeal(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "abn_amro",
+ "asn_bank",
+ "bunq",
+ "buut",
+ "handelsbanken",
+ "ing",
+ "knab",
+ "moneyou",
+ "n26",
+ "nn",
+ "rabobank",
+ "regiobank",
+ "revolut",
+ "sns_bank",
+ "triodos_bank",
+ "van_lanschot",
+ "yoursafe",
+ ]
+ ]
+ """
+ The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataInteracPresent(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataKakaoPay(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataKlarna(TypedDict):
+ dob: NotRequired["PaymentIntentConfirmParamsPaymentMethodDataKlarnaDob"]
+ """
+ Customer's date of birth
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataKlarnaDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataKonbini(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataKrCard(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataLink(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataMbWay(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataMobilepay(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataMultibanco(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataNaverPay(TypedDict):
+ funding: NotRequired[Literal["card", "points"]]
+ """
+ Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataNzBankAccount(TypedDict):
+ account_holder_name: NotRequired[str]
+ """
+ The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
+ """
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bank_code: str
+ """
+ The numeric code for the bank account's bank.
+ """
+ branch_code: str
+ """
+ The numeric code for the bank account's bank branch.
+ """
+ reference: NotRequired[str]
+ suffix: str
+ """
+ The suffix of the bank account number.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataOxxo(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataP24(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "alior_bank",
+ "bank_millennium",
+ "bank_nowy_bfg_sa",
+ "bank_pekao_sa",
+ "banki_spbdzielcze",
+ "blik",
+ "bnp_paribas",
+ "boz",
+ "citi_handlowy",
+ "credit_agricole",
+ "envelobank",
+ "etransfer_pocztowy24",
+ "getin_bank",
+ "ideabank",
+ "ing",
+ "inteligo",
+ "mbank_mtransfer",
+ "nest_przelew",
+ "noble_pay",
+ "pbac_z_ipko",
+ "plus_bank",
+ "santander_przelew24",
+ "tmobile_usbugi_bankowe",
+ "toyota_bank",
+ "velobank",
+ "volkswagen_bank",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataPayByBank(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataPayco(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataPaynow(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataPaypal(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataPix(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataPromptpay(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataRadarOptions(TypedDict):
+ session: NotRequired[str]
+ """
+ A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataRevolutPay(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataSamsungPay(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataSatispay(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataSepaDebit(TypedDict):
+ iban: str
+ """
+ IBAN of the bank account.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataSofort(TypedDict):
+ country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
+ """
+ Two-letter ISO code representing the country the bank account is located in.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataSwish(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataTwint(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataUsBankAccount(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type: individual or company.
+ """
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account.
+ """
+ account_type: NotRequired[Literal["checking", "savings"]]
+ """
+ Account type: checkings or savings. Defaults to checking if omitted.
+ """
+ financial_connections_account: NotRequired[str]
+ """
+ The ID of a Financial Connections Account to use as a payment method.
+ """
+ routing_number: NotRequired[str]
+ """
+ Routing number of the bank account.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataWechatPay(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodDataZip(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptions(TypedDict):
+ acss_debit: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsAcssDebit"
+ ]
+ """
+ If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
+ """
+ affirm: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsAffirm"
+ ]
+ """
+ If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
+ """
+ afterpay_clearpay: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsAfterpayClearpay"
+ ]
+ """
+ If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
+ """
+ alipay: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsAlipay"
+ ]
+ """
+ If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
+ """
+ alma: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsAlma"
+ ]
+ """
+ If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
+ """
+ amazon_pay: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsAmazonPay"
+ ]
+ """
+ If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
+ """
+ au_becs_debit: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsAuBecsDebit"
+ ]
+ """
+ If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
+ """
+ bacs_debit: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
+ """
+ bancontact: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsBancontact"
+ ]
+ """
+ If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
+ """
+ billie: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsBillie"
+ ]
+ """
+ If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
+ """
+ blik: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsBlik"
+ ]
+ """
+ If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
+ """
+ boleto: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsBoleto"
+ ]
+ """
+ If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
+ """
+ card: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsCard"
+ ]
+ """
+ Configuration for any card payments attempted on this PaymentIntent.
+ """
+ card_present: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsCardPresent"
+ ]
+ """
+ If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
+ """
+ cashapp: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsCashapp"
+ ]
+ """
+ If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
+ """
+ crypto: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsCrypto"
+ ]
+ """
+ If this is a `crypto` PaymentMethod, this sub-hash contains details about the Crypto payment method options.
+ """
+ customer_balance: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsCustomerBalance"
+ ]
+ """
+ If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
+ """
+ eps: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsEps"
+ ]
+ """
+ If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
+ """
+ fpx: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsFpx"
+ ]
+ """
+ If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
+ """
+ giropay: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsGiropay"
+ ]
+ """
+ If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
+ """
+ grabpay: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsGrabpay"
+ ]
+ """
+ If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
+ """
+ ideal: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsIdeal"
+ ]
+ """
+ If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
+ """
+ interac_present: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsInteracPresent"
+ ]
+ """
+ If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
+ """
+ kakao_pay: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsKakaoPay"
+ ]
+ """
+ If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
+ """
+ klarna: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsKlarna"
+ ]
+ """
+ If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
+ """
+ konbini: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsKonbini"
+ ]
+ """
+ If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
+ """
+ kr_card: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsKrCard"
+ ]
+ """
+ If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
+ """
+ link: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsLink"
+ ]
+ """
+ If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
+ """
+ mb_way: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsMbWay"
+ ]
+ """
+ If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
+ """
+ mobilepay: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsMobilepay"
+ ]
+ """
+ If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
+ """
+ multibanco: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsMultibanco"
+ ]
+ """
+ If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
+ """
+ naver_pay: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsNaverPay"
+ ]
+ """
+ If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
+ """
+ nz_bank_account: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsNzBankAccount"
+ ]
+ """
+ If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
+ """
+ oxxo: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsOxxo"
+ ]
+ """
+ If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
+ """
+ p24: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsP24"
+ ]
+ """
+ If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
+ """
+ pay_by_bank: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsPayByBank"
+ ]
+ """
+ If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
+ """
+ payco: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsPayco"
+ ]
+ """
+ If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
+ """
+ paynow: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsPaynow"
+ ]
+ """
+ If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
+ """
+ paypal: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsPaypal"
+ ]
+ """
+ If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
+ """
+ pix: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsPix"
+ ]
+ """
+ If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
+ """
+ promptpay: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsPromptpay"
+ ]
+ """
+ If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
+ """
+ revolut_pay: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsRevolutPay"
+ ]
+ """
+ If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
+ """
+ samsung_pay: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsSamsungPay"
+ ]
+ """
+ If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
+ """
+ satispay: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsSatispay"
+ ]
+ """
+ If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
+ """
+ sepa_debit: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
+ """
+ sofort: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsSofort"
+ ]
+ """
+ If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
+ """
+ swish: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsSwish"
+ ]
+ """
+ If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
+ """
+ twint: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsTwint"
+ ]
+ """
+ If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
+ """
+ us_bank_account: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
+ """
+ wechat_pay: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsWechatPay"
+ ]
+ """
+ If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
+ """
+ zip: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsZip"
+ ]
+ """
+ If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsAcssDebit(TypedDict):
+ mandate_options: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsAcssDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsAcssDebitMandateOptions(
+ TypedDict,
+):
+ custom_mandate_url: NotRequired["Literal['']|str"]
+ """
+ A URL for custom mandate text to render during confirmation step.
+ The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
+ or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
+ """
+ interval_description: NotRequired[str]
+ """
+ Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
+ """
+ payment_schedule: NotRequired[Literal["combined", "interval", "sporadic"]]
+ """
+ Payment schedule for the mandate.
+ """
+ transaction_type: NotRequired[Literal["business", "personal"]]
+ """
+ Transaction type of the mandate.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsAffirm(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ preferred_locale: NotRequired[str]
+ """
+ Preferred language of the Affirm authorization page that the customer is redirected to.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsAfterpayClearpay(
+ TypedDict
+):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ reference: NotRequired[str]
+ """
+ An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
+ This field differs from the statement descriptor and item name.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsAlipay(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsAlma(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsAmazonPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsAuBecsDebit(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsBacsDebit(TypedDict):
+ mandate_options: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsBacsDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsBacsDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsBancontact(TypedDict):
+ preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
+ """
+ Preferred language of the Bancontact authorization page that the customer is redirected to.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsBillie(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsBlik(TypedDict):
+ code: NotRequired[str]
+ """
+ The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
+ """
+ setup_future_usage: NotRequired["Literal['']|Literal['none']"]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsBoleto(TypedDict):
+ expires_after_days: NotRequired[int]
+ """
+ The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsCard(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ cvc_token: NotRequired[str]
+ """
+ A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
+ """
+ installments: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsCardInstallments"
+ ]
+ """
+ Installment configuration for payments attempted on this PaymentIntent.
+
+ For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
+ """
+ mandate_options: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsCardMandateOptions"
+ ]
+ """
+ Configuration options for setting up an eMandate for cards issued in India.
+ """
+ moto: NotRequired[bool]
+ """
+ When specified, this parameter indicates that a transaction will be marked
+ as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
+ parameter can only be provided during confirmation.
+ """
+ network: NotRequired[
+ Literal[
+ "amex",
+ "cartes_bancaires",
+ "diners",
+ "discover",
+ "eftpos_au",
+ "girocard",
+ "interac",
+ "jcb",
+ "link",
+ "mastercard",
+ "unionpay",
+ "unknown",
+ "visa",
+ ]
+ ]
+ """
+ Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
+ """
+ request_extended_authorization: NotRequired[
+ Literal["if_available", "never"]
+ ]
+ """
+ Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
+ """
+ request_incremental_authorization: NotRequired[
+ Literal["if_available", "never"]
+ ]
+ """
+ Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
+ """
+ request_multicapture: NotRequired[Literal["if_available", "never"]]
+ """
+ Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
+ """
+ request_overcapture: NotRequired[Literal["if_available", "never"]]
+ """
+ Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
+ """
+ request_three_d_secure: NotRequired[
+ Literal["any", "automatic", "challenge"]
+ ]
+ """
+ We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
+ """
+ require_cvc_recollection: NotRequired[bool]
+ """
+ When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ statement_descriptor_suffix_kana: NotRequired["Literal['']|str"]
+ """
+ Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that's set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
+ """
+ statement_descriptor_suffix_kanji: NotRequired["Literal['']|str"]
+ """
+ Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that's set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
+ """
+ three_d_secure: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsCardThreeDSecure"
+ ]
+ """
+ If 3D Secure authentication was performed with a third-party provider,
+ the authentication details to use for this payment.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsCardInstallments(
+ TypedDict
+):
+ enabled: NotRequired[bool]
+ """
+ Setting to true enables installments for this PaymentIntent.
+ This will cause the response to contain a list of available installment plans.
+ Setting to false will prevent any selected plan from applying to a charge.
+ """
+ plan: NotRequired[
+ "Literal['']|PaymentIntentConfirmParamsPaymentMethodOptionsCardInstallmentsPlan"
+ ]
+ """
+ The selected installment plan to use for this payment attempt.
+ This parameter can only be provided during confirmation.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsCardInstallmentsPlan(
+ TypedDict,
+):
+ count: NotRequired[int]
+ """
+ For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
+ """
+ interval: NotRequired[Literal["month"]]
+ """
+ For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
+ One of `month`.
+ """
+ type: Literal["bonus", "fixed_count", "revolving"]
+ """
+ Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsCardMandateOptions(
+ TypedDict,
+):
+ amount: int
+ """
+ Amount to be charged for future payments.
+ """
+ amount_type: Literal["fixed", "maximum"]
+ """
+ One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
+ """
+ description: NotRequired[str]
+ """
+ A description of the mandate or subscription that is meant to be displayed to the customer.
+ """
+ end_date: NotRequired[int]
+ """
+ End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
+ """
+ interval: Literal["day", "month", "sporadic", "week", "year"]
+ """
+ Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
+ """
+ reference: str
+ """
+ Unique identifier for the mandate or subscription.
+ """
+ start_date: int
+ """
+ Start date of the mandate or subscription. Start date should not be lesser than yesterday.
+ """
+ supported_types: NotRequired[List[Literal["india"]]]
+ """
+ Specifies the type of mandates supported. Possible values are `india`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsCardThreeDSecure(
+ TypedDict
+):
+ ares_trans_status: NotRequired[Literal["A", "C", "I", "N", "R", "U", "Y"]]
+ """
+ The `transStatus` returned from the card Issuer's ACS in the ARes.
+ """
+ cryptogram: str
+ """
+ The cryptogram, also known as the "authentication value" (AAV, CAVV or
+ AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
+ (Most 3D Secure providers will return the base64-encoded version, which
+ is what you should specify here.)
+ """
+ electronic_commerce_indicator: NotRequired[
+ Literal["01", "02", "05", "06", "07"]
+ ]
+ """
+ The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
+ provider and indicates what degree of authentication was performed.
+ """
+ exemption_indicator: NotRequired[Literal["low_risk", "none"]]
+ """
+ The exemption requested via 3DS and accepted by the issuer at authentication time.
+ """
+ network_options: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
+ ]
+ """
+ Network specific 3DS fields. Network specific arguments require an
+ explicit card brand choice. The parameter `payment_method_options.card.network``
+ must be populated accordingly
+ """
+ requestor_challenge_indicator: NotRequired[str]
+ """
+ The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
+ AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
+ """
+ transaction_id: str
+ """
+ For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
+ Transaction ID (dsTransID).
+ """
+ version: Literal["1.0.2", "2.1.0", "2.2.0"]
+ """
+ The version of 3D Secure that was performed.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
+ TypedDict,
+):
+ cartes_bancaires: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
+ ]
+ """
+ Cartes Bancaires-specific 3DS fields.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
+ TypedDict,
+):
+ cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
+ """
+ The cryptogram calculation algorithm used by the card Issuer's ACS
+ to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
+ messageExtension: CB-AVALGO
+ """
+ cb_exemption: NotRequired[str]
+ """
+ The exemption indicator returned from Cartes Bancaires in the ARes.
+ message extension: CB-EXEMPTION; string (4 characters)
+ This is a 3 byte bitmap (low significant byte first and most significant
+ bit first) that has been Base64 encoded
+ """
+ cb_score: NotRequired[int]
+ """
+ The risk score returned from Cartes Bancaires in the ARes.
+ message extension: CB-SCORE; numeric value 0-99
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsCardPresent(TypedDict):
+ request_extended_authorization: NotRequired[bool]
+ """
+ Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
+ """
+ request_incremental_authorization_support: NotRequired[bool]
+ """
+ Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
+ """
+ routing: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsCardPresentRouting"
+ ]
+ """
+ Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsCardPresentRouting(
+ TypedDict,
+):
+ requested_priority: NotRequired[Literal["domestic", "international"]]
+ """
+ Routing requested priority
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsCashapp(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsCrypto(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsCustomerBalance(TypedDict):
+ bank_transfer: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsCustomerBalanceBankTransfer"
+ ]
+ """
+ Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
+ """
+ funding_type: NotRequired[Literal["bank_transfer"]]
+ """
+ The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsCustomerBalanceBankTransfer(
+ TypedDict,
+):
+ eu_bank_transfer: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
+ ]
+ """
+ Configuration for the eu_bank_transfer funding type.
+ """
+ requested_address_types: NotRequired[
+ List[
+ Literal[
+ "aba", "iban", "sepa", "sort_code", "spei", "swift", "zengin"
+ ]
+ ]
+ ]
+ """
+ List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
+
+ Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
+ """
+ type: Literal[
+ "eu_bank_transfer",
+ "gb_bank_transfer",
+ "jp_bank_transfer",
+ "mx_bank_transfer",
+ "us_bank_transfer",
+ ]
+ """
+ The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
+ TypedDict,
+):
+ country: str
+ """
+ The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsEps(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsFpx(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsGiropay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsGrabpay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsIdeal(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsInteracPresent(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsKakaoPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsKlarna(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ on_demand: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsKlarnaOnDemand"
+ ]
+ """
+ On-demand details if setting up or charging an on-demand payment.
+ """
+ preferred_locale: NotRequired[
+ Literal[
+ "cs-CZ",
+ "da-DK",
+ "de-AT",
+ "de-CH",
+ "de-DE",
+ "el-GR",
+ "en-AT",
+ "en-AU",
+ "en-BE",
+ "en-CA",
+ "en-CH",
+ "en-CZ",
+ "en-DE",
+ "en-DK",
+ "en-ES",
+ "en-FI",
+ "en-FR",
+ "en-GB",
+ "en-GR",
+ "en-IE",
+ "en-IT",
+ "en-NL",
+ "en-NO",
+ "en-NZ",
+ "en-PL",
+ "en-PT",
+ "en-RO",
+ "en-SE",
+ "en-US",
+ "es-ES",
+ "es-US",
+ "fi-FI",
+ "fr-BE",
+ "fr-CA",
+ "fr-CH",
+ "fr-FR",
+ "it-CH",
+ "it-IT",
+ "nb-NO",
+ "nl-BE",
+ "nl-NL",
+ "pl-PL",
+ "pt-PT",
+ "ro-RO",
+ "sv-FI",
+ "sv-SE",
+ ]
+ ]
+ """
+ Preferred language of the Klarna authorization page that the customer is redirected to
+ """
+ setup_future_usage: NotRequired[
+ Literal["none", "off_session", "on_session"]
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ subscriptions: NotRequired[
+ "Literal['']|List[PaymentIntentConfirmParamsPaymentMethodOptionsKlarnaSubscription]"
+ ]
+ """
+ Subscription details if setting up or charging a subscription.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
+ average_amount: NotRequired[int]
+ """
+ Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ maximum_amount: NotRequired[int]
+ """
+ The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ minimum_amount: NotRequired[int]
+ """
+ The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
+ """
+ Interval at which the customer is making purchases
+ """
+ purchase_interval_count: NotRequired[int]
+ """
+ The number of `purchase_interval` between charges
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsKlarnaSubscription(
+ TypedDict,
+):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Unit of time between subscription charges.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
+ """
+ name: NotRequired[str]
+ """
+ Name for subscription.
+ """
+ next_billing: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
+ ]
+ """
+ Describes the upcoming charge for this subscription.
+ """
+ reference: str
+ """
+ A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
+ TypedDict,
+):
+ amount: int
+ """
+ The amount of the next charge for the subscription.
+ """
+ date: str
+ """
+ The date of the next charge for the subscription in YYYY-MM-DD format.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsKonbini(TypedDict):
+ confirmation_number: NotRequired["Literal['']|str"]
+ """
+ An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
+ """
+ expires_after_days: NotRequired["Literal['']|int"]
+ """
+ The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
+ """
+ expires_at: NotRequired["Literal['']|int"]
+ """
+ The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsKrCard(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsLink(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ persistent_token: NotRequired[str]
+ """
+ [Deprecated] This is a legacy parameter that no longer has any function.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsMbWay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsMobilepay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsMultibanco(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsNaverPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsNzBankAccount(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsOxxo(TypedDict):
+ expires_after_days: NotRequired[int]
+ """
+ The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsP24(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ tos_shown_and_accepted: NotRequired[bool]
+ """
+ Confirm that the payer has accepted the P24 terms and conditions.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsPayByBank(TypedDict):
+ pass
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsPayco(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsPaynow(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsPaypal(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ preferred_locale: NotRequired[
+ Literal[
+ "cs-CZ",
+ "da-DK",
+ "de-AT",
+ "de-DE",
+ "de-LU",
+ "el-GR",
+ "en-GB",
+ "en-US",
+ "es-ES",
+ "fi-FI",
+ "fr-BE",
+ "fr-FR",
+ "fr-LU",
+ "hu-HU",
+ "it-IT",
+ "nl-BE",
+ "nl-NL",
+ "pl-PL",
+ "pt-PT",
+ "sk-SK",
+ "sv-SE",
+ ]
+ ]
+ """
+ [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
+ """
+ reference: NotRequired[str]
+ """
+ A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
+ """
+ risk_correlation_id: NotRequired[str]
+ """
+ The risk correlation ID for an on-session payment using a saved PayPal payment method.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsPix(TypedDict):
+ amount_includes_iof: NotRequired[Literal["always", "never"]]
+ """
+ Determines if the amount includes the IOF tax. Defaults to `never`.
+ """
+ expires_after_seconds: NotRequired[int]
+ """
+ The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
+ """
+ expires_at: NotRequired[int]
+ """
+ The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsPromptpay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsRevolutPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsSamsungPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsSatispay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsSepaDebit(TypedDict):
+ mandate_options: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsSepaDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsSepaDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsSofort(TypedDict):
+ preferred_language: NotRequired[
+ "Literal['']|Literal['de', 'en', 'es', 'fr', 'it', 'nl', 'pl']"
+ ]
+ """
+ Language shown to the payer on redirect.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsSwish(TypedDict):
+ reference: NotRequired["Literal['']|str"]
+ """
+ A reference for this payment to be displayed in the Swish app.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsTwint(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsUsBankAccount(TypedDict):
+ financial_connections: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
+ ]
+ """
+ Additional fields for Financial Connections Session creation
+ """
+ mandate_options: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsUsBankAccountMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ networks: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsUsBankAccountNetworks"
+ ]
+ """
+ Additional fields for network related functions
+ """
+ preferred_settlement_speed: NotRequired[
+ "Literal['']|Literal['fastest', 'standard']"
+ ]
+ """
+ Preferred transaction settlement speed
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
+ TypedDict,
+):
+ filters: NotRequired[
+ "PaymentIntentConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
+ ]
+ """
+ Provide filters for the linked accounts that the customer can select for the payment method.
+ """
+ permissions: NotRequired[
+ List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ ]
+ """
+ The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+ return_url: NotRequired[str]
+ """
+ For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
+ TypedDict,
+):
+ account_subcategories: NotRequired[List[Literal["checking", "savings"]]]
+ """
+ The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsUsBankAccountMandateOptions(
+ TypedDict,
+):
+ collection_method: NotRequired["Literal['']|Literal['paper']"]
+ """
+ The method used to collect offline mandate customer acceptance.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsUsBankAccountNetworks(
+ TypedDict,
+):
+ requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
+ """
+ Triggers validations to run across the selected networks
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsWechatPay(TypedDict):
+ app_id: NotRequired[str]
+ """
+ The app ID registered with WeChat Pay. Only required when client is ios or android.
+ """
+ client: NotRequired[Literal["android", "ios", "web"]]
+ """
+ The client type that the end customer will pay from
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsPaymentMethodOptionsZip(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentConfirmParamsRadarOptions(TypedDict):
+ session: NotRequired[str]
+ """
+ A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
+ """
+
+
+class PaymentIntentConfirmParamsShipping(TypedDict):
+ address: "PaymentIntentConfirmParamsShippingAddress"
+ """
+ Shipping address.
+ """
+ carrier: NotRequired[str]
+ """
+ The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
+ """
+ name: str
+ """
+ Recipient name.
+ """
+ phone: NotRequired[str]
+ """
+ Recipient phone (including extension).
+ """
+ tracking_number: NotRequired[str]
+ """
+ The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
+ """
+
+
+class PaymentIntentConfirmParamsShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
diff --git a/stripe/params/_payment_intent_create_params.py b/stripe/params/_payment_intent_create_params.py
new file mode 100644
index 000000000..b44d07029
--- /dev/null
+++ b/stripe/params/_payment_intent_create_params.py
@@ -0,0 +1,3033 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PaymentIntentCreateParams(RequestOptions):
+ amount: int
+ """
+ Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
+ """
+ application_fee_amount: NotRequired[int]
+ """
+ The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+ automatic_payment_methods: NotRequired[
+ "PaymentIntentCreateParamsAutomaticPaymentMethods"
+ ]
+ """
+ When you enable this parameter, this PaymentIntent accepts payment methods that you enable in the Dashboard and that are compatible with this PaymentIntent's other parameters.
+ """
+ capture_method: NotRequired[
+ Literal["automatic", "automatic_async", "manual"]
+ ]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ confirm: NotRequired[bool]
+ """
+ Set to `true` to attempt to [confirm this PaymentIntent](https://stripe.com/docs/api/payment_intents/confirm) immediately. This parameter defaults to `false`. When creating and confirming a PaymentIntent at the same time, you can also provide the parameters available in the [Confirm API](https://stripe.com/docs/api/payment_intents/confirm).
+ """
+ confirmation_method: NotRequired[Literal["automatic", "manual"]]
+ """
+ Describes whether we can confirm this PaymentIntent automatically, or if it requires customer action to confirm the payment.
+ """
+ confirmation_token: NotRequired[str]
+ """
+ ID of the ConfirmationToken used to confirm this PaymentIntent.
+
+ If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ customer: NotRequired[str]
+ """
+ ID of the Customer this PaymentIntent belongs to, if one exists.
+
+ Payment methods attached to other Customers cannot be used with this PaymentIntent.
+
+ If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ error_on_requires_action: NotRequired[bool]
+ """
+ Set to `true` to fail the payment attempt if the PaymentIntent transitions into `requires_action`. Use this parameter for simpler integrations that don't handle customer actions, such as [saving cards without authentication](https://stripe.com/docs/payments/save-card-without-authentication). This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
+ """
+ excluded_payment_method_types: NotRequired[
+ List[
+ Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "card",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ ]
+ ]
+ """
+ The list of payment method types to exclude from use with this payment.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ mandate: NotRequired[str]
+ """
+ ID of the mandate that's used for this payment. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
+ """
+ mandate_data: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsMandateData"
+ ]
+ """
+ This hash contains details about the Mandate to create. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ off_session: NotRequired["bool|Literal['one_off', 'recurring']"]
+ """
+ Set to `true` to indicate that the customer isn't in your checkout flow during this payment attempt and can't authenticate. Use this parameter in scenarios where you collect card details and [charge them later](https://stripe.com/docs/payments/cards/charging-saved-cards). This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
+ """
+ on_behalf_of: NotRequired[str]
+ """
+ The Stripe account ID that these funds are intended for. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+ payment_method: NotRequired[str]
+ """
+ ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods#compatibility) object) to attach to this PaymentIntent.
+
+ If you don't provide the `payment_method` parameter or the `source` parameter with `confirm=true`, `source` automatically populates with `customer.default_source` to improve migration for users of the Charges API. We recommend that you explicitly provide the `payment_method` moving forward.
+ If the payment method is attached to a Customer, you must also provide the ID of that Customer as the [customer](https://stripe.com/docs/api#create_payment_intent-customer) parameter of this PaymentIntent.
+ end
+ """
+ payment_method_configuration: NotRequired[str]
+ """
+ The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this PaymentIntent.
+ """
+ payment_method_data: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodData"
+ ]
+ """
+ If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
+ in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
+ property on the PaymentIntent.
+ """
+ payment_method_options: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptions"
+ ]
+ """
+ Payment method-specific configuration for this PaymentIntent.
+ """
+ payment_method_types: NotRequired[List[str]]
+ """
+ The list of payment method types (for example, a card) that this PaymentIntent can use. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
+ """
+ radar_options: NotRequired["PaymentIntentCreateParamsRadarOptions"]
+ """
+ Options to configure Radar. Learn more about [Radar Sessions](https://stripe.com/docs/radar/radar-session).
+ """
+ receipt_email: NotRequired[str]
+ """
+ Email address to send the receipt to. If you specify `receipt_email` for a payment in live mode, you send a receipt regardless of your [email settings](https://dashboard.stripe.com/account/emails).
+ """
+ return_url: NotRequired[str]
+ """
+ The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
+ """
+ setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+ shipping: NotRequired["PaymentIntentCreateParamsShipping"]
+ """
+ Shipping information for this PaymentIntent.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
+
+ Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
+ """
+ statement_descriptor_suffix: NotRequired[str]
+ """
+ Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
+ """
+ transfer_data: NotRequired["PaymentIntentCreateParamsTransferData"]
+ """
+ The parameters that you can use to automatically create a Transfer.
+ Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+ transfer_group: NotRequired[str]
+ """
+ A string that identifies the resulting payment as part of a group. Learn more about the [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers).
+ """
+ use_stripe_sdk: NotRequired[bool]
+ """
+ Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
+ """
+
+
+class PaymentIntentCreateParamsAutomaticPaymentMethods(TypedDict):
+ allow_redirects: NotRequired[Literal["always", "never"]]
+ """
+ Controls whether this PaymentIntent will accept redirect-based payment methods.
+
+ Redirect-based payment methods may require your customer to be redirected to a payment method's app or site for authentication or additional steps. To [confirm](https://stripe.com/docs/api/payment_intents/confirm) this PaymentIntent, you may be required to provide a `return_url` to redirect customers back to your site after they authenticate or complete the payment.
+ """
+ enabled: bool
+ """
+ Whether this feature is enabled.
+ """
+
+
+class PaymentIntentCreateParamsMandateData(TypedDict):
+ customer_acceptance: (
+ "PaymentIntentCreateParamsMandateDataCustomerAcceptance"
+ )
+ """
+ This hash contains details about the customer acceptance of the Mandate.
+ """
+
+
+class PaymentIntentCreateParamsMandateDataCustomerAcceptance(TypedDict):
+ accepted_at: NotRequired[int]
+ """
+ The time at which the customer accepted the Mandate.
+ """
+ offline: NotRequired[
+ "PaymentIntentCreateParamsMandateDataCustomerAcceptanceOffline"
+ ]
+ """
+ If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
+ """
+ online: NotRequired[
+ "PaymentIntentCreateParamsMandateDataCustomerAcceptanceOnline"
+ ]
+ """
+ If this is a Mandate accepted online, this hash contains details about the online acceptance.
+ """
+ type: Literal["offline", "online"]
+ """
+ The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
+ """
+
+
+class PaymentIntentCreateParamsMandateDataCustomerAcceptanceOffline(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsMandateDataCustomerAcceptanceOnline(TypedDict):
+ ip_address: str
+ """
+ The IP address from which the Mandate was accepted by the customer.
+ """
+ user_agent: str
+ """
+ The user agent of the browser from which the Mandate was accepted by the customer.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodData(TypedDict):
+ acss_debit: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataAcssDebit"
+ ]
+ """
+ If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
+ """
+ affirm: NotRequired["PaymentIntentCreateParamsPaymentMethodDataAffirm"]
+ """
+ If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
+ """
+ afterpay_clearpay: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataAfterpayClearpay"
+ ]
+ """
+ If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
+ """
+ alipay: NotRequired["PaymentIntentCreateParamsPaymentMethodDataAlipay"]
+ """
+ If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
+ """
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
+ """
+ alma: NotRequired["PaymentIntentCreateParamsPaymentMethodDataAlma"]
+ """
+ If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
+ """
+ amazon_pay: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataAmazonPay"
+ ]
+ """
+ If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
+ """
+ au_becs_debit: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataAuBecsDebit"
+ ]
+ """
+ If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
+ """
+ bacs_debit: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
+ """
+ bancontact: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataBancontact"
+ ]
+ """
+ If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
+ """
+ billie: NotRequired["PaymentIntentCreateParamsPaymentMethodDataBillie"]
+ """
+ If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
+ """
+ billing_details: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataBillingDetails"
+ ]
+ """
+ Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+ """
+ blik: NotRequired["PaymentIntentCreateParamsPaymentMethodDataBlik"]
+ """
+ If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
+ """
+ boleto: NotRequired["PaymentIntentCreateParamsPaymentMethodDataBoleto"]
+ """
+ If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
+ """
+ cashapp: NotRequired["PaymentIntentCreateParamsPaymentMethodDataCashapp"]
+ """
+ If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
+ """
+ crypto: NotRequired["PaymentIntentCreateParamsPaymentMethodDataCrypto"]
+ """
+ If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
+ """
+ customer_balance: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataCustomerBalance"
+ ]
+ """
+ If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
+ """
+ eps: NotRequired["PaymentIntentCreateParamsPaymentMethodDataEps"]
+ """
+ If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
+ """
+ fpx: NotRequired["PaymentIntentCreateParamsPaymentMethodDataFpx"]
+ """
+ If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
+ """
+ giropay: NotRequired["PaymentIntentCreateParamsPaymentMethodDataGiropay"]
+ """
+ If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
+ """
+ grabpay: NotRequired["PaymentIntentCreateParamsPaymentMethodDataGrabpay"]
+ """
+ If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
+ """
+ ideal: NotRequired["PaymentIntentCreateParamsPaymentMethodDataIdeal"]
+ """
+ If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
+ """
+ interac_present: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataInteracPresent"
+ ]
+ """
+ If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
+ """
+ kakao_pay: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataKakaoPay"
+ ]
+ """
+ If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
+ """
+ klarna: NotRequired["PaymentIntentCreateParamsPaymentMethodDataKlarna"]
+ """
+ If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
+ """
+ konbini: NotRequired["PaymentIntentCreateParamsPaymentMethodDataKonbini"]
+ """
+ If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
+ """
+ kr_card: NotRequired["PaymentIntentCreateParamsPaymentMethodDataKrCard"]
+ """
+ If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
+ """
+ link: NotRequired["PaymentIntentCreateParamsPaymentMethodDataLink"]
+ """
+ If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
+ """
+ mb_way: NotRequired["PaymentIntentCreateParamsPaymentMethodDataMbWay"]
+ """
+ If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ mobilepay: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataMobilepay"
+ ]
+ """
+ If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
+ """
+ multibanco: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataMultibanco"
+ ]
+ """
+ If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
+ """
+ naver_pay: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataNaverPay"
+ ]
+ """
+ If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
+ """
+ nz_bank_account: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataNzBankAccount"
+ ]
+ """
+ If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
+ """
+ oxxo: NotRequired["PaymentIntentCreateParamsPaymentMethodDataOxxo"]
+ """
+ If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
+ """
+ p24: NotRequired["PaymentIntentCreateParamsPaymentMethodDataP24"]
+ """
+ If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
+ """
+ pay_by_bank: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataPayByBank"
+ ]
+ """
+ If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
+ """
+ payco: NotRequired["PaymentIntentCreateParamsPaymentMethodDataPayco"]
+ """
+ If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
+ """
+ paynow: NotRequired["PaymentIntentCreateParamsPaymentMethodDataPaynow"]
+ """
+ If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
+ """
+ paypal: NotRequired["PaymentIntentCreateParamsPaymentMethodDataPaypal"]
+ """
+ If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
+ """
+ pix: NotRequired["PaymentIntentCreateParamsPaymentMethodDataPix"]
+ """
+ If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
+ """
+ promptpay: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataPromptpay"
+ ]
+ """
+ If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
+ """
+ radar_options: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataRadarOptions"
+ ]
+ """
+ Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
+ """
+ revolut_pay: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataRevolutPay"
+ ]
+ """
+ If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
+ """
+ samsung_pay: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataSamsungPay"
+ ]
+ """
+ If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
+ """
+ satispay: NotRequired["PaymentIntentCreateParamsPaymentMethodDataSatispay"]
+ """
+ If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
+ """
+ sepa_debit: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
+ """
+ sofort: NotRequired["PaymentIntentCreateParamsPaymentMethodDataSofort"]
+ """
+ If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
+ """
+ swish: NotRequired["PaymentIntentCreateParamsPaymentMethodDataSwish"]
+ """
+ If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
+ """
+ twint: NotRequired["PaymentIntentCreateParamsPaymentMethodDataTwint"]
+ """
+ If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
+ """
+ type: Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "link",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ """
+ The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
+ """
+ us_bank_account: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataUsBankAccount"
+ ]
+ """
+ If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
+ """
+ wechat_pay: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodDataWechatPay"
+ ]
+ """
+ If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
+ """
+ zip: NotRequired["PaymentIntentCreateParamsPaymentMethodDataZip"]
+ """
+ If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataAcssDebit(TypedDict):
+ account_number: str
+ """
+ Customer's bank account number.
+ """
+ institution_number: str
+ """
+ Institution number of the customer's bank.
+ """
+ transit_number: str
+ """
+ Transit number of the customer's bank.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataAffirm(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataAfterpayClearpay(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataAlipay(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataAlma(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataAmazonPay(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataAuBecsDebit(TypedDict):
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bsb_number: str
+ """
+ Bank-State-Branch number of the bank account.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataBacsDebit(TypedDict):
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account that the funds will be debited from.
+ """
+ sort_code: NotRequired[str]
+ """
+ Sort code of the bank account. (e.g., `10-20-30`)
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataBancontact(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataBillie(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataBillingDetails(TypedDict):
+ address: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodDataBillingDetailsAddress"
+ ]
+ """
+ Billing address.
+ """
+ email: NotRequired["Literal['']|str"]
+ """
+ Email address.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Full name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Billing phone number (including extension).
+ """
+ tax_id: NotRequired[str]
+ """
+ Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataBillingDetailsAddress(
+ TypedDict,
+):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataBlik(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataBoleto(TypedDict):
+ tax_id: str
+ """
+ The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataCashapp(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataCrypto(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataCustomerBalance(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataEps(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "arzte_und_apotheker_bank",
+ "austrian_anadi_bank_ag",
+ "bank_austria",
+ "bankhaus_carl_spangler",
+ "bankhaus_schelhammer_und_schattera_ag",
+ "bawag_psk_ag",
+ "bks_bank_ag",
+ "brull_kallmus_bank_ag",
+ "btv_vier_lander_bank",
+ "capital_bank_grawe_gruppe_ag",
+ "deutsche_bank_ag",
+ "dolomitenbank",
+ "easybank_ag",
+ "erste_bank_und_sparkassen",
+ "hypo_alpeadriabank_international_ag",
+ "hypo_bank_burgenland_aktiengesellschaft",
+ "hypo_noe_lb_fur_niederosterreich_u_wien",
+ "hypo_oberosterreich_salzburg_steiermark",
+ "hypo_tirol_bank_ag",
+ "hypo_vorarlberg_bank_ag",
+ "marchfelder_bank",
+ "oberbank_ag",
+ "raiffeisen_bankengruppe_osterreich",
+ "schoellerbank_ag",
+ "sparda_bank_wien",
+ "volksbank_gruppe",
+ "volkskreditbank_ag",
+ "vr_bank_braunau",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataFpx(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type for FPX transaction
+ """
+ bank: Literal[
+ "affin_bank",
+ "agrobank",
+ "alliance_bank",
+ "ambank",
+ "bank_islam",
+ "bank_muamalat",
+ "bank_of_china",
+ "bank_rakyat",
+ "bsn",
+ "cimb",
+ "deutsche_bank",
+ "hong_leong_bank",
+ "hsbc",
+ "kfh",
+ "maybank2e",
+ "maybank2u",
+ "ocbc",
+ "pb_enterprise",
+ "public_bank",
+ "rhb",
+ "standard_chartered",
+ "uob",
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataGiropay(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataGrabpay(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataIdeal(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "abn_amro",
+ "asn_bank",
+ "bunq",
+ "buut",
+ "handelsbanken",
+ "ing",
+ "knab",
+ "moneyou",
+ "n26",
+ "nn",
+ "rabobank",
+ "regiobank",
+ "revolut",
+ "sns_bank",
+ "triodos_bank",
+ "van_lanschot",
+ "yoursafe",
+ ]
+ ]
+ """
+ The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataInteracPresent(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataKakaoPay(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataKlarna(TypedDict):
+ dob: NotRequired["PaymentIntentCreateParamsPaymentMethodDataKlarnaDob"]
+ """
+ Customer's date of birth
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataKlarnaDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataKonbini(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataKrCard(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataLink(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataMbWay(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataMobilepay(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataMultibanco(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataNaverPay(TypedDict):
+ funding: NotRequired[Literal["card", "points"]]
+ """
+ Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataNzBankAccount(TypedDict):
+ account_holder_name: NotRequired[str]
+ """
+ The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
+ """
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bank_code: str
+ """
+ The numeric code for the bank account's bank.
+ """
+ branch_code: str
+ """
+ The numeric code for the bank account's bank branch.
+ """
+ reference: NotRequired[str]
+ suffix: str
+ """
+ The suffix of the bank account number.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataOxxo(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataP24(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "alior_bank",
+ "bank_millennium",
+ "bank_nowy_bfg_sa",
+ "bank_pekao_sa",
+ "banki_spbdzielcze",
+ "blik",
+ "bnp_paribas",
+ "boz",
+ "citi_handlowy",
+ "credit_agricole",
+ "envelobank",
+ "etransfer_pocztowy24",
+ "getin_bank",
+ "ideabank",
+ "ing",
+ "inteligo",
+ "mbank_mtransfer",
+ "nest_przelew",
+ "noble_pay",
+ "pbac_z_ipko",
+ "plus_bank",
+ "santander_przelew24",
+ "tmobile_usbugi_bankowe",
+ "toyota_bank",
+ "velobank",
+ "volkswagen_bank",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataPayByBank(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataPayco(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataPaynow(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataPaypal(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataPix(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataPromptpay(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataRadarOptions(TypedDict):
+ session: NotRequired[str]
+ """
+ A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataRevolutPay(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataSamsungPay(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataSatispay(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataSepaDebit(TypedDict):
+ iban: str
+ """
+ IBAN of the bank account.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataSofort(TypedDict):
+ country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
+ """
+ Two-letter ISO code representing the country the bank account is located in.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataSwish(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataTwint(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataUsBankAccount(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type: individual or company.
+ """
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account.
+ """
+ account_type: NotRequired[Literal["checking", "savings"]]
+ """
+ Account type: checkings or savings. Defaults to checking if omitted.
+ """
+ financial_connections_account: NotRequired[str]
+ """
+ The ID of a Financial Connections Account to use as a payment method.
+ """
+ routing_number: NotRequired[str]
+ """
+ Routing number of the bank account.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodDataWechatPay(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodDataZip(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodOptions(TypedDict):
+ acss_debit: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsAcssDebit"
+ ]
+ """
+ If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
+ """
+ affirm: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsAffirm"
+ ]
+ """
+ If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
+ """
+ afterpay_clearpay: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsAfterpayClearpay"
+ ]
+ """
+ If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
+ """
+ alipay: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsAlipay"
+ ]
+ """
+ If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
+ """
+ alma: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsAlma"
+ ]
+ """
+ If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
+ """
+ amazon_pay: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsAmazonPay"
+ ]
+ """
+ If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
+ """
+ au_becs_debit: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsAuBecsDebit"
+ ]
+ """
+ If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
+ """
+ bacs_debit: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
+ """
+ bancontact: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsBancontact"
+ ]
+ """
+ If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
+ """
+ billie: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsBillie"
+ ]
+ """
+ If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
+ """
+ blik: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsBlik"
+ ]
+ """
+ If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
+ """
+ boleto: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsBoleto"
+ ]
+ """
+ If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
+ """
+ card: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsCard"
+ ]
+ """
+ Configuration for any card payments attempted on this PaymentIntent.
+ """
+ card_present: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsCardPresent"
+ ]
+ """
+ If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
+ """
+ cashapp: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsCashapp"
+ ]
+ """
+ If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
+ """
+ crypto: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsCrypto"
+ ]
+ """
+ If this is a `crypto` PaymentMethod, this sub-hash contains details about the Crypto payment method options.
+ """
+ customer_balance: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsCustomerBalance"
+ ]
+ """
+ If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
+ """
+ eps: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsEps"
+ ]
+ """
+ If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
+ """
+ fpx: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsFpx"
+ ]
+ """
+ If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
+ """
+ giropay: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsGiropay"
+ ]
+ """
+ If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
+ """
+ grabpay: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsGrabpay"
+ ]
+ """
+ If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
+ """
+ ideal: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsIdeal"
+ ]
+ """
+ If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
+ """
+ interac_present: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsInteracPresent"
+ ]
+ """
+ If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
+ """
+ kakao_pay: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsKakaoPay"
+ ]
+ """
+ If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
+ """
+ klarna: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsKlarna"
+ ]
+ """
+ If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
+ """
+ konbini: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsKonbini"
+ ]
+ """
+ If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
+ """
+ kr_card: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsKrCard"
+ ]
+ """
+ If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
+ """
+ link: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsLink"
+ ]
+ """
+ If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
+ """
+ mb_way: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsMbWay"
+ ]
+ """
+ If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
+ """
+ mobilepay: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsMobilepay"
+ ]
+ """
+ If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
+ """
+ multibanco: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsMultibanco"
+ ]
+ """
+ If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
+ """
+ naver_pay: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsNaverPay"
+ ]
+ """
+ If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
+ """
+ nz_bank_account: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsNzBankAccount"
+ ]
+ """
+ If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
+ """
+ oxxo: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsOxxo"
+ ]
+ """
+ If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
+ """
+ p24: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsP24"
+ ]
+ """
+ If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
+ """
+ pay_by_bank: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsPayByBank"
+ ]
+ """
+ If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
+ """
+ payco: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsPayco"
+ ]
+ """
+ If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
+ """
+ paynow: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsPaynow"
+ ]
+ """
+ If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
+ """
+ paypal: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsPaypal"
+ ]
+ """
+ If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
+ """
+ pix: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsPix"
+ ]
+ """
+ If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
+ """
+ promptpay: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsPromptpay"
+ ]
+ """
+ If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
+ """
+ revolut_pay: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsRevolutPay"
+ ]
+ """
+ If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
+ """
+ samsung_pay: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsSamsungPay"
+ ]
+ """
+ If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
+ """
+ satispay: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsSatispay"
+ ]
+ """
+ If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
+ """
+ sepa_debit: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
+ """
+ sofort: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsSofort"
+ ]
+ """
+ If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
+ """
+ swish: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsSwish"
+ ]
+ """
+ If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
+ """
+ twint: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsTwint"
+ ]
+ """
+ If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
+ """
+ us_bank_account: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
+ """
+ wechat_pay: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsWechatPay"
+ ]
+ """
+ If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
+ """
+ zip: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsZip"
+ ]
+ """
+ If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsAcssDebit(TypedDict):
+ mandate_options: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsAcssDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsAcssDebitMandateOptions(
+ TypedDict,
+):
+ custom_mandate_url: NotRequired["Literal['']|str"]
+ """
+ A URL for custom mandate text to render during confirmation step.
+ The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
+ or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
+ """
+ interval_description: NotRequired[str]
+ """
+ Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
+ """
+ payment_schedule: NotRequired[Literal["combined", "interval", "sporadic"]]
+ """
+ Payment schedule for the mandate.
+ """
+ transaction_type: NotRequired[Literal["business", "personal"]]
+ """
+ Transaction type of the mandate.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsAffirm(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ preferred_locale: NotRequired[str]
+ """
+ Preferred language of the Affirm authorization page that the customer is redirected to.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsAfterpayClearpay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ reference: NotRequired[str]
+ """
+ An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
+ This field differs from the statement descriptor and item name.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsAlipay(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsAlma(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsAmazonPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsAuBecsDebit(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsBacsDebit(TypedDict):
+ mandate_options: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsBacsDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsBacsDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsBancontact(TypedDict):
+ preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
+ """
+ Preferred language of the Bancontact authorization page that the customer is redirected to.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsBillie(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsBlik(TypedDict):
+ code: NotRequired[str]
+ """
+ The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
+ """
+ setup_future_usage: NotRequired["Literal['']|Literal['none']"]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsBoleto(TypedDict):
+ expires_after_days: NotRequired[int]
+ """
+ The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsCard(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ cvc_token: NotRequired[str]
+ """
+ A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
+ """
+ installments: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsCardInstallments"
+ ]
+ """
+ Installment configuration for payments attempted on this PaymentIntent.
+
+ For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
+ """
+ mandate_options: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsCardMandateOptions"
+ ]
+ """
+ Configuration options for setting up an eMandate for cards issued in India.
+ """
+ moto: NotRequired[bool]
+ """
+ When specified, this parameter indicates that a transaction will be marked
+ as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
+ parameter can only be provided during confirmation.
+ """
+ network: NotRequired[
+ Literal[
+ "amex",
+ "cartes_bancaires",
+ "diners",
+ "discover",
+ "eftpos_au",
+ "girocard",
+ "interac",
+ "jcb",
+ "link",
+ "mastercard",
+ "unionpay",
+ "unknown",
+ "visa",
+ ]
+ ]
+ """
+ Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
+ """
+ request_extended_authorization: NotRequired[
+ Literal["if_available", "never"]
+ ]
+ """
+ Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
+ """
+ request_incremental_authorization: NotRequired[
+ Literal["if_available", "never"]
+ ]
+ """
+ Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
+ """
+ request_multicapture: NotRequired[Literal["if_available", "never"]]
+ """
+ Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
+ """
+ request_overcapture: NotRequired[Literal["if_available", "never"]]
+ """
+ Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
+ """
+ request_three_d_secure: NotRequired[
+ Literal["any", "automatic", "challenge"]
+ ]
+ """
+ We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
+ """
+ require_cvc_recollection: NotRequired[bool]
+ """
+ When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ statement_descriptor_suffix_kana: NotRequired["Literal['']|str"]
+ """
+ Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that's set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
+ """
+ statement_descriptor_suffix_kanji: NotRequired["Literal['']|str"]
+ """
+ Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that's set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
+ """
+ three_d_secure: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsCardThreeDSecure"
+ ]
+ """
+ If 3D Secure authentication was performed with a third-party provider,
+ the authentication details to use for this payment.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsCardInstallments(TypedDict):
+ enabled: NotRequired[bool]
+ """
+ Setting to true enables installments for this PaymentIntent.
+ This will cause the response to contain a list of available installment plans.
+ Setting to false will prevent any selected plan from applying to a charge.
+ """
+ plan: NotRequired[
+ "Literal['']|PaymentIntentCreateParamsPaymentMethodOptionsCardInstallmentsPlan"
+ ]
+ """
+ The selected installment plan to use for this payment attempt.
+ This parameter can only be provided during confirmation.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsCardInstallmentsPlan(
+ TypedDict,
+):
+ count: NotRequired[int]
+ """
+ For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
+ """
+ interval: NotRequired[Literal["month"]]
+ """
+ For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
+ One of `month`.
+ """
+ type: Literal["bonus", "fixed_count", "revolving"]
+ """
+ Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsCardMandateOptions(
+ TypedDict,
+):
+ amount: int
+ """
+ Amount to be charged for future payments.
+ """
+ amount_type: Literal["fixed", "maximum"]
+ """
+ One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
+ """
+ description: NotRequired[str]
+ """
+ A description of the mandate or subscription that is meant to be displayed to the customer.
+ """
+ end_date: NotRequired[int]
+ """
+ End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
+ """
+ interval: Literal["day", "month", "sporadic", "week", "year"]
+ """
+ Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
+ """
+ reference: str
+ """
+ Unique identifier for the mandate or subscription.
+ """
+ start_date: int
+ """
+ Start date of the mandate or subscription. Start date should not be lesser than yesterday.
+ """
+ supported_types: NotRequired[List[Literal["india"]]]
+ """
+ Specifies the type of mandates supported. Possible values are `india`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
+ ares_trans_status: NotRequired[Literal["A", "C", "I", "N", "R", "U", "Y"]]
+ """
+ The `transStatus` returned from the card Issuer's ACS in the ARes.
+ """
+ cryptogram: str
+ """
+ The cryptogram, also known as the "authentication value" (AAV, CAVV or
+ AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
+ (Most 3D Secure providers will return the base64-encoded version, which
+ is what you should specify here.)
+ """
+ electronic_commerce_indicator: NotRequired[
+ Literal["01", "02", "05", "06", "07"]
+ ]
+ """
+ The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
+ provider and indicates what degree of authentication was performed.
+ """
+ exemption_indicator: NotRequired[Literal["low_risk", "none"]]
+ """
+ The exemption requested via 3DS and accepted by the issuer at authentication time.
+ """
+ network_options: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
+ ]
+ """
+ Network specific 3DS fields. Network specific arguments require an
+ explicit card brand choice. The parameter `payment_method_options.card.network``
+ must be populated accordingly
+ """
+ requestor_challenge_indicator: NotRequired[str]
+ """
+ The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
+ AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
+ """
+ transaction_id: str
+ """
+ For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
+ Transaction ID (dsTransID).
+ """
+ version: Literal["1.0.2", "2.1.0", "2.2.0"]
+ """
+ The version of 3D Secure that was performed.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
+ TypedDict,
+):
+ cartes_bancaires: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
+ ]
+ """
+ Cartes Bancaires-specific 3DS fields.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
+ TypedDict,
+):
+ cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
+ """
+ The cryptogram calculation algorithm used by the card Issuer's ACS
+ to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
+ messageExtension: CB-AVALGO
+ """
+ cb_exemption: NotRequired[str]
+ """
+ The exemption indicator returned from Cartes Bancaires in the ARes.
+ message extension: CB-EXEMPTION; string (4 characters)
+ This is a 3 byte bitmap (low significant byte first and most significant
+ bit first) that has been Base64 encoded
+ """
+ cb_score: NotRequired[int]
+ """
+ The risk score returned from Cartes Bancaires in the ARes.
+ message extension: CB-SCORE; numeric value 0-99
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsCardPresent(TypedDict):
+ request_extended_authorization: NotRequired[bool]
+ """
+ Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
+ """
+ request_incremental_authorization_support: NotRequired[bool]
+ """
+ Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
+ """
+ routing: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsCardPresentRouting"
+ ]
+ """
+ Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsCardPresentRouting(
+ TypedDict,
+):
+ requested_priority: NotRequired[Literal["domestic", "international"]]
+ """
+ Routing requested priority
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsCashapp(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsCrypto(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsCustomerBalance(TypedDict):
+ bank_transfer: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsCustomerBalanceBankTransfer"
+ ]
+ """
+ Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
+ """
+ funding_type: NotRequired[Literal["bank_transfer"]]
+ """
+ The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsCustomerBalanceBankTransfer(
+ TypedDict,
+):
+ eu_bank_transfer: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
+ ]
+ """
+ Configuration for the eu_bank_transfer funding type.
+ """
+ requested_address_types: NotRequired[
+ List[
+ Literal[
+ "aba", "iban", "sepa", "sort_code", "spei", "swift", "zengin"
+ ]
+ ]
+ ]
+ """
+ List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
+
+ Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
+ """
+ type: Literal[
+ "eu_bank_transfer",
+ "gb_bank_transfer",
+ "jp_bank_transfer",
+ "mx_bank_transfer",
+ "us_bank_transfer",
+ ]
+ """
+ The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
+ TypedDict,
+):
+ country: str
+ """
+ The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsEps(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsFpx(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsGiropay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsGrabpay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsIdeal(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsInteracPresent(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsKakaoPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsKlarna(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ on_demand: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsKlarnaOnDemand"
+ ]
+ """
+ On-demand details if setting up or charging an on-demand payment.
+ """
+ preferred_locale: NotRequired[
+ Literal[
+ "cs-CZ",
+ "da-DK",
+ "de-AT",
+ "de-CH",
+ "de-DE",
+ "el-GR",
+ "en-AT",
+ "en-AU",
+ "en-BE",
+ "en-CA",
+ "en-CH",
+ "en-CZ",
+ "en-DE",
+ "en-DK",
+ "en-ES",
+ "en-FI",
+ "en-FR",
+ "en-GB",
+ "en-GR",
+ "en-IE",
+ "en-IT",
+ "en-NL",
+ "en-NO",
+ "en-NZ",
+ "en-PL",
+ "en-PT",
+ "en-RO",
+ "en-SE",
+ "en-US",
+ "es-ES",
+ "es-US",
+ "fi-FI",
+ "fr-BE",
+ "fr-CA",
+ "fr-CH",
+ "fr-FR",
+ "it-CH",
+ "it-IT",
+ "nb-NO",
+ "nl-BE",
+ "nl-NL",
+ "pl-PL",
+ "pt-PT",
+ "ro-RO",
+ "sv-FI",
+ "sv-SE",
+ ]
+ ]
+ """
+ Preferred language of the Klarna authorization page that the customer is redirected to
+ """
+ setup_future_usage: NotRequired[
+ Literal["none", "off_session", "on_session"]
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ subscriptions: NotRequired[
+ "Literal['']|List[PaymentIntentCreateParamsPaymentMethodOptionsKlarnaSubscription]"
+ ]
+ """
+ Subscription details if setting up or charging a subscription.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
+ average_amount: NotRequired[int]
+ """
+ Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ maximum_amount: NotRequired[int]
+ """
+ The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ minimum_amount: NotRequired[int]
+ """
+ The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
+ """
+ Interval at which the customer is making purchases
+ """
+ purchase_interval_count: NotRequired[int]
+ """
+ The number of `purchase_interval` between charges
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsKlarnaSubscription(
+ TypedDict,
+):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Unit of time between subscription charges.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
+ """
+ name: NotRequired[str]
+ """
+ Name for subscription.
+ """
+ next_billing: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
+ ]
+ """
+ Describes the upcoming charge for this subscription.
+ """
+ reference: str
+ """
+ A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
+ TypedDict,
+):
+ amount: int
+ """
+ The amount of the next charge for the subscription.
+ """
+ date: str
+ """
+ The date of the next charge for the subscription in YYYY-MM-DD format.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsKonbini(TypedDict):
+ confirmation_number: NotRequired["Literal['']|str"]
+ """
+ An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
+ """
+ expires_after_days: NotRequired["Literal['']|int"]
+ """
+ The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
+ """
+ expires_at: NotRequired["Literal['']|int"]
+ """
+ The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsKrCard(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsLink(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ persistent_token: NotRequired[str]
+ """
+ [Deprecated] This is a legacy parameter that no longer has any function.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsMbWay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsMobilepay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsMultibanco(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsNaverPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsNzBankAccount(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsOxxo(TypedDict):
+ expires_after_days: NotRequired[int]
+ """
+ The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsP24(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ tos_shown_and_accepted: NotRequired[bool]
+ """
+ Confirm that the payer has accepted the P24 terms and conditions.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsPayByBank(TypedDict):
+ pass
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsPayco(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsPaynow(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsPaypal(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ preferred_locale: NotRequired[
+ Literal[
+ "cs-CZ",
+ "da-DK",
+ "de-AT",
+ "de-DE",
+ "de-LU",
+ "el-GR",
+ "en-GB",
+ "en-US",
+ "es-ES",
+ "fi-FI",
+ "fr-BE",
+ "fr-FR",
+ "fr-LU",
+ "hu-HU",
+ "it-IT",
+ "nl-BE",
+ "nl-NL",
+ "pl-PL",
+ "pt-PT",
+ "sk-SK",
+ "sv-SE",
+ ]
+ ]
+ """
+ [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
+ """
+ reference: NotRequired[str]
+ """
+ A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
+ """
+ risk_correlation_id: NotRequired[str]
+ """
+ The risk correlation ID for an on-session payment using a saved PayPal payment method.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsPix(TypedDict):
+ amount_includes_iof: NotRequired[Literal["always", "never"]]
+ """
+ Determines if the amount includes the IOF tax. Defaults to `never`.
+ """
+ expires_after_seconds: NotRequired[int]
+ """
+ The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
+ """
+ expires_at: NotRequired[int]
+ """
+ The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsPromptpay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsRevolutPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsSamsungPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsSatispay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsSepaDebit(TypedDict):
+ mandate_options: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsSepaDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsSepaDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsSofort(TypedDict):
+ preferred_language: NotRequired[
+ "Literal['']|Literal['de', 'en', 'es', 'fr', 'it', 'nl', 'pl']"
+ ]
+ """
+ Language shown to the payer on redirect.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsSwish(TypedDict):
+ reference: NotRequired["Literal['']|str"]
+ """
+ A reference for this payment to be displayed in the Swish app.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsTwint(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsUsBankAccount(TypedDict):
+ financial_connections: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
+ ]
+ """
+ Additional fields for Financial Connections Session creation
+ """
+ mandate_options: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsUsBankAccountMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ networks: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsUsBankAccountNetworks"
+ ]
+ """
+ Additional fields for network related functions
+ """
+ preferred_settlement_speed: NotRequired[
+ "Literal['']|Literal['fastest', 'standard']"
+ ]
+ """
+ Preferred transaction settlement speed
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
+ TypedDict,
+):
+ filters: NotRequired[
+ "PaymentIntentCreateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
+ ]
+ """
+ Provide filters for the linked accounts that the customer can select for the payment method.
+ """
+ permissions: NotRequired[
+ List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ ]
+ """
+ The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+ return_url: NotRequired[str]
+ """
+ For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
+ TypedDict,
+):
+ account_subcategories: NotRequired[List[Literal["checking", "savings"]]]
+ """
+ The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsUsBankAccountMandateOptions(
+ TypedDict,
+):
+ collection_method: NotRequired["Literal['']|Literal['paper']"]
+ """
+ The method used to collect offline mandate customer acceptance.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsUsBankAccountNetworks(
+ TypedDict,
+):
+ requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
+ """
+ Triggers validations to run across the selected networks
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsWechatPay(TypedDict):
+ app_id: NotRequired[str]
+ """
+ The app ID registered with WeChat Pay. Only required when client is ios or android.
+ """
+ client: NotRequired[Literal["android", "ios", "web"]]
+ """
+ The client type that the end customer will pay from
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsPaymentMethodOptionsZip(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentCreateParamsRadarOptions(TypedDict):
+ session: NotRequired[str]
+ """
+ A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
+ """
+
+
+class PaymentIntentCreateParamsShipping(TypedDict):
+ address: "PaymentIntentCreateParamsShippingAddress"
+ """
+ Shipping address.
+ """
+ carrier: NotRequired[str]
+ """
+ The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
+ """
+ name: str
+ """
+ Recipient name.
+ """
+ phone: NotRequired[str]
+ """
+ Recipient phone (including extension).
+ """
+ tracking_number: NotRequired[str]
+ """
+ The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
+ """
+
+
+class PaymentIntentCreateParamsShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class PaymentIntentCreateParamsTransferData(TypedDict):
+ amount: NotRequired[int]
+ """
+ The amount that will be transferred automatically when a charge succeeds.
+ The amount is capped at the total transaction amount and if no amount is set,
+ the full amount is transferred.
+
+ If you intend to collect a fee and you need a more robust reporting experience, using
+ [application_fee_amount](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-application_fee_amount)
+ might be a better fit for your integration.
+ """
+ destination: str
+ """
+ If specified, successful charges will be attributed to the destination
+ account for tax reporting, and the funds from charges will be transferred
+ to the destination account. The ID of the resulting transfer will be
+ returned on the successful charge's `transfer` field.
+ """
diff --git a/stripe/params/_payment_intent_increment_authorization_params.py b/stripe/params/_payment_intent_increment_authorization_params.py
new file mode 100644
index 000000000..c2ba0fdc3
--- /dev/null
+++ b/stripe/params/_payment_intent_increment_authorization_params.py
@@ -0,0 +1,46 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import NotRequired, TypedDict
+
+
+class PaymentIntentIncrementAuthorizationParams(RequestOptions):
+ amount: int
+ """
+ The updated total amount that you intend to collect from the cardholder. This amount must be greater than the currently authorized amount.
+ """
+ application_fee_amount: NotRequired[int]
+ """
+ The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ Text that appears on the customer's statement as the statement descriptor for a non-card or card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
+ """
+ transfer_data: NotRequired[
+ "PaymentIntentIncrementAuthorizationParamsTransferData"
+ ]
+ """
+ The parameters used to automatically create a transfer after the payment is captured.
+ Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+
+
+class PaymentIntentIncrementAuthorizationParamsTransferData(TypedDict):
+ amount: NotRequired[int]
+ """
+ The amount that will be transferred automatically when a charge succeeds.
+ """
diff --git a/stripe/params/_payment_intent_list_params.py b/stripe/params/_payment_intent_list_params.py
new file mode 100644
index 000000000..711a58f45
--- /dev/null
+++ b/stripe/params/_payment_intent_list_params.py
@@ -0,0 +1,51 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class PaymentIntentListParams(RequestOptions):
+ created: NotRequired["PaymentIntentListParamsCreated|int"]
+ """
+ A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp or a dictionary with a number of different query options.
+ """
+ customer: NotRequired[str]
+ """
+ Only return PaymentIntents for the customer that this customer ID specifies.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class PaymentIntentListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_payment_intent_modify_params.py b/stripe/params/_payment_intent_modify_params.py
new file mode 100644
index 000000000..2fb7db541
--- /dev/null
+++ b/stripe/params/_payment_intent_modify_params.py
@@ -0,0 +1,2847 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PaymentIntentModifyParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
+ """
+ application_fee_amount: NotRequired["Literal['']|int"]
+ """
+ The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+ capture_method: NotRequired[
+ Literal["automatic", "automatic_async", "manual"]
+ ]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ customer: NotRequired[str]
+ """
+ ID of the Customer this PaymentIntent belongs to, if one exists.
+
+ Payment methods attached to other Customers cannot be used with this PaymentIntent.
+
+ If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ excluded_payment_method_types: NotRequired[
+ "Literal['']|List[Literal['acss_debit', 'affirm', 'afterpay_clearpay', 'alipay', 'alma', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'billie', 'blik', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'mb_way', 'mobilepay', 'multibanco', 'naver_pay', 'nz_bank_account', 'oxxo', 'p24', 'pay_by_bank', 'payco', 'paynow', 'paypal', 'pix', 'promptpay', 'revolut_pay', 'samsung_pay', 'satispay', 'sepa_debit', 'sofort', 'swish', 'twint', 'us_bank_account', 'wechat_pay', 'zip']]"
+ ]
+ """
+ The list of payment method types to exclude from use with this payment.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ payment_method: NotRequired[str]
+ """
+ ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods/transitioning#compatibility) object) to attach to this PaymentIntent. To unset this field to null, pass in an empty string.
+ """
+ payment_method_configuration: NotRequired[str]
+ """
+ The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this PaymentIntent.
+ """
+ payment_method_data: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodData"
+ ]
+ """
+ If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
+ in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
+ property on the PaymentIntent.
+ """
+ payment_method_options: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptions"
+ ]
+ """
+ Payment-method-specific configuration for this PaymentIntent.
+ """
+ payment_method_types: NotRequired[List[str]]
+ """
+ The list of payment method types (for example, card) that this PaymentIntent can use. Use `automatic_payment_methods` to manage payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
+ """
+ receipt_email: NotRequired["Literal['']|str"]
+ """
+ Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ shipping: NotRequired["Literal['']|PaymentIntentModifyParamsShipping"]
+ """
+ Shipping information for this PaymentIntent.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
+
+ Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
+ """
+ statement_descriptor_suffix: NotRequired[str]
+ """
+ Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
+ """
+ transfer_data: NotRequired["PaymentIntentModifyParamsTransferData"]
+ """
+ Use this parameter to automatically create a Transfer when the payment succeeds. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+ transfer_group: NotRequired[str]
+ """
+ A string that identifies the resulting payment as part of a group. You can only provide `transfer_group` if it hasn't been set. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodData(TypedDict):
+ acss_debit: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataAcssDebit"
+ ]
+ """
+ If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
+ """
+ affirm: NotRequired["PaymentIntentModifyParamsPaymentMethodDataAffirm"]
+ """
+ If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
+ """
+ afterpay_clearpay: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataAfterpayClearpay"
+ ]
+ """
+ If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
+ """
+ alipay: NotRequired["PaymentIntentModifyParamsPaymentMethodDataAlipay"]
+ """
+ If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
+ """
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
+ """
+ alma: NotRequired["PaymentIntentModifyParamsPaymentMethodDataAlma"]
+ """
+ If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
+ """
+ amazon_pay: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataAmazonPay"
+ ]
+ """
+ If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
+ """
+ au_becs_debit: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataAuBecsDebit"
+ ]
+ """
+ If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
+ """
+ bacs_debit: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
+ """
+ bancontact: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataBancontact"
+ ]
+ """
+ If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
+ """
+ billie: NotRequired["PaymentIntentModifyParamsPaymentMethodDataBillie"]
+ """
+ If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
+ """
+ billing_details: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataBillingDetails"
+ ]
+ """
+ Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+ """
+ blik: NotRequired["PaymentIntentModifyParamsPaymentMethodDataBlik"]
+ """
+ If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
+ """
+ boleto: NotRequired["PaymentIntentModifyParamsPaymentMethodDataBoleto"]
+ """
+ If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
+ """
+ cashapp: NotRequired["PaymentIntentModifyParamsPaymentMethodDataCashapp"]
+ """
+ If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
+ """
+ crypto: NotRequired["PaymentIntentModifyParamsPaymentMethodDataCrypto"]
+ """
+ If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
+ """
+ customer_balance: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataCustomerBalance"
+ ]
+ """
+ If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
+ """
+ eps: NotRequired["PaymentIntentModifyParamsPaymentMethodDataEps"]
+ """
+ If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
+ """
+ fpx: NotRequired["PaymentIntentModifyParamsPaymentMethodDataFpx"]
+ """
+ If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
+ """
+ giropay: NotRequired["PaymentIntentModifyParamsPaymentMethodDataGiropay"]
+ """
+ If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
+ """
+ grabpay: NotRequired["PaymentIntentModifyParamsPaymentMethodDataGrabpay"]
+ """
+ If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
+ """
+ ideal: NotRequired["PaymentIntentModifyParamsPaymentMethodDataIdeal"]
+ """
+ If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
+ """
+ interac_present: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataInteracPresent"
+ ]
+ """
+ If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
+ """
+ kakao_pay: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataKakaoPay"
+ ]
+ """
+ If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
+ """
+ klarna: NotRequired["PaymentIntentModifyParamsPaymentMethodDataKlarna"]
+ """
+ If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
+ """
+ konbini: NotRequired["PaymentIntentModifyParamsPaymentMethodDataKonbini"]
+ """
+ If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
+ """
+ kr_card: NotRequired["PaymentIntentModifyParamsPaymentMethodDataKrCard"]
+ """
+ If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
+ """
+ link: NotRequired["PaymentIntentModifyParamsPaymentMethodDataLink"]
+ """
+ If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
+ """
+ mb_way: NotRequired["PaymentIntentModifyParamsPaymentMethodDataMbWay"]
+ """
+ If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ mobilepay: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataMobilepay"
+ ]
+ """
+ If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
+ """
+ multibanco: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataMultibanco"
+ ]
+ """
+ If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
+ """
+ naver_pay: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataNaverPay"
+ ]
+ """
+ If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
+ """
+ nz_bank_account: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataNzBankAccount"
+ ]
+ """
+ If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
+ """
+ oxxo: NotRequired["PaymentIntentModifyParamsPaymentMethodDataOxxo"]
+ """
+ If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
+ """
+ p24: NotRequired["PaymentIntentModifyParamsPaymentMethodDataP24"]
+ """
+ If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
+ """
+ pay_by_bank: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataPayByBank"
+ ]
+ """
+ If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
+ """
+ payco: NotRequired["PaymentIntentModifyParamsPaymentMethodDataPayco"]
+ """
+ If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
+ """
+ paynow: NotRequired["PaymentIntentModifyParamsPaymentMethodDataPaynow"]
+ """
+ If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
+ """
+ paypal: NotRequired["PaymentIntentModifyParamsPaymentMethodDataPaypal"]
+ """
+ If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
+ """
+ pix: NotRequired["PaymentIntentModifyParamsPaymentMethodDataPix"]
+ """
+ If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
+ """
+ promptpay: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataPromptpay"
+ ]
+ """
+ If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
+ """
+ radar_options: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataRadarOptions"
+ ]
+ """
+ Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
+ """
+ revolut_pay: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataRevolutPay"
+ ]
+ """
+ If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
+ """
+ samsung_pay: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataSamsungPay"
+ ]
+ """
+ If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
+ """
+ satispay: NotRequired["PaymentIntentModifyParamsPaymentMethodDataSatispay"]
+ """
+ If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
+ """
+ sepa_debit: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
+ """
+ sofort: NotRequired["PaymentIntentModifyParamsPaymentMethodDataSofort"]
+ """
+ If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
+ """
+ swish: NotRequired["PaymentIntentModifyParamsPaymentMethodDataSwish"]
+ """
+ If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
+ """
+ twint: NotRequired["PaymentIntentModifyParamsPaymentMethodDataTwint"]
+ """
+ If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
+ """
+ type: Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "link",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ """
+ The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
+ """
+ us_bank_account: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataUsBankAccount"
+ ]
+ """
+ If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
+ """
+ wechat_pay: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodDataWechatPay"
+ ]
+ """
+ If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
+ """
+ zip: NotRequired["PaymentIntentModifyParamsPaymentMethodDataZip"]
+ """
+ If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataAcssDebit(TypedDict):
+ account_number: str
+ """
+ Customer's bank account number.
+ """
+ institution_number: str
+ """
+ Institution number of the customer's bank.
+ """
+ transit_number: str
+ """
+ Transit number of the customer's bank.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataAffirm(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataAfterpayClearpay(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataAlipay(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataAlma(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataAmazonPay(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataAuBecsDebit(TypedDict):
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bsb_number: str
+ """
+ Bank-State-Branch number of the bank account.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataBacsDebit(TypedDict):
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account that the funds will be debited from.
+ """
+ sort_code: NotRequired[str]
+ """
+ Sort code of the bank account. (e.g., `10-20-30`)
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataBancontact(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataBillie(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataBillingDetails(TypedDict):
+ address: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodDataBillingDetailsAddress"
+ ]
+ """
+ Billing address.
+ """
+ email: NotRequired["Literal['']|str"]
+ """
+ Email address.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Full name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Billing phone number (including extension).
+ """
+ tax_id: NotRequired[str]
+ """
+ Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataBillingDetailsAddress(
+ TypedDict,
+):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataBlik(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataBoleto(TypedDict):
+ tax_id: str
+ """
+ The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataCashapp(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataCrypto(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataCustomerBalance(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataEps(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "arzte_und_apotheker_bank",
+ "austrian_anadi_bank_ag",
+ "bank_austria",
+ "bankhaus_carl_spangler",
+ "bankhaus_schelhammer_und_schattera_ag",
+ "bawag_psk_ag",
+ "bks_bank_ag",
+ "brull_kallmus_bank_ag",
+ "btv_vier_lander_bank",
+ "capital_bank_grawe_gruppe_ag",
+ "deutsche_bank_ag",
+ "dolomitenbank",
+ "easybank_ag",
+ "erste_bank_und_sparkassen",
+ "hypo_alpeadriabank_international_ag",
+ "hypo_bank_burgenland_aktiengesellschaft",
+ "hypo_noe_lb_fur_niederosterreich_u_wien",
+ "hypo_oberosterreich_salzburg_steiermark",
+ "hypo_tirol_bank_ag",
+ "hypo_vorarlberg_bank_ag",
+ "marchfelder_bank",
+ "oberbank_ag",
+ "raiffeisen_bankengruppe_osterreich",
+ "schoellerbank_ag",
+ "sparda_bank_wien",
+ "volksbank_gruppe",
+ "volkskreditbank_ag",
+ "vr_bank_braunau",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataFpx(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type for FPX transaction
+ """
+ bank: Literal[
+ "affin_bank",
+ "agrobank",
+ "alliance_bank",
+ "ambank",
+ "bank_islam",
+ "bank_muamalat",
+ "bank_of_china",
+ "bank_rakyat",
+ "bsn",
+ "cimb",
+ "deutsche_bank",
+ "hong_leong_bank",
+ "hsbc",
+ "kfh",
+ "maybank2e",
+ "maybank2u",
+ "ocbc",
+ "pb_enterprise",
+ "public_bank",
+ "rhb",
+ "standard_chartered",
+ "uob",
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataGiropay(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataGrabpay(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataIdeal(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "abn_amro",
+ "asn_bank",
+ "bunq",
+ "buut",
+ "handelsbanken",
+ "ing",
+ "knab",
+ "moneyou",
+ "n26",
+ "nn",
+ "rabobank",
+ "regiobank",
+ "revolut",
+ "sns_bank",
+ "triodos_bank",
+ "van_lanschot",
+ "yoursafe",
+ ]
+ ]
+ """
+ The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataInteracPresent(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataKakaoPay(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataKlarna(TypedDict):
+ dob: NotRequired["PaymentIntentModifyParamsPaymentMethodDataKlarnaDob"]
+ """
+ Customer's date of birth
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataKlarnaDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataKonbini(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataKrCard(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataLink(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataMbWay(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataMobilepay(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataMultibanco(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataNaverPay(TypedDict):
+ funding: NotRequired[Literal["card", "points"]]
+ """
+ Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataNzBankAccount(TypedDict):
+ account_holder_name: NotRequired[str]
+ """
+ The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
+ """
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bank_code: str
+ """
+ The numeric code for the bank account's bank.
+ """
+ branch_code: str
+ """
+ The numeric code for the bank account's bank branch.
+ """
+ reference: NotRequired[str]
+ suffix: str
+ """
+ The suffix of the bank account number.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataOxxo(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataP24(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "alior_bank",
+ "bank_millennium",
+ "bank_nowy_bfg_sa",
+ "bank_pekao_sa",
+ "banki_spbdzielcze",
+ "blik",
+ "bnp_paribas",
+ "boz",
+ "citi_handlowy",
+ "credit_agricole",
+ "envelobank",
+ "etransfer_pocztowy24",
+ "getin_bank",
+ "ideabank",
+ "ing",
+ "inteligo",
+ "mbank_mtransfer",
+ "nest_przelew",
+ "noble_pay",
+ "pbac_z_ipko",
+ "plus_bank",
+ "santander_przelew24",
+ "tmobile_usbugi_bankowe",
+ "toyota_bank",
+ "velobank",
+ "volkswagen_bank",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataPayByBank(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataPayco(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataPaynow(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataPaypal(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataPix(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataPromptpay(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataRadarOptions(TypedDict):
+ session: NotRequired[str]
+ """
+ A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataRevolutPay(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataSamsungPay(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataSatispay(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataSepaDebit(TypedDict):
+ iban: str
+ """
+ IBAN of the bank account.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataSofort(TypedDict):
+ country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
+ """
+ Two-letter ISO code representing the country the bank account is located in.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataSwish(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataTwint(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataUsBankAccount(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type: individual or company.
+ """
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account.
+ """
+ account_type: NotRequired[Literal["checking", "savings"]]
+ """
+ Account type: checkings or savings. Defaults to checking if omitted.
+ """
+ financial_connections_account: NotRequired[str]
+ """
+ The ID of a Financial Connections Account to use as a payment method.
+ """
+ routing_number: NotRequired[str]
+ """
+ Routing number of the bank account.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodDataWechatPay(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodDataZip(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodOptions(TypedDict):
+ acss_debit: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsAcssDebit"
+ ]
+ """
+ If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
+ """
+ affirm: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsAffirm"
+ ]
+ """
+ If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
+ """
+ afterpay_clearpay: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsAfterpayClearpay"
+ ]
+ """
+ If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
+ """
+ alipay: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsAlipay"
+ ]
+ """
+ If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
+ """
+ alma: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsAlma"
+ ]
+ """
+ If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
+ """
+ amazon_pay: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsAmazonPay"
+ ]
+ """
+ If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
+ """
+ au_becs_debit: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsAuBecsDebit"
+ ]
+ """
+ If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
+ """
+ bacs_debit: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
+ """
+ bancontact: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsBancontact"
+ ]
+ """
+ If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
+ """
+ billie: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsBillie"
+ ]
+ """
+ If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
+ """
+ blik: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsBlik"
+ ]
+ """
+ If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
+ """
+ boleto: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsBoleto"
+ ]
+ """
+ If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
+ """
+ card: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsCard"
+ ]
+ """
+ Configuration for any card payments attempted on this PaymentIntent.
+ """
+ card_present: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsCardPresent"
+ ]
+ """
+ If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
+ """
+ cashapp: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsCashapp"
+ ]
+ """
+ If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
+ """
+ crypto: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsCrypto"
+ ]
+ """
+ If this is a `crypto` PaymentMethod, this sub-hash contains details about the Crypto payment method options.
+ """
+ customer_balance: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsCustomerBalance"
+ ]
+ """
+ If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
+ """
+ eps: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsEps"
+ ]
+ """
+ If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
+ """
+ fpx: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsFpx"
+ ]
+ """
+ If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
+ """
+ giropay: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsGiropay"
+ ]
+ """
+ If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
+ """
+ grabpay: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsGrabpay"
+ ]
+ """
+ If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
+ """
+ ideal: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsIdeal"
+ ]
+ """
+ If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
+ """
+ interac_present: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsInteracPresent"
+ ]
+ """
+ If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
+ """
+ kakao_pay: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsKakaoPay"
+ ]
+ """
+ If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
+ """
+ klarna: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsKlarna"
+ ]
+ """
+ If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
+ """
+ konbini: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsKonbini"
+ ]
+ """
+ If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
+ """
+ kr_card: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsKrCard"
+ ]
+ """
+ If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
+ """
+ link: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsLink"
+ ]
+ """
+ If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
+ """
+ mb_way: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsMbWay"
+ ]
+ """
+ If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
+ """
+ mobilepay: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsMobilepay"
+ ]
+ """
+ If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
+ """
+ multibanco: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsMultibanco"
+ ]
+ """
+ If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
+ """
+ naver_pay: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsNaverPay"
+ ]
+ """
+ If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
+ """
+ nz_bank_account: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsNzBankAccount"
+ ]
+ """
+ If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
+ """
+ oxxo: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsOxxo"
+ ]
+ """
+ If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
+ """
+ p24: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsP24"
+ ]
+ """
+ If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
+ """
+ pay_by_bank: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsPayByBank"
+ ]
+ """
+ If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
+ """
+ payco: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsPayco"
+ ]
+ """
+ If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
+ """
+ paynow: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsPaynow"
+ ]
+ """
+ If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
+ """
+ paypal: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsPaypal"
+ ]
+ """
+ If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
+ """
+ pix: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsPix"
+ ]
+ """
+ If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
+ """
+ promptpay: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsPromptpay"
+ ]
+ """
+ If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
+ """
+ revolut_pay: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsRevolutPay"
+ ]
+ """
+ If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
+ """
+ samsung_pay: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsSamsungPay"
+ ]
+ """
+ If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
+ """
+ satispay: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsSatispay"
+ ]
+ """
+ If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
+ """
+ sepa_debit: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
+ """
+ sofort: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsSofort"
+ ]
+ """
+ If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
+ """
+ swish: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsSwish"
+ ]
+ """
+ If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
+ """
+ twint: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsTwint"
+ ]
+ """
+ If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
+ """
+ us_bank_account: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
+ """
+ wechat_pay: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsWechatPay"
+ ]
+ """
+ If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
+ """
+ zip: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsZip"
+ ]
+ """
+ If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsAcssDebit(TypedDict):
+ mandate_options: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsAcssDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsAcssDebitMandateOptions(
+ TypedDict,
+):
+ custom_mandate_url: NotRequired["Literal['']|str"]
+ """
+ A URL for custom mandate text to render during confirmation step.
+ The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
+ or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
+ """
+ interval_description: NotRequired[str]
+ """
+ Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
+ """
+ payment_schedule: NotRequired[Literal["combined", "interval", "sporadic"]]
+ """
+ Payment schedule for the mandate.
+ """
+ transaction_type: NotRequired[Literal["business", "personal"]]
+ """
+ Transaction type of the mandate.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsAffirm(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ preferred_locale: NotRequired[str]
+ """
+ Preferred language of the Affirm authorization page that the customer is redirected to.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsAfterpayClearpay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ reference: NotRequired[str]
+ """
+ An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
+ This field differs from the statement descriptor and item name.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsAlipay(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsAlma(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsAmazonPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsAuBecsDebit(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsBacsDebit(TypedDict):
+ mandate_options: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsBacsDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsBacsDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsBancontact(TypedDict):
+ preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
+ """
+ Preferred language of the Bancontact authorization page that the customer is redirected to.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsBillie(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsBlik(TypedDict):
+ code: NotRequired[str]
+ """
+ The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
+ """
+ setup_future_usage: NotRequired["Literal['']|Literal['none']"]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsBoleto(TypedDict):
+ expires_after_days: NotRequired[int]
+ """
+ The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsCard(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ cvc_token: NotRequired[str]
+ """
+ A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
+ """
+ installments: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsCardInstallments"
+ ]
+ """
+ Installment configuration for payments attempted on this PaymentIntent.
+
+ For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
+ """
+ mandate_options: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsCardMandateOptions"
+ ]
+ """
+ Configuration options for setting up an eMandate for cards issued in India.
+ """
+ moto: NotRequired[bool]
+ """
+ When specified, this parameter indicates that a transaction will be marked
+ as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
+ parameter can only be provided during confirmation.
+ """
+ network: NotRequired[
+ Literal[
+ "amex",
+ "cartes_bancaires",
+ "diners",
+ "discover",
+ "eftpos_au",
+ "girocard",
+ "interac",
+ "jcb",
+ "link",
+ "mastercard",
+ "unionpay",
+ "unknown",
+ "visa",
+ ]
+ ]
+ """
+ Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
+ """
+ request_extended_authorization: NotRequired[
+ Literal["if_available", "never"]
+ ]
+ """
+ Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
+ """
+ request_incremental_authorization: NotRequired[
+ Literal["if_available", "never"]
+ ]
+ """
+ Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
+ """
+ request_multicapture: NotRequired[Literal["if_available", "never"]]
+ """
+ Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
+ """
+ request_overcapture: NotRequired[Literal["if_available", "never"]]
+ """
+ Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
+ """
+ request_three_d_secure: NotRequired[
+ Literal["any", "automatic", "challenge"]
+ ]
+ """
+ We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
+ """
+ require_cvc_recollection: NotRequired[bool]
+ """
+ When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ statement_descriptor_suffix_kana: NotRequired["Literal['']|str"]
+ """
+ Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that's set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
+ """
+ statement_descriptor_suffix_kanji: NotRequired["Literal['']|str"]
+ """
+ Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that's set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
+ """
+ three_d_secure: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsCardThreeDSecure"
+ ]
+ """
+ If 3D Secure authentication was performed with a third-party provider,
+ the authentication details to use for this payment.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsCardInstallments(TypedDict):
+ enabled: NotRequired[bool]
+ """
+ Setting to true enables installments for this PaymentIntent.
+ This will cause the response to contain a list of available installment plans.
+ Setting to false will prevent any selected plan from applying to a charge.
+ """
+ plan: NotRequired[
+ "Literal['']|PaymentIntentModifyParamsPaymentMethodOptionsCardInstallmentsPlan"
+ ]
+ """
+ The selected installment plan to use for this payment attempt.
+ This parameter can only be provided during confirmation.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsCardInstallmentsPlan(
+ TypedDict,
+):
+ count: NotRequired[int]
+ """
+ For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
+ """
+ interval: NotRequired[Literal["month"]]
+ """
+ For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
+ One of `month`.
+ """
+ type: Literal["bonus", "fixed_count", "revolving"]
+ """
+ Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsCardMandateOptions(
+ TypedDict,
+):
+ amount: int
+ """
+ Amount to be charged for future payments.
+ """
+ amount_type: Literal["fixed", "maximum"]
+ """
+ One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
+ """
+ description: NotRequired[str]
+ """
+ A description of the mandate or subscription that is meant to be displayed to the customer.
+ """
+ end_date: NotRequired[int]
+ """
+ End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
+ """
+ interval: Literal["day", "month", "sporadic", "week", "year"]
+ """
+ Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
+ """
+ reference: str
+ """
+ Unique identifier for the mandate or subscription.
+ """
+ start_date: int
+ """
+ Start date of the mandate or subscription. Start date should not be lesser than yesterday.
+ """
+ supported_types: NotRequired[List[Literal["india"]]]
+ """
+ Specifies the type of mandates supported. Possible values are `india`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
+ ares_trans_status: NotRequired[Literal["A", "C", "I", "N", "R", "U", "Y"]]
+ """
+ The `transStatus` returned from the card Issuer's ACS in the ARes.
+ """
+ cryptogram: str
+ """
+ The cryptogram, also known as the "authentication value" (AAV, CAVV or
+ AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
+ (Most 3D Secure providers will return the base64-encoded version, which
+ is what you should specify here.)
+ """
+ electronic_commerce_indicator: NotRequired[
+ Literal["01", "02", "05", "06", "07"]
+ ]
+ """
+ The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
+ provider and indicates what degree of authentication was performed.
+ """
+ exemption_indicator: NotRequired[Literal["low_risk", "none"]]
+ """
+ The exemption requested via 3DS and accepted by the issuer at authentication time.
+ """
+ network_options: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
+ ]
+ """
+ Network specific 3DS fields. Network specific arguments require an
+ explicit card brand choice. The parameter `payment_method_options.card.network``
+ must be populated accordingly
+ """
+ requestor_challenge_indicator: NotRequired[str]
+ """
+ The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
+ AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
+ """
+ transaction_id: str
+ """
+ For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
+ Transaction ID (dsTransID).
+ """
+ version: Literal["1.0.2", "2.1.0", "2.2.0"]
+ """
+ The version of 3D Secure that was performed.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
+ TypedDict,
+):
+ cartes_bancaires: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
+ ]
+ """
+ Cartes Bancaires-specific 3DS fields.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
+ TypedDict,
+):
+ cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
+ """
+ The cryptogram calculation algorithm used by the card Issuer's ACS
+ to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
+ messageExtension: CB-AVALGO
+ """
+ cb_exemption: NotRequired[str]
+ """
+ The exemption indicator returned from Cartes Bancaires in the ARes.
+ message extension: CB-EXEMPTION; string (4 characters)
+ This is a 3 byte bitmap (low significant byte first and most significant
+ bit first) that has been Base64 encoded
+ """
+ cb_score: NotRequired[int]
+ """
+ The risk score returned from Cartes Bancaires in the ARes.
+ message extension: CB-SCORE; numeric value 0-99
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsCardPresent(TypedDict):
+ request_extended_authorization: NotRequired[bool]
+ """
+ Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
+ """
+ request_incremental_authorization_support: NotRequired[bool]
+ """
+ Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
+ """
+ routing: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsCardPresentRouting"
+ ]
+ """
+ Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsCardPresentRouting(
+ TypedDict,
+):
+ requested_priority: NotRequired[Literal["domestic", "international"]]
+ """
+ Routing requested priority
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsCashapp(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsCrypto(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsCustomerBalance(TypedDict):
+ bank_transfer: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsCustomerBalanceBankTransfer"
+ ]
+ """
+ Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
+ """
+ funding_type: NotRequired[Literal["bank_transfer"]]
+ """
+ The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsCustomerBalanceBankTransfer(
+ TypedDict,
+):
+ eu_bank_transfer: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
+ ]
+ """
+ Configuration for the eu_bank_transfer funding type.
+ """
+ requested_address_types: NotRequired[
+ List[
+ Literal[
+ "aba", "iban", "sepa", "sort_code", "spei", "swift", "zengin"
+ ]
+ ]
+ ]
+ """
+ List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
+
+ Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
+ """
+ type: Literal[
+ "eu_bank_transfer",
+ "gb_bank_transfer",
+ "jp_bank_transfer",
+ "mx_bank_transfer",
+ "us_bank_transfer",
+ ]
+ """
+ The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
+ TypedDict,
+):
+ country: str
+ """
+ The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsEps(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsFpx(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsGiropay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsGrabpay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsIdeal(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsInteracPresent(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsKakaoPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsKlarna(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ on_demand: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsKlarnaOnDemand"
+ ]
+ """
+ On-demand details if setting up or charging an on-demand payment.
+ """
+ preferred_locale: NotRequired[
+ Literal[
+ "cs-CZ",
+ "da-DK",
+ "de-AT",
+ "de-CH",
+ "de-DE",
+ "el-GR",
+ "en-AT",
+ "en-AU",
+ "en-BE",
+ "en-CA",
+ "en-CH",
+ "en-CZ",
+ "en-DE",
+ "en-DK",
+ "en-ES",
+ "en-FI",
+ "en-FR",
+ "en-GB",
+ "en-GR",
+ "en-IE",
+ "en-IT",
+ "en-NL",
+ "en-NO",
+ "en-NZ",
+ "en-PL",
+ "en-PT",
+ "en-RO",
+ "en-SE",
+ "en-US",
+ "es-ES",
+ "es-US",
+ "fi-FI",
+ "fr-BE",
+ "fr-CA",
+ "fr-CH",
+ "fr-FR",
+ "it-CH",
+ "it-IT",
+ "nb-NO",
+ "nl-BE",
+ "nl-NL",
+ "pl-PL",
+ "pt-PT",
+ "ro-RO",
+ "sv-FI",
+ "sv-SE",
+ ]
+ ]
+ """
+ Preferred language of the Klarna authorization page that the customer is redirected to
+ """
+ setup_future_usage: NotRequired[
+ Literal["none", "off_session", "on_session"]
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ subscriptions: NotRequired[
+ "Literal['']|List[PaymentIntentModifyParamsPaymentMethodOptionsKlarnaSubscription]"
+ ]
+ """
+ Subscription details if setting up or charging a subscription.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
+ average_amount: NotRequired[int]
+ """
+ Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ maximum_amount: NotRequired[int]
+ """
+ The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ minimum_amount: NotRequired[int]
+ """
+ The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
+ """
+ Interval at which the customer is making purchases
+ """
+ purchase_interval_count: NotRequired[int]
+ """
+ The number of `purchase_interval` between charges
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsKlarnaSubscription(
+ TypedDict,
+):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Unit of time between subscription charges.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
+ """
+ name: NotRequired[str]
+ """
+ Name for subscription.
+ """
+ next_billing: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
+ ]
+ """
+ Describes the upcoming charge for this subscription.
+ """
+ reference: str
+ """
+ A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
+ TypedDict,
+):
+ amount: int
+ """
+ The amount of the next charge for the subscription.
+ """
+ date: str
+ """
+ The date of the next charge for the subscription in YYYY-MM-DD format.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsKonbini(TypedDict):
+ confirmation_number: NotRequired["Literal['']|str"]
+ """
+ An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
+ """
+ expires_after_days: NotRequired["Literal['']|int"]
+ """
+ The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
+ """
+ expires_at: NotRequired["Literal['']|int"]
+ """
+ The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsKrCard(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsLink(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ persistent_token: NotRequired[str]
+ """
+ [Deprecated] This is a legacy parameter that no longer has any function.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsMbWay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsMobilepay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsMultibanco(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsNaverPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsNzBankAccount(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsOxxo(TypedDict):
+ expires_after_days: NotRequired[int]
+ """
+ The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsP24(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ tos_shown_and_accepted: NotRequired[bool]
+ """
+ Confirm that the payer has accepted the P24 terms and conditions.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsPayByBank(TypedDict):
+ pass
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsPayco(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsPaynow(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsPaypal(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ preferred_locale: NotRequired[
+ Literal[
+ "cs-CZ",
+ "da-DK",
+ "de-AT",
+ "de-DE",
+ "de-LU",
+ "el-GR",
+ "en-GB",
+ "en-US",
+ "es-ES",
+ "fi-FI",
+ "fr-BE",
+ "fr-FR",
+ "fr-LU",
+ "hu-HU",
+ "it-IT",
+ "nl-BE",
+ "nl-NL",
+ "pl-PL",
+ "pt-PT",
+ "sk-SK",
+ "sv-SE",
+ ]
+ ]
+ """
+ [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
+ """
+ reference: NotRequired[str]
+ """
+ A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
+ """
+ risk_correlation_id: NotRequired[str]
+ """
+ The risk correlation ID for an on-session payment using a saved PayPal payment method.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsPix(TypedDict):
+ amount_includes_iof: NotRequired[Literal["always", "never"]]
+ """
+ Determines if the amount includes the IOF tax. Defaults to `never`.
+ """
+ expires_after_seconds: NotRequired[int]
+ """
+ The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
+ """
+ expires_at: NotRequired[int]
+ """
+ The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsPromptpay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsRevolutPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsSamsungPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsSatispay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsSepaDebit(TypedDict):
+ mandate_options: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsSepaDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsSepaDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsSofort(TypedDict):
+ preferred_language: NotRequired[
+ "Literal['']|Literal['de', 'en', 'es', 'fr', 'it', 'nl', 'pl']"
+ ]
+ """
+ Language shown to the payer on redirect.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsSwish(TypedDict):
+ reference: NotRequired["Literal['']|str"]
+ """
+ A reference for this payment to be displayed in the Swish app.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsTwint(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsUsBankAccount(TypedDict):
+ financial_connections: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
+ ]
+ """
+ Additional fields for Financial Connections Session creation
+ """
+ mandate_options: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsUsBankAccountMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ networks: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsUsBankAccountNetworks"
+ ]
+ """
+ Additional fields for network related functions
+ """
+ preferred_settlement_speed: NotRequired[
+ "Literal['']|Literal['fastest', 'standard']"
+ ]
+ """
+ Preferred transaction settlement speed
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
+ TypedDict,
+):
+ filters: NotRequired[
+ "PaymentIntentModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
+ ]
+ """
+ Provide filters for the linked accounts that the customer can select for the payment method.
+ """
+ permissions: NotRequired[
+ List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ ]
+ """
+ The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+ return_url: NotRequired[str]
+ """
+ For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
+ TypedDict,
+):
+ account_subcategories: NotRequired[List[Literal["checking", "savings"]]]
+ """
+ The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsUsBankAccountMandateOptions(
+ TypedDict,
+):
+ collection_method: NotRequired["Literal['']|Literal['paper']"]
+ """
+ The method used to collect offline mandate customer acceptance.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsUsBankAccountNetworks(
+ TypedDict,
+):
+ requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
+ """
+ Triggers validations to run across the selected networks
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsWechatPay(TypedDict):
+ app_id: NotRequired[str]
+ """
+ The app ID registered with WeChat Pay. Only required when client is ios or android.
+ """
+ client: NotRequired[Literal["android", "ios", "web"]]
+ """
+ The client type that the end customer will pay from
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsPaymentMethodOptionsZip(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentModifyParamsShipping(TypedDict):
+ address: "PaymentIntentModifyParamsShippingAddress"
+ """
+ Shipping address.
+ """
+ carrier: NotRequired[str]
+ """
+ The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
+ """
+ name: str
+ """
+ Recipient name.
+ """
+ phone: NotRequired[str]
+ """
+ Recipient phone (including extension).
+ """
+ tracking_number: NotRequired[str]
+ """
+ The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
+ """
+
+
+class PaymentIntentModifyParamsShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class PaymentIntentModifyParamsTransferData(TypedDict):
+ amount: NotRequired[int]
+ """
+ The amount that will be transferred automatically when a charge succeeds.
+ """
diff --git a/stripe/params/_payment_intent_retrieve_params.py b/stripe/params/_payment_intent_retrieve_params.py
new file mode 100644
index 000000000..ab9d23dd0
--- /dev/null
+++ b/stripe/params/_payment_intent_retrieve_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentIntentRetrieveParams(RequestOptions):
+ client_secret: NotRequired[str]
+ """
+ The client secret of the PaymentIntent. We require it if you use a publishable key to retrieve the source.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payment_intent_search_params.py b/stripe/params/_payment_intent_search_params.py
new file mode 100644
index 000000000..53c3cc376
--- /dev/null
+++ b/stripe/params/_payment_intent_search_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentIntentSearchParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ page: NotRequired[str]
+ """
+ A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
+ """
+ query: str
+ """
+ The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for payment intents](https://stripe.com/docs/search#query-fields-for-payment-intents).
+ """
diff --git a/stripe/params/_payment_intent_update_params.py b/stripe/params/_payment_intent_update_params.py
new file mode 100644
index 000000000..e24322f22
--- /dev/null
+++ b/stripe/params/_payment_intent_update_params.py
@@ -0,0 +1,2846 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PaymentIntentUpdateParams(TypedDict):
+ amount: NotRequired[int]
+ """
+ Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
+ """
+ application_fee_amount: NotRequired["Literal['']|int"]
+ """
+ The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+ capture_method: NotRequired[
+ Literal["automatic", "automatic_async", "manual"]
+ ]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ customer: NotRequired[str]
+ """
+ ID of the Customer this PaymentIntent belongs to, if one exists.
+
+ Payment methods attached to other Customers cannot be used with this PaymentIntent.
+
+ If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ excluded_payment_method_types: NotRequired[
+ "Literal['']|List[Literal['acss_debit', 'affirm', 'afterpay_clearpay', 'alipay', 'alma', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'billie', 'blik', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'mb_way', 'mobilepay', 'multibanco', 'naver_pay', 'nz_bank_account', 'oxxo', 'p24', 'pay_by_bank', 'payco', 'paynow', 'paypal', 'pix', 'promptpay', 'revolut_pay', 'samsung_pay', 'satispay', 'sepa_debit', 'sofort', 'swish', 'twint', 'us_bank_account', 'wechat_pay', 'zip']]"
+ ]
+ """
+ The list of payment method types to exclude from use with this payment.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ payment_method: NotRequired[str]
+ """
+ ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods/transitioning#compatibility) object) to attach to this PaymentIntent. To unset this field to null, pass in an empty string.
+ """
+ payment_method_configuration: NotRequired[str]
+ """
+ The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this PaymentIntent.
+ """
+ payment_method_data: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodData"
+ ]
+ """
+ If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
+ in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
+ property on the PaymentIntent.
+ """
+ payment_method_options: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptions"
+ ]
+ """
+ Payment-method-specific configuration for this PaymentIntent.
+ """
+ payment_method_types: NotRequired[List[str]]
+ """
+ The list of payment method types (for example, card) that this PaymentIntent can use. Use `automatic_payment_methods` to manage payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
+ """
+ receipt_email: NotRequired["Literal['']|str"]
+ """
+ Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ shipping: NotRequired["Literal['']|PaymentIntentUpdateParamsShipping"]
+ """
+ Shipping information for this PaymentIntent.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
+
+ Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
+ """
+ statement_descriptor_suffix: NotRequired[str]
+ """
+ Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
+ """
+ transfer_data: NotRequired["PaymentIntentUpdateParamsTransferData"]
+ """
+ Use this parameter to automatically create a Transfer when the payment succeeds. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+ transfer_group: NotRequired[str]
+ """
+ A string that identifies the resulting payment as part of a group. You can only provide `transfer_group` if it hasn't been set. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodData(TypedDict):
+ acss_debit: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataAcssDebit"
+ ]
+ """
+ If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
+ """
+ affirm: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataAffirm"]
+ """
+ If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
+ """
+ afterpay_clearpay: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataAfterpayClearpay"
+ ]
+ """
+ If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
+ """
+ alipay: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataAlipay"]
+ """
+ If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
+ """
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
+ """
+ alma: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataAlma"]
+ """
+ If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
+ """
+ amazon_pay: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataAmazonPay"
+ ]
+ """
+ If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
+ """
+ au_becs_debit: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataAuBecsDebit"
+ ]
+ """
+ If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
+ """
+ bacs_debit: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
+ """
+ bancontact: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataBancontact"
+ ]
+ """
+ If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
+ """
+ billie: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataBillie"]
+ """
+ If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
+ """
+ billing_details: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataBillingDetails"
+ ]
+ """
+ Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+ """
+ blik: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataBlik"]
+ """
+ If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
+ """
+ boleto: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataBoleto"]
+ """
+ If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
+ """
+ cashapp: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataCashapp"]
+ """
+ If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
+ """
+ crypto: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataCrypto"]
+ """
+ If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
+ """
+ customer_balance: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataCustomerBalance"
+ ]
+ """
+ If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
+ """
+ eps: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataEps"]
+ """
+ If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
+ """
+ fpx: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataFpx"]
+ """
+ If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
+ """
+ giropay: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataGiropay"]
+ """
+ If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
+ """
+ grabpay: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataGrabpay"]
+ """
+ If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
+ """
+ ideal: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataIdeal"]
+ """
+ If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
+ """
+ interac_present: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataInteracPresent"
+ ]
+ """
+ If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
+ """
+ kakao_pay: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataKakaoPay"
+ ]
+ """
+ If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
+ """
+ klarna: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataKlarna"]
+ """
+ If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
+ """
+ konbini: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataKonbini"]
+ """
+ If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
+ """
+ kr_card: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataKrCard"]
+ """
+ If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
+ """
+ link: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataLink"]
+ """
+ If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
+ """
+ mb_way: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataMbWay"]
+ """
+ If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ mobilepay: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataMobilepay"
+ ]
+ """
+ If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
+ """
+ multibanco: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataMultibanco"
+ ]
+ """
+ If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
+ """
+ naver_pay: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataNaverPay"
+ ]
+ """
+ If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
+ """
+ nz_bank_account: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataNzBankAccount"
+ ]
+ """
+ If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
+ """
+ oxxo: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataOxxo"]
+ """
+ If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
+ """
+ p24: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataP24"]
+ """
+ If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
+ """
+ pay_by_bank: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataPayByBank"
+ ]
+ """
+ If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
+ """
+ payco: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataPayco"]
+ """
+ If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
+ """
+ paynow: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataPaynow"]
+ """
+ If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
+ """
+ paypal: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataPaypal"]
+ """
+ If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
+ """
+ pix: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataPix"]
+ """
+ If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
+ """
+ promptpay: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataPromptpay"
+ ]
+ """
+ If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
+ """
+ radar_options: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataRadarOptions"
+ ]
+ """
+ Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
+ """
+ revolut_pay: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataRevolutPay"
+ ]
+ """
+ If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
+ """
+ samsung_pay: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataSamsungPay"
+ ]
+ """
+ If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
+ """
+ satispay: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataSatispay"]
+ """
+ If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
+ """
+ sepa_debit: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
+ """
+ sofort: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataSofort"]
+ """
+ If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
+ """
+ swish: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataSwish"]
+ """
+ If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
+ """
+ twint: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataTwint"]
+ """
+ If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
+ """
+ type: Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "link",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ """
+ The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
+ """
+ us_bank_account: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataUsBankAccount"
+ ]
+ """
+ If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
+ """
+ wechat_pay: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodDataWechatPay"
+ ]
+ """
+ If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
+ """
+ zip: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataZip"]
+ """
+ If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataAcssDebit(TypedDict):
+ account_number: str
+ """
+ Customer's bank account number.
+ """
+ institution_number: str
+ """
+ Institution number of the customer's bank.
+ """
+ transit_number: str
+ """
+ Transit number of the customer's bank.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataAffirm(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataAfterpayClearpay(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataAlipay(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataAlma(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataAmazonPay(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataAuBecsDebit(TypedDict):
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bsb_number: str
+ """
+ Bank-State-Branch number of the bank account.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataBacsDebit(TypedDict):
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account that the funds will be debited from.
+ """
+ sort_code: NotRequired[str]
+ """
+ Sort code of the bank account. (e.g., `10-20-30`)
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataBancontact(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataBillie(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataBillingDetails(TypedDict):
+ address: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodDataBillingDetailsAddress"
+ ]
+ """
+ Billing address.
+ """
+ email: NotRequired["Literal['']|str"]
+ """
+ Email address.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Full name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Billing phone number (including extension).
+ """
+ tax_id: NotRequired[str]
+ """
+ Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataBillingDetailsAddress(
+ TypedDict,
+):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataBlik(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataBoleto(TypedDict):
+ tax_id: str
+ """
+ The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataCashapp(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataCrypto(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataCustomerBalance(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataEps(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "arzte_und_apotheker_bank",
+ "austrian_anadi_bank_ag",
+ "bank_austria",
+ "bankhaus_carl_spangler",
+ "bankhaus_schelhammer_und_schattera_ag",
+ "bawag_psk_ag",
+ "bks_bank_ag",
+ "brull_kallmus_bank_ag",
+ "btv_vier_lander_bank",
+ "capital_bank_grawe_gruppe_ag",
+ "deutsche_bank_ag",
+ "dolomitenbank",
+ "easybank_ag",
+ "erste_bank_und_sparkassen",
+ "hypo_alpeadriabank_international_ag",
+ "hypo_bank_burgenland_aktiengesellschaft",
+ "hypo_noe_lb_fur_niederosterreich_u_wien",
+ "hypo_oberosterreich_salzburg_steiermark",
+ "hypo_tirol_bank_ag",
+ "hypo_vorarlberg_bank_ag",
+ "marchfelder_bank",
+ "oberbank_ag",
+ "raiffeisen_bankengruppe_osterreich",
+ "schoellerbank_ag",
+ "sparda_bank_wien",
+ "volksbank_gruppe",
+ "volkskreditbank_ag",
+ "vr_bank_braunau",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataFpx(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type for FPX transaction
+ """
+ bank: Literal[
+ "affin_bank",
+ "agrobank",
+ "alliance_bank",
+ "ambank",
+ "bank_islam",
+ "bank_muamalat",
+ "bank_of_china",
+ "bank_rakyat",
+ "bsn",
+ "cimb",
+ "deutsche_bank",
+ "hong_leong_bank",
+ "hsbc",
+ "kfh",
+ "maybank2e",
+ "maybank2u",
+ "ocbc",
+ "pb_enterprise",
+ "public_bank",
+ "rhb",
+ "standard_chartered",
+ "uob",
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataGiropay(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataGrabpay(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataIdeal(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "abn_amro",
+ "asn_bank",
+ "bunq",
+ "buut",
+ "handelsbanken",
+ "ing",
+ "knab",
+ "moneyou",
+ "n26",
+ "nn",
+ "rabobank",
+ "regiobank",
+ "revolut",
+ "sns_bank",
+ "triodos_bank",
+ "van_lanschot",
+ "yoursafe",
+ ]
+ ]
+ """
+ The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataInteracPresent(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataKakaoPay(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataKlarna(TypedDict):
+ dob: NotRequired["PaymentIntentUpdateParamsPaymentMethodDataKlarnaDob"]
+ """
+ Customer's date of birth
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataKlarnaDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataKonbini(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataKrCard(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataLink(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataMbWay(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataMobilepay(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataMultibanco(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataNaverPay(TypedDict):
+ funding: NotRequired[Literal["card", "points"]]
+ """
+ Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataNzBankAccount(TypedDict):
+ account_holder_name: NotRequired[str]
+ """
+ The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
+ """
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bank_code: str
+ """
+ The numeric code for the bank account's bank.
+ """
+ branch_code: str
+ """
+ The numeric code for the bank account's bank branch.
+ """
+ reference: NotRequired[str]
+ suffix: str
+ """
+ The suffix of the bank account number.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataOxxo(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataP24(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "alior_bank",
+ "bank_millennium",
+ "bank_nowy_bfg_sa",
+ "bank_pekao_sa",
+ "banki_spbdzielcze",
+ "blik",
+ "bnp_paribas",
+ "boz",
+ "citi_handlowy",
+ "credit_agricole",
+ "envelobank",
+ "etransfer_pocztowy24",
+ "getin_bank",
+ "ideabank",
+ "ing",
+ "inteligo",
+ "mbank_mtransfer",
+ "nest_przelew",
+ "noble_pay",
+ "pbac_z_ipko",
+ "plus_bank",
+ "santander_przelew24",
+ "tmobile_usbugi_bankowe",
+ "toyota_bank",
+ "velobank",
+ "volkswagen_bank",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataPayByBank(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataPayco(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataPaynow(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataPaypal(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataPix(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataPromptpay(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataRadarOptions(TypedDict):
+ session: NotRequired[str]
+ """
+ A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataRevolutPay(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataSamsungPay(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataSatispay(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataSepaDebit(TypedDict):
+ iban: str
+ """
+ IBAN of the bank account.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataSofort(TypedDict):
+ country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
+ """
+ Two-letter ISO code representing the country the bank account is located in.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataSwish(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataTwint(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataUsBankAccount(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type: individual or company.
+ """
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account.
+ """
+ account_type: NotRequired[Literal["checking", "savings"]]
+ """
+ Account type: checkings or savings. Defaults to checking if omitted.
+ """
+ financial_connections_account: NotRequired[str]
+ """
+ The ID of a Financial Connections Account to use as a payment method.
+ """
+ routing_number: NotRequired[str]
+ """
+ Routing number of the bank account.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataWechatPay(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodDataZip(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptions(TypedDict):
+ acss_debit: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsAcssDebit"
+ ]
+ """
+ If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
+ """
+ affirm: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsAffirm"
+ ]
+ """
+ If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
+ """
+ afterpay_clearpay: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsAfterpayClearpay"
+ ]
+ """
+ If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
+ """
+ alipay: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsAlipay"
+ ]
+ """
+ If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
+ """
+ alma: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsAlma"
+ ]
+ """
+ If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
+ """
+ amazon_pay: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsAmazonPay"
+ ]
+ """
+ If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
+ """
+ au_becs_debit: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsAuBecsDebit"
+ ]
+ """
+ If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
+ """
+ bacs_debit: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
+ """
+ bancontact: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsBancontact"
+ ]
+ """
+ If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
+ """
+ billie: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsBillie"
+ ]
+ """
+ If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
+ """
+ blik: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsBlik"
+ ]
+ """
+ If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
+ """
+ boleto: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsBoleto"
+ ]
+ """
+ If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
+ """
+ card: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsCard"
+ ]
+ """
+ Configuration for any card payments attempted on this PaymentIntent.
+ """
+ card_present: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsCardPresent"
+ ]
+ """
+ If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
+ """
+ cashapp: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsCashapp"
+ ]
+ """
+ If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
+ """
+ crypto: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsCrypto"
+ ]
+ """
+ If this is a `crypto` PaymentMethod, this sub-hash contains details about the Crypto payment method options.
+ """
+ customer_balance: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsCustomerBalance"
+ ]
+ """
+ If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
+ """
+ eps: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsEps"
+ ]
+ """
+ If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
+ """
+ fpx: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsFpx"
+ ]
+ """
+ If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
+ """
+ giropay: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsGiropay"
+ ]
+ """
+ If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
+ """
+ grabpay: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsGrabpay"
+ ]
+ """
+ If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
+ """
+ ideal: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsIdeal"
+ ]
+ """
+ If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
+ """
+ interac_present: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsInteracPresent"
+ ]
+ """
+ If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
+ """
+ kakao_pay: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsKakaoPay"
+ ]
+ """
+ If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
+ """
+ klarna: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsKlarna"
+ ]
+ """
+ If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
+ """
+ konbini: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsKonbini"
+ ]
+ """
+ If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
+ """
+ kr_card: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsKrCard"
+ ]
+ """
+ If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
+ """
+ link: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsLink"
+ ]
+ """
+ If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
+ """
+ mb_way: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsMbWay"
+ ]
+ """
+ If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
+ """
+ mobilepay: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsMobilepay"
+ ]
+ """
+ If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
+ """
+ multibanco: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsMultibanco"
+ ]
+ """
+ If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
+ """
+ naver_pay: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsNaverPay"
+ ]
+ """
+ If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
+ """
+ nz_bank_account: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsNzBankAccount"
+ ]
+ """
+ If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
+ """
+ oxxo: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsOxxo"
+ ]
+ """
+ If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
+ """
+ p24: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsP24"
+ ]
+ """
+ If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
+ """
+ pay_by_bank: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsPayByBank"
+ ]
+ """
+ If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
+ """
+ payco: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsPayco"
+ ]
+ """
+ If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
+ """
+ paynow: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsPaynow"
+ ]
+ """
+ If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
+ """
+ paypal: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsPaypal"
+ ]
+ """
+ If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
+ """
+ pix: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsPix"
+ ]
+ """
+ If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
+ """
+ promptpay: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsPromptpay"
+ ]
+ """
+ If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
+ """
+ revolut_pay: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsRevolutPay"
+ ]
+ """
+ If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
+ """
+ samsung_pay: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsSamsungPay"
+ ]
+ """
+ If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
+ """
+ satispay: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsSatispay"
+ ]
+ """
+ If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
+ """
+ sepa_debit: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
+ """
+ sofort: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsSofort"
+ ]
+ """
+ If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
+ """
+ swish: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsSwish"
+ ]
+ """
+ If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
+ """
+ twint: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsTwint"
+ ]
+ """
+ If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
+ """
+ us_bank_account: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
+ """
+ wechat_pay: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsWechatPay"
+ ]
+ """
+ If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
+ """
+ zip: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsZip"
+ ]
+ """
+ If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsAcssDebit(TypedDict):
+ mandate_options: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsAcssDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsAcssDebitMandateOptions(
+ TypedDict,
+):
+ custom_mandate_url: NotRequired["Literal['']|str"]
+ """
+ A URL for custom mandate text to render during confirmation step.
+ The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
+ or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
+ """
+ interval_description: NotRequired[str]
+ """
+ Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
+ """
+ payment_schedule: NotRequired[Literal["combined", "interval", "sporadic"]]
+ """
+ Payment schedule for the mandate.
+ """
+ transaction_type: NotRequired[Literal["business", "personal"]]
+ """
+ Transaction type of the mandate.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsAffirm(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ preferred_locale: NotRequired[str]
+ """
+ Preferred language of the Affirm authorization page that the customer is redirected to.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsAfterpayClearpay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ reference: NotRequired[str]
+ """
+ An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
+ This field differs from the statement descriptor and item name.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsAlipay(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsAlma(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsAmazonPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsAuBecsDebit(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsBacsDebit(TypedDict):
+ mandate_options: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsBacsDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsBacsDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsBancontact(TypedDict):
+ preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
+ """
+ Preferred language of the Bancontact authorization page that the customer is redirected to.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsBillie(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsBlik(TypedDict):
+ code: NotRequired[str]
+ """
+ The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
+ """
+ setup_future_usage: NotRequired["Literal['']|Literal['none']"]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsBoleto(TypedDict):
+ expires_after_days: NotRequired[int]
+ """
+ The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsCard(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ cvc_token: NotRequired[str]
+ """
+ A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
+ """
+ installments: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsCardInstallments"
+ ]
+ """
+ Installment configuration for payments attempted on this PaymentIntent.
+
+ For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
+ """
+ mandate_options: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsCardMandateOptions"
+ ]
+ """
+ Configuration options for setting up an eMandate for cards issued in India.
+ """
+ moto: NotRequired[bool]
+ """
+ When specified, this parameter indicates that a transaction will be marked
+ as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
+ parameter can only be provided during confirmation.
+ """
+ network: NotRequired[
+ Literal[
+ "amex",
+ "cartes_bancaires",
+ "diners",
+ "discover",
+ "eftpos_au",
+ "girocard",
+ "interac",
+ "jcb",
+ "link",
+ "mastercard",
+ "unionpay",
+ "unknown",
+ "visa",
+ ]
+ ]
+ """
+ Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
+ """
+ request_extended_authorization: NotRequired[
+ Literal["if_available", "never"]
+ ]
+ """
+ Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
+ """
+ request_incremental_authorization: NotRequired[
+ Literal["if_available", "never"]
+ ]
+ """
+ Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
+ """
+ request_multicapture: NotRequired[Literal["if_available", "never"]]
+ """
+ Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
+ """
+ request_overcapture: NotRequired[Literal["if_available", "never"]]
+ """
+ Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
+ """
+ request_three_d_secure: NotRequired[
+ Literal["any", "automatic", "challenge"]
+ ]
+ """
+ We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
+ """
+ require_cvc_recollection: NotRequired[bool]
+ """
+ When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ statement_descriptor_suffix_kana: NotRequired["Literal['']|str"]
+ """
+ Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that's set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
+ """
+ statement_descriptor_suffix_kanji: NotRequired["Literal['']|str"]
+ """
+ Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that's set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
+ """
+ three_d_secure: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsCardThreeDSecure"
+ ]
+ """
+ If 3D Secure authentication was performed with a third-party provider,
+ the authentication details to use for this payment.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsCardInstallments(TypedDict):
+ enabled: NotRequired[bool]
+ """
+ Setting to true enables installments for this PaymentIntent.
+ This will cause the response to contain a list of available installment plans.
+ Setting to false will prevent any selected plan from applying to a charge.
+ """
+ plan: NotRequired[
+ "Literal['']|PaymentIntentUpdateParamsPaymentMethodOptionsCardInstallmentsPlan"
+ ]
+ """
+ The selected installment plan to use for this payment attempt.
+ This parameter can only be provided during confirmation.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsCardInstallmentsPlan(
+ TypedDict,
+):
+ count: NotRequired[int]
+ """
+ For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
+ """
+ interval: NotRequired[Literal["month"]]
+ """
+ For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
+ One of `month`.
+ """
+ type: Literal["bonus", "fixed_count", "revolving"]
+ """
+ Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsCardMandateOptions(
+ TypedDict,
+):
+ amount: int
+ """
+ Amount to be charged for future payments.
+ """
+ amount_type: Literal["fixed", "maximum"]
+ """
+ One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
+ """
+ description: NotRequired[str]
+ """
+ A description of the mandate or subscription that is meant to be displayed to the customer.
+ """
+ end_date: NotRequired[int]
+ """
+ End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
+ """
+ interval: Literal["day", "month", "sporadic", "week", "year"]
+ """
+ Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
+ """
+ reference: str
+ """
+ Unique identifier for the mandate or subscription.
+ """
+ start_date: int
+ """
+ Start date of the mandate or subscription. Start date should not be lesser than yesterday.
+ """
+ supported_types: NotRequired[List[Literal["india"]]]
+ """
+ Specifies the type of mandates supported. Possible values are `india`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
+ ares_trans_status: NotRequired[Literal["A", "C", "I", "N", "R", "U", "Y"]]
+ """
+ The `transStatus` returned from the card Issuer's ACS in the ARes.
+ """
+ cryptogram: str
+ """
+ The cryptogram, also known as the "authentication value" (AAV, CAVV or
+ AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
+ (Most 3D Secure providers will return the base64-encoded version, which
+ is what you should specify here.)
+ """
+ electronic_commerce_indicator: NotRequired[
+ Literal["01", "02", "05", "06", "07"]
+ ]
+ """
+ The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
+ provider and indicates what degree of authentication was performed.
+ """
+ exemption_indicator: NotRequired[Literal["low_risk", "none"]]
+ """
+ The exemption requested via 3DS and accepted by the issuer at authentication time.
+ """
+ network_options: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
+ ]
+ """
+ Network specific 3DS fields. Network specific arguments require an
+ explicit card brand choice. The parameter `payment_method_options.card.network``
+ must be populated accordingly
+ """
+ requestor_challenge_indicator: NotRequired[str]
+ """
+ The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
+ AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
+ """
+ transaction_id: str
+ """
+ For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
+ Transaction ID (dsTransID).
+ """
+ version: Literal["1.0.2", "2.1.0", "2.2.0"]
+ """
+ The version of 3D Secure that was performed.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
+ TypedDict,
+):
+ cartes_bancaires: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
+ ]
+ """
+ Cartes Bancaires-specific 3DS fields.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
+ TypedDict,
+):
+ cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
+ """
+ The cryptogram calculation algorithm used by the card Issuer's ACS
+ to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
+ messageExtension: CB-AVALGO
+ """
+ cb_exemption: NotRequired[str]
+ """
+ The exemption indicator returned from Cartes Bancaires in the ARes.
+ message extension: CB-EXEMPTION; string (4 characters)
+ This is a 3 byte bitmap (low significant byte first and most significant
+ bit first) that has been Base64 encoded
+ """
+ cb_score: NotRequired[int]
+ """
+ The risk score returned from Cartes Bancaires in the ARes.
+ message extension: CB-SCORE; numeric value 0-99
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsCardPresent(TypedDict):
+ request_extended_authorization: NotRequired[bool]
+ """
+ Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
+ """
+ request_incremental_authorization_support: NotRequired[bool]
+ """
+ Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
+ """
+ routing: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsCardPresentRouting"
+ ]
+ """
+ Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsCardPresentRouting(
+ TypedDict,
+):
+ requested_priority: NotRequired[Literal["domestic", "international"]]
+ """
+ Routing requested priority
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsCashapp(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsCrypto(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsCustomerBalance(TypedDict):
+ bank_transfer: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsCustomerBalanceBankTransfer"
+ ]
+ """
+ Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
+ """
+ funding_type: NotRequired[Literal["bank_transfer"]]
+ """
+ The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsCustomerBalanceBankTransfer(
+ TypedDict,
+):
+ eu_bank_transfer: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
+ ]
+ """
+ Configuration for the eu_bank_transfer funding type.
+ """
+ requested_address_types: NotRequired[
+ List[
+ Literal[
+ "aba", "iban", "sepa", "sort_code", "spei", "swift", "zengin"
+ ]
+ ]
+ ]
+ """
+ List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
+
+ Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
+ """
+ type: Literal[
+ "eu_bank_transfer",
+ "gb_bank_transfer",
+ "jp_bank_transfer",
+ "mx_bank_transfer",
+ "us_bank_transfer",
+ ]
+ """
+ The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
+ TypedDict,
+):
+ country: str
+ """
+ The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsEps(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsFpx(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsGiropay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsGrabpay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsIdeal(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsInteracPresent(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsKakaoPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsKlarna(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ on_demand: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsKlarnaOnDemand"
+ ]
+ """
+ On-demand details if setting up or charging an on-demand payment.
+ """
+ preferred_locale: NotRequired[
+ Literal[
+ "cs-CZ",
+ "da-DK",
+ "de-AT",
+ "de-CH",
+ "de-DE",
+ "el-GR",
+ "en-AT",
+ "en-AU",
+ "en-BE",
+ "en-CA",
+ "en-CH",
+ "en-CZ",
+ "en-DE",
+ "en-DK",
+ "en-ES",
+ "en-FI",
+ "en-FR",
+ "en-GB",
+ "en-GR",
+ "en-IE",
+ "en-IT",
+ "en-NL",
+ "en-NO",
+ "en-NZ",
+ "en-PL",
+ "en-PT",
+ "en-RO",
+ "en-SE",
+ "en-US",
+ "es-ES",
+ "es-US",
+ "fi-FI",
+ "fr-BE",
+ "fr-CA",
+ "fr-CH",
+ "fr-FR",
+ "it-CH",
+ "it-IT",
+ "nb-NO",
+ "nl-BE",
+ "nl-NL",
+ "pl-PL",
+ "pt-PT",
+ "ro-RO",
+ "sv-FI",
+ "sv-SE",
+ ]
+ ]
+ """
+ Preferred language of the Klarna authorization page that the customer is redirected to
+ """
+ setup_future_usage: NotRequired[
+ Literal["none", "off_session", "on_session"]
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ subscriptions: NotRequired[
+ "Literal['']|List[PaymentIntentUpdateParamsPaymentMethodOptionsKlarnaSubscription]"
+ ]
+ """
+ Subscription details if setting up or charging a subscription.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
+ average_amount: NotRequired[int]
+ """
+ Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ maximum_amount: NotRequired[int]
+ """
+ The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ minimum_amount: NotRequired[int]
+ """
+ The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
+ """
+ Interval at which the customer is making purchases
+ """
+ purchase_interval_count: NotRequired[int]
+ """
+ The number of `purchase_interval` between charges
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsKlarnaSubscription(
+ TypedDict,
+):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Unit of time between subscription charges.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
+ """
+ name: NotRequired[str]
+ """
+ Name for subscription.
+ """
+ next_billing: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
+ ]
+ """
+ Describes the upcoming charge for this subscription.
+ """
+ reference: str
+ """
+ A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
+ TypedDict,
+):
+ amount: int
+ """
+ The amount of the next charge for the subscription.
+ """
+ date: str
+ """
+ The date of the next charge for the subscription in YYYY-MM-DD format.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsKonbini(TypedDict):
+ confirmation_number: NotRequired["Literal['']|str"]
+ """
+ An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
+ """
+ expires_after_days: NotRequired["Literal['']|int"]
+ """
+ The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
+ """
+ expires_at: NotRequired["Literal['']|int"]
+ """
+ The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsKrCard(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsLink(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ persistent_token: NotRequired[str]
+ """
+ [Deprecated] This is a legacy parameter that no longer has any function.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsMbWay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsMobilepay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsMultibanco(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsNaverPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsNzBankAccount(TypedDict):
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsOxxo(TypedDict):
+ expires_after_days: NotRequired[int]
+ """
+ The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsP24(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ tos_shown_and_accepted: NotRequired[bool]
+ """
+ Confirm that the payer has accepted the P24 terms and conditions.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsPayByBank(TypedDict):
+ pass
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsPayco(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsPaynow(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsPaypal(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ preferred_locale: NotRequired[
+ Literal[
+ "cs-CZ",
+ "da-DK",
+ "de-AT",
+ "de-DE",
+ "de-LU",
+ "el-GR",
+ "en-GB",
+ "en-US",
+ "es-ES",
+ "fi-FI",
+ "fr-BE",
+ "fr-FR",
+ "fr-LU",
+ "hu-HU",
+ "it-IT",
+ "nl-BE",
+ "nl-NL",
+ "pl-PL",
+ "pt-PT",
+ "sk-SK",
+ "sv-SE",
+ ]
+ ]
+ """
+ [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
+ """
+ reference: NotRequired[str]
+ """
+ A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
+ """
+ risk_correlation_id: NotRequired[str]
+ """
+ The risk correlation ID for an on-session payment using a saved PayPal payment method.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsPix(TypedDict):
+ amount_includes_iof: NotRequired[Literal["always", "never"]]
+ """
+ Determines if the amount includes the IOF tax. Defaults to `never`.
+ """
+ expires_after_seconds: NotRequired[int]
+ """
+ The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
+ """
+ expires_at: NotRequired[int]
+ """
+ The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsPromptpay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsRevolutPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsSamsungPay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsSatispay(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds are captured from the customer's account.
+
+ If provided, this parameter overrides the behavior of the top-level [capture_method](https://docs.stripe.com/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
+
+ If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsSepaDebit(TypedDict):
+ mandate_options: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsSepaDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsSepaDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsSofort(TypedDict):
+ preferred_language: NotRequired[
+ "Literal['']|Literal['de', 'en', 'es', 'fr', 'it', 'nl', 'pl']"
+ ]
+ """
+ Language shown to the payer on redirect.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsSwish(TypedDict):
+ reference: NotRequired["Literal['']|str"]
+ """
+ A reference for this payment to be displayed in the Swish app.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsTwint(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsUsBankAccount(TypedDict):
+ financial_connections: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
+ ]
+ """
+ Additional fields for Financial Connections Session creation
+ """
+ mandate_options: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsUsBankAccountMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ networks: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsUsBankAccountNetworks"
+ ]
+ """
+ Additional fields for network related functions
+ """
+ preferred_settlement_speed: NotRequired[
+ "Literal['']|Literal['fastest', 'standard']"
+ ]
+ """
+ Preferred transaction settlement speed
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session', 'on_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
+ TypedDict,
+):
+ filters: NotRequired[
+ "PaymentIntentUpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
+ ]
+ """
+ Provide filters for the linked accounts that the customer can select for the payment method.
+ """
+ permissions: NotRequired[
+ List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ ]
+ """
+ The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+ return_url: NotRequired[str]
+ """
+ For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
+ TypedDict,
+):
+ account_subcategories: NotRequired[List[Literal["checking", "savings"]]]
+ """
+ The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsUsBankAccountMandateOptions(
+ TypedDict,
+):
+ collection_method: NotRequired["Literal['']|Literal['paper']"]
+ """
+ The method used to collect offline mandate customer acceptance.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsUsBankAccountNetworks(
+ TypedDict,
+):
+ requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
+ """
+ Triggers validations to run across the selected networks
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsWechatPay(TypedDict):
+ app_id: NotRequired[str]
+ """
+ The app ID registered with WeChat Pay. Only required when client is ios or android.
+ """
+ client: NotRequired[Literal["android", "ios", "web"]]
+ """
+ The client type that the end customer will pay from
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsPaymentMethodOptionsZip(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class PaymentIntentUpdateParamsShipping(TypedDict):
+ address: "PaymentIntentUpdateParamsShippingAddress"
+ """
+ Shipping address.
+ """
+ carrier: NotRequired[str]
+ """
+ The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
+ """
+ name: str
+ """
+ Recipient name.
+ """
+ phone: NotRequired[str]
+ """
+ Recipient phone (including extension).
+ """
+ tracking_number: NotRequired[str]
+ """
+ The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
+ """
+
+
+class PaymentIntentUpdateParamsShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class PaymentIntentUpdateParamsTransferData(TypedDict):
+ amount: NotRequired[int]
+ """
+ The amount that will be transferred automatically when a charge succeeds.
+ """
diff --git a/stripe/params/_payment_intent_verify_microdeposits_params.py b/stripe/params/_payment_intent_verify_microdeposits_params.py
new file mode 100644
index 000000000..d00db29ba
--- /dev/null
+++ b/stripe/params/_payment_intent_verify_microdeposits_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentIntentVerifyMicrodepositsParams(RequestOptions):
+ amounts: NotRequired[List[int]]
+ """
+ Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.
+ """
+ descriptor_code: NotRequired[str]
+ """
+ A six-character code starting with SM present in the microdeposit sent to the bank account.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payment_link_create_params.py b/stripe/params/_payment_link_create_params.py
new file mode 100644
index 000000000..db51296e3
--- /dev/null
+++ b/stripe/params/_payment_link_create_params.py
@@ -0,0 +1,1054 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PaymentLinkCreateParams(RequestOptions):
+ after_completion: NotRequired["PaymentLinkCreateParamsAfterCompletion"]
+ """
+ Behavior after the purchase is complete.
+ """
+ allow_promotion_codes: NotRequired[bool]
+ """
+ Enables user redeemable promotion codes.
+ """
+ application_fee_amount: NotRequired[int]
+ """
+ The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. Can only be applied when there are no line items with recurring prices.
+ """
+ application_fee_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
+ """
+ automatic_tax: NotRequired["PaymentLinkCreateParamsAutomaticTax"]
+ """
+ Configuration for automatic tax collection.
+ """
+ billing_address_collection: NotRequired[Literal["auto", "required"]]
+ """
+ Configuration for collecting the customer's billing address. Defaults to `auto`.
+ """
+ consent_collection: NotRequired["PaymentLinkCreateParamsConsentCollection"]
+ """
+ Configure fields to gather active consent from customers.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies) and supported by each line item's price.
+ """
+ custom_fields: NotRequired[List["PaymentLinkCreateParamsCustomField"]]
+ """
+ Collect additional information from your customer using custom fields. Up to 3 fields are supported.
+ """
+ custom_text: NotRequired["PaymentLinkCreateParamsCustomText"]
+ """
+ Display additional text for your customers using custom text.
+ """
+ customer_creation: NotRequired[Literal["always", "if_required"]]
+ """
+ Configures whether [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link create a [Customer](https://stripe.com/docs/api/customers).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ inactive_message: NotRequired[str]
+ """
+ The custom message to be displayed to a customer when a payment link is no longer active.
+ """
+ invoice_creation: NotRequired["PaymentLinkCreateParamsInvoiceCreation"]
+ """
+ Generate a post-purchase Invoice for one-time payments.
+ """
+ line_items: List["PaymentLinkCreateParamsLineItem"]
+ """
+ The line items representing what is being sold. Each line item represents an item being sold. Up to 20 line items are supported.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. Metadata associated with this Payment Link will automatically be copied to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
+ """
+ on_behalf_of: NotRequired[str]
+ """
+ The account on behalf of which to charge.
+ """
+ optional_items: NotRequired[List["PaymentLinkCreateParamsOptionalItem"]]
+ """
+ A list of optional items the customer can add to their order at checkout. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices).
+ There is a maximum of 10 optional items allowed on a payment link, and the existing limits on the number of line items allowed on a payment link apply to the combined number of line items and optional items.
+ There is a maximum of 20 combined line items and optional items.
+ """
+ payment_intent_data: NotRequired[
+ "PaymentLinkCreateParamsPaymentIntentData"
+ ]
+ """
+ A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
+ """
+ payment_method_collection: NotRequired[Literal["always", "if_required"]]
+ """
+ Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.This may occur if the Checkout Session includes a free trial or a discount.
+
+ Can only be set in `subscription` mode. Defaults to `always`.
+
+ 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[
+ List[
+ Literal[
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "card",
+ "cashapp",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "klarna",
+ "konbini",
+ "link",
+ "mobilepay",
+ "multibanco",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ ]
+ ]
+ """
+ The list of payment method types that customers can use. If no value is passed, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods) (20+ payment methods [supported](https://stripe.com/docs/payments/payment-methods/integration-options#payment-method-product-support)).
+ """
+ phone_number_collection: NotRequired[
+ "PaymentLinkCreateParamsPhoneNumberCollection"
+ ]
+ """
+ Controls phone number collection settings during checkout.
+
+ We recommend that you review your privacy policy and check with your legal contacts.
+ """
+ restrictions: NotRequired["PaymentLinkCreateParamsRestrictions"]
+ """
+ Settings that restrict the usage of a payment link.
+ """
+ shipping_address_collection: NotRequired[
+ "PaymentLinkCreateParamsShippingAddressCollection"
+ ]
+ """
+ Configuration for collecting the customer's shipping address.
+ """
+ shipping_options: NotRequired[
+ List["PaymentLinkCreateParamsShippingOption"]
+ ]
+ """
+ The shipping rate options to apply to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
+ """
+ submit_type: NotRequired[
+ Literal["auto", "book", "donate", "pay", "subscribe"]
+ ]
+ """
+ Describes the type of transaction being performed in order to customize relevant text on the page, such as the submit button. Changing this value will also affect the hostname in the [url](https://stripe.com/docs/api/payment_links/payment_links/object#url) property (example: `donate.stripe.com`).
+ """
+ subscription_data: NotRequired["PaymentLinkCreateParamsSubscriptionData"]
+ """
+ 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["PaymentLinkCreateParamsTaxIdCollection"]
+ """
+ Controls tax ID collection during checkout.
+ """
+ transfer_data: NotRequired["PaymentLinkCreateParamsTransferData"]
+ """
+ The account (if any) the payments will be attributed to for tax reporting, and where funds from each payment will be transferred to.
+ """
+
+
+class PaymentLinkCreateParamsAfterCompletion(TypedDict):
+ hosted_confirmation: NotRequired[
+ "PaymentLinkCreateParamsAfterCompletionHostedConfirmation"
+ ]
+ """
+ Configuration when `type=hosted_confirmation`.
+ """
+ redirect: NotRequired["PaymentLinkCreateParamsAfterCompletionRedirect"]
+ """
+ Configuration when `type=redirect`.
+ """
+ type: Literal["hosted_confirmation", "redirect"]
+ """
+ The specified behavior after the purchase is complete. Either `redirect` or `hosted_confirmation`.
+ """
+
+
+class PaymentLinkCreateParamsAfterCompletionHostedConfirmation(TypedDict):
+ custom_message: NotRequired[str]
+ """
+ A custom message to display to the customer after the purchase is complete.
+ """
+
+
+class PaymentLinkCreateParamsAfterCompletionRedirect(TypedDict):
+ url: str
+ """
+ The URL the customer will be redirected to after the purchase is complete. You can embed `{CHECKOUT_SESSION_ID}` into the URL to have the `id` of the completed [checkout session](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-id) included.
+ """
+
+
+class PaymentLinkCreateParamsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
+
+ Enabling this parameter causes the payment link to collect any billing address information necessary for tax calculation.
+ """
+ liability: NotRequired["PaymentLinkCreateParamsAutomaticTaxLiability"]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class PaymentLinkCreateParamsAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class PaymentLinkCreateParamsConsentCollection(TypedDict):
+ payment_method_reuse_agreement: NotRequired[
+ "PaymentLinkCreateParamsConsentCollectionPaymentMethodReuseAgreement"
+ ]
+ """
+ Determines the display of payment method reuse agreement text in the UI. If set to `hidden`, it will hide legal text related to the reuse of a payment method.
+ """
+ promotions: NotRequired[Literal["auto", "none"]]
+ """
+ If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
+ Session will determine whether to display an option to opt into promotional communication
+ from the merchant depending on the customer's locale. Only available to US merchants.
+ """
+ terms_of_service: NotRequired[Literal["none", "required"]]
+ """
+ If set to `required`, it requires customers to check a terms of service checkbox before being able to pay.
+ There must be a valid terms of service URL set in your [Dashboard settings](https://dashboard.stripe.com/settings/public).
+ """
+
+
+class PaymentLinkCreateParamsConsentCollectionPaymentMethodReuseAgreement(
+ TypedDict,
+):
+ position: Literal["auto", "hidden"]
+ """
+ Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's
+ defaults will be used. When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
+ """
+
+
+class PaymentLinkCreateParamsCustomField(TypedDict):
+ dropdown: NotRequired["PaymentLinkCreateParamsCustomFieldDropdown"]
+ """
+ Configuration for `type=dropdown` fields.
+ """
+ key: str
+ """
+ String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
+ """
+ label: "PaymentLinkCreateParamsCustomFieldLabel"
+ """
+ The label for the field, displayed to the customer.
+ """
+ numeric: NotRequired["PaymentLinkCreateParamsCustomFieldNumeric"]
+ """
+ Configuration for `type=numeric` fields.
+ """
+ optional: NotRequired[bool]
+ """
+ Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
+ """
+ text: NotRequired["PaymentLinkCreateParamsCustomFieldText"]
+ """
+ Configuration for `type=text` fields.
+ """
+ type: Literal["dropdown", "numeric", "text"]
+ """
+ The type of the field.
+ """
+
+
+class PaymentLinkCreateParamsCustomFieldDropdown(TypedDict):
+ default_value: NotRequired[str]
+ """
+ The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
+ """
+ options: List["PaymentLinkCreateParamsCustomFieldDropdownOption"]
+ """
+ The options available for the customer to select. Up to 200 options allowed.
+ """
+
+
+class PaymentLinkCreateParamsCustomFieldDropdownOption(TypedDict):
+ label: str
+ """
+ The label for the option, displayed to the customer. Up to 100 characters.
+ """
+ value: str
+ """
+ The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
+ """
+
+
+class PaymentLinkCreateParamsCustomFieldLabel(TypedDict):
+ custom: str
+ """
+ Custom text for the label, displayed to the customer. Up to 50 characters.
+ """
+ type: Literal["custom"]
+ """
+ The type of the label.
+ """
+
+
+class PaymentLinkCreateParamsCustomFieldNumeric(TypedDict):
+ default_value: NotRequired[str]
+ """
+ The value that will pre-fill the field on the payment page.
+ """
+ maximum_length: NotRequired[int]
+ """
+ The maximum character length constraint for the customer's input.
+ """
+ minimum_length: NotRequired[int]
+ """
+ The minimum character length requirement for the customer's input.
+ """
+
+
+class PaymentLinkCreateParamsCustomFieldText(TypedDict):
+ default_value: NotRequired[str]
+ """
+ The value that will pre-fill the field on the payment page.
+ """
+ maximum_length: NotRequired[int]
+ """
+ The maximum character length constraint for the customer's input.
+ """
+ minimum_length: NotRequired[int]
+ """
+ The minimum character length requirement for the customer's input.
+ """
+
+
+class PaymentLinkCreateParamsCustomText(TypedDict):
+ after_submit: NotRequired[
+ "Literal['']|PaymentLinkCreateParamsCustomTextAfterSubmit"
+ ]
+ """
+ Custom text that should be displayed after the payment confirmation button.
+ """
+ shipping_address: NotRequired[
+ "Literal['']|PaymentLinkCreateParamsCustomTextShippingAddress"
+ ]
+ """
+ Custom text that should be displayed alongside shipping address collection.
+ """
+ submit: NotRequired["Literal['']|PaymentLinkCreateParamsCustomTextSubmit"]
+ """
+ Custom text that should be displayed alongside the payment confirmation button.
+ """
+ terms_of_service_acceptance: NotRequired[
+ "Literal['']|PaymentLinkCreateParamsCustomTextTermsOfServiceAcceptance"
+ ]
+ """
+ Custom text that should be displayed in place of the default terms of service agreement text.
+ """
+
+
+class PaymentLinkCreateParamsCustomTextAfterSubmit(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class PaymentLinkCreateParamsCustomTextShippingAddress(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class PaymentLinkCreateParamsCustomTextSubmit(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class PaymentLinkCreateParamsCustomTextTermsOfServiceAcceptance(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class PaymentLinkCreateParamsInvoiceCreation(TypedDict):
+ enabled: bool
+ """
+ Whether the feature is enabled
+ """
+ invoice_data: NotRequired[
+ "PaymentLinkCreateParamsInvoiceCreationInvoiceData"
+ ]
+ """
+ Invoice PDF configuration.
+ """
+
+
+class PaymentLinkCreateParamsInvoiceCreationInvoiceData(TypedDict):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with the invoice.
+ """
+ custom_fields: NotRequired[
+ "Literal['']|List[PaymentLinkCreateParamsInvoiceCreationInvoiceDataCustomField]"
+ ]
+ """
+ Default custom fields to be displayed on invoices for this customer.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ footer: NotRequired[str]
+ """
+ Default footer to be displayed on invoices for this customer.
+ """
+ issuer: NotRequired[
+ "PaymentLinkCreateParamsInvoiceCreationInvoiceDataIssuer"
+ ]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ rendering_options: NotRequired[
+ "Literal['']|PaymentLinkCreateParamsInvoiceCreationInvoiceDataRenderingOptions"
+ ]
+ """
+ Default options for invoice PDF rendering for this customer.
+ """
+
+
+class PaymentLinkCreateParamsInvoiceCreationInvoiceDataCustomField(TypedDict):
+ name: str
+ """
+ The name of the custom field. This may be up to 40 characters.
+ """
+ value: str
+ """
+ The value of the custom field. This may be up to 140 characters.
+ """
+
+
+class PaymentLinkCreateParamsInvoiceCreationInvoiceDataIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class PaymentLinkCreateParamsInvoiceCreationInvoiceDataRenderingOptions(
+ TypedDict,
+):
+ amount_tax_display: NotRequired[
+ "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
+ ]
+ """
+ How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
+ """
+ template: NotRequired[str]
+ """
+ ID of the invoice rendering template to use for this invoice.
+ """
+
+
+class PaymentLinkCreateParamsLineItem(TypedDict):
+ adjustable_quantity: NotRequired[
+ "PaymentLinkCreateParamsLineItemAdjustableQuantity"
+ ]
+ """
+ When set, provides configuration for this item's quantity to be adjusted by the customer during checkout.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object. One of `price` or `price_data` is required.
+ """
+ price_data: NotRequired["PaymentLinkCreateParamsLineItemPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: int
+ """
+ The quantity of the line item being purchased.
+ """
+
+
+class PaymentLinkCreateParamsLineItemAdjustableQuantity(TypedDict):
+ enabled: bool
+ """
+ Set to true if the quantity can be adjusted to any non-negative Integer.
+ """
+ maximum: NotRequired[int]
+ """
+ The maximum quantity the customer can purchase. By default this value is 99. You can specify a value up to 999999.
+ """
+ minimum: NotRequired[int]
+ """
+ The minimum quantity the customer can purchase. By default this value is 0. If there is only one item in the cart then that item's quantity cannot go down to 0.
+ """
+
+
+class PaymentLinkCreateParamsLineItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: NotRequired[str]
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
+ """
+ product_data: NotRequired[
+ "PaymentLinkCreateParamsLineItemPriceDataProductData"
+ ]
+ """
+ Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
+ """
+ recurring: NotRequired["PaymentLinkCreateParamsLineItemPriceDataRecurring"]
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class PaymentLinkCreateParamsLineItemPriceDataProductData(TypedDict):
+ description: NotRequired[str]
+ """
+ The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
+ """
+ images: NotRequired[List[str]]
+ """
+ A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: str
+ """
+ The product's name, meant to be displayable to the customer.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+ unit_label: NotRequired[str]
+ """
+ A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
+ """
+
+
+class PaymentLinkCreateParamsLineItemPriceDataRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
+
+
+class PaymentLinkCreateParamsOptionalItem(TypedDict):
+ adjustable_quantity: NotRequired[
+ "PaymentLinkCreateParamsOptionalItemAdjustableQuantity"
+ ]
+ """
+ When set, provides configuration for the customer to adjust the quantity of the line item created when a customer chooses to add this optional item to their order.
+ """
+ price: str
+ """
+ The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object.
+ """
+ quantity: int
+ """
+ The initial quantity of the line item created when a customer chooses to add this optional item to their order.
+ """
+
+
+class PaymentLinkCreateParamsOptionalItemAdjustableQuantity(TypedDict):
+ enabled: bool
+ """
+ Set to true if the quantity can be adjusted to any non-negative integer.
+ """
+ maximum: NotRequired[int]
+ """
+ The maximum quantity of this item the customer can purchase. By default this value is 99.
+ """
+ minimum: NotRequired[int]
+ """
+ The minimum quantity of this item the customer must purchase, if they choose to purchase it. Because this item is optional, the customer will always be able to remove it from their order, even if the `minimum` configured here is greater than 0. By default this value is 0.
+ """
+
+
+class PaymentLinkCreateParamsPaymentIntentData(TypedDict):
+ capture_method: NotRequired[
+ Literal["automatic", "automatic_async", "manual"]
+ ]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Payment Intents](https://stripe.com/docs/api/payment_intents) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
+ """
+ setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
+ """
+ Indicates that you intend to [make future payments](https://stripe.com/docs/payments/payment-intents#future-usage) with the payment method collected by this Checkout Session.
+
+ When setting this to `on_session`, Checkout will show a notice to the customer that their payment details will be saved.
+
+ When setting this to `off_session`, Checkout will show a notice to the customer that their payment details will be saved and used for future payments.
+
+ If a Customer has been provided or Checkout creates a new Customer,Checkout will attach the payment method to the Customer.
+
+ If Checkout does not create a Customer, the payment method is not attached to a Customer. To reuse the payment method, you can retrieve it from the Checkout Session's PaymentIntent.
+
+ When processing card payments, Checkout also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as SCA.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
+
+ Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
+ """
+ statement_descriptor_suffix: NotRequired[str]
+ """
+ Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
+ """
+ transfer_group: NotRequired[str]
+ """
+ A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
+ """
+
+
+class PaymentLinkCreateParamsPhoneNumberCollection(TypedDict):
+ enabled: bool
+ """
+ Set to `true` to enable phone number collection.
+ """
+
+
+class PaymentLinkCreateParamsRestrictions(TypedDict):
+ completed_sessions: "PaymentLinkCreateParamsRestrictionsCompletedSessions"
+ """
+ Configuration for the `completed_sessions` restriction type.
+ """
+
+
+class PaymentLinkCreateParamsRestrictionsCompletedSessions(TypedDict):
+ limit: int
+ """
+ The maximum number of checkout sessions that can be completed for the `completed_sessions` restriction to be met.
+ """
+
+
+class PaymentLinkCreateParamsShippingAddressCollection(TypedDict):
+ allowed_countries: List[
+ Literal[
+ "AC",
+ "AD",
+ "AE",
+ "AF",
+ "AG",
+ "AI",
+ "AL",
+ "AM",
+ "AO",
+ "AQ",
+ "AR",
+ "AT",
+ "AU",
+ "AW",
+ "AX",
+ "AZ",
+ "BA",
+ "BB",
+ "BD",
+ "BE",
+ "BF",
+ "BG",
+ "BH",
+ "BI",
+ "BJ",
+ "BL",
+ "BM",
+ "BN",
+ "BO",
+ "BQ",
+ "BR",
+ "BS",
+ "BT",
+ "BV",
+ "BW",
+ "BY",
+ "BZ",
+ "CA",
+ "CD",
+ "CF",
+ "CG",
+ "CH",
+ "CI",
+ "CK",
+ "CL",
+ "CM",
+ "CN",
+ "CO",
+ "CR",
+ "CV",
+ "CW",
+ "CY",
+ "CZ",
+ "DE",
+ "DJ",
+ "DK",
+ "DM",
+ "DO",
+ "DZ",
+ "EC",
+ "EE",
+ "EG",
+ "EH",
+ "ER",
+ "ES",
+ "ET",
+ "FI",
+ "FJ",
+ "FK",
+ "FO",
+ "FR",
+ "GA",
+ "GB",
+ "GD",
+ "GE",
+ "GF",
+ "GG",
+ "GH",
+ "GI",
+ "GL",
+ "GM",
+ "GN",
+ "GP",
+ "GQ",
+ "GR",
+ "GS",
+ "GT",
+ "GU",
+ "GW",
+ "GY",
+ "HK",
+ "HN",
+ "HR",
+ "HT",
+ "HU",
+ "ID",
+ "IE",
+ "IL",
+ "IM",
+ "IN",
+ "IO",
+ "IQ",
+ "IS",
+ "IT",
+ "JE",
+ "JM",
+ "JO",
+ "JP",
+ "KE",
+ "KG",
+ "KH",
+ "KI",
+ "KM",
+ "KN",
+ "KR",
+ "KW",
+ "KY",
+ "KZ",
+ "LA",
+ "LB",
+ "LC",
+ "LI",
+ "LK",
+ "LR",
+ "LS",
+ "LT",
+ "LU",
+ "LV",
+ "LY",
+ "MA",
+ "MC",
+ "MD",
+ "ME",
+ "MF",
+ "MG",
+ "MK",
+ "ML",
+ "MM",
+ "MN",
+ "MO",
+ "MQ",
+ "MR",
+ "MS",
+ "MT",
+ "MU",
+ "MV",
+ "MW",
+ "MX",
+ "MY",
+ "MZ",
+ "NA",
+ "NC",
+ "NE",
+ "NG",
+ "NI",
+ "NL",
+ "NO",
+ "NP",
+ "NR",
+ "NU",
+ "NZ",
+ "OM",
+ "PA",
+ "PE",
+ "PF",
+ "PG",
+ "PH",
+ "PK",
+ "PL",
+ "PM",
+ "PN",
+ "PR",
+ "PS",
+ "PT",
+ "PY",
+ "QA",
+ "RE",
+ "RO",
+ "RS",
+ "RU",
+ "RW",
+ "SA",
+ "SB",
+ "SC",
+ "SD",
+ "SE",
+ "SG",
+ "SH",
+ "SI",
+ "SJ",
+ "SK",
+ "SL",
+ "SM",
+ "SN",
+ "SO",
+ "SR",
+ "SS",
+ "ST",
+ "SV",
+ "SX",
+ "SZ",
+ "TA",
+ "TC",
+ "TD",
+ "TF",
+ "TG",
+ "TH",
+ "TJ",
+ "TK",
+ "TL",
+ "TM",
+ "TN",
+ "TO",
+ "TR",
+ "TT",
+ "TV",
+ "TW",
+ "TZ",
+ "UA",
+ "UG",
+ "US",
+ "UY",
+ "UZ",
+ "VA",
+ "VC",
+ "VE",
+ "VG",
+ "VN",
+ "VU",
+ "WF",
+ "WS",
+ "XK",
+ "YE",
+ "YT",
+ "ZA",
+ "ZM",
+ "ZW",
+ "ZZ",
+ ]
+ ]
+ """
+ An array of two-letter ISO country codes representing which countries Checkout should provide as options for
+ shipping locations.
+ """
+
+
+class PaymentLinkCreateParamsShippingOption(TypedDict):
+ shipping_rate: NotRequired[str]
+ """
+ The ID of the Shipping Rate to use for this shipping option.
+ """
+
+
+class PaymentLinkCreateParamsSubscriptionData(TypedDict):
+ description: NotRequired[str]
+ """
+ The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
+ """
+ invoice_settings: NotRequired[
+ "PaymentLinkCreateParamsSubscriptionDataInvoiceSettings"
+ ]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Subscriptions](https://stripe.com/docs/api/subscriptions) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
+ """
+ trial_period_days: NotRequired[int]
+ """
+ Integer representing the number of trial period days before the customer is charged for the first time. Has to be at least 1.
+ """
+ trial_settings: NotRequired[
+ "PaymentLinkCreateParamsSubscriptionDataTrialSettings"
+ ]
+ """
+ Settings related to subscription trials.
+ """
+
+
+class PaymentLinkCreateParamsSubscriptionDataInvoiceSettings(TypedDict):
+ issuer: NotRequired[
+ "PaymentLinkCreateParamsSubscriptionDataInvoiceSettingsIssuer"
+ ]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class PaymentLinkCreateParamsSubscriptionDataInvoiceSettingsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class PaymentLinkCreateParamsSubscriptionDataTrialSettings(TypedDict):
+ end_behavior: (
+ "PaymentLinkCreateParamsSubscriptionDataTrialSettingsEndBehavior"
+ )
+ """
+ Defines how the subscription should behave when the user's free trial ends.
+ """
+
+
+class PaymentLinkCreateParamsSubscriptionDataTrialSettingsEndBehavior(
+ TypedDict,
+):
+ missing_payment_method: Literal["cancel", "create_invoice", "pause"]
+ """
+ Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
+ """
+
+
+class PaymentLinkCreateParamsTaxIdCollection(TypedDict):
+ enabled: bool
+ """
+ Enable tax ID collection during checkout. Defaults to `false`.
+ """
+ required: NotRequired[Literal["if_supported", "never"]]
+ """
+ Describes whether a tax ID is required during checkout. Defaults to `never`.
+ """
+
+
+class PaymentLinkCreateParamsTransferData(TypedDict):
+ amount: NotRequired[int]
+ """
+ The amount that will be transferred automatically when a charge succeeds.
+ """
+ destination: str
+ """
+ If specified, successful charges will be attributed to the destination
+ account for tax reporting, and the funds from charges will be transferred
+ to the destination account. The ID of the resulting transfer will be
+ returned on the successful charge's `transfer` field.
+ """
diff --git a/stripe/params/_payment_link_line_item_list_params.py b/stripe/params/_payment_link_line_item_list_params.py
new file mode 100644
index 000000000..8f57382c4
--- /dev/null
+++ b/stripe/params/_payment_link_line_item_list_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class PaymentLinkLineItemListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_payment_link_list_line_items_params.py b/stripe/params/_payment_link_list_line_items_params.py
new file mode 100644
index 000000000..8defb5211
--- /dev/null
+++ b/stripe/params/_payment_link_list_line_items_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentLinkListLineItemsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_payment_link_list_params.py b/stripe/params/_payment_link_list_params.py
new file mode 100644
index 000000000..bc7689ecb
--- /dev/null
+++ b/stripe/params/_payment_link_list_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentLinkListParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Only return payment links that are active or inactive (e.g., pass `false` to list all inactive payment links).
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_payment_link_modify_params.py b/stripe/params/_payment_link_modify_params.py
new file mode 100644
index 000000000..2939193ec
--- /dev/null
+++ b/stripe/params/_payment_link_modify_params.py
@@ -0,0 +1,804 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PaymentLinkModifyParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Whether the payment link's `url` is active. If `false`, customers visiting the URL will be shown a page saying that the link has been deactivated.
+ """
+ after_completion: NotRequired["PaymentLinkModifyParamsAfterCompletion"]
+ """
+ Behavior after the purchase is complete.
+ """
+ allow_promotion_codes: NotRequired[bool]
+ """
+ Enables user redeemable promotion codes.
+ """
+ automatic_tax: NotRequired["PaymentLinkModifyParamsAutomaticTax"]
+ """
+ Configuration for automatic tax collection.
+ """
+ billing_address_collection: NotRequired[Literal["auto", "required"]]
+ """
+ Configuration for collecting the customer's billing address. Defaults to `auto`.
+ """
+ custom_fields: NotRequired[
+ "Literal['']|List[PaymentLinkModifyParamsCustomField]"
+ ]
+ """
+ Collect additional information from your customer using custom fields. Up to 3 fields are supported.
+ """
+ custom_text: NotRequired["PaymentLinkModifyParamsCustomText"]
+ """
+ Display additional text for your customers using custom text.
+ """
+ customer_creation: NotRequired[Literal["always", "if_required"]]
+ """
+ Configures whether [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link create a [Customer](https://stripe.com/docs/api/customers).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ inactive_message: NotRequired["Literal['']|str"]
+ """
+ The custom message to be displayed to a customer when a payment link is no longer active.
+ """
+ invoice_creation: NotRequired["PaymentLinkModifyParamsInvoiceCreation"]
+ """
+ Generate a post-purchase Invoice for one-time payments.
+ """
+ line_items: NotRequired[List["PaymentLinkModifyParamsLineItem"]]
+ """
+ The line items representing what is being sold. Each line item represents an item being sold. Up to 20 line items are supported.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. Metadata associated with this Payment Link will automatically be copied to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
+ """
+ payment_intent_data: NotRequired[
+ "PaymentLinkModifyParamsPaymentIntentData"
+ ]
+ """
+ A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
+ """
+ payment_method_collection: NotRequired[Literal["always", "if_required"]]
+ """
+ Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.This may occur if the Checkout Session includes a free trial or a discount.
+
+ Can only be set in `subscription` mode. Defaults to `always`.
+
+ 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', 'alma', 'au_becs_debit', 'bacs_debit', 'bancontact', 'billie', 'blik', 'boleto', 'card', 'cashapp', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'klarna', 'konbini', 'link', 'mobilepay', 'multibanco', 'oxxo', 'p24', 'pay_by_bank', 'paynow', 'paypal', 'pix', 'promptpay', 'satispay', 'sepa_debit', 'sofort', 'swish', 'twint', 'us_bank_account', 'wechat_pay', 'zip']]"
+ ]
+ """
+ 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).
+ """
+ phone_number_collection: NotRequired[
+ "PaymentLinkModifyParamsPhoneNumberCollection"
+ ]
+ """
+ Controls phone number collection settings during checkout.
+
+ We recommend that you review your privacy policy and check with your legal contacts.
+ """
+ restrictions: NotRequired[
+ "Literal['']|PaymentLinkModifyParamsRestrictions"
+ ]
+ """
+ Settings that restrict the usage of a payment link.
+ """
+ shipping_address_collection: NotRequired[
+ "Literal['']|PaymentLinkModifyParamsShippingAddressCollection"
+ ]
+ """
+ Configuration for collecting the customer's shipping address.
+ """
+ submit_type: NotRequired[
+ Literal["auto", "book", "donate", "pay", "subscribe"]
+ ]
+ """
+ Describes the type of transaction being performed in order to customize relevant text on the page, such as the submit button. Changing this value will also affect the hostname in the [url](https://stripe.com/docs/api/payment_links/payment_links/object#url) property (example: `donate.stripe.com`).
+ """
+ subscription_data: NotRequired["PaymentLinkModifyParamsSubscriptionData"]
+ """
+ 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["PaymentLinkModifyParamsTaxIdCollection"]
+ """
+ Controls tax ID collection during checkout.
+ """
+
+
+class PaymentLinkModifyParamsAfterCompletion(TypedDict):
+ hosted_confirmation: NotRequired[
+ "PaymentLinkModifyParamsAfterCompletionHostedConfirmation"
+ ]
+ """
+ Configuration when `type=hosted_confirmation`.
+ """
+ redirect: NotRequired["PaymentLinkModifyParamsAfterCompletionRedirect"]
+ """
+ Configuration when `type=redirect`.
+ """
+ type: Literal["hosted_confirmation", "redirect"]
+ """
+ The specified behavior after the purchase is complete. Either `redirect` or `hosted_confirmation`.
+ """
+
+
+class PaymentLinkModifyParamsAfterCompletionHostedConfirmation(TypedDict):
+ custom_message: NotRequired[str]
+ """
+ A custom message to display to the customer after the purchase is complete.
+ """
+
+
+class PaymentLinkModifyParamsAfterCompletionRedirect(TypedDict):
+ url: str
+ """
+ The URL the customer will be redirected to after the purchase is complete. You can embed `{CHECKOUT_SESSION_ID}` into the URL to have the `id` of the completed [checkout session](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-id) included.
+ """
+
+
+class PaymentLinkModifyParamsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
+
+ Enabling this parameter causes the payment link to collect any billing address information necessary for tax calculation.
+ """
+ liability: NotRequired["PaymentLinkModifyParamsAutomaticTaxLiability"]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class PaymentLinkModifyParamsAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class PaymentLinkModifyParamsCustomField(TypedDict):
+ dropdown: NotRequired["PaymentLinkModifyParamsCustomFieldDropdown"]
+ """
+ Configuration for `type=dropdown` fields.
+ """
+ key: str
+ """
+ String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
+ """
+ label: "PaymentLinkModifyParamsCustomFieldLabel"
+ """
+ The label for the field, displayed to the customer.
+ """
+ numeric: NotRequired["PaymentLinkModifyParamsCustomFieldNumeric"]
+ """
+ Configuration for `type=numeric` fields.
+ """
+ optional: NotRequired[bool]
+ """
+ Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
+ """
+ text: NotRequired["PaymentLinkModifyParamsCustomFieldText"]
+ """
+ Configuration for `type=text` fields.
+ """
+ type: Literal["dropdown", "numeric", "text"]
+ """
+ The type of the field.
+ """
+
+
+class PaymentLinkModifyParamsCustomFieldDropdown(TypedDict):
+ default_value: NotRequired[str]
+ """
+ The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
+ """
+ options: List["PaymentLinkModifyParamsCustomFieldDropdownOption"]
+ """
+ The options available for the customer to select. Up to 200 options allowed.
+ """
+
+
+class PaymentLinkModifyParamsCustomFieldDropdownOption(TypedDict):
+ label: str
+ """
+ The label for the option, displayed to the customer. Up to 100 characters.
+ """
+ value: str
+ """
+ The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
+ """
+
+
+class PaymentLinkModifyParamsCustomFieldLabel(TypedDict):
+ custom: str
+ """
+ Custom text for the label, displayed to the customer. Up to 50 characters.
+ """
+ type: Literal["custom"]
+ """
+ The type of the label.
+ """
+
+
+class PaymentLinkModifyParamsCustomFieldNumeric(TypedDict):
+ default_value: NotRequired[str]
+ """
+ The value that will pre-fill the field on the payment page.
+ """
+ maximum_length: NotRequired[int]
+ """
+ The maximum character length constraint for the customer's input.
+ """
+ minimum_length: NotRequired[int]
+ """
+ The minimum character length requirement for the customer's input.
+ """
+
+
+class PaymentLinkModifyParamsCustomFieldText(TypedDict):
+ default_value: NotRequired[str]
+ """
+ The value that will pre-fill the field on the payment page.
+ """
+ maximum_length: NotRequired[int]
+ """
+ The maximum character length constraint for the customer's input.
+ """
+ minimum_length: NotRequired[int]
+ """
+ The minimum character length requirement for the customer's input.
+ """
+
+
+class PaymentLinkModifyParamsCustomText(TypedDict):
+ after_submit: NotRequired[
+ "Literal['']|PaymentLinkModifyParamsCustomTextAfterSubmit"
+ ]
+ """
+ Custom text that should be displayed after the payment confirmation button.
+ """
+ shipping_address: NotRequired[
+ "Literal['']|PaymentLinkModifyParamsCustomTextShippingAddress"
+ ]
+ """
+ Custom text that should be displayed alongside shipping address collection.
+ """
+ submit: NotRequired["Literal['']|PaymentLinkModifyParamsCustomTextSubmit"]
+ """
+ Custom text that should be displayed alongside the payment confirmation button.
+ """
+ terms_of_service_acceptance: NotRequired[
+ "Literal['']|PaymentLinkModifyParamsCustomTextTermsOfServiceAcceptance"
+ ]
+ """
+ Custom text that should be displayed in place of the default terms of service agreement text.
+ """
+
+
+class PaymentLinkModifyParamsCustomTextAfterSubmit(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class PaymentLinkModifyParamsCustomTextShippingAddress(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class PaymentLinkModifyParamsCustomTextSubmit(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class PaymentLinkModifyParamsCustomTextTermsOfServiceAcceptance(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class PaymentLinkModifyParamsInvoiceCreation(TypedDict):
+ enabled: bool
+ """
+ Whether the feature is enabled
+ """
+ invoice_data: NotRequired[
+ "PaymentLinkModifyParamsInvoiceCreationInvoiceData"
+ ]
+ """
+ Invoice PDF configuration.
+ """
+
+
+class PaymentLinkModifyParamsInvoiceCreationInvoiceData(TypedDict):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with the invoice.
+ """
+ custom_fields: NotRequired[
+ "Literal['']|List[PaymentLinkModifyParamsInvoiceCreationInvoiceDataCustomField]"
+ ]
+ """
+ Default custom fields to be displayed on invoices for this customer.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ footer: NotRequired[str]
+ """
+ Default footer to be displayed on invoices for this customer.
+ """
+ issuer: NotRequired[
+ "PaymentLinkModifyParamsInvoiceCreationInvoiceDataIssuer"
+ ]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ rendering_options: NotRequired[
+ "Literal['']|PaymentLinkModifyParamsInvoiceCreationInvoiceDataRenderingOptions"
+ ]
+ """
+ Default options for invoice PDF rendering for this customer.
+ """
+
+
+class PaymentLinkModifyParamsInvoiceCreationInvoiceDataCustomField(TypedDict):
+ name: str
+ """
+ The name of the custom field. This may be up to 40 characters.
+ """
+ value: str
+ """
+ The value of the custom field. This may be up to 140 characters.
+ """
+
+
+class PaymentLinkModifyParamsInvoiceCreationInvoiceDataIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class PaymentLinkModifyParamsInvoiceCreationInvoiceDataRenderingOptions(
+ TypedDict,
+):
+ amount_tax_display: NotRequired[
+ "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
+ ]
+ """
+ How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
+ """
+ template: NotRequired[str]
+ """
+ ID of the invoice rendering template to use for this invoice.
+ """
+
+
+class PaymentLinkModifyParamsLineItem(TypedDict):
+ adjustable_quantity: NotRequired[
+ "PaymentLinkModifyParamsLineItemAdjustableQuantity"
+ ]
+ """
+ When set, provides configuration for this item's quantity to be adjusted by the customer during checkout.
+ """
+ id: str
+ """
+ The ID of an existing line item on the payment link.
+ """
+ quantity: NotRequired[int]
+ """
+ The quantity of the line item being purchased.
+ """
+
+
+class PaymentLinkModifyParamsLineItemAdjustableQuantity(TypedDict):
+ enabled: bool
+ """
+ Set to true if the quantity can be adjusted to any non-negative Integer.
+ """
+ maximum: NotRequired[int]
+ """
+ The maximum quantity the customer can purchase. By default this value is 99. You can specify a value up to 999999.
+ """
+ minimum: NotRequired[int]
+ """
+ The minimum quantity the customer can purchase. By default this value is 0. If there is only one item in the cart then that item's quantity cannot go down to 0.
+ """
+
+
+class PaymentLinkModifyParamsPaymentIntentData(TypedDict):
+ description: NotRequired["Literal['']|str"]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Payment Intents](https://stripe.com/docs/api/payment_intents) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
+ """
+ statement_descriptor: NotRequired["Literal['']|str"]
+ """
+ Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
+
+ Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
+ """
+ statement_descriptor_suffix: NotRequired["Literal['']|str"]
+ """
+ Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
+ """
+ transfer_group: NotRequired["Literal['']|str"]
+ """
+ A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
+ """
+
+
+class PaymentLinkModifyParamsPhoneNumberCollection(TypedDict):
+ enabled: bool
+ """
+ Set to `true` to enable phone number collection.
+ """
+
+
+class PaymentLinkModifyParamsRestrictions(TypedDict):
+ completed_sessions: "PaymentLinkModifyParamsRestrictionsCompletedSessions"
+ """
+ Configuration for the `completed_sessions` restriction type.
+ """
+
+
+class PaymentLinkModifyParamsRestrictionsCompletedSessions(TypedDict):
+ limit: int
+ """
+ The maximum number of checkout sessions that can be completed for the `completed_sessions` restriction to be met.
+ """
+
+
+class PaymentLinkModifyParamsShippingAddressCollection(TypedDict):
+ allowed_countries: List[
+ Literal[
+ "AC",
+ "AD",
+ "AE",
+ "AF",
+ "AG",
+ "AI",
+ "AL",
+ "AM",
+ "AO",
+ "AQ",
+ "AR",
+ "AT",
+ "AU",
+ "AW",
+ "AX",
+ "AZ",
+ "BA",
+ "BB",
+ "BD",
+ "BE",
+ "BF",
+ "BG",
+ "BH",
+ "BI",
+ "BJ",
+ "BL",
+ "BM",
+ "BN",
+ "BO",
+ "BQ",
+ "BR",
+ "BS",
+ "BT",
+ "BV",
+ "BW",
+ "BY",
+ "BZ",
+ "CA",
+ "CD",
+ "CF",
+ "CG",
+ "CH",
+ "CI",
+ "CK",
+ "CL",
+ "CM",
+ "CN",
+ "CO",
+ "CR",
+ "CV",
+ "CW",
+ "CY",
+ "CZ",
+ "DE",
+ "DJ",
+ "DK",
+ "DM",
+ "DO",
+ "DZ",
+ "EC",
+ "EE",
+ "EG",
+ "EH",
+ "ER",
+ "ES",
+ "ET",
+ "FI",
+ "FJ",
+ "FK",
+ "FO",
+ "FR",
+ "GA",
+ "GB",
+ "GD",
+ "GE",
+ "GF",
+ "GG",
+ "GH",
+ "GI",
+ "GL",
+ "GM",
+ "GN",
+ "GP",
+ "GQ",
+ "GR",
+ "GS",
+ "GT",
+ "GU",
+ "GW",
+ "GY",
+ "HK",
+ "HN",
+ "HR",
+ "HT",
+ "HU",
+ "ID",
+ "IE",
+ "IL",
+ "IM",
+ "IN",
+ "IO",
+ "IQ",
+ "IS",
+ "IT",
+ "JE",
+ "JM",
+ "JO",
+ "JP",
+ "KE",
+ "KG",
+ "KH",
+ "KI",
+ "KM",
+ "KN",
+ "KR",
+ "KW",
+ "KY",
+ "KZ",
+ "LA",
+ "LB",
+ "LC",
+ "LI",
+ "LK",
+ "LR",
+ "LS",
+ "LT",
+ "LU",
+ "LV",
+ "LY",
+ "MA",
+ "MC",
+ "MD",
+ "ME",
+ "MF",
+ "MG",
+ "MK",
+ "ML",
+ "MM",
+ "MN",
+ "MO",
+ "MQ",
+ "MR",
+ "MS",
+ "MT",
+ "MU",
+ "MV",
+ "MW",
+ "MX",
+ "MY",
+ "MZ",
+ "NA",
+ "NC",
+ "NE",
+ "NG",
+ "NI",
+ "NL",
+ "NO",
+ "NP",
+ "NR",
+ "NU",
+ "NZ",
+ "OM",
+ "PA",
+ "PE",
+ "PF",
+ "PG",
+ "PH",
+ "PK",
+ "PL",
+ "PM",
+ "PN",
+ "PR",
+ "PS",
+ "PT",
+ "PY",
+ "QA",
+ "RE",
+ "RO",
+ "RS",
+ "RU",
+ "RW",
+ "SA",
+ "SB",
+ "SC",
+ "SD",
+ "SE",
+ "SG",
+ "SH",
+ "SI",
+ "SJ",
+ "SK",
+ "SL",
+ "SM",
+ "SN",
+ "SO",
+ "SR",
+ "SS",
+ "ST",
+ "SV",
+ "SX",
+ "SZ",
+ "TA",
+ "TC",
+ "TD",
+ "TF",
+ "TG",
+ "TH",
+ "TJ",
+ "TK",
+ "TL",
+ "TM",
+ "TN",
+ "TO",
+ "TR",
+ "TT",
+ "TV",
+ "TW",
+ "TZ",
+ "UA",
+ "UG",
+ "US",
+ "UY",
+ "UZ",
+ "VA",
+ "VC",
+ "VE",
+ "VG",
+ "VN",
+ "VU",
+ "WF",
+ "WS",
+ "XK",
+ "YE",
+ "YT",
+ "ZA",
+ "ZM",
+ "ZW",
+ "ZZ",
+ ]
+ ]
+ """
+ An array of two-letter ISO country codes representing which countries Checkout should provide as options for
+ shipping locations.
+ """
+
+
+class PaymentLinkModifyParamsSubscriptionData(TypedDict):
+ invoice_settings: NotRequired[
+ "PaymentLinkModifyParamsSubscriptionDataInvoiceSettings"
+ ]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Subscriptions](https://stripe.com/docs/api/subscriptions) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
+ """
+ trial_period_days: NotRequired["Literal['']|int"]
+ """
+ Integer representing the number of trial period days before the customer is charged for the first time. Has to be at least 1.
+ """
+ trial_settings: NotRequired[
+ "Literal['']|PaymentLinkModifyParamsSubscriptionDataTrialSettings"
+ ]
+ """
+ Settings related to subscription trials.
+ """
+
+
+class PaymentLinkModifyParamsSubscriptionDataInvoiceSettings(TypedDict):
+ issuer: NotRequired[
+ "PaymentLinkModifyParamsSubscriptionDataInvoiceSettingsIssuer"
+ ]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class PaymentLinkModifyParamsSubscriptionDataInvoiceSettingsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class PaymentLinkModifyParamsSubscriptionDataTrialSettings(TypedDict):
+ end_behavior: (
+ "PaymentLinkModifyParamsSubscriptionDataTrialSettingsEndBehavior"
+ )
+ """
+ Defines how the subscription should behave when the user's free trial ends.
+ """
+
+
+class PaymentLinkModifyParamsSubscriptionDataTrialSettingsEndBehavior(
+ TypedDict,
+):
+ missing_payment_method: Literal["cancel", "create_invoice", "pause"]
+ """
+ Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
+ """
+
+
+class PaymentLinkModifyParamsTaxIdCollection(TypedDict):
+ enabled: bool
+ """
+ Enable tax ID collection during checkout. Defaults to `false`.
+ """
+ required: NotRequired[Literal["if_supported", "never"]]
+ """
+ Describes whether a tax ID is required during checkout. Defaults to `never`.
+ """
diff --git a/stripe/params/_payment_link_retrieve_params.py b/stripe/params/_payment_link_retrieve_params.py
new file mode 100644
index 000000000..c73ebaf77
--- /dev/null
+++ b/stripe/params/_payment_link_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentLinkRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payment_link_update_params.py b/stripe/params/_payment_link_update_params.py
new file mode 100644
index 000000000..cf0c29168
--- /dev/null
+++ b/stripe/params/_payment_link_update_params.py
@@ -0,0 +1,803 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PaymentLinkUpdateParams(TypedDict):
+ active: NotRequired[bool]
+ """
+ Whether the payment link's `url` is active. If `false`, customers visiting the URL will be shown a page saying that the link has been deactivated.
+ """
+ after_completion: NotRequired["PaymentLinkUpdateParamsAfterCompletion"]
+ """
+ Behavior after the purchase is complete.
+ """
+ allow_promotion_codes: NotRequired[bool]
+ """
+ Enables user redeemable promotion codes.
+ """
+ automatic_tax: NotRequired["PaymentLinkUpdateParamsAutomaticTax"]
+ """
+ Configuration for automatic tax collection.
+ """
+ billing_address_collection: NotRequired[Literal["auto", "required"]]
+ """
+ Configuration for collecting the customer's billing address. Defaults to `auto`.
+ """
+ custom_fields: NotRequired[
+ "Literal['']|List[PaymentLinkUpdateParamsCustomField]"
+ ]
+ """
+ Collect additional information from your customer using custom fields. Up to 3 fields are supported.
+ """
+ custom_text: NotRequired["PaymentLinkUpdateParamsCustomText"]
+ """
+ Display additional text for your customers using custom text.
+ """
+ customer_creation: NotRequired[Literal["always", "if_required"]]
+ """
+ Configures whether [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link create a [Customer](https://stripe.com/docs/api/customers).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ inactive_message: NotRequired["Literal['']|str"]
+ """
+ The custom message to be displayed to a customer when a payment link is no longer active.
+ """
+ invoice_creation: NotRequired["PaymentLinkUpdateParamsInvoiceCreation"]
+ """
+ Generate a post-purchase Invoice for one-time payments.
+ """
+ line_items: NotRequired[List["PaymentLinkUpdateParamsLineItem"]]
+ """
+ The line items representing what is being sold. Each line item represents an item being sold. Up to 20 line items are supported.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. Metadata associated with this Payment Link will automatically be copied to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
+ """
+ payment_intent_data: NotRequired[
+ "PaymentLinkUpdateParamsPaymentIntentData"
+ ]
+ """
+ A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
+ """
+ payment_method_collection: NotRequired[Literal["always", "if_required"]]
+ """
+ Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.This may occur if the Checkout Session includes a free trial or a discount.
+
+ Can only be set in `subscription` mode. Defaults to `always`.
+
+ 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', 'alma', 'au_becs_debit', 'bacs_debit', 'bancontact', 'billie', 'blik', 'boleto', 'card', 'cashapp', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'klarna', 'konbini', 'link', 'mobilepay', 'multibanco', 'oxxo', 'p24', 'pay_by_bank', 'paynow', 'paypal', 'pix', 'promptpay', 'satispay', 'sepa_debit', 'sofort', 'swish', 'twint', 'us_bank_account', 'wechat_pay', 'zip']]"
+ ]
+ """
+ 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).
+ """
+ phone_number_collection: NotRequired[
+ "PaymentLinkUpdateParamsPhoneNumberCollection"
+ ]
+ """
+ Controls phone number collection settings during checkout.
+
+ We recommend that you review your privacy policy and check with your legal contacts.
+ """
+ restrictions: NotRequired[
+ "Literal['']|PaymentLinkUpdateParamsRestrictions"
+ ]
+ """
+ Settings that restrict the usage of a payment link.
+ """
+ shipping_address_collection: NotRequired[
+ "Literal['']|PaymentLinkUpdateParamsShippingAddressCollection"
+ ]
+ """
+ Configuration for collecting the customer's shipping address.
+ """
+ submit_type: NotRequired[
+ Literal["auto", "book", "donate", "pay", "subscribe"]
+ ]
+ """
+ Describes the type of transaction being performed in order to customize relevant text on the page, such as the submit button. Changing this value will also affect the hostname in the [url](https://stripe.com/docs/api/payment_links/payment_links/object#url) property (example: `donate.stripe.com`).
+ """
+ subscription_data: NotRequired["PaymentLinkUpdateParamsSubscriptionData"]
+ """
+ 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["PaymentLinkUpdateParamsTaxIdCollection"]
+ """
+ Controls tax ID collection during checkout.
+ """
+
+
+class PaymentLinkUpdateParamsAfterCompletion(TypedDict):
+ hosted_confirmation: NotRequired[
+ "PaymentLinkUpdateParamsAfterCompletionHostedConfirmation"
+ ]
+ """
+ Configuration when `type=hosted_confirmation`.
+ """
+ redirect: NotRequired["PaymentLinkUpdateParamsAfterCompletionRedirect"]
+ """
+ Configuration when `type=redirect`.
+ """
+ type: Literal["hosted_confirmation", "redirect"]
+ """
+ The specified behavior after the purchase is complete. Either `redirect` or `hosted_confirmation`.
+ """
+
+
+class PaymentLinkUpdateParamsAfterCompletionHostedConfirmation(TypedDict):
+ custom_message: NotRequired[str]
+ """
+ A custom message to display to the customer after the purchase is complete.
+ """
+
+
+class PaymentLinkUpdateParamsAfterCompletionRedirect(TypedDict):
+ url: str
+ """
+ The URL the customer will be redirected to after the purchase is complete. You can embed `{CHECKOUT_SESSION_ID}` into the URL to have the `id` of the completed [checkout session](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-id) included.
+ """
+
+
+class PaymentLinkUpdateParamsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
+
+ Enabling this parameter causes the payment link to collect any billing address information necessary for tax calculation.
+ """
+ liability: NotRequired["PaymentLinkUpdateParamsAutomaticTaxLiability"]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class PaymentLinkUpdateParamsAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class PaymentLinkUpdateParamsCustomField(TypedDict):
+ dropdown: NotRequired["PaymentLinkUpdateParamsCustomFieldDropdown"]
+ """
+ Configuration for `type=dropdown` fields.
+ """
+ key: str
+ """
+ String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
+ """
+ label: "PaymentLinkUpdateParamsCustomFieldLabel"
+ """
+ The label for the field, displayed to the customer.
+ """
+ numeric: NotRequired["PaymentLinkUpdateParamsCustomFieldNumeric"]
+ """
+ Configuration for `type=numeric` fields.
+ """
+ optional: NotRequired[bool]
+ """
+ Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
+ """
+ text: NotRequired["PaymentLinkUpdateParamsCustomFieldText"]
+ """
+ Configuration for `type=text` fields.
+ """
+ type: Literal["dropdown", "numeric", "text"]
+ """
+ The type of the field.
+ """
+
+
+class PaymentLinkUpdateParamsCustomFieldDropdown(TypedDict):
+ default_value: NotRequired[str]
+ """
+ The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
+ """
+ options: List["PaymentLinkUpdateParamsCustomFieldDropdownOption"]
+ """
+ The options available for the customer to select. Up to 200 options allowed.
+ """
+
+
+class PaymentLinkUpdateParamsCustomFieldDropdownOption(TypedDict):
+ label: str
+ """
+ The label for the option, displayed to the customer. Up to 100 characters.
+ """
+ value: str
+ """
+ The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
+ """
+
+
+class PaymentLinkUpdateParamsCustomFieldLabel(TypedDict):
+ custom: str
+ """
+ Custom text for the label, displayed to the customer. Up to 50 characters.
+ """
+ type: Literal["custom"]
+ """
+ The type of the label.
+ """
+
+
+class PaymentLinkUpdateParamsCustomFieldNumeric(TypedDict):
+ default_value: NotRequired[str]
+ """
+ The value that will pre-fill the field on the payment page.
+ """
+ maximum_length: NotRequired[int]
+ """
+ The maximum character length constraint for the customer's input.
+ """
+ minimum_length: NotRequired[int]
+ """
+ The minimum character length requirement for the customer's input.
+ """
+
+
+class PaymentLinkUpdateParamsCustomFieldText(TypedDict):
+ default_value: NotRequired[str]
+ """
+ The value that will pre-fill the field on the payment page.
+ """
+ maximum_length: NotRequired[int]
+ """
+ The maximum character length constraint for the customer's input.
+ """
+ minimum_length: NotRequired[int]
+ """
+ The minimum character length requirement for the customer's input.
+ """
+
+
+class PaymentLinkUpdateParamsCustomText(TypedDict):
+ after_submit: NotRequired[
+ "Literal['']|PaymentLinkUpdateParamsCustomTextAfterSubmit"
+ ]
+ """
+ Custom text that should be displayed after the payment confirmation button.
+ """
+ shipping_address: NotRequired[
+ "Literal['']|PaymentLinkUpdateParamsCustomTextShippingAddress"
+ ]
+ """
+ Custom text that should be displayed alongside shipping address collection.
+ """
+ submit: NotRequired["Literal['']|PaymentLinkUpdateParamsCustomTextSubmit"]
+ """
+ Custom text that should be displayed alongside the payment confirmation button.
+ """
+ terms_of_service_acceptance: NotRequired[
+ "Literal['']|PaymentLinkUpdateParamsCustomTextTermsOfServiceAcceptance"
+ ]
+ """
+ Custom text that should be displayed in place of the default terms of service agreement text.
+ """
+
+
+class PaymentLinkUpdateParamsCustomTextAfterSubmit(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class PaymentLinkUpdateParamsCustomTextShippingAddress(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class PaymentLinkUpdateParamsCustomTextSubmit(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class PaymentLinkUpdateParamsCustomTextTermsOfServiceAcceptance(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class PaymentLinkUpdateParamsInvoiceCreation(TypedDict):
+ enabled: bool
+ """
+ Whether the feature is enabled
+ """
+ invoice_data: NotRequired[
+ "PaymentLinkUpdateParamsInvoiceCreationInvoiceData"
+ ]
+ """
+ Invoice PDF configuration.
+ """
+
+
+class PaymentLinkUpdateParamsInvoiceCreationInvoiceData(TypedDict):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with the invoice.
+ """
+ custom_fields: NotRequired[
+ "Literal['']|List[PaymentLinkUpdateParamsInvoiceCreationInvoiceDataCustomField]"
+ ]
+ """
+ Default custom fields to be displayed on invoices for this customer.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ footer: NotRequired[str]
+ """
+ Default footer to be displayed on invoices for this customer.
+ """
+ issuer: NotRequired[
+ "PaymentLinkUpdateParamsInvoiceCreationInvoiceDataIssuer"
+ ]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ rendering_options: NotRequired[
+ "Literal['']|PaymentLinkUpdateParamsInvoiceCreationInvoiceDataRenderingOptions"
+ ]
+ """
+ Default options for invoice PDF rendering for this customer.
+ """
+
+
+class PaymentLinkUpdateParamsInvoiceCreationInvoiceDataCustomField(TypedDict):
+ name: str
+ """
+ The name of the custom field. This may be up to 40 characters.
+ """
+ value: str
+ """
+ The value of the custom field. This may be up to 140 characters.
+ """
+
+
+class PaymentLinkUpdateParamsInvoiceCreationInvoiceDataIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class PaymentLinkUpdateParamsInvoiceCreationInvoiceDataRenderingOptions(
+ TypedDict,
+):
+ amount_tax_display: NotRequired[
+ "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
+ ]
+ """
+ How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
+ """
+ template: NotRequired[str]
+ """
+ ID of the invoice rendering template to use for this invoice.
+ """
+
+
+class PaymentLinkUpdateParamsLineItem(TypedDict):
+ adjustable_quantity: NotRequired[
+ "PaymentLinkUpdateParamsLineItemAdjustableQuantity"
+ ]
+ """
+ When set, provides configuration for this item's quantity to be adjusted by the customer during checkout.
+ """
+ id: str
+ """
+ The ID of an existing line item on the payment link.
+ """
+ quantity: NotRequired[int]
+ """
+ The quantity of the line item being purchased.
+ """
+
+
+class PaymentLinkUpdateParamsLineItemAdjustableQuantity(TypedDict):
+ enabled: bool
+ """
+ Set to true if the quantity can be adjusted to any non-negative Integer.
+ """
+ maximum: NotRequired[int]
+ """
+ The maximum quantity the customer can purchase. By default this value is 99. You can specify a value up to 999999.
+ """
+ minimum: NotRequired[int]
+ """
+ The minimum quantity the customer can purchase. By default this value is 0. If there is only one item in the cart then that item's quantity cannot go down to 0.
+ """
+
+
+class PaymentLinkUpdateParamsPaymentIntentData(TypedDict):
+ description: NotRequired["Literal['']|str"]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Payment Intents](https://stripe.com/docs/api/payment_intents) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
+ """
+ statement_descriptor: NotRequired["Literal['']|str"]
+ """
+ Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
+
+ Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
+ """
+ statement_descriptor_suffix: NotRequired["Literal['']|str"]
+ """
+ Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
+ """
+ transfer_group: NotRequired["Literal['']|str"]
+ """
+ A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
+ """
+
+
+class PaymentLinkUpdateParamsPhoneNumberCollection(TypedDict):
+ enabled: bool
+ """
+ Set to `true` to enable phone number collection.
+ """
+
+
+class PaymentLinkUpdateParamsRestrictions(TypedDict):
+ completed_sessions: "PaymentLinkUpdateParamsRestrictionsCompletedSessions"
+ """
+ Configuration for the `completed_sessions` restriction type.
+ """
+
+
+class PaymentLinkUpdateParamsRestrictionsCompletedSessions(TypedDict):
+ limit: int
+ """
+ The maximum number of checkout sessions that can be completed for the `completed_sessions` restriction to be met.
+ """
+
+
+class PaymentLinkUpdateParamsShippingAddressCollection(TypedDict):
+ allowed_countries: List[
+ Literal[
+ "AC",
+ "AD",
+ "AE",
+ "AF",
+ "AG",
+ "AI",
+ "AL",
+ "AM",
+ "AO",
+ "AQ",
+ "AR",
+ "AT",
+ "AU",
+ "AW",
+ "AX",
+ "AZ",
+ "BA",
+ "BB",
+ "BD",
+ "BE",
+ "BF",
+ "BG",
+ "BH",
+ "BI",
+ "BJ",
+ "BL",
+ "BM",
+ "BN",
+ "BO",
+ "BQ",
+ "BR",
+ "BS",
+ "BT",
+ "BV",
+ "BW",
+ "BY",
+ "BZ",
+ "CA",
+ "CD",
+ "CF",
+ "CG",
+ "CH",
+ "CI",
+ "CK",
+ "CL",
+ "CM",
+ "CN",
+ "CO",
+ "CR",
+ "CV",
+ "CW",
+ "CY",
+ "CZ",
+ "DE",
+ "DJ",
+ "DK",
+ "DM",
+ "DO",
+ "DZ",
+ "EC",
+ "EE",
+ "EG",
+ "EH",
+ "ER",
+ "ES",
+ "ET",
+ "FI",
+ "FJ",
+ "FK",
+ "FO",
+ "FR",
+ "GA",
+ "GB",
+ "GD",
+ "GE",
+ "GF",
+ "GG",
+ "GH",
+ "GI",
+ "GL",
+ "GM",
+ "GN",
+ "GP",
+ "GQ",
+ "GR",
+ "GS",
+ "GT",
+ "GU",
+ "GW",
+ "GY",
+ "HK",
+ "HN",
+ "HR",
+ "HT",
+ "HU",
+ "ID",
+ "IE",
+ "IL",
+ "IM",
+ "IN",
+ "IO",
+ "IQ",
+ "IS",
+ "IT",
+ "JE",
+ "JM",
+ "JO",
+ "JP",
+ "KE",
+ "KG",
+ "KH",
+ "KI",
+ "KM",
+ "KN",
+ "KR",
+ "KW",
+ "KY",
+ "KZ",
+ "LA",
+ "LB",
+ "LC",
+ "LI",
+ "LK",
+ "LR",
+ "LS",
+ "LT",
+ "LU",
+ "LV",
+ "LY",
+ "MA",
+ "MC",
+ "MD",
+ "ME",
+ "MF",
+ "MG",
+ "MK",
+ "ML",
+ "MM",
+ "MN",
+ "MO",
+ "MQ",
+ "MR",
+ "MS",
+ "MT",
+ "MU",
+ "MV",
+ "MW",
+ "MX",
+ "MY",
+ "MZ",
+ "NA",
+ "NC",
+ "NE",
+ "NG",
+ "NI",
+ "NL",
+ "NO",
+ "NP",
+ "NR",
+ "NU",
+ "NZ",
+ "OM",
+ "PA",
+ "PE",
+ "PF",
+ "PG",
+ "PH",
+ "PK",
+ "PL",
+ "PM",
+ "PN",
+ "PR",
+ "PS",
+ "PT",
+ "PY",
+ "QA",
+ "RE",
+ "RO",
+ "RS",
+ "RU",
+ "RW",
+ "SA",
+ "SB",
+ "SC",
+ "SD",
+ "SE",
+ "SG",
+ "SH",
+ "SI",
+ "SJ",
+ "SK",
+ "SL",
+ "SM",
+ "SN",
+ "SO",
+ "SR",
+ "SS",
+ "ST",
+ "SV",
+ "SX",
+ "SZ",
+ "TA",
+ "TC",
+ "TD",
+ "TF",
+ "TG",
+ "TH",
+ "TJ",
+ "TK",
+ "TL",
+ "TM",
+ "TN",
+ "TO",
+ "TR",
+ "TT",
+ "TV",
+ "TW",
+ "TZ",
+ "UA",
+ "UG",
+ "US",
+ "UY",
+ "UZ",
+ "VA",
+ "VC",
+ "VE",
+ "VG",
+ "VN",
+ "VU",
+ "WF",
+ "WS",
+ "XK",
+ "YE",
+ "YT",
+ "ZA",
+ "ZM",
+ "ZW",
+ "ZZ",
+ ]
+ ]
+ """
+ An array of two-letter ISO country codes representing which countries Checkout should provide as options for
+ shipping locations.
+ """
+
+
+class PaymentLinkUpdateParamsSubscriptionData(TypedDict):
+ invoice_settings: NotRequired[
+ "PaymentLinkUpdateParamsSubscriptionDataInvoiceSettings"
+ ]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Subscriptions](https://stripe.com/docs/api/subscriptions) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
+ """
+ trial_period_days: NotRequired["Literal['']|int"]
+ """
+ Integer representing the number of trial period days before the customer is charged for the first time. Has to be at least 1.
+ """
+ trial_settings: NotRequired[
+ "Literal['']|PaymentLinkUpdateParamsSubscriptionDataTrialSettings"
+ ]
+ """
+ Settings related to subscription trials.
+ """
+
+
+class PaymentLinkUpdateParamsSubscriptionDataInvoiceSettings(TypedDict):
+ issuer: NotRequired[
+ "PaymentLinkUpdateParamsSubscriptionDataInvoiceSettingsIssuer"
+ ]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class PaymentLinkUpdateParamsSubscriptionDataInvoiceSettingsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class PaymentLinkUpdateParamsSubscriptionDataTrialSettings(TypedDict):
+ end_behavior: (
+ "PaymentLinkUpdateParamsSubscriptionDataTrialSettingsEndBehavior"
+ )
+ """
+ Defines how the subscription should behave when the user's free trial ends.
+ """
+
+
+class PaymentLinkUpdateParamsSubscriptionDataTrialSettingsEndBehavior(
+ TypedDict,
+):
+ missing_payment_method: Literal["cancel", "create_invoice", "pause"]
+ """
+ Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
+ """
+
+
+class PaymentLinkUpdateParamsTaxIdCollection(TypedDict):
+ enabled: bool
+ """
+ Enable tax ID collection during checkout. Defaults to `false`.
+ """
+ required: NotRequired[Literal["if_supported", "never"]]
+ """
+ Describes whether a tax ID is required during checkout. Defaults to `never`.
+ """
diff --git a/stripe/params/_payment_method_attach_params.py b/stripe/params/_payment_method_attach_params.py
new file mode 100644
index 000000000..ea9ae2eb4
--- /dev/null
+++ b/stripe/params/_payment_method_attach_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentMethodAttachParams(RequestOptions):
+ customer: str
+ """
+ The ID of the customer to which to attach the PaymentMethod.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payment_method_configuration_create_params.py b/stripe/params/_payment_method_configuration_create_params.py
new file mode 100644
index 000000000..f34f894e5
--- /dev/null
+++ b/stripe/params/_payment_method_configuration_create_params.py
@@ -0,0 +1,1158 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PaymentMethodConfigurationCreateParams(RequestOptions):
+ acss_debit: NotRequired["PaymentMethodConfigurationCreateParamsAcssDebit"]
+ """
+ Canadian pre-authorized debit payments, check this [page](https://stripe.com/docs/payments/acss-debit) for more details like country availability.
+ """
+ affirm: NotRequired["PaymentMethodConfigurationCreateParamsAffirm"]
+ """
+ [Affirm](https://www.affirm.com/) gives your customers a way to split purchases over a series of payments. Depending on the purchase, they can pay with four interest-free payments (Split Pay) or pay over a longer term (Installments), which might include interest. Check this [page](https://stripe.com/docs/payments/affirm) for more details like country availability.
+ """
+ afterpay_clearpay: NotRequired[
+ "PaymentMethodConfigurationCreateParamsAfterpayClearpay"
+ ]
+ """
+ Afterpay gives your customers a way to pay for purchases in installments, check this [page](https://stripe.com/docs/payments/afterpay-clearpay) for more details like country availability. Afterpay is particularly popular among businesses selling fashion, beauty, and sports products.
+ """
+ alipay: NotRequired["PaymentMethodConfigurationCreateParamsAlipay"]
+ """
+ Alipay is a digital wallet in China that has more than a billion active users worldwide. Alipay users can pay on the web or on a mobile device using login credentials or their Alipay app. Alipay has a low dispute rate and reduces fraud by authenticating payments using the customer's login credentials. Check this [page](https://stripe.com/docs/payments/alipay) for more details.
+ """
+ alma: NotRequired["PaymentMethodConfigurationCreateParamsAlma"]
+ """
+ Alma is a Buy Now, Pay Later payment method that offers customers the ability to pay in 2, 3, or 4 installments.
+ """
+ amazon_pay: NotRequired["PaymentMethodConfigurationCreateParamsAmazonPay"]
+ """
+ Amazon Pay is a wallet payment method that lets your customers check out the same way as on Amazon.
+ """
+ apple_pay: NotRequired["PaymentMethodConfigurationCreateParamsApplePay"]
+ """
+ Stripe users can accept [Apple Pay](https://stripe.com/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. There are no additional fees to process Apple Pay payments, and the [pricing](https://stripe.com/pricing) is the same as other card transactions. Check this [page](https://stripe.com/docs/apple-pay) for more details.
+ """
+ apple_pay_later: NotRequired[
+ "PaymentMethodConfigurationCreateParamsApplePayLater"
+ ]
+ """
+ Apple Pay Later, a payment method for customers to buy now and pay later, gives your customers a way to split purchases into four installments across six weeks.
+ """
+ au_becs_debit: NotRequired[
+ "PaymentMethodConfigurationCreateParamsAuBecsDebit"
+ ]
+ """
+ Stripe users in Australia can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with an Australian bank account. Check this [page](https://stripe.com/docs/payments/au-becs-debit) for more details.
+ """
+ bacs_debit: NotRequired["PaymentMethodConfigurationCreateParamsBacsDebit"]
+ """
+ Stripe users in the UK can accept Bacs Direct Debit payments from customers with a UK bank account, check this [page](https://stripe.com/docs/payments/payment-methods/bacs-debit) for more details.
+ """
+ bancontact: NotRequired["PaymentMethodConfigurationCreateParamsBancontact"]
+ """
+ Bancontact is the most popular online payment method in Belgium, with over 15 million cards in circulation. [Customers](https://stripe.com/docs/api/customers) use a Bancontact card or mobile app linked to a Belgian bank account to make online payments that are secure, guaranteed, and confirmed immediately. Check this [page](https://stripe.com/docs/payments/bancontact) for more details.
+ """
+ billie: NotRequired["PaymentMethodConfigurationCreateParamsBillie"]
+ """
+ Billie is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method that offers businesses Pay by Invoice where they offer payment terms ranging from 7-120 days. Customers are redirected from your website or app, authorize the payment with Billie, then return to your website or app. You get [immediate notification](https://docs.stripe.com/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
+ """
+ blik: NotRequired["PaymentMethodConfigurationCreateParamsBlik"]
+ """
+ BLIK is a [single use](https://stripe.com/docs/payments/payment-methods#usage) payment method that requires customers to authenticate their payments. When customers want to pay online using BLIK, they request a six-digit code from their banking application and enter it into the payment collection form. Check this [page](https://stripe.com/docs/payments/blik) for more details.
+ """
+ boleto: NotRequired["PaymentMethodConfigurationCreateParamsBoleto"]
+ """
+ Boleto is an official (regulated by the Central Bank of Brazil) payment method in Brazil. Check this [page](https://stripe.com/docs/payments/boleto) for more details.
+ """
+ card: NotRequired["PaymentMethodConfigurationCreateParamsCard"]
+ """
+ Cards are a popular way for consumers and businesses to pay online or in person. Stripe supports global and local card networks.
+ """
+ cartes_bancaires: NotRequired[
+ "PaymentMethodConfigurationCreateParamsCartesBancaires"
+ ]
+ """
+ Cartes Bancaires is France's local card network. More than 95% of these cards are co-branded with either Visa or Mastercard, meaning you can process these cards over either Cartes Bancaires or the Visa or Mastercard networks. Check this [page](https://stripe.com/docs/payments/cartes-bancaires) for more details.
+ """
+ cashapp: NotRequired["PaymentMethodConfigurationCreateParamsCashapp"]
+ """
+ Cash App is a popular consumer app in the US that allows customers to bank, invest, send, and receive money using their digital wallet. Check this [page](https://stripe.com/docs/payments/cash-app-pay) for more details.
+ """
+ customer_balance: NotRequired[
+ "PaymentMethodConfigurationCreateParamsCustomerBalance"
+ ]
+ """
+ Uses a customer's [cash balance](https://stripe.com/docs/payments/customer-balance) for the payment. The cash balance can be funded via a bank transfer. Check this [page](https://stripe.com/docs/payments/bank-transfers) for more details.
+ """
+ eps: NotRequired["PaymentMethodConfigurationCreateParamsEps"]
+ """
+ EPS is an Austria-based payment method that allows customers to complete transactions online using their bank credentials. EPS is supported by all Austrian banks and is accepted by over 80% of Austrian online retailers. Check this [page](https://stripe.com/docs/payments/eps) for more details.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ fpx: NotRequired["PaymentMethodConfigurationCreateParamsFpx"]
+ """
+ Financial Process Exchange (FPX) is a Malaysia-based payment method that allows customers to complete transactions online using their bank credentials. Bank Negara Malaysia (BNM), the Central Bank of Malaysia, and eleven other major Malaysian financial institutions are members of the PayNet Group, which owns and operates FPX. It is one of the most popular online payment methods in Malaysia, with nearly 90 million transactions in 2018 according to BNM. Check this [page](https://stripe.com/docs/payments/fpx) for more details.
+ """
+ fr_meal_voucher_conecs: NotRequired[
+ "PaymentMethodConfigurationCreateParamsFrMealVoucherConecs"
+ ]
+ """
+ Meal vouchers in France, or “titres-restaurant”, is a local benefits program commonly offered by employers for their employees to purchase prepared food and beverages on working days. Check this [page](https://stripe.com/docs/payments/benefits/fr-meal-vouchers) for more details.
+ """
+ giropay: NotRequired["PaymentMethodConfigurationCreateParamsGiropay"]
+ """
+ giropay is a German payment method based on online banking, introduced in 2006. It allows customers to complete transactions online using their online banking environment, with funds debited from their bank account. Depending on their bank, customers confirm payments on giropay using a second factor of authentication or a PIN. giropay accounts for 10% of online checkouts in Germany. Check this [page](https://stripe.com/docs/payments/giropay) for more details.
+ """
+ google_pay: NotRequired["PaymentMethodConfigurationCreateParamsGooglePay"]
+ """
+ Google Pay allows customers to make payments in your app or website using any credit or debit card saved to their Google Account, including those from Google Play, YouTube, Chrome, or an Android device. Use the Google Pay API to request any credit or debit card stored in your customer's Google account. Check this [page](https://stripe.com/docs/google-pay) for more details.
+ """
+ grabpay: NotRequired["PaymentMethodConfigurationCreateParamsGrabpay"]
+ """
+ GrabPay is a payment method developed by [Grab](https://www.grab.com/sg/consumer/finance/pay/). GrabPay is a digital wallet - customers maintain a balance in their wallets that they pay out with. Check this [page](https://stripe.com/docs/payments/grabpay) for more details.
+ """
+ ideal: NotRequired["PaymentMethodConfigurationCreateParamsIdeal"]
+ """
+ iDEAL is a Netherlands-based payment method that allows customers to complete transactions online using their bank credentials. All major Dutch banks are members of Currence, the scheme that operates iDEAL, making it the most popular online payment method in the Netherlands with a share of online transactions close to 55%. Check this [page](https://stripe.com/docs/payments/ideal) for more details.
+ """
+ jcb: NotRequired["PaymentMethodConfigurationCreateParamsJcb"]
+ """
+ JCB is a credit card company based in Japan. JCB is currently available in Japan to businesses approved by JCB, and available to all businesses in Australia, Canada, Hong Kong, Japan, New Zealand, Singapore, Switzerland, United Kingdom, United States, and all countries in the European Economic Area except Iceland. Check this [page](https://support.stripe.com/questions/accepting-japan-credit-bureau-%28jcb%29-payments) for more details.
+ """
+ kakao_pay: NotRequired["PaymentMethodConfigurationCreateParamsKakaoPay"]
+ """
+ Kakao Pay is a popular local wallet available in South Korea.
+ """
+ klarna: NotRequired["PaymentMethodConfigurationCreateParamsKlarna"]
+ """
+ Klarna gives customers a range of [payment options](https://stripe.com/docs/payments/klarna#payment-options) during checkout. Available payment options vary depending on the customer's billing address and the transaction amount. These payment options make it convenient for customers to purchase items in all price ranges. Check this [page](https://stripe.com/docs/payments/klarna) for more details.
+ """
+ konbini: NotRequired["PaymentMethodConfigurationCreateParamsKonbini"]
+ """
+ Konbini allows customers in Japan to pay for bills and online purchases at convenience stores with cash. Check this [page](https://stripe.com/docs/payments/konbini) for more details.
+ """
+ kr_card: NotRequired["PaymentMethodConfigurationCreateParamsKrCard"]
+ """
+ Korean cards let users pay using locally issued cards from South Korea.
+ """
+ link: NotRequired["PaymentMethodConfigurationCreateParamsLink"]
+ """
+ [Link](https://stripe.com/docs/payments/link) is a payment method network. With Link, users save their payment details once, then reuse that information to pay with one click for any business on the network.
+ """
+ mobilepay: NotRequired["PaymentMethodConfigurationCreateParamsMobilepay"]
+ """
+ MobilePay is a [single-use](https://stripe.com/docs/payments/payment-methods#usage) card wallet payment method used in Denmark and Finland. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the MobilePay app. Check this [page](https://stripe.com/docs/payments/mobilepay) for more details.
+ """
+ multibanco: NotRequired["PaymentMethodConfigurationCreateParamsMultibanco"]
+ """
+ Stripe users in Europe and the United States can accept Multibanco payments from customers in Portugal using [Sources](https://stripe.com/docs/sources)—a single integration path for creating payments using any supported method.
+ """
+ name: NotRequired[str]
+ """
+ Configuration name.
+ """
+ naver_pay: NotRequired["PaymentMethodConfigurationCreateParamsNaverPay"]
+ """
+ Naver Pay is a popular local wallet available in South Korea.
+ """
+ nz_bank_account: NotRequired[
+ "PaymentMethodConfigurationCreateParamsNzBankAccount"
+ ]
+ """
+ Stripe users in New Zealand can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with a New Zeland bank account. Check this [page](https://stripe.com/docs/payments/nz-bank-account) for more details.
+ """
+ oxxo: NotRequired["PaymentMethodConfigurationCreateParamsOxxo"]
+ """
+ OXXO is a Mexican chain of convenience stores with thousands of locations across Latin America and represents nearly 20% of online transactions in Mexico. OXXO allows customers to pay bills and online purchases in-store with cash. Check this [page](https://stripe.com/docs/payments/oxxo) for more details.
+ """
+ p24: NotRequired["PaymentMethodConfigurationCreateParamsP24"]
+ """
+ Przelewy24 is a Poland-based payment method aggregator that allows customers to complete transactions online using bank transfers and other methods. Bank transfers account for 30% of online payments in Poland and Przelewy24 provides a way for customers to pay with over 165 banks. Check this [page](https://stripe.com/docs/payments/p24) for more details.
+ """
+ parent: NotRequired[str]
+ """
+ Configuration's parent configuration. Specify to create a child configuration.
+ """
+ pay_by_bank: NotRequired["PaymentMethodConfigurationCreateParamsPayByBank"]
+ """
+ Pay by bank is a redirect payment method backed by bank transfers. A customer is redirected to their bank to authorize a bank transfer for a given amount. This removes a lot of the error risks inherent in waiting for the customer to initiate a transfer themselves, and is less expensive than card payments.
+ """
+ payco: NotRequired["PaymentMethodConfigurationCreateParamsPayco"]
+ """
+ PAYCO is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
+ """
+ paynow: NotRequired["PaymentMethodConfigurationCreateParamsPaynow"]
+ """
+ PayNow is a Singapore-based payment method that allows customers to make a payment using their preferred app from participating banks and participating non-bank financial institutions. Check this [page](https://stripe.com/docs/payments/paynow) for more details.
+ """
+ paypal: NotRequired["PaymentMethodConfigurationCreateParamsPaypal"]
+ """
+ PayPal, a digital wallet popular with customers in Europe, allows your customers worldwide to pay using their PayPal account. Check this [page](https://stripe.com/docs/payments/paypal) for more details.
+ """
+ pix: NotRequired["PaymentMethodConfigurationCreateParamsPix"]
+ """
+ Pix is a payment method popular in Brazil. When paying with Pix, customers authenticate and approve payments by scanning a QR code in their preferred banking app. Check this [page](https://docs.stripe.com/payments/pix) for more details.
+ """
+ promptpay: NotRequired["PaymentMethodConfigurationCreateParamsPromptpay"]
+ """
+ PromptPay is a Thailand-based payment method that allows customers to make a payment using their preferred app from participating banks. Check this [page](https://stripe.com/docs/payments/promptpay) for more details.
+ """
+ revolut_pay: NotRequired[
+ "PaymentMethodConfigurationCreateParamsRevolutPay"
+ ]
+ """
+ Revolut Pay, developed by Revolut, a global finance app, is a digital wallet payment method. Revolut Pay uses the customer's stored balance or cards to fund the payment, and offers the option for non-Revolut customers to save their details after their first purchase.
+ """
+ samsung_pay: NotRequired[
+ "PaymentMethodConfigurationCreateParamsSamsungPay"
+ ]
+ """
+ Samsung Pay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
+ """
+ satispay: NotRequired["PaymentMethodConfigurationCreateParamsSatispay"]
+ """
+ Satispay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method where customers are required to [authenticate](https://docs.stripe.com/payments/payment-methods#customer-actions) their payment. Customers pay by being redirected from your website or app, authorizing the payment with Satispay, then returning to your website or app. You get [immediate notification](https://docs.stripe.com/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
+ """
+ sepa_debit: NotRequired["PaymentMethodConfigurationCreateParamsSepaDebit"]
+ """
+ The [Single Euro Payments Area (SEPA)](https://en.wikipedia.org/wiki/Single_Euro_Payments_Area) is an initiative of the European Union to simplify payments within and across member countries. SEPA established and enforced banking standards to allow for the direct debiting of every EUR-denominated bank account within the SEPA region, check this [page](https://stripe.com/docs/payments/sepa-debit) for more details.
+ """
+ sofort: NotRequired["PaymentMethodConfigurationCreateParamsSofort"]
+ """
+ Stripe users in Europe and the United States can use the [Payment Intents API](https://stripe.com/docs/payments/payment-intents)—a single integration path for creating payments using any supported method—to accept [Sofort](https://www.sofort.com/) payments from customers. Check this [page](https://stripe.com/docs/payments/sofort) for more details.
+ """
+ swish: NotRequired["PaymentMethodConfigurationCreateParamsSwish"]
+ """
+ Swish is a [real-time](https://stripe.com/docs/payments/real-time) payment method popular in Sweden. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the Swish mobile app and the Swedish BankID mobile app. Check this [page](https://stripe.com/docs/payments/swish) for more details.
+ """
+ twint: NotRequired["PaymentMethodConfigurationCreateParamsTwint"]
+ """
+ Twint is a payment method popular in Switzerland. It allows customers to pay using their mobile phone. Check this [page](https://docs.stripe.com/payments/twint) for more details.
+ """
+ us_bank_account: NotRequired[
+ "PaymentMethodConfigurationCreateParamsUsBankAccount"
+ ]
+ """
+ Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check this [page](https://stripe.com/docs/payments/ach-direct-debit) for more details.
+ """
+ wechat_pay: NotRequired["PaymentMethodConfigurationCreateParamsWechatPay"]
+ """
+ WeChat, owned by Tencent, is China's leading mobile app with over 1 billion monthly active users. Chinese consumers can use WeChat Pay to pay for goods and services inside of businesses' apps and websites. WeChat Pay users buy most frequently in gaming, e-commerce, travel, online education, and food/nutrition. Check this [page](https://stripe.com/docs/payments/wechat-pay) for more details.
+ """
+ zip: NotRequired["PaymentMethodConfigurationCreateParamsZip"]
+ """
+ Zip gives your customers a way to split purchases over a series of payments. Check this [page](https://stripe.com/docs/payments/zip) for more details like country availability.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsAcssDebit(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsAcssDebitDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsAcssDebitDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsAffirm(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsAffirmDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsAffirmDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsAfterpayClearpay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsAfterpayClearpayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsAfterpayClearpayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsAlipay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsAlipayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsAlipayDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsAlma(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsAlmaDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsAlmaDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsAmazonPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsAmazonPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsAmazonPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsApplePay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsApplePayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsApplePayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsApplePayLater(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsApplePayLaterDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsApplePayLaterDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsAuBecsDebit(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsAuBecsDebitDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsAuBecsDebitDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsBacsDebit(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsBacsDebitDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsBacsDebitDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsBancontact(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsBancontactDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsBancontactDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsBillie(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsBillieDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsBillieDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsBlik(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsBlikDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsBlikDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsBoleto(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsBoletoDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsBoletoDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsCard(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsCardDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsCardDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsCartesBancaires(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsCartesBancairesDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsCartesBancairesDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsCashapp(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsCashappDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsCashappDisplayPreference(
+ TypedDict
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsCustomerBalance(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsCustomerBalanceDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsCustomerBalanceDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsEps(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsEpsDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsEpsDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsFpx(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsFpxDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsFpxDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsFrMealVoucherConecs(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsFrMealVoucherConecsDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsFrMealVoucherConecsDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsGiropay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsGiropayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsGiropayDisplayPreference(
+ TypedDict
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsGooglePay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsGooglePayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsGooglePayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsGrabpay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsGrabpayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsGrabpayDisplayPreference(
+ TypedDict
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsIdeal(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsIdealDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsIdealDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsJcb(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsJcbDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsJcbDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsKakaoPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsKakaoPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsKakaoPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsKlarna(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsKlarnaDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsKlarnaDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsKonbini(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsKonbiniDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsKonbiniDisplayPreference(
+ TypedDict
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsKrCard(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsKrCardDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsKrCardDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsLink(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsLinkDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsLinkDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsMobilepay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsMobilepayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsMobilepayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsMultibanco(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsMultibancoDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsMultibancoDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsNaverPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsNaverPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsNaverPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsNzBankAccount(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsNzBankAccountDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsNzBankAccountDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsOxxo(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsOxxoDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsOxxoDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsP24(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsP24DisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsP24DisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsPayByBank(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsPayByBankDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsPayByBankDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsPayco(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsPaycoDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsPaycoDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsPaynow(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsPaynowDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsPaynowDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsPaypal(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsPaypalDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsPaypalDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsPix(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsPixDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsPixDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsPromptpay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsPromptpayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsPromptpayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsRevolutPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsRevolutPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsRevolutPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsSamsungPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsSamsungPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsSamsungPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsSatispay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsSatispayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsSatispayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsSepaDebit(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsSepaDebitDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsSepaDebitDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsSofort(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsSofortDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsSofortDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsSwish(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsSwishDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsSwishDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsTwint(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsTwintDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsTwintDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsUsBankAccount(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsUsBankAccountDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsUsBankAccountDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsWechatPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsWechatPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsWechatPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsZip(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationCreateParamsZipDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationCreateParamsZipDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
diff --git a/stripe/params/_payment_method_configuration_list_params.py b/stripe/params/_payment_method_configuration_list_params.py
new file mode 100644
index 000000000..260d38878
--- /dev/null
+++ b/stripe/params/_payment_method_configuration_list_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class PaymentMethodConfigurationListParams(RequestOptions):
+ application: NotRequired["Literal['']|str"]
+ """
+ The Connect application to filter by.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_payment_method_configuration_modify_params.py b/stripe/params/_payment_method_configuration_modify_params.py
new file mode 100644
index 000000000..9e9877be7
--- /dev/null
+++ b/stripe/params/_payment_method_configuration_modify_params.py
@@ -0,0 +1,1158 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PaymentMethodConfigurationModifyParams(RequestOptions):
+ acss_debit: NotRequired["PaymentMethodConfigurationModifyParamsAcssDebit"]
+ """
+ Canadian pre-authorized debit payments, check this [page](https://stripe.com/docs/payments/acss-debit) for more details like country availability.
+ """
+ active: NotRequired[bool]
+ """
+ Whether the configuration can be used for new payments.
+ """
+ affirm: NotRequired["PaymentMethodConfigurationModifyParamsAffirm"]
+ """
+ [Affirm](https://www.affirm.com/) gives your customers a way to split purchases over a series of payments. Depending on the purchase, they can pay with four interest-free payments (Split Pay) or pay over a longer term (Installments), which might include interest. Check this [page](https://stripe.com/docs/payments/affirm) for more details like country availability.
+ """
+ afterpay_clearpay: NotRequired[
+ "PaymentMethodConfigurationModifyParamsAfterpayClearpay"
+ ]
+ """
+ Afterpay gives your customers a way to pay for purchases in installments, check this [page](https://stripe.com/docs/payments/afterpay-clearpay) for more details like country availability. Afterpay is particularly popular among businesses selling fashion, beauty, and sports products.
+ """
+ alipay: NotRequired["PaymentMethodConfigurationModifyParamsAlipay"]
+ """
+ Alipay is a digital wallet in China that has more than a billion active users worldwide. Alipay users can pay on the web or on a mobile device using login credentials or their Alipay app. Alipay has a low dispute rate and reduces fraud by authenticating payments using the customer's login credentials. Check this [page](https://stripe.com/docs/payments/alipay) for more details.
+ """
+ alma: NotRequired["PaymentMethodConfigurationModifyParamsAlma"]
+ """
+ Alma is a Buy Now, Pay Later payment method that offers customers the ability to pay in 2, 3, or 4 installments.
+ """
+ amazon_pay: NotRequired["PaymentMethodConfigurationModifyParamsAmazonPay"]
+ """
+ Amazon Pay is a wallet payment method that lets your customers check out the same way as on Amazon.
+ """
+ apple_pay: NotRequired["PaymentMethodConfigurationModifyParamsApplePay"]
+ """
+ Stripe users can accept [Apple Pay](https://stripe.com/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. There are no additional fees to process Apple Pay payments, and the [pricing](https://stripe.com/pricing) is the same as other card transactions. Check this [page](https://stripe.com/docs/apple-pay) for more details.
+ """
+ apple_pay_later: NotRequired[
+ "PaymentMethodConfigurationModifyParamsApplePayLater"
+ ]
+ """
+ Apple Pay Later, a payment method for customers to buy now and pay later, gives your customers a way to split purchases into four installments across six weeks.
+ """
+ au_becs_debit: NotRequired[
+ "PaymentMethodConfigurationModifyParamsAuBecsDebit"
+ ]
+ """
+ Stripe users in Australia can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with an Australian bank account. Check this [page](https://stripe.com/docs/payments/au-becs-debit) for more details.
+ """
+ bacs_debit: NotRequired["PaymentMethodConfigurationModifyParamsBacsDebit"]
+ """
+ Stripe users in the UK can accept Bacs Direct Debit payments from customers with a UK bank account, check this [page](https://stripe.com/docs/payments/payment-methods/bacs-debit) for more details.
+ """
+ bancontact: NotRequired["PaymentMethodConfigurationModifyParamsBancontact"]
+ """
+ Bancontact is the most popular online payment method in Belgium, with over 15 million cards in circulation. [Customers](https://stripe.com/docs/api/customers) use a Bancontact card or mobile app linked to a Belgian bank account to make online payments that are secure, guaranteed, and confirmed immediately. Check this [page](https://stripe.com/docs/payments/bancontact) for more details.
+ """
+ billie: NotRequired["PaymentMethodConfigurationModifyParamsBillie"]
+ """
+ Billie is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method that offers businesses Pay by Invoice where they offer payment terms ranging from 7-120 days. Customers are redirected from your website or app, authorize the payment with Billie, then return to your website or app. You get [immediate notification](https://docs.stripe.com/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
+ """
+ blik: NotRequired["PaymentMethodConfigurationModifyParamsBlik"]
+ """
+ BLIK is a [single use](https://stripe.com/docs/payments/payment-methods#usage) payment method that requires customers to authenticate their payments. When customers want to pay online using BLIK, they request a six-digit code from their banking application and enter it into the payment collection form. Check this [page](https://stripe.com/docs/payments/blik) for more details.
+ """
+ boleto: NotRequired["PaymentMethodConfigurationModifyParamsBoleto"]
+ """
+ Boleto is an official (regulated by the Central Bank of Brazil) payment method in Brazil. Check this [page](https://stripe.com/docs/payments/boleto) for more details.
+ """
+ card: NotRequired["PaymentMethodConfigurationModifyParamsCard"]
+ """
+ Cards are a popular way for consumers and businesses to pay online or in person. Stripe supports global and local card networks.
+ """
+ cartes_bancaires: NotRequired[
+ "PaymentMethodConfigurationModifyParamsCartesBancaires"
+ ]
+ """
+ Cartes Bancaires is France's local card network. More than 95% of these cards are co-branded with either Visa or Mastercard, meaning you can process these cards over either Cartes Bancaires or the Visa or Mastercard networks. Check this [page](https://stripe.com/docs/payments/cartes-bancaires) for more details.
+ """
+ cashapp: NotRequired["PaymentMethodConfigurationModifyParamsCashapp"]
+ """
+ Cash App is a popular consumer app in the US that allows customers to bank, invest, send, and receive money using their digital wallet. Check this [page](https://stripe.com/docs/payments/cash-app-pay) for more details.
+ """
+ customer_balance: NotRequired[
+ "PaymentMethodConfigurationModifyParamsCustomerBalance"
+ ]
+ """
+ Uses a customer's [cash balance](https://stripe.com/docs/payments/customer-balance) for the payment. The cash balance can be funded via a bank transfer. Check this [page](https://stripe.com/docs/payments/bank-transfers) for more details.
+ """
+ eps: NotRequired["PaymentMethodConfigurationModifyParamsEps"]
+ """
+ EPS is an Austria-based payment method that allows customers to complete transactions online using their bank credentials. EPS is supported by all Austrian banks and is accepted by over 80% of Austrian online retailers. Check this [page](https://stripe.com/docs/payments/eps) for more details.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ fpx: NotRequired["PaymentMethodConfigurationModifyParamsFpx"]
+ """
+ Financial Process Exchange (FPX) is a Malaysia-based payment method that allows customers to complete transactions online using their bank credentials. Bank Negara Malaysia (BNM), the Central Bank of Malaysia, and eleven other major Malaysian financial institutions are members of the PayNet Group, which owns and operates FPX. It is one of the most popular online payment methods in Malaysia, with nearly 90 million transactions in 2018 according to BNM. Check this [page](https://stripe.com/docs/payments/fpx) for more details.
+ """
+ fr_meal_voucher_conecs: NotRequired[
+ "PaymentMethodConfigurationModifyParamsFrMealVoucherConecs"
+ ]
+ """
+ Meal vouchers in France, or “titres-restaurant”, is a local benefits program commonly offered by employers for their employees to purchase prepared food and beverages on working days. Check this [page](https://stripe.com/docs/payments/benefits/fr-meal-vouchers) for more details.
+ """
+ giropay: NotRequired["PaymentMethodConfigurationModifyParamsGiropay"]
+ """
+ giropay is a German payment method based on online banking, introduced in 2006. It allows customers to complete transactions online using their online banking environment, with funds debited from their bank account. Depending on their bank, customers confirm payments on giropay using a second factor of authentication or a PIN. giropay accounts for 10% of online checkouts in Germany. Check this [page](https://stripe.com/docs/payments/giropay) for more details.
+ """
+ google_pay: NotRequired["PaymentMethodConfigurationModifyParamsGooglePay"]
+ """
+ Google Pay allows customers to make payments in your app or website using any credit or debit card saved to their Google Account, including those from Google Play, YouTube, Chrome, or an Android device. Use the Google Pay API to request any credit or debit card stored in your customer's Google account. Check this [page](https://stripe.com/docs/google-pay) for more details.
+ """
+ grabpay: NotRequired["PaymentMethodConfigurationModifyParamsGrabpay"]
+ """
+ GrabPay is a payment method developed by [Grab](https://www.grab.com/sg/consumer/finance/pay/). GrabPay is a digital wallet - customers maintain a balance in their wallets that they pay out with. Check this [page](https://stripe.com/docs/payments/grabpay) for more details.
+ """
+ ideal: NotRequired["PaymentMethodConfigurationModifyParamsIdeal"]
+ """
+ iDEAL is a Netherlands-based payment method that allows customers to complete transactions online using their bank credentials. All major Dutch banks are members of Currence, the scheme that operates iDEAL, making it the most popular online payment method in the Netherlands with a share of online transactions close to 55%. Check this [page](https://stripe.com/docs/payments/ideal) for more details.
+ """
+ jcb: NotRequired["PaymentMethodConfigurationModifyParamsJcb"]
+ """
+ JCB is a credit card company based in Japan. JCB is currently available in Japan to businesses approved by JCB, and available to all businesses in Australia, Canada, Hong Kong, Japan, New Zealand, Singapore, Switzerland, United Kingdom, United States, and all countries in the European Economic Area except Iceland. Check this [page](https://support.stripe.com/questions/accepting-japan-credit-bureau-%28jcb%29-payments) for more details.
+ """
+ kakao_pay: NotRequired["PaymentMethodConfigurationModifyParamsKakaoPay"]
+ """
+ Kakao Pay is a popular local wallet available in South Korea.
+ """
+ klarna: NotRequired["PaymentMethodConfigurationModifyParamsKlarna"]
+ """
+ Klarna gives customers a range of [payment options](https://stripe.com/docs/payments/klarna#payment-options) during checkout. Available payment options vary depending on the customer's billing address and the transaction amount. These payment options make it convenient for customers to purchase items in all price ranges. Check this [page](https://stripe.com/docs/payments/klarna) for more details.
+ """
+ konbini: NotRequired["PaymentMethodConfigurationModifyParamsKonbini"]
+ """
+ Konbini allows customers in Japan to pay for bills and online purchases at convenience stores with cash. Check this [page](https://stripe.com/docs/payments/konbini) for more details.
+ """
+ kr_card: NotRequired["PaymentMethodConfigurationModifyParamsKrCard"]
+ """
+ Korean cards let users pay using locally issued cards from South Korea.
+ """
+ link: NotRequired["PaymentMethodConfigurationModifyParamsLink"]
+ """
+ [Link](https://stripe.com/docs/payments/link) is a payment method network. With Link, users save their payment details once, then reuse that information to pay with one click for any business on the network.
+ """
+ mobilepay: NotRequired["PaymentMethodConfigurationModifyParamsMobilepay"]
+ """
+ MobilePay is a [single-use](https://stripe.com/docs/payments/payment-methods#usage) card wallet payment method used in Denmark and Finland. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the MobilePay app. Check this [page](https://stripe.com/docs/payments/mobilepay) for more details.
+ """
+ multibanco: NotRequired["PaymentMethodConfigurationModifyParamsMultibanco"]
+ """
+ Stripe users in Europe and the United States can accept Multibanco payments from customers in Portugal using [Sources](https://stripe.com/docs/sources)—a single integration path for creating payments using any supported method.
+ """
+ name: NotRequired[str]
+ """
+ Configuration name.
+ """
+ naver_pay: NotRequired["PaymentMethodConfigurationModifyParamsNaverPay"]
+ """
+ Naver Pay is a popular local wallet available in South Korea.
+ """
+ nz_bank_account: NotRequired[
+ "PaymentMethodConfigurationModifyParamsNzBankAccount"
+ ]
+ """
+ Stripe users in New Zealand can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with a New Zeland bank account. Check this [page](https://stripe.com/docs/payments/nz-bank-account) for more details.
+ """
+ oxxo: NotRequired["PaymentMethodConfigurationModifyParamsOxxo"]
+ """
+ OXXO is a Mexican chain of convenience stores with thousands of locations across Latin America and represents nearly 20% of online transactions in Mexico. OXXO allows customers to pay bills and online purchases in-store with cash. Check this [page](https://stripe.com/docs/payments/oxxo) for more details.
+ """
+ p24: NotRequired["PaymentMethodConfigurationModifyParamsP24"]
+ """
+ Przelewy24 is a Poland-based payment method aggregator that allows customers to complete transactions online using bank transfers and other methods. Bank transfers account for 30% of online payments in Poland and Przelewy24 provides a way for customers to pay with over 165 banks. Check this [page](https://stripe.com/docs/payments/p24) for more details.
+ """
+ pay_by_bank: NotRequired["PaymentMethodConfigurationModifyParamsPayByBank"]
+ """
+ Pay by bank is a redirect payment method backed by bank transfers. A customer is redirected to their bank to authorize a bank transfer for a given amount. This removes a lot of the error risks inherent in waiting for the customer to initiate a transfer themselves, and is less expensive than card payments.
+ """
+ payco: NotRequired["PaymentMethodConfigurationModifyParamsPayco"]
+ """
+ PAYCO is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
+ """
+ paynow: NotRequired["PaymentMethodConfigurationModifyParamsPaynow"]
+ """
+ PayNow is a Singapore-based payment method that allows customers to make a payment using their preferred app from participating banks and participating non-bank financial institutions. Check this [page](https://stripe.com/docs/payments/paynow) for more details.
+ """
+ paypal: NotRequired["PaymentMethodConfigurationModifyParamsPaypal"]
+ """
+ PayPal, a digital wallet popular with customers in Europe, allows your customers worldwide to pay using their PayPal account. Check this [page](https://stripe.com/docs/payments/paypal) for more details.
+ """
+ pix: NotRequired["PaymentMethodConfigurationModifyParamsPix"]
+ """
+ Pix is a payment method popular in Brazil. When paying with Pix, customers authenticate and approve payments by scanning a QR code in their preferred banking app. Check this [page](https://docs.stripe.com/payments/pix) for more details.
+ """
+ promptpay: NotRequired["PaymentMethodConfigurationModifyParamsPromptpay"]
+ """
+ PromptPay is a Thailand-based payment method that allows customers to make a payment using their preferred app from participating banks. Check this [page](https://stripe.com/docs/payments/promptpay) for more details.
+ """
+ revolut_pay: NotRequired[
+ "PaymentMethodConfigurationModifyParamsRevolutPay"
+ ]
+ """
+ Revolut Pay, developed by Revolut, a global finance app, is a digital wallet payment method. Revolut Pay uses the customer's stored balance or cards to fund the payment, and offers the option for non-Revolut customers to save their details after their first purchase.
+ """
+ samsung_pay: NotRequired[
+ "PaymentMethodConfigurationModifyParamsSamsungPay"
+ ]
+ """
+ Samsung Pay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
+ """
+ satispay: NotRequired["PaymentMethodConfigurationModifyParamsSatispay"]
+ """
+ Satispay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method where customers are required to [authenticate](https://docs.stripe.com/payments/payment-methods#customer-actions) their payment. Customers pay by being redirected from your website or app, authorizing the payment with Satispay, then returning to your website or app. You get [immediate notification](https://docs.stripe.com/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
+ """
+ sepa_debit: NotRequired["PaymentMethodConfigurationModifyParamsSepaDebit"]
+ """
+ The [Single Euro Payments Area (SEPA)](https://en.wikipedia.org/wiki/Single_Euro_Payments_Area) is an initiative of the European Union to simplify payments within and across member countries. SEPA established and enforced banking standards to allow for the direct debiting of every EUR-denominated bank account within the SEPA region, check this [page](https://stripe.com/docs/payments/sepa-debit) for more details.
+ """
+ sofort: NotRequired["PaymentMethodConfigurationModifyParamsSofort"]
+ """
+ Stripe users in Europe and the United States can use the [Payment Intents API](https://stripe.com/docs/payments/payment-intents)—a single integration path for creating payments using any supported method—to accept [Sofort](https://www.sofort.com/) payments from customers. Check this [page](https://stripe.com/docs/payments/sofort) for more details.
+ """
+ swish: NotRequired["PaymentMethodConfigurationModifyParamsSwish"]
+ """
+ Swish is a [real-time](https://stripe.com/docs/payments/real-time) payment method popular in Sweden. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the Swish mobile app and the Swedish BankID mobile app. Check this [page](https://stripe.com/docs/payments/swish) for more details.
+ """
+ twint: NotRequired["PaymentMethodConfigurationModifyParamsTwint"]
+ """
+ Twint is a payment method popular in Switzerland. It allows customers to pay using their mobile phone. Check this [page](https://docs.stripe.com/payments/twint) for more details.
+ """
+ us_bank_account: NotRequired[
+ "PaymentMethodConfigurationModifyParamsUsBankAccount"
+ ]
+ """
+ Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check this [page](https://stripe.com/docs/payments/ach-direct-debit) for more details.
+ """
+ wechat_pay: NotRequired["PaymentMethodConfigurationModifyParamsWechatPay"]
+ """
+ WeChat, owned by Tencent, is China's leading mobile app with over 1 billion monthly active users. Chinese consumers can use WeChat Pay to pay for goods and services inside of businesses' apps and websites. WeChat Pay users buy most frequently in gaming, e-commerce, travel, online education, and food/nutrition. Check this [page](https://stripe.com/docs/payments/wechat-pay) for more details.
+ """
+ zip: NotRequired["PaymentMethodConfigurationModifyParamsZip"]
+ """
+ Zip gives your customers a way to split purchases over a series of payments. Check this [page](https://stripe.com/docs/payments/zip) for more details like country availability.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsAcssDebit(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsAcssDebitDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsAcssDebitDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsAffirm(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsAffirmDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsAffirmDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsAfterpayClearpay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsAfterpayClearpayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsAfterpayClearpayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsAlipay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsAlipayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsAlipayDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsAlma(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsAlmaDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsAlmaDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsAmazonPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsAmazonPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsAmazonPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsApplePay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsApplePayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsApplePayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsApplePayLater(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsApplePayLaterDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsApplePayLaterDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsAuBecsDebit(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsAuBecsDebitDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsAuBecsDebitDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsBacsDebit(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsBacsDebitDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsBacsDebitDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsBancontact(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsBancontactDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsBancontactDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsBillie(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsBillieDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsBillieDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsBlik(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsBlikDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsBlikDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsBoleto(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsBoletoDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsBoletoDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsCard(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsCardDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsCardDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsCartesBancaires(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsCartesBancairesDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsCartesBancairesDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsCashapp(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsCashappDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsCashappDisplayPreference(
+ TypedDict
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsCustomerBalance(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsCustomerBalanceDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsCustomerBalanceDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsEps(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsEpsDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsEpsDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsFpx(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsFpxDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsFpxDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsFrMealVoucherConecs(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsFrMealVoucherConecsDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsFrMealVoucherConecsDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsGiropay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsGiropayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsGiropayDisplayPreference(
+ TypedDict
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsGooglePay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsGooglePayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsGooglePayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsGrabpay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsGrabpayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsGrabpayDisplayPreference(
+ TypedDict
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsIdeal(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsIdealDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsIdealDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsJcb(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsJcbDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsJcbDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsKakaoPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsKakaoPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsKakaoPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsKlarna(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsKlarnaDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsKlarnaDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsKonbini(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsKonbiniDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsKonbiniDisplayPreference(
+ TypedDict
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsKrCard(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsKrCardDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsKrCardDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsLink(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsLinkDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsLinkDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsMobilepay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsMobilepayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsMobilepayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsMultibanco(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsMultibancoDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsMultibancoDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsNaverPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsNaverPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsNaverPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsNzBankAccount(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsNzBankAccountDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsNzBankAccountDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsOxxo(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsOxxoDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsOxxoDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsP24(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsP24DisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsP24DisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsPayByBank(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsPayByBankDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsPayByBankDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsPayco(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsPaycoDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsPaycoDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsPaynow(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsPaynowDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsPaynowDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsPaypal(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsPaypalDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsPaypalDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsPix(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsPixDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsPixDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsPromptpay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsPromptpayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsPromptpayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsRevolutPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsRevolutPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsRevolutPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsSamsungPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsSamsungPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsSamsungPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsSatispay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsSatispayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsSatispayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsSepaDebit(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsSepaDebitDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsSepaDebitDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsSofort(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsSofortDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsSofortDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsSwish(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsSwishDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsSwishDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsTwint(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsTwintDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsTwintDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsUsBankAccount(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsUsBankAccountDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsUsBankAccountDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsWechatPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsWechatPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsWechatPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsZip(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationModifyParamsZipDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationModifyParamsZipDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
diff --git a/stripe/params/_payment_method_configuration_retrieve_params.py b/stripe/params/_payment_method_configuration_retrieve_params.py
new file mode 100644
index 000000000..49c5f0256
--- /dev/null
+++ b/stripe/params/_payment_method_configuration_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentMethodConfigurationRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payment_method_configuration_update_params.py b/stripe/params/_payment_method_configuration_update_params.py
new file mode 100644
index 000000000..e96425887
--- /dev/null
+++ b/stripe/params/_payment_method_configuration_update_params.py
@@ -0,0 +1,1157 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PaymentMethodConfigurationUpdateParams(TypedDict):
+ acss_debit: NotRequired["PaymentMethodConfigurationUpdateParamsAcssDebit"]
+ """
+ Canadian pre-authorized debit payments, check this [page](https://stripe.com/docs/payments/acss-debit) for more details like country availability.
+ """
+ active: NotRequired[bool]
+ """
+ Whether the configuration can be used for new payments.
+ """
+ affirm: NotRequired["PaymentMethodConfigurationUpdateParamsAffirm"]
+ """
+ [Affirm](https://www.affirm.com/) gives your customers a way to split purchases over a series of payments. Depending on the purchase, they can pay with four interest-free payments (Split Pay) or pay over a longer term (Installments), which might include interest. Check this [page](https://stripe.com/docs/payments/affirm) for more details like country availability.
+ """
+ afterpay_clearpay: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsAfterpayClearpay"
+ ]
+ """
+ Afterpay gives your customers a way to pay for purchases in installments, check this [page](https://stripe.com/docs/payments/afterpay-clearpay) for more details like country availability. Afterpay is particularly popular among businesses selling fashion, beauty, and sports products.
+ """
+ alipay: NotRequired["PaymentMethodConfigurationUpdateParamsAlipay"]
+ """
+ Alipay is a digital wallet in China that has more than a billion active users worldwide. Alipay users can pay on the web or on a mobile device using login credentials or their Alipay app. Alipay has a low dispute rate and reduces fraud by authenticating payments using the customer's login credentials. Check this [page](https://stripe.com/docs/payments/alipay) for more details.
+ """
+ alma: NotRequired["PaymentMethodConfigurationUpdateParamsAlma"]
+ """
+ Alma is a Buy Now, Pay Later payment method that offers customers the ability to pay in 2, 3, or 4 installments.
+ """
+ amazon_pay: NotRequired["PaymentMethodConfigurationUpdateParamsAmazonPay"]
+ """
+ Amazon Pay is a wallet payment method that lets your customers check out the same way as on Amazon.
+ """
+ apple_pay: NotRequired["PaymentMethodConfigurationUpdateParamsApplePay"]
+ """
+ Stripe users can accept [Apple Pay](https://stripe.com/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. There are no additional fees to process Apple Pay payments, and the [pricing](https://stripe.com/pricing) is the same as other card transactions. Check this [page](https://stripe.com/docs/apple-pay) for more details.
+ """
+ apple_pay_later: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsApplePayLater"
+ ]
+ """
+ Apple Pay Later, a payment method for customers to buy now and pay later, gives your customers a way to split purchases into four installments across six weeks.
+ """
+ au_becs_debit: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsAuBecsDebit"
+ ]
+ """
+ Stripe users in Australia can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with an Australian bank account. Check this [page](https://stripe.com/docs/payments/au-becs-debit) for more details.
+ """
+ bacs_debit: NotRequired["PaymentMethodConfigurationUpdateParamsBacsDebit"]
+ """
+ Stripe users in the UK can accept Bacs Direct Debit payments from customers with a UK bank account, check this [page](https://stripe.com/docs/payments/payment-methods/bacs-debit) for more details.
+ """
+ bancontact: NotRequired["PaymentMethodConfigurationUpdateParamsBancontact"]
+ """
+ Bancontact is the most popular online payment method in Belgium, with over 15 million cards in circulation. [Customers](https://stripe.com/docs/api/customers) use a Bancontact card or mobile app linked to a Belgian bank account to make online payments that are secure, guaranteed, and confirmed immediately. Check this [page](https://stripe.com/docs/payments/bancontact) for more details.
+ """
+ billie: NotRequired["PaymentMethodConfigurationUpdateParamsBillie"]
+ """
+ Billie is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method that offers businesses Pay by Invoice where they offer payment terms ranging from 7-120 days. Customers are redirected from your website or app, authorize the payment with Billie, then return to your website or app. You get [immediate notification](https://docs.stripe.com/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
+ """
+ blik: NotRequired["PaymentMethodConfigurationUpdateParamsBlik"]
+ """
+ BLIK is a [single use](https://stripe.com/docs/payments/payment-methods#usage) payment method that requires customers to authenticate their payments. When customers want to pay online using BLIK, they request a six-digit code from their banking application and enter it into the payment collection form. Check this [page](https://stripe.com/docs/payments/blik) for more details.
+ """
+ boleto: NotRequired["PaymentMethodConfigurationUpdateParamsBoleto"]
+ """
+ Boleto is an official (regulated by the Central Bank of Brazil) payment method in Brazil. Check this [page](https://stripe.com/docs/payments/boleto) for more details.
+ """
+ card: NotRequired["PaymentMethodConfigurationUpdateParamsCard"]
+ """
+ Cards are a popular way for consumers and businesses to pay online or in person. Stripe supports global and local card networks.
+ """
+ cartes_bancaires: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsCartesBancaires"
+ ]
+ """
+ Cartes Bancaires is France's local card network. More than 95% of these cards are co-branded with either Visa or Mastercard, meaning you can process these cards over either Cartes Bancaires or the Visa or Mastercard networks. Check this [page](https://stripe.com/docs/payments/cartes-bancaires) for more details.
+ """
+ cashapp: NotRequired["PaymentMethodConfigurationUpdateParamsCashapp"]
+ """
+ Cash App is a popular consumer app in the US that allows customers to bank, invest, send, and receive money using their digital wallet. Check this [page](https://stripe.com/docs/payments/cash-app-pay) for more details.
+ """
+ customer_balance: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsCustomerBalance"
+ ]
+ """
+ Uses a customer's [cash balance](https://stripe.com/docs/payments/customer-balance) for the payment. The cash balance can be funded via a bank transfer. Check this [page](https://stripe.com/docs/payments/bank-transfers) for more details.
+ """
+ eps: NotRequired["PaymentMethodConfigurationUpdateParamsEps"]
+ """
+ EPS is an Austria-based payment method that allows customers to complete transactions online using their bank credentials. EPS is supported by all Austrian banks and is accepted by over 80% of Austrian online retailers. Check this [page](https://stripe.com/docs/payments/eps) for more details.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ fpx: NotRequired["PaymentMethodConfigurationUpdateParamsFpx"]
+ """
+ Financial Process Exchange (FPX) is a Malaysia-based payment method that allows customers to complete transactions online using their bank credentials. Bank Negara Malaysia (BNM), the Central Bank of Malaysia, and eleven other major Malaysian financial institutions are members of the PayNet Group, which owns and operates FPX. It is one of the most popular online payment methods in Malaysia, with nearly 90 million transactions in 2018 according to BNM. Check this [page](https://stripe.com/docs/payments/fpx) for more details.
+ """
+ fr_meal_voucher_conecs: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsFrMealVoucherConecs"
+ ]
+ """
+ Meal vouchers in France, or “titres-restaurant”, is a local benefits program commonly offered by employers for their employees to purchase prepared food and beverages on working days. Check this [page](https://stripe.com/docs/payments/benefits/fr-meal-vouchers) for more details.
+ """
+ giropay: NotRequired["PaymentMethodConfigurationUpdateParamsGiropay"]
+ """
+ giropay is a German payment method based on online banking, introduced in 2006. It allows customers to complete transactions online using their online banking environment, with funds debited from their bank account. Depending on their bank, customers confirm payments on giropay using a second factor of authentication or a PIN. giropay accounts for 10% of online checkouts in Germany. Check this [page](https://stripe.com/docs/payments/giropay) for more details.
+ """
+ google_pay: NotRequired["PaymentMethodConfigurationUpdateParamsGooglePay"]
+ """
+ Google Pay allows customers to make payments in your app or website using any credit or debit card saved to their Google Account, including those from Google Play, YouTube, Chrome, or an Android device. Use the Google Pay API to request any credit or debit card stored in your customer's Google account. Check this [page](https://stripe.com/docs/google-pay) for more details.
+ """
+ grabpay: NotRequired["PaymentMethodConfigurationUpdateParamsGrabpay"]
+ """
+ GrabPay is a payment method developed by [Grab](https://www.grab.com/sg/consumer/finance/pay/). GrabPay is a digital wallet - customers maintain a balance in their wallets that they pay out with. Check this [page](https://stripe.com/docs/payments/grabpay) for more details.
+ """
+ ideal: NotRequired["PaymentMethodConfigurationUpdateParamsIdeal"]
+ """
+ iDEAL is a Netherlands-based payment method that allows customers to complete transactions online using their bank credentials. All major Dutch banks are members of Currence, the scheme that operates iDEAL, making it the most popular online payment method in the Netherlands with a share of online transactions close to 55%. Check this [page](https://stripe.com/docs/payments/ideal) for more details.
+ """
+ jcb: NotRequired["PaymentMethodConfigurationUpdateParamsJcb"]
+ """
+ JCB is a credit card company based in Japan. JCB is currently available in Japan to businesses approved by JCB, and available to all businesses in Australia, Canada, Hong Kong, Japan, New Zealand, Singapore, Switzerland, United Kingdom, United States, and all countries in the European Economic Area except Iceland. Check this [page](https://support.stripe.com/questions/accepting-japan-credit-bureau-%28jcb%29-payments) for more details.
+ """
+ kakao_pay: NotRequired["PaymentMethodConfigurationUpdateParamsKakaoPay"]
+ """
+ Kakao Pay is a popular local wallet available in South Korea.
+ """
+ klarna: NotRequired["PaymentMethodConfigurationUpdateParamsKlarna"]
+ """
+ Klarna gives customers a range of [payment options](https://stripe.com/docs/payments/klarna#payment-options) during checkout. Available payment options vary depending on the customer's billing address and the transaction amount. These payment options make it convenient for customers to purchase items in all price ranges. Check this [page](https://stripe.com/docs/payments/klarna) for more details.
+ """
+ konbini: NotRequired["PaymentMethodConfigurationUpdateParamsKonbini"]
+ """
+ Konbini allows customers in Japan to pay for bills and online purchases at convenience stores with cash. Check this [page](https://stripe.com/docs/payments/konbini) for more details.
+ """
+ kr_card: NotRequired["PaymentMethodConfigurationUpdateParamsKrCard"]
+ """
+ Korean cards let users pay using locally issued cards from South Korea.
+ """
+ link: NotRequired["PaymentMethodConfigurationUpdateParamsLink"]
+ """
+ [Link](https://stripe.com/docs/payments/link) is a payment method network. With Link, users save their payment details once, then reuse that information to pay with one click for any business on the network.
+ """
+ mobilepay: NotRequired["PaymentMethodConfigurationUpdateParamsMobilepay"]
+ """
+ MobilePay is a [single-use](https://stripe.com/docs/payments/payment-methods#usage) card wallet payment method used in Denmark and Finland. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the MobilePay app. Check this [page](https://stripe.com/docs/payments/mobilepay) for more details.
+ """
+ multibanco: NotRequired["PaymentMethodConfigurationUpdateParamsMultibanco"]
+ """
+ Stripe users in Europe and the United States can accept Multibanco payments from customers in Portugal using [Sources](https://stripe.com/docs/sources)—a single integration path for creating payments using any supported method.
+ """
+ name: NotRequired[str]
+ """
+ Configuration name.
+ """
+ naver_pay: NotRequired["PaymentMethodConfigurationUpdateParamsNaverPay"]
+ """
+ Naver Pay is a popular local wallet available in South Korea.
+ """
+ nz_bank_account: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsNzBankAccount"
+ ]
+ """
+ Stripe users in New Zealand can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with a New Zeland bank account. Check this [page](https://stripe.com/docs/payments/nz-bank-account) for more details.
+ """
+ oxxo: NotRequired["PaymentMethodConfigurationUpdateParamsOxxo"]
+ """
+ OXXO is a Mexican chain of convenience stores with thousands of locations across Latin America and represents nearly 20% of online transactions in Mexico. OXXO allows customers to pay bills and online purchases in-store with cash. Check this [page](https://stripe.com/docs/payments/oxxo) for more details.
+ """
+ p24: NotRequired["PaymentMethodConfigurationUpdateParamsP24"]
+ """
+ Przelewy24 is a Poland-based payment method aggregator that allows customers to complete transactions online using bank transfers and other methods. Bank transfers account for 30% of online payments in Poland and Przelewy24 provides a way for customers to pay with over 165 banks. Check this [page](https://stripe.com/docs/payments/p24) for more details.
+ """
+ pay_by_bank: NotRequired["PaymentMethodConfigurationUpdateParamsPayByBank"]
+ """
+ Pay by bank is a redirect payment method backed by bank transfers. A customer is redirected to their bank to authorize a bank transfer for a given amount. This removes a lot of the error risks inherent in waiting for the customer to initiate a transfer themselves, and is less expensive than card payments.
+ """
+ payco: NotRequired["PaymentMethodConfigurationUpdateParamsPayco"]
+ """
+ PAYCO is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
+ """
+ paynow: NotRequired["PaymentMethodConfigurationUpdateParamsPaynow"]
+ """
+ PayNow is a Singapore-based payment method that allows customers to make a payment using their preferred app from participating banks and participating non-bank financial institutions. Check this [page](https://stripe.com/docs/payments/paynow) for more details.
+ """
+ paypal: NotRequired["PaymentMethodConfigurationUpdateParamsPaypal"]
+ """
+ PayPal, a digital wallet popular with customers in Europe, allows your customers worldwide to pay using their PayPal account. Check this [page](https://stripe.com/docs/payments/paypal) for more details.
+ """
+ pix: NotRequired["PaymentMethodConfigurationUpdateParamsPix"]
+ """
+ Pix is a payment method popular in Brazil. When paying with Pix, customers authenticate and approve payments by scanning a QR code in their preferred banking app. Check this [page](https://docs.stripe.com/payments/pix) for more details.
+ """
+ promptpay: NotRequired["PaymentMethodConfigurationUpdateParamsPromptpay"]
+ """
+ PromptPay is a Thailand-based payment method that allows customers to make a payment using their preferred app from participating banks. Check this [page](https://stripe.com/docs/payments/promptpay) for more details.
+ """
+ revolut_pay: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsRevolutPay"
+ ]
+ """
+ Revolut Pay, developed by Revolut, a global finance app, is a digital wallet payment method. Revolut Pay uses the customer's stored balance or cards to fund the payment, and offers the option for non-Revolut customers to save their details after their first purchase.
+ """
+ samsung_pay: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsSamsungPay"
+ ]
+ """
+ Samsung Pay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
+ """
+ satispay: NotRequired["PaymentMethodConfigurationUpdateParamsSatispay"]
+ """
+ Satispay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method where customers are required to [authenticate](https://docs.stripe.com/payments/payment-methods#customer-actions) their payment. Customers pay by being redirected from your website or app, authorizing the payment with Satispay, then returning to your website or app. You get [immediate notification](https://docs.stripe.com/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
+ """
+ sepa_debit: NotRequired["PaymentMethodConfigurationUpdateParamsSepaDebit"]
+ """
+ The [Single Euro Payments Area (SEPA)](https://en.wikipedia.org/wiki/Single_Euro_Payments_Area) is an initiative of the European Union to simplify payments within and across member countries. SEPA established and enforced banking standards to allow for the direct debiting of every EUR-denominated bank account within the SEPA region, check this [page](https://stripe.com/docs/payments/sepa-debit) for more details.
+ """
+ sofort: NotRequired["PaymentMethodConfigurationUpdateParamsSofort"]
+ """
+ Stripe users in Europe and the United States can use the [Payment Intents API](https://stripe.com/docs/payments/payment-intents)—a single integration path for creating payments using any supported method—to accept [Sofort](https://www.sofort.com/) payments from customers. Check this [page](https://stripe.com/docs/payments/sofort) for more details.
+ """
+ swish: NotRequired["PaymentMethodConfigurationUpdateParamsSwish"]
+ """
+ Swish is a [real-time](https://stripe.com/docs/payments/real-time) payment method popular in Sweden. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the Swish mobile app and the Swedish BankID mobile app. Check this [page](https://stripe.com/docs/payments/swish) for more details.
+ """
+ twint: NotRequired["PaymentMethodConfigurationUpdateParamsTwint"]
+ """
+ Twint is a payment method popular in Switzerland. It allows customers to pay using their mobile phone. Check this [page](https://docs.stripe.com/payments/twint) for more details.
+ """
+ us_bank_account: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsUsBankAccount"
+ ]
+ """
+ Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check this [page](https://stripe.com/docs/payments/ach-direct-debit) for more details.
+ """
+ wechat_pay: NotRequired["PaymentMethodConfigurationUpdateParamsWechatPay"]
+ """
+ WeChat, owned by Tencent, is China's leading mobile app with over 1 billion monthly active users. Chinese consumers can use WeChat Pay to pay for goods and services inside of businesses' apps and websites. WeChat Pay users buy most frequently in gaming, e-commerce, travel, online education, and food/nutrition. Check this [page](https://stripe.com/docs/payments/wechat-pay) for more details.
+ """
+ zip: NotRequired["PaymentMethodConfigurationUpdateParamsZip"]
+ """
+ Zip gives your customers a way to split purchases over a series of payments. Check this [page](https://stripe.com/docs/payments/zip) for more details like country availability.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsAcssDebit(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsAcssDebitDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsAcssDebitDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsAffirm(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsAffirmDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsAffirmDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsAfterpayClearpay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsAfterpayClearpayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsAfterpayClearpayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsAlipay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsAlipayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsAlipayDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsAlma(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsAlmaDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsAlmaDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsAmazonPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsAmazonPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsAmazonPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsApplePay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsApplePayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsApplePayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsApplePayLater(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsApplePayLaterDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsApplePayLaterDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsAuBecsDebit(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsAuBecsDebitDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsAuBecsDebitDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsBacsDebit(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsBacsDebitDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsBacsDebitDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsBancontact(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsBancontactDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsBancontactDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsBillie(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsBillieDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsBillieDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsBlik(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsBlikDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsBlikDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsBoleto(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsBoletoDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsBoletoDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsCard(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsCardDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsCardDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsCartesBancaires(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsCartesBancairesDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsCartesBancairesDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsCashapp(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsCashappDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsCashappDisplayPreference(
+ TypedDict
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsCustomerBalance(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsCustomerBalanceDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsCustomerBalanceDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsEps(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsEpsDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsEpsDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsFpx(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsFpxDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsFpxDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsFrMealVoucherConecs(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsFrMealVoucherConecsDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsFrMealVoucherConecsDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsGiropay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsGiropayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsGiropayDisplayPreference(
+ TypedDict
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsGooglePay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsGooglePayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsGooglePayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsGrabpay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsGrabpayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsGrabpayDisplayPreference(
+ TypedDict
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsIdeal(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsIdealDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsIdealDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsJcb(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsJcbDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsJcbDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsKakaoPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsKakaoPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsKakaoPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsKlarna(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsKlarnaDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsKlarnaDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsKonbini(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsKonbiniDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsKonbiniDisplayPreference(
+ TypedDict
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsKrCard(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsKrCardDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsKrCardDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsLink(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsLinkDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsLinkDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsMobilepay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsMobilepayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsMobilepayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsMultibanco(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsMultibancoDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsMultibancoDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsNaverPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsNaverPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsNaverPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsNzBankAccount(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsNzBankAccountDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsNzBankAccountDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsOxxo(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsOxxoDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsOxxoDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsP24(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsP24DisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsP24DisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsPayByBank(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsPayByBankDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsPayByBankDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsPayco(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsPaycoDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsPaycoDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsPaynow(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsPaynowDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsPaynowDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsPaypal(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsPaypalDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsPaypalDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsPix(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsPixDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsPixDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsPromptpay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsPromptpayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsPromptpayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsRevolutPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsRevolutPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsRevolutPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsSamsungPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsSamsungPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsSamsungPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsSatispay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsSatispayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsSatispayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsSepaDebit(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsSepaDebitDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsSepaDebitDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsSofort(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsSofortDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsSofortDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsSwish(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsSwishDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsSwishDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsTwint(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsTwintDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsTwintDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsUsBankAccount(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsUsBankAccountDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsUsBankAccountDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsWechatPay(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsWechatPayDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsWechatPayDisplayPreference(
+ TypedDict,
+):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsZip(TypedDict):
+ display_preference: NotRequired[
+ "PaymentMethodConfigurationUpdateParamsZipDisplayPreference"
+ ]
+ """
+ Whether or not the payment method should be displayed.
+ """
+
+
+class PaymentMethodConfigurationUpdateParamsZipDisplayPreference(TypedDict):
+ preference: NotRequired[Literal["none", "off", "on"]]
+ """
+ The account's preference for whether or not to display this payment method.
+ """
diff --git a/stripe/params/_payment_method_create_params.py b/stripe/params/_payment_method_create_params.py
new file mode 100644
index 000000000..84a22d872
--- /dev/null
+++ b/stripe/params/_payment_method_create_params.py
@@ -0,0 +1,794 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PaymentMethodCreateParams(RequestOptions):
+ acss_debit: NotRequired["PaymentMethodCreateParamsAcssDebit"]
+ """
+ If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
+ """
+ affirm: NotRequired["PaymentMethodCreateParamsAffirm"]
+ """
+ If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
+ """
+ afterpay_clearpay: NotRequired["PaymentMethodCreateParamsAfterpayClearpay"]
+ """
+ If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
+ """
+ alipay: NotRequired["PaymentMethodCreateParamsAlipay"]
+ """
+ If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
+ """
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
+ """
+ alma: NotRequired["PaymentMethodCreateParamsAlma"]
+ """
+ If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
+ """
+ amazon_pay: NotRequired["PaymentMethodCreateParamsAmazonPay"]
+ """
+ If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
+ """
+ au_becs_debit: NotRequired["PaymentMethodCreateParamsAuBecsDebit"]
+ """
+ If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
+ """
+ bacs_debit: NotRequired["PaymentMethodCreateParamsBacsDebit"]
+ """
+ If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
+ """
+ bancontact: NotRequired["PaymentMethodCreateParamsBancontact"]
+ """
+ If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
+ """
+ billie: NotRequired["PaymentMethodCreateParamsBillie"]
+ """
+ If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
+ """
+ billing_details: NotRequired["PaymentMethodCreateParamsBillingDetails"]
+ """
+ Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+ """
+ blik: NotRequired["PaymentMethodCreateParamsBlik"]
+ """
+ If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
+ """
+ boleto: NotRequired["PaymentMethodCreateParamsBoleto"]
+ """
+ If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
+ """
+ card: NotRequired["PaymentMethodCreateParamsCard"]
+ """
+ If this is a `card` PaymentMethod, this hash contains the user's card details. For backwards compatibility, you can alternatively provide a Stripe token (e.g., for Apple Pay, Amex Express Checkout, or legacy Checkout) into the card hash with format `card: {token: "tok_visa"}`. When providing a card number, you must meet the requirements for [PCI compliance](https://stripe.com/docs/security#validating-pci-compliance). We strongly recommend using Stripe.js instead of interacting with this API directly.
+ """
+ cashapp: NotRequired["PaymentMethodCreateParamsCashapp"]
+ """
+ If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
+ """
+ crypto: NotRequired["PaymentMethodCreateParamsCrypto"]
+ """
+ If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
+ """
+ customer: NotRequired[str]
+ """
+ The `Customer` to whom the original PaymentMethod is attached.
+ """
+ customer_balance: NotRequired["PaymentMethodCreateParamsCustomerBalance"]
+ """
+ If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
+ """
+ eps: NotRequired["PaymentMethodCreateParamsEps"]
+ """
+ If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ fpx: NotRequired["PaymentMethodCreateParamsFpx"]
+ """
+ If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
+ """
+ giropay: NotRequired["PaymentMethodCreateParamsGiropay"]
+ """
+ If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
+ """
+ grabpay: NotRequired["PaymentMethodCreateParamsGrabpay"]
+ """
+ If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
+ """
+ ideal: NotRequired["PaymentMethodCreateParamsIdeal"]
+ """
+ If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
+ """
+ interac_present: NotRequired["PaymentMethodCreateParamsInteracPresent"]
+ """
+ If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
+ """
+ kakao_pay: NotRequired["PaymentMethodCreateParamsKakaoPay"]
+ """
+ If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
+ """
+ klarna: NotRequired["PaymentMethodCreateParamsKlarna"]
+ """
+ If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
+ """
+ konbini: NotRequired["PaymentMethodCreateParamsKonbini"]
+ """
+ If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
+ """
+ kr_card: NotRequired["PaymentMethodCreateParamsKrCard"]
+ """
+ If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
+ """
+ link: NotRequired["PaymentMethodCreateParamsLink"]
+ """
+ If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
+ """
+ mb_way: NotRequired["PaymentMethodCreateParamsMbWay"]
+ """
+ If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ mobilepay: NotRequired["PaymentMethodCreateParamsMobilepay"]
+ """
+ If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
+ """
+ multibanco: NotRequired["PaymentMethodCreateParamsMultibanco"]
+ """
+ If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
+ """
+ naver_pay: NotRequired["PaymentMethodCreateParamsNaverPay"]
+ """
+ If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
+ """
+ nz_bank_account: NotRequired["PaymentMethodCreateParamsNzBankAccount"]
+ """
+ If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
+ """
+ oxxo: NotRequired["PaymentMethodCreateParamsOxxo"]
+ """
+ If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
+ """
+ p24: NotRequired["PaymentMethodCreateParamsP24"]
+ """
+ If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
+ """
+ pay_by_bank: NotRequired["PaymentMethodCreateParamsPayByBank"]
+ """
+ If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
+ """
+ payco: NotRequired["PaymentMethodCreateParamsPayco"]
+ """
+ If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
+ """
+ payment_method: NotRequired[str]
+ """
+ The PaymentMethod to share.
+ """
+ paynow: NotRequired["PaymentMethodCreateParamsPaynow"]
+ """
+ If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
+ """
+ paypal: NotRequired["PaymentMethodCreateParamsPaypal"]
+ """
+ If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
+ """
+ pix: NotRequired["PaymentMethodCreateParamsPix"]
+ """
+ If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
+ """
+ promptpay: NotRequired["PaymentMethodCreateParamsPromptpay"]
+ """
+ If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
+ """
+ radar_options: NotRequired["PaymentMethodCreateParamsRadarOptions"]
+ """
+ Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
+ """
+ revolut_pay: NotRequired["PaymentMethodCreateParamsRevolutPay"]
+ """
+ If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
+ """
+ samsung_pay: NotRequired["PaymentMethodCreateParamsSamsungPay"]
+ """
+ If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
+ """
+ satispay: NotRequired["PaymentMethodCreateParamsSatispay"]
+ """
+ If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
+ """
+ sepa_debit: NotRequired["PaymentMethodCreateParamsSepaDebit"]
+ """
+ If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
+ """
+ sofort: NotRequired["PaymentMethodCreateParamsSofort"]
+ """
+ If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
+ """
+ swish: NotRequired["PaymentMethodCreateParamsSwish"]
+ """
+ If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
+ """
+ twint: NotRequired["PaymentMethodCreateParamsTwint"]
+ """
+ If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
+ """
+ type: NotRequired[
+ Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "card",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "link",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ ]
+ """
+ The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
+ """
+ us_bank_account: NotRequired["PaymentMethodCreateParamsUsBankAccount"]
+ """
+ If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
+ """
+ wechat_pay: NotRequired["PaymentMethodCreateParamsWechatPay"]
+ """
+ If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
+ """
+ zip: NotRequired["PaymentMethodCreateParamsZip"]
+ """
+ If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
+ """
+
+
+class PaymentMethodCreateParamsAcssDebit(TypedDict):
+ account_number: str
+ """
+ Customer's bank account number.
+ """
+ institution_number: str
+ """
+ Institution number of the customer's bank.
+ """
+ transit_number: str
+ """
+ Transit number of the customer's bank.
+ """
+
+
+class PaymentMethodCreateParamsAffirm(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsAfterpayClearpay(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsAlipay(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsAlma(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsAmazonPay(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsAuBecsDebit(TypedDict):
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bsb_number: str
+ """
+ Bank-State-Branch number of the bank account.
+ """
+
+
+class PaymentMethodCreateParamsBacsDebit(TypedDict):
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account that the funds will be debited from.
+ """
+ sort_code: NotRequired[str]
+ """
+ Sort code of the bank account. (e.g., `10-20-30`)
+ """
+
+
+class PaymentMethodCreateParamsBancontact(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsBillie(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsBillingDetails(TypedDict):
+ address: NotRequired[
+ "Literal['']|PaymentMethodCreateParamsBillingDetailsAddress"
+ ]
+ """
+ Billing address.
+ """
+ email: NotRequired["Literal['']|str"]
+ """
+ Email address.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Full name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Billing phone number (including extension).
+ """
+ tax_id: NotRequired[str]
+ """
+ Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
+ """
+
+
+class PaymentMethodCreateParamsBillingDetailsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class PaymentMethodCreateParamsBlik(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsBoleto(TypedDict):
+ tax_id: str
+ """
+ The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
+ """
+
+
+class PaymentMethodCreateParamsCard(TypedDict):
+ cvc: NotRequired[str]
+ """
+ The card's CVC. It is highly recommended to always include this value.
+ """
+ exp_month: NotRequired[int]
+ """
+ Two-digit number representing the card's expiration month.
+ """
+ exp_year: NotRequired[int]
+ """
+ Four-digit number representing the card's expiration year.
+ """
+ networks: NotRequired["PaymentMethodCreateParamsCardNetworks"]
+ """
+ Contains information about card networks used to process the payment.
+ """
+ number: NotRequired[str]
+ """
+ The card number, as a string without any separators.
+ """
+ token: NotRequired[str]
+ """
+ For backwards compatibility, you can alternatively provide a Stripe token (e.g., for Apple Pay, Amex Express Checkout, or legacy Checkout) into the card hash with format card: {token: "tok_visa"}.
+ """
+
+
+class PaymentMethodCreateParamsCardNetworks(TypedDict):
+ preferred: NotRequired[Literal["cartes_bancaires", "mastercard", "visa"]]
+ """
+ The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
+ """
+
+
+class PaymentMethodCreateParamsCashapp(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsCrypto(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsCustomerBalance(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsEps(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "arzte_und_apotheker_bank",
+ "austrian_anadi_bank_ag",
+ "bank_austria",
+ "bankhaus_carl_spangler",
+ "bankhaus_schelhammer_und_schattera_ag",
+ "bawag_psk_ag",
+ "bks_bank_ag",
+ "brull_kallmus_bank_ag",
+ "btv_vier_lander_bank",
+ "capital_bank_grawe_gruppe_ag",
+ "deutsche_bank_ag",
+ "dolomitenbank",
+ "easybank_ag",
+ "erste_bank_und_sparkassen",
+ "hypo_alpeadriabank_international_ag",
+ "hypo_bank_burgenland_aktiengesellschaft",
+ "hypo_noe_lb_fur_niederosterreich_u_wien",
+ "hypo_oberosterreich_salzburg_steiermark",
+ "hypo_tirol_bank_ag",
+ "hypo_vorarlberg_bank_ag",
+ "marchfelder_bank",
+ "oberbank_ag",
+ "raiffeisen_bankengruppe_osterreich",
+ "schoellerbank_ag",
+ "sparda_bank_wien",
+ "volksbank_gruppe",
+ "volkskreditbank_ag",
+ "vr_bank_braunau",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class PaymentMethodCreateParamsFpx(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type for FPX transaction
+ """
+ bank: Literal[
+ "affin_bank",
+ "agrobank",
+ "alliance_bank",
+ "ambank",
+ "bank_islam",
+ "bank_muamalat",
+ "bank_of_china",
+ "bank_rakyat",
+ "bsn",
+ "cimb",
+ "deutsche_bank",
+ "hong_leong_bank",
+ "hsbc",
+ "kfh",
+ "maybank2e",
+ "maybank2u",
+ "ocbc",
+ "pb_enterprise",
+ "public_bank",
+ "rhb",
+ "standard_chartered",
+ "uob",
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class PaymentMethodCreateParamsGiropay(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsGrabpay(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsIdeal(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "abn_amro",
+ "asn_bank",
+ "bunq",
+ "buut",
+ "handelsbanken",
+ "ing",
+ "knab",
+ "moneyou",
+ "n26",
+ "nn",
+ "rabobank",
+ "regiobank",
+ "revolut",
+ "sns_bank",
+ "triodos_bank",
+ "van_lanschot",
+ "yoursafe",
+ ]
+ ]
+ """
+ The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
+ """
+
+
+class PaymentMethodCreateParamsInteracPresent(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsKakaoPay(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsKlarna(TypedDict):
+ dob: NotRequired["PaymentMethodCreateParamsKlarnaDob"]
+ """
+ Customer's date of birth
+ """
+
+
+class PaymentMethodCreateParamsKlarnaDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class PaymentMethodCreateParamsKonbini(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsKrCard(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsLink(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsMbWay(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsMobilepay(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsMultibanco(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsNaverPay(TypedDict):
+ funding: NotRequired[Literal["card", "points"]]
+ """
+ Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
+ """
+
+
+class PaymentMethodCreateParamsNzBankAccount(TypedDict):
+ account_holder_name: NotRequired[str]
+ """
+ The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
+ """
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bank_code: str
+ """
+ The numeric code for the bank account's bank.
+ """
+ branch_code: str
+ """
+ The numeric code for the bank account's bank branch.
+ """
+ reference: NotRequired[str]
+ suffix: str
+ """
+ The suffix of the bank account number.
+ """
+
+
+class PaymentMethodCreateParamsOxxo(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsP24(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "alior_bank",
+ "bank_millennium",
+ "bank_nowy_bfg_sa",
+ "bank_pekao_sa",
+ "banki_spbdzielcze",
+ "blik",
+ "bnp_paribas",
+ "boz",
+ "citi_handlowy",
+ "credit_agricole",
+ "envelobank",
+ "etransfer_pocztowy24",
+ "getin_bank",
+ "ideabank",
+ "ing",
+ "inteligo",
+ "mbank_mtransfer",
+ "nest_przelew",
+ "noble_pay",
+ "pbac_z_ipko",
+ "plus_bank",
+ "santander_przelew24",
+ "tmobile_usbugi_bankowe",
+ "toyota_bank",
+ "velobank",
+ "volkswagen_bank",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class PaymentMethodCreateParamsPayByBank(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsPayco(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsPaynow(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsPaypal(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsPix(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsPromptpay(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsRadarOptions(TypedDict):
+ session: NotRequired[str]
+ """
+ A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
+ """
+
+
+class PaymentMethodCreateParamsRevolutPay(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsSamsungPay(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsSatispay(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsSepaDebit(TypedDict):
+ iban: str
+ """
+ IBAN of the bank account.
+ """
+
+
+class PaymentMethodCreateParamsSofort(TypedDict):
+ country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
+ """
+ Two-letter ISO code representing the country the bank account is located in.
+ """
+
+
+class PaymentMethodCreateParamsSwish(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsTwint(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsUsBankAccount(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type: individual or company.
+ """
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account.
+ """
+ account_type: NotRequired[Literal["checking", "savings"]]
+ """
+ Account type: checkings or savings. Defaults to checking if omitted.
+ """
+ financial_connections_account: NotRequired[str]
+ """
+ The ID of a Financial Connections Account to use as a payment method.
+ """
+ routing_number: NotRequired[str]
+ """
+ Routing number of the bank account.
+ """
+
+
+class PaymentMethodCreateParamsWechatPay(TypedDict):
+ pass
+
+
+class PaymentMethodCreateParamsZip(TypedDict):
+ pass
diff --git a/stripe/params/_payment_method_detach_params.py b/stripe/params/_payment_method_detach_params.py
new file mode 100644
index 000000000..5bb35345f
--- /dev/null
+++ b/stripe/params/_payment_method_detach_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentMethodDetachParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payment_method_domain_create_params.py b/stripe/params/_payment_method_domain_create_params.py
new file mode 100644
index 000000000..5d5ac32fe
--- /dev/null
+++ b/stripe/params/_payment_method_domain_create_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentMethodDomainCreateParams(RequestOptions):
+ domain_name: str
+ """
+ The domain name that this payment method domain object represents.
+ """
+ enabled: NotRequired[bool]
+ """
+ Whether this payment method domain is enabled. If the domain is not enabled, payment methods that require a payment method domain will not appear in Elements or Embedded Checkout.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payment_method_domain_list_params.py b/stripe/params/_payment_method_domain_list_params.py
new file mode 100644
index 000000000..bd52dd55f
--- /dev/null
+++ b/stripe/params/_payment_method_domain_list_params.py
@@ -0,0 +1,32 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentMethodDomainListParams(RequestOptions):
+ domain_name: NotRequired[str]
+ """
+ The domain name that this payment method domain object represents.
+ """
+ enabled: NotRequired[bool]
+ """
+ Whether this payment method domain is enabled. If the domain is not enabled, payment methods will not appear in Elements or Embedded Checkout
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_payment_method_domain_modify_params.py b/stripe/params/_payment_method_domain_modify_params.py
new file mode 100644
index 000000000..a0079efbc
--- /dev/null
+++ b/stripe/params/_payment_method_domain_modify_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentMethodDomainModifyParams(RequestOptions):
+ enabled: NotRequired[bool]
+ """
+ Whether this payment method domain is enabled. If the domain is not enabled, payment methods that require a payment method domain will not appear in Elements or Embedded Checkout.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payment_method_domain_retrieve_params.py b/stripe/params/_payment_method_domain_retrieve_params.py
new file mode 100644
index 000000000..43fca1500
--- /dev/null
+++ b/stripe/params/_payment_method_domain_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentMethodDomainRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payment_method_domain_update_params.py b/stripe/params/_payment_method_domain_update_params.py
new file mode 100644
index 000000000..1a4135bf5
--- /dev/null
+++ b/stripe/params/_payment_method_domain_update_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class PaymentMethodDomainUpdateParams(TypedDict):
+ enabled: NotRequired[bool]
+ """
+ Whether this payment method domain is enabled. If the domain is not enabled, payment methods that require a payment method domain will not appear in Elements or Embedded Checkout.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payment_method_domain_validate_params.py b/stripe/params/_payment_method_domain_validate_params.py
new file mode 100644
index 000000000..ca4d58a75
--- /dev/null
+++ b/stripe/params/_payment_method_domain_validate_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentMethodDomainValidateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payment_method_list_params.py b/stripe/params/_payment_method_list_params.py
new file mode 100644
index 000000000..3cd50fca4
--- /dev/null
+++ b/stripe/params/_payment_method_list_params.py
@@ -0,0 +1,84 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class PaymentMethodListParams(RequestOptions):
+ customer: NotRequired[str]
+ """
+ The ID of the customer whose PaymentMethods will be retrieved.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ type: NotRequired[
+ Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "card",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "link",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ ]
+ """
+ An optional filter on the list, based on the object `type` field. Without the filter, the list includes all current and future payment method types. If your integration expects only one type of payment method in the response, make sure to provide a type value in the request.
+ """
diff --git a/stripe/params/_payment_method_modify_params.py b/stripe/params/_payment_method_modify_params.py
new file mode 100644
index 000000000..b1132da37
--- /dev/null
+++ b/stripe/params/_payment_method_modify_params.py
@@ -0,0 +1,119 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PaymentMethodModifyParams(RequestOptions):
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
+ """
+ billing_details: NotRequired["PaymentMethodModifyParamsBillingDetails"]
+ """
+ Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+ """
+ card: NotRequired["PaymentMethodModifyParamsCard"]
+ """
+ If this is a `card` PaymentMethod, this hash contains the user's card details.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ us_bank_account: NotRequired["PaymentMethodModifyParamsUsBankAccount"]
+ """
+ If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
+ """
+
+
+class PaymentMethodModifyParamsBillingDetails(TypedDict):
+ address: NotRequired[
+ "Literal['']|PaymentMethodModifyParamsBillingDetailsAddress"
+ ]
+ """
+ Billing address.
+ """
+ email: NotRequired["Literal['']|str"]
+ """
+ Email address.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Full name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Billing phone number (including extension).
+ """
+ tax_id: NotRequired[str]
+ """
+ Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
+ """
+
+
+class PaymentMethodModifyParamsBillingDetailsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class PaymentMethodModifyParamsCard(TypedDict):
+ exp_month: NotRequired[int]
+ """
+ Two-digit number representing the card's expiration month.
+ """
+ exp_year: NotRequired[int]
+ """
+ Four-digit number representing the card's expiration year.
+ """
+ networks: NotRequired["PaymentMethodModifyParamsCardNetworks"]
+ """
+ Contains information about card networks used to process the payment.
+ """
+
+
+class PaymentMethodModifyParamsCardNetworks(TypedDict):
+ preferred: NotRequired[
+ "Literal['']|Literal['cartes_bancaires', 'mastercard', 'visa']"
+ ]
+ """
+ The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
+ """
+
+
+class PaymentMethodModifyParamsUsBankAccount(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Bank account holder type.
+ """
+ account_type: NotRequired[Literal["checking", "savings"]]
+ """
+ Bank account type.
+ """
diff --git a/stripe/params/_payment_method_retrieve_params.py b/stripe/params/_payment_method_retrieve_params.py
new file mode 100644
index 000000000..39b976dbb
--- /dev/null
+++ b/stripe/params/_payment_method_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PaymentMethodRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payment_method_update_params.py b/stripe/params/_payment_method_update_params.py
new file mode 100644
index 000000000..1c73b4027
--- /dev/null
+++ b/stripe/params/_payment_method_update_params.py
@@ -0,0 +1,118 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PaymentMethodUpdateParams(TypedDict):
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
+ """
+ billing_details: NotRequired["PaymentMethodUpdateParamsBillingDetails"]
+ """
+ Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+ """
+ card: NotRequired["PaymentMethodUpdateParamsCard"]
+ """
+ If this is a `card` PaymentMethod, this hash contains the user's card details.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ us_bank_account: NotRequired["PaymentMethodUpdateParamsUsBankAccount"]
+ """
+ If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
+ """
+
+
+class PaymentMethodUpdateParamsBillingDetails(TypedDict):
+ address: NotRequired[
+ "Literal['']|PaymentMethodUpdateParamsBillingDetailsAddress"
+ ]
+ """
+ Billing address.
+ """
+ email: NotRequired["Literal['']|str"]
+ """
+ Email address.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Full name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Billing phone number (including extension).
+ """
+ tax_id: NotRequired[str]
+ """
+ Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
+ """
+
+
+class PaymentMethodUpdateParamsBillingDetailsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class PaymentMethodUpdateParamsCard(TypedDict):
+ exp_month: NotRequired[int]
+ """
+ Two-digit number representing the card's expiration month.
+ """
+ exp_year: NotRequired[int]
+ """
+ Four-digit number representing the card's expiration year.
+ """
+ networks: NotRequired["PaymentMethodUpdateParamsCardNetworks"]
+ """
+ Contains information about card networks used to process the payment.
+ """
+
+
+class PaymentMethodUpdateParamsCardNetworks(TypedDict):
+ preferred: NotRequired[
+ "Literal['']|Literal['cartes_bancaires', 'mastercard', 'visa']"
+ ]
+ """
+ The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
+ """
+
+
+class PaymentMethodUpdateParamsUsBankAccount(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Bank account holder type.
+ """
+ account_type: NotRequired[Literal["checking", "savings"]]
+ """
+ Bank account type.
+ """
diff --git a/stripe/params/_payout_cancel_params.py b/stripe/params/_payout_cancel_params.py
new file mode 100644
index 000000000..937a5b099
--- /dev/null
+++ b/stripe/params/_payout_cancel_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PayoutCancelParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payout_create_params.py b/stripe/params/_payout_create_params.py
new file mode 100644
index 000000000..9df088fda
--- /dev/null
+++ b/stripe/params/_payout_create_params.py
@@ -0,0 +1,48 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class PayoutCreateParams(RequestOptions):
+ amount: int
+ """
+ A positive integer in cents representing how much to payout.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ destination: NotRequired[str]
+ """
+ The ID of a bank account or a card to send the payout to. If you don't provide a destination, we use the default external account for the specified currency.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ method: NotRequired[Literal["instant", "standard"]]
+ """
+ The method used to send this payout, which is `standard` or `instant`. We support `instant` for payouts to debit cards and bank accounts in certain countries. Learn more about [bank support for Instant Payouts](https://stripe.com/docs/payouts/instant-payouts-banks).
+ """
+ payout_method: NotRequired[str]
+ """
+ The ID of a v2 FinancialAccount to send funds to.
+ """
+ source_type: NotRequired[Literal["bank_account", "card", "fpx"]]
+ """
+ The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the Balances API. One of `bank_account`, `card`, or `fpx`.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ A string that displays on the recipient's bank or card statement (up to 22 characters). A `statement_descriptor` that's longer than 22 characters return an error. Most banks truncate this information and display it inconsistently. Some banks might not display it at all.
+ """
diff --git a/stripe/params/_payout_list_params.py b/stripe/params/_payout_list_params.py
new file mode 100644
index 000000000..e60283906
--- /dev/null
+++ b/stripe/params/_payout_list_params.py
@@ -0,0 +1,78 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class PayoutListParams(RequestOptions):
+ arrival_date: NotRequired["PayoutListParamsArrivalDate|int"]
+ """
+ Only return payouts that are expected to arrive during the given date interval.
+ """
+ created: NotRequired["PayoutListParamsCreated|int"]
+ """
+ Only return payouts that were created during the given date interval.
+ """
+ destination: NotRequired[str]
+ """
+ The ID of an external account - only return payouts sent to this external account.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[str]
+ """
+ Only return payouts that have the given status: `pending`, `paid`, `failed`, or `canceled`.
+ """
+
+
+class PayoutListParamsArrivalDate(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
+
+
+class PayoutListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_payout_modify_params.py b/stripe/params/_payout_modify_params.py
new file mode 100644
index 000000000..732d10bd7
--- /dev/null
+++ b/stripe/params/_payout_modify_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class PayoutModifyParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_payout_retrieve_params.py b/stripe/params/_payout_retrieve_params.py
new file mode 100644
index 000000000..1f76e5747
--- /dev/null
+++ b/stripe/params/_payout_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PayoutRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_payout_reverse_params.py b/stripe/params/_payout_reverse_params.py
new file mode 100644
index 000000000..2e95e113a
--- /dev/null
+++ b/stripe/params/_payout_reverse_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import NotRequired
+
+
+class PayoutReverseParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_payout_update_params.py b/stripe/params/_payout_update_params.py
new file mode 100644
index 000000000..04a99d7da
--- /dev/null
+++ b/stripe/params/_payout_update_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PayoutUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_plan_create_params.py b/stripe/params/_plan_create_params.py
new file mode 100644
index 000000000..43c20a246
--- /dev/null
+++ b/stripe/params/_plan_create_params.py
@@ -0,0 +1,144 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List, Union
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PlanCreateParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Whether the plan is currently available for new subscriptions. Defaults to `true`.
+ """
+ amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free plan) representing how much to charge on a recurring basis.
+ """
+ amount_decimal: NotRequired[str]
+ """
+ Same as `amount`, but accepts a decimal value with at most 12 decimal places. Only one of `amount` and `amount_decimal` can be set.
+ """
+ billing_scheme: NotRequired[Literal["per_unit", "tiered"]]
+ """
+ Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ id: NotRequired[str]
+ """
+ An identifier randomly generated by Stripe. Used to identify this plan when subscribing a customer. You can optionally override this ID, but the ID must be unique across all plans in your Stripe account. You can, however, use the same plan ID in both live and test modes.
+ """
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ meter: NotRequired[str]
+ """
+ The meter tracking the usage of a metered price
+ """
+ nickname: NotRequired[str]
+ """
+ A brief description of the plan, hidden from customers.
+ """
+ product: NotRequired["PlanCreateParamsProduct|str"]
+ tiers: NotRequired[List["PlanCreateParamsTier"]]
+ """
+ Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
+ """
+ tiers_mode: NotRequired[Literal["graduated", "volume"]]
+ """
+ Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows.
+ """
+ transform_usage: NotRequired["PlanCreateParamsTransformUsage"]
+ """
+ Apply a transformation to the reported usage or set quantity before computing the billed price. Cannot be combined with `tiers`.
+ """
+ trial_period_days: NotRequired[int]
+ """
+ Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
+ """
+ usage_type: NotRequired[Literal["licensed", "metered"]]
+ """
+ Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.
+ """
+
+
+class PlanCreateParamsProduct(TypedDict):
+ active: NotRequired[bool]
+ """
+ Whether the product is currently available for purchase. Defaults to `true`.
+ """
+ id: NotRequired[str]
+ """
+ The identifier for the product. Must be unique. If not provided, an identifier will be randomly generated.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: str
+ """
+ The product's name, meant to be displayable to the customer.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
+
+ This may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+ unit_label: NotRequired[str]
+ """
+ A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
+ """
+
+
+class PlanCreateParamsTier(TypedDict):
+ flat_amount: NotRequired[int]
+ """
+ The flat billing amount for an entire tier, regardless of the number of units in the tier.
+ """
+ flat_amount_decimal: NotRequired[str]
+ """
+ Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
+ """
+ unit_amount: NotRequired[int]
+ """
+ The per unit billing amount for each individual unit for which this tier applies.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+ up_to: Union[Literal["inf"], int]
+ """
+ Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
+ """
+
+
+class PlanCreateParamsTransformUsage(TypedDict):
+ divide_by: int
+ """
+ Divide usage by this number.
+ """
+ round: Literal["down", "up"]
+ """
+ After division, either round the result `up` or `down`.
+ """
diff --git a/stripe/params/_plan_delete_params.py b/stripe/params/_plan_delete_params.py
new file mode 100644
index 000000000..7980a799b
--- /dev/null
+++ b/stripe/params/_plan_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class PlanDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/_plan_list_params.py b/stripe/params/_plan_list_params.py
new file mode 100644
index 000000000..e33e7ce1a
--- /dev/null
+++ b/stripe/params/_plan_list_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class PlanListParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Only return plans that are active or inactive (e.g., pass `false` to list all inactive plans).
+ """
+ created: NotRequired["PlanListParamsCreated|int"]
+ """
+ A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ product: NotRequired[str]
+ """
+ Only return plans for the given product.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class PlanListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_plan_modify_params.py b/stripe/params/_plan_modify_params.py
new file mode 100644
index 000000000..c9efc214b
--- /dev/null
+++ b/stripe/params/_plan_modify_params.py
@@ -0,0 +1,32 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class PlanModifyParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Whether the plan is currently available for new subscriptions.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ nickname: NotRequired[str]
+ """
+ A brief description of the plan, hidden from customers.
+ """
+ product: NotRequired[str]
+ """
+ The product the plan belongs to. This cannot be changed once it has been used in a subscription or subscription schedule.
+ """
+ trial_period_days: NotRequired[int]
+ """
+ Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
+ """
diff --git a/stripe/params/_plan_retrieve_params.py b/stripe/params/_plan_retrieve_params.py
new file mode 100644
index 000000000..f1d5ea9e1
--- /dev/null
+++ b/stripe/params/_plan_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PlanRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_plan_update_params.py b/stripe/params/_plan_update_params.py
new file mode 100644
index 000000000..7c2ef5cf2
--- /dev/null
+++ b/stripe/params/_plan_update_params.py
@@ -0,0 +1,31 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PlanUpdateParams(TypedDict):
+ active: NotRequired[bool]
+ """
+ Whether the plan is currently available for new subscriptions.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ nickname: NotRequired[str]
+ """
+ A brief description of the plan, hidden from customers.
+ """
+ product: NotRequired[str]
+ """
+ The product the plan belongs to. This cannot be changed once it has been used in a subscription or subscription schedule.
+ """
+ trial_period_days: NotRequired[int]
+ """
+ Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
+ """
diff --git a/stripe/params/_price_create_params.py b/stripe/params/_price_create_params.py
new file mode 100644
index 000000000..decaa2d7e
--- /dev/null
+++ b/stripe/params/_price_create_params.py
@@ -0,0 +1,262 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List, Union
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PriceCreateParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Whether the price can be used for new purchases. Defaults to `true`.
+ """
+ billing_scheme: NotRequired[Literal["per_unit", "tiered"]]
+ """
+ Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `unit_amount` or `unit_amount_decimal`) will be charged per unit in `quantity` (for prices with `usage_type=licensed`), or per unit of total usage (for prices with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ currency_options: NotRequired[
+ Dict[str, "PriceCreateParamsCurrencyOptions"]
+ ]
+ """
+ Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+ custom_unit_amount: NotRequired["PriceCreateParamsCustomUnitAmount"]
+ """
+ When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ lookup_key: NotRequired[str]
+ """
+ A lookup key used to retrieve prices dynamically from a static string. This may be up to 200 characters.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ nickname: NotRequired[str]
+ """
+ A brief description of the price, hidden from customers.
+ """
+ product: NotRequired[str]
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ product_data: NotRequired["PriceCreateParamsProductData"]
+ """
+ These fields can be used to create a new product that this price will belong to.
+ """
+ recurring: NotRequired["PriceCreateParamsRecurring"]
+ """
+ The recurring components of a price such as `interval` and `usage_type`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ tiers: NotRequired[List["PriceCreateParamsTier"]]
+ """
+ Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
+ """
+ tiers_mode: NotRequired[Literal["graduated", "volume"]]
+ """
+ Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows.
+ """
+ transfer_lookup_key: NotRequired[bool]
+ """
+ If set to true, will atomically remove the lookup key from the existing price, and assign it to this price.
+ """
+ transform_quantity: NotRequired["PriceCreateParamsTransformQuantity"]
+ """
+ Apply a transformation to the reported usage or set quantity before computing the billed price. Cannot be combined with `tiers`.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge. One of `unit_amount`, `unit_amount_decimal`, or `custom_unit_amount` is required, unless `billing_scheme=tiered`.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class PriceCreateParamsCurrencyOptions(TypedDict):
+ custom_unit_amount: NotRequired[
+ "PriceCreateParamsCurrencyOptionsCustomUnitAmount"
+ ]
+ """
+ When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ tiers: NotRequired[List["PriceCreateParamsCurrencyOptionsTier"]]
+ """
+ Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class PriceCreateParamsCurrencyOptionsCustomUnitAmount(TypedDict):
+ enabled: bool
+ """
+ Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
+ """
+ maximum: NotRequired[int]
+ """
+ The maximum unit amount the customer can specify for this item.
+ """
+ minimum: NotRequired[int]
+ """
+ The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
+ """
+ preset: NotRequired[int]
+ """
+ The starting unit amount which can be updated by the customer.
+ """
+
+
+class PriceCreateParamsCurrencyOptionsTier(TypedDict):
+ flat_amount: NotRequired[int]
+ """
+ The flat billing amount for an entire tier, regardless of the number of units in the tier.
+ """
+ flat_amount_decimal: NotRequired[str]
+ """
+ Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
+ """
+ unit_amount: NotRequired[int]
+ """
+ The per unit billing amount for each individual unit for which this tier applies.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+ up_to: Union[Literal["inf"], int]
+ """
+ Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
+ """
+
+
+class PriceCreateParamsCustomUnitAmount(TypedDict):
+ enabled: bool
+ """
+ Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
+ """
+ maximum: NotRequired[int]
+ """
+ The maximum unit amount the customer can specify for this item.
+ """
+ minimum: NotRequired[int]
+ """
+ The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
+ """
+ preset: NotRequired[int]
+ """
+ The starting unit amount which can be updated by the customer.
+ """
+
+
+class PriceCreateParamsProductData(TypedDict):
+ active: NotRequired[bool]
+ """
+ Whether the product is currently available for purchase. Defaults to `true`.
+ """
+ id: NotRequired[str]
+ """
+ The identifier for the product. Must be unique. If not provided, an identifier will be randomly generated.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: str
+ """
+ The product's name, meant to be displayable to the customer.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
+
+ This may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+ unit_label: NotRequired[str]
+ """
+ A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
+ """
+
+
+class PriceCreateParamsRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
+ meter: NotRequired[str]
+ """
+ The meter tracking the usage of a metered price
+ """
+ trial_period_days: NotRequired[int]
+ """
+ Default number of trial days when subscribing a customer to this price using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
+ """
+ usage_type: NotRequired[Literal["licensed", "metered"]]
+ """
+ Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.
+ """
+
+
+class PriceCreateParamsTier(TypedDict):
+ flat_amount: NotRequired[int]
+ """
+ The flat billing amount for an entire tier, regardless of the number of units in the tier.
+ """
+ flat_amount_decimal: NotRequired[str]
+ """
+ Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
+ """
+ unit_amount: NotRequired[int]
+ """
+ The per unit billing amount for each individual unit for which this tier applies.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+ up_to: Union[Literal["inf"], int]
+ """
+ Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
+ """
+
+
+class PriceCreateParamsTransformQuantity(TypedDict):
+ divide_by: int
+ """
+ Divide usage by this number.
+ """
+ round: Literal["down", "up"]
+ """
+ After division, either round the result `up` or `down`.
+ """
diff --git a/stripe/params/_price_list_params.py b/stripe/params/_price_list_params.py
new file mode 100644
index 000000000..e1df106d0
--- /dev/null
+++ b/stripe/params/_price_list_params.py
@@ -0,0 +1,86 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PriceListParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Only return prices that are active or inactive (e.g., pass `false` to list all inactive prices).
+ """
+ created: NotRequired["PriceListParamsCreated|int"]
+ """
+ A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
+ """
+ currency: NotRequired[str]
+ """
+ Only return prices for the given currency.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ lookup_keys: NotRequired[List[str]]
+ """
+ Only return the price with these lookup_keys, if any exist. You can specify up to 10 lookup_keys.
+ """
+ product: NotRequired[str]
+ """
+ Only return prices for the given product.
+ """
+ recurring: NotRequired["PriceListParamsRecurring"]
+ """
+ Only return prices with these recurring fields.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ type: NotRequired[Literal["one_time", "recurring"]]
+ """
+ Only return prices of type `recurring` or `one_time`.
+ """
+
+
+class PriceListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
+
+
+class PriceListParamsRecurring(TypedDict):
+ interval: NotRequired[Literal["day", "month", "week", "year"]]
+ """
+ Filter by billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ meter: NotRequired[str]
+ """
+ Filter by the price's meter.
+ """
+ usage_type: NotRequired[Literal["licensed", "metered"]]
+ """
+ Filter by the usage type for this price. Can be either `metered` or `licensed`.
+ """
diff --git a/stripe/params/_price_modify_params.py b/stripe/params/_price_modify_params.py
new file mode 100644
index 000000000..1f8983ae8
--- /dev/null
+++ b/stripe/params/_price_modify_params.py
@@ -0,0 +1,109 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List, Union
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PriceModifyParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Whether the price can be used for new purchases. Defaults to `true`.
+ """
+ currency_options: NotRequired[
+ "Literal['']|Dict[str, PriceModifyParamsCurrencyOptions]"
+ ]
+ """
+ Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ lookup_key: NotRequired[str]
+ """
+ A lookup key used to retrieve prices dynamically from a static string. This may be up to 200 characters.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ nickname: NotRequired[str]
+ """
+ A brief description of the price, hidden from customers.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ transfer_lookup_key: NotRequired[bool]
+ """
+ If set to true, will atomically remove the lookup key from the existing price, and assign it to this price.
+ """
+
+
+class PriceModifyParamsCurrencyOptions(TypedDict):
+ custom_unit_amount: NotRequired[
+ "PriceModifyParamsCurrencyOptionsCustomUnitAmount"
+ ]
+ """
+ When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ tiers: NotRequired[List["PriceModifyParamsCurrencyOptionsTier"]]
+ """
+ Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class PriceModifyParamsCurrencyOptionsCustomUnitAmount(TypedDict):
+ enabled: bool
+ """
+ Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
+ """
+ maximum: NotRequired[int]
+ """
+ The maximum unit amount the customer can specify for this item.
+ """
+ minimum: NotRequired[int]
+ """
+ The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
+ """
+ preset: NotRequired[int]
+ """
+ The starting unit amount which can be updated by the customer.
+ """
+
+
+class PriceModifyParamsCurrencyOptionsTier(TypedDict):
+ flat_amount: NotRequired[int]
+ """
+ The flat billing amount for an entire tier, regardless of the number of units in the tier.
+ """
+ flat_amount_decimal: NotRequired[str]
+ """
+ Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
+ """
+ unit_amount: NotRequired[int]
+ """
+ The per unit billing amount for each individual unit for which this tier applies.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+ up_to: Union[Literal["inf"], int]
+ """
+ Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
+ """
diff --git a/stripe/params/_price_retrieve_params.py b/stripe/params/_price_retrieve_params.py
new file mode 100644
index 000000000..e8138021b
--- /dev/null
+++ b/stripe/params/_price_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PriceRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_price_search_params.py b/stripe/params/_price_search_params.py
new file mode 100644
index 000000000..f10b84c39
--- /dev/null
+++ b/stripe/params/_price_search_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PriceSearchParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ page: NotRequired[str]
+ """
+ A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
+ """
+ query: str
+ """
+ The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for prices](https://stripe.com/docs/search#query-fields-for-prices).
+ """
diff --git a/stripe/params/_price_update_params.py b/stripe/params/_price_update_params.py
new file mode 100644
index 000000000..35b483618
--- /dev/null
+++ b/stripe/params/_price_update_params.py
@@ -0,0 +1,108 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List, Union
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PriceUpdateParams(TypedDict):
+ active: NotRequired[bool]
+ """
+ Whether the price can be used for new purchases. Defaults to `true`.
+ """
+ currency_options: NotRequired[
+ "Literal['']|Dict[str, PriceUpdateParamsCurrencyOptions]"
+ ]
+ """
+ Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ lookup_key: NotRequired[str]
+ """
+ A lookup key used to retrieve prices dynamically from a static string. This may be up to 200 characters.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ nickname: NotRequired[str]
+ """
+ A brief description of the price, hidden from customers.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ transfer_lookup_key: NotRequired[bool]
+ """
+ If set to true, will atomically remove the lookup key from the existing price, and assign it to this price.
+ """
+
+
+class PriceUpdateParamsCurrencyOptions(TypedDict):
+ custom_unit_amount: NotRequired[
+ "PriceUpdateParamsCurrencyOptionsCustomUnitAmount"
+ ]
+ """
+ When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ tiers: NotRequired[List["PriceUpdateParamsCurrencyOptionsTier"]]
+ """
+ Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class PriceUpdateParamsCurrencyOptionsCustomUnitAmount(TypedDict):
+ enabled: bool
+ """
+ Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
+ """
+ maximum: NotRequired[int]
+ """
+ The maximum unit amount the customer can specify for this item.
+ """
+ minimum: NotRequired[int]
+ """
+ The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
+ """
+ preset: NotRequired[int]
+ """
+ The starting unit amount which can be updated by the customer.
+ """
+
+
+class PriceUpdateParamsCurrencyOptionsTier(TypedDict):
+ flat_amount: NotRequired[int]
+ """
+ The flat billing amount for an entire tier, regardless of the number of units in the tier.
+ """
+ flat_amount_decimal: NotRequired[str]
+ """
+ Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
+ """
+ unit_amount: NotRequired[int]
+ """
+ The per unit billing amount for each individual unit for which this tier applies.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+ up_to: Union[Literal["inf"], int]
+ """
+ Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
+ """
diff --git a/stripe/params/_product_create_feature_params.py b/stripe/params/_product_create_feature_params.py
new file mode 100644
index 000000000..4ec04f542
--- /dev/null
+++ b/stripe/params/_product_create_feature_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ProductCreateFeatureParams(RequestOptions):
+ entitlement_feature: str
+ """
+ The ID of the [Feature](https://stripe.com/docs/api/entitlements/feature) object attached to this product.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_product_create_params.py b/stripe/params/_product_create_params.py
new file mode 100644
index 000000000..761f0fd6a
--- /dev/null
+++ b/stripe/params/_product_create_params.py
@@ -0,0 +1,243 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List, Union
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ProductCreateParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Whether the product is currently available for purchase. Defaults to `true`.
+ """
+ default_price_data: NotRequired["ProductCreateParamsDefaultPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object. This Price will be set as the default price for this product.
+ """
+ description: NotRequired[str]
+ """
+ The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ id: NotRequired[str]
+ """
+ An identifier will be randomly generated by Stripe. You can optionally override this ID, but the ID must be unique across all products in your Stripe account.
+ """
+ images: NotRequired[List[str]]
+ """
+ A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
+ """
+ marketing_features: NotRequired[
+ List["ProductCreateParamsMarketingFeature"]
+ ]
+ """
+ A list of up to 15 marketing features for this product. These are displayed in [pricing tables](https://stripe.com/docs/payments/checkout/pricing-table).
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: str
+ """
+ The product's name, meant to be displayable to the customer.
+ """
+ package_dimensions: NotRequired["ProductCreateParamsPackageDimensions"]
+ """
+ The dimensions of this product for shipping purposes.
+ """
+ shippable: NotRequired[bool]
+ """
+ Whether this product is shipped (i.e., physical goods).
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
+
+ This may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
+ It must contain at least one letter. Only used for subscription payments.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+ type: NotRequired[Literal["good", "service"]]
+ """
+ The type of the product. Defaults to `service` if not explicitly specified, enabling use of this product with Subscriptions and Plans. Set this parameter to `good` to use this product with Orders and SKUs. On API versions before `2018-02-05`, this field defaults to `good` for compatibility reasons.
+ """
+ unit_label: NotRequired[str]
+ """
+ A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
+ """
+ url: NotRequired[str]
+ """
+ A URL of a publicly-accessible webpage for this product.
+ """
+
+
+class ProductCreateParamsDefaultPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ currency_options: NotRequired[
+ Dict[str, "ProductCreateParamsDefaultPriceDataCurrencyOptions"]
+ ]
+ """
+ Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+ custom_unit_amount: NotRequired[
+ "ProductCreateParamsDefaultPriceDataCustomUnitAmount"
+ ]
+ """
+ When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ recurring: NotRequired["ProductCreateParamsDefaultPriceDataRecurring"]
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge. One of `unit_amount`, `unit_amount_decimal`, or `custom_unit_amount` is required.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class ProductCreateParamsDefaultPriceDataCurrencyOptions(TypedDict):
+ custom_unit_amount: NotRequired[
+ "ProductCreateParamsDefaultPriceDataCurrencyOptionsCustomUnitAmount"
+ ]
+ """
+ When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ tiers: NotRequired[
+ List["ProductCreateParamsDefaultPriceDataCurrencyOptionsTier"]
+ ]
+ """
+ Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class ProductCreateParamsDefaultPriceDataCurrencyOptionsCustomUnitAmount(
+ TypedDict,
+):
+ enabled: bool
+ """
+ Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
+ """
+ maximum: NotRequired[int]
+ """
+ The maximum unit amount the customer can specify for this item.
+ """
+ minimum: NotRequired[int]
+ """
+ The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
+ """
+ preset: NotRequired[int]
+ """
+ The starting unit amount which can be updated by the customer.
+ """
+
+
+class ProductCreateParamsDefaultPriceDataCurrencyOptionsTier(TypedDict):
+ flat_amount: NotRequired[int]
+ """
+ The flat billing amount for an entire tier, regardless of the number of units in the tier.
+ """
+ flat_amount_decimal: NotRequired[str]
+ """
+ Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
+ """
+ unit_amount: NotRequired[int]
+ """
+ The per unit billing amount for each individual unit for which this tier applies.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+ up_to: Union[Literal["inf"], int]
+ """
+ Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
+ """
+
+
+class ProductCreateParamsDefaultPriceDataCustomUnitAmount(TypedDict):
+ enabled: bool
+ """
+ Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
+ """
+ maximum: NotRequired[int]
+ """
+ The maximum unit amount the customer can specify for this item.
+ """
+ minimum: NotRequired[int]
+ """
+ The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
+ """
+ preset: NotRequired[int]
+ """
+ The starting unit amount which can be updated by the customer.
+ """
+
+
+class ProductCreateParamsDefaultPriceDataRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
+
+
+class ProductCreateParamsMarketingFeature(TypedDict):
+ name: str
+ """
+ The marketing feature name. Up to 80 characters long.
+ """
+
+
+class ProductCreateParamsPackageDimensions(TypedDict):
+ height: float
+ """
+ Height, in inches. Maximum precision is 2 decimal places.
+ """
+ length: float
+ """
+ Length, in inches. Maximum precision is 2 decimal places.
+ """
+ weight: float
+ """
+ Weight, in ounces. Maximum precision is 2 decimal places.
+ """
+ width: float
+ """
+ Width, in inches. Maximum precision is 2 decimal places.
+ """
diff --git a/stripe/params/_product_delete_feature_params.py b/stripe/params/_product_delete_feature_params.py
new file mode 100644
index 000000000..354bb60a7
--- /dev/null
+++ b/stripe/params/_product_delete_feature_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class ProductDeleteFeatureParams(RequestOptions):
+ pass
diff --git a/stripe/params/_product_delete_params.py b/stripe/params/_product_delete_params.py
new file mode 100644
index 000000000..b758f6bfb
--- /dev/null
+++ b/stripe/params/_product_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class ProductDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/_product_feature_create_params.py b/stripe/params/_product_feature_create_params.py
new file mode 100644
index 000000000..b52580ed9
--- /dev/null
+++ b/stripe/params/_product_feature_create_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ProductFeatureCreateParams(TypedDict):
+ entitlement_feature: str
+ """
+ The ID of the [Feature](https://stripe.com/docs/api/entitlements/feature) object attached to this product.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_product_feature_delete_params.py b/stripe/params/_product_feature_delete_params.py
new file mode 100644
index 000000000..8cee6f289
--- /dev/null
+++ b/stripe/params/_product_feature_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing_extensions import TypedDict
+
+
+class ProductFeatureDeleteParams(TypedDict):
+ pass
diff --git a/stripe/params/_product_feature_list_params.py b/stripe/params/_product_feature_list_params.py
new file mode 100644
index 000000000..6e35305b7
--- /dev/null
+++ b/stripe/params/_product_feature_list_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ProductFeatureListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_product_feature_retrieve_params.py b/stripe/params/_product_feature_retrieve_params.py
new file mode 100644
index 000000000..d34196415
--- /dev/null
+++ b/stripe/params/_product_feature_retrieve_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ProductFeatureRetrieveParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_product_list_features_params.py b/stripe/params/_product_list_features_params.py
new file mode 100644
index 000000000..23b455651
--- /dev/null
+++ b/stripe/params/_product_list_features_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ProductListFeaturesParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_product_list_params.py b/stripe/params/_product_list_params.py
new file mode 100644
index 000000000..c52f65b89
--- /dev/null
+++ b/stripe/params/_product_list_params.py
@@ -0,0 +1,67 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ProductListParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Only return products that are active or inactive (e.g., pass `false` to list all inactive products).
+ """
+ created: NotRequired["ProductListParamsCreated|int"]
+ """
+ Only return products that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ ids: NotRequired[List[str]]
+ """
+ Only return products with the given IDs. Cannot be used with [starting_after](https://stripe.com/docs/api#list_products-starting_after) or [ending_before](https://stripe.com/docs/api#list_products-ending_before).
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ shippable: NotRequired[bool]
+ """
+ Only return products that can be shipped (i.e., physical, not digital products).
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ type: NotRequired[Literal["good", "service"]]
+ """
+ Only return products of this type.
+ """
+ url: NotRequired[str]
+ """
+ Only return products with the given url.
+ """
+
+
+class ProductListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_product_modify_params.py b/stripe/params/_product_modify_params.py
new file mode 100644
index 000000000..1a7381951
--- /dev/null
+++ b/stripe/params/_product_modify_params.py
@@ -0,0 +1,97 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ProductModifyParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Whether the product is available for purchase.
+ """
+ default_price: NotRequired[str]
+ """
+ The ID of the [Price](https://stripe.com/docs/api/prices) object that is the default price for this product.
+ """
+ description: NotRequired["Literal['']|str"]
+ """
+ The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ images: NotRequired["Literal['']|List[str]"]
+ """
+ A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
+ """
+ marketing_features: NotRequired[
+ "Literal['']|List[ProductModifyParamsMarketingFeature]"
+ ]
+ """
+ A list of up to 15 marketing features for this product. These are displayed in [pricing tables](https://stripe.com/docs/payments/checkout/pricing-table).
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired[str]
+ """
+ The product's name, meant to be displayable to the customer.
+ """
+ package_dimensions: NotRequired[
+ "Literal['']|ProductModifyParamsPackageDimensions"
+ ]
+ """
+ The dimensions of this product for shipping purposes.
+ """
+ shippable: NotRequired[bool]
+ """
+ Whether this product is shipped (i.e., physical goods).
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
+
+ This may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
+ It must contain at least one letter. May only be set if `type=service`. Only used for subscription payments.
+ """
+ tax_code: NotRequired["Literal['']|str"]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+ unit_label: NotRequired["Literal['']|str"]
+ """
+ A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal. May only be set if `type=service`.
+ """
+ url: NotRequired["Literal['']|str"]
+ """
+ A URL of a publicly-accessible webpage for this product.
+ """
+
+
+class ProductModifyParamsMarketingFeature(TypedDict):
+ name: str
+ """
+ The marketing feature name. Up to 80 characters long.
+ """
+
+
+class ProductModifyParamsPackageDimensions(TypedDict):
+ height: float
+ """
+ Height, in inches. Maximum precision is 2 decimal places.
+ """
+ length: float
+ """
+ Length, in inches. Maximum precision is 2 decimal places.
+ """
+ weight: float
+ """
+ Weight, in ounces. Maximum precision is 2 decimal places.
+ """
+ width: float
+ """
+ Width, in inches. Maximum precision is 2 decimal places.
+ """
diff --git a/stripe/params/_product_retrieve_feature_params.py b/stripe/params/_product_retrieve_feature_params.py
new file mode 100644
index 000000000..7d3f8f208
--- /dev/null
+++ b/stripe/params/_product_retrieve_feature_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ProductRetrieveFeatureParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_product_retrieve_params.py b/stripe/params/_product_retrieve_params.py
new file mode 100644
index 000000000..c9cc1bd6b
--- /dev/null
+++ b/stripe/params/_product_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ProductRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_product_search_params.py b/stripe/params/_product_search_params.py
new file mode 100644
index 000000000..e9ac3e56b
--- /dev/null
+++ b/stripe/params/_product_search_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ProductSearchParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ page: NotRequired[str]
+ """
+ A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
+ """
+ query: str
+ """
+ The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for products](https://stripe.com/docs/search#query-fields-for-products).
+ """
diff --git a/stripe/params/_product_update_params.py b/stripe/params/_product_update_params.py
new file mode 100644
index 000000000..685966a0e
--- /dev/null
+++ b/stripe/params/_product_update_params.py
@@ -0,0 +1,96 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ProductUpdateParams(TypedDict):
+ active: NotRequired[bool]
+ """
+ Whether the product is available for purchase.
+ """
+ default_price: NotRequired[str]
+ """
+ The ID of the [Price](https://stripe.com/docs/api/prices) object that is the default price for this product.
+ """
+ description: NotRequired["Literal['']|str"]
+ """
+ The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ images: NotRequired["Literal['']|List[str]"]
+ """
+ A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
+ """
+ marketing_features: NotRequired[
+ "Literal['']|List[ProductUpdateParamsMarketingFeature]"
+ ]
+ """
+ A list of up to 15 marketing features for this product. These are displayed in [pricing tables](https://stripe.com/docs/payments/checkout/pricing-table).
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired[str]
+ """
+ The product's name, meant to be displayable to the customer.
+ """
+ package_dimensions: NotRequired[
+ "Literal['']|ProductUpdateParamsPackageDimensions"
+ ]
+ """
+ The dimensions of this product for shipping purposes.
+ """
+ shippable: NotRequired[bool]
+ """
+ Whether this product is shipped (i.e., physical goods).
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
+
+ This may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
+ It must contain at least one letter. May only be set if `type=service`. Only used for subscription payments.
+ """
+ tax_code: NotRequired["Literal['']|str"]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+ unit_label: NotRequired["Literal['']|str"]
+ """
+ A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal. May only be set if `type=service`.
+ """
+ url: NotRequired["Literal['']|str"]
+ """
+ A URL of a publicly-accessible webpage for this product.
+ """
+
+
+class ProductUpdateParamsMarketingFeature(TypedDict):
+ name: str
+ """
+ The marketing feature name. Up to 80 characters long.
+ """
+
+
+class ProductUpdateParamsPackageDimensions(TypedDict):
+ height: float
+ """
+ Height, in inches. Maximum precision is 2 decimal places.
+ """
+ length: float
+ """
+ Length, in inches. Maximum precision is 2 decimal places.
+ """
+ weight: float
+ """
+ Weight, in ounces. Maximum precision is 2 decimal places.
+ """
+ width: float
+ """
+ Width, in inches. Maximum precision is 2 decimal places.
+ """
diff --git a/stripe/params/_promotion_code_create_params.py b/stripe/params/_promotion_code_create_params.py
new file mode 100644
index 000000000..684750d87
--- /dev/null
+++ b/stripe/params/_promotion_code_create_params.py
@@ -0,0 +1,85 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PromotionCodeCreateParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Whether the promotion code is currently active.
+ """
+ code: NotRequired[str]
+ """
+ The customer-facing code. Regardless of case, this code must be unique across all active promotion codes for a specific customer. Valid characters are lower case letters (a-z), upper case letters (A-Z), and digits (0-9).
+
+ If left blank, we will generate one automatically.
+ """
+ customer: NotRequired[str]
+ """
+ The customer that this promotion code can be used by. If not set, the promotion code can be used by all customers.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired[int]
+ """
+ The timestamp at which this promotion code will expire. If the coupon has specified a `redeems_by`, then this value cannot be after the coupon's `redeems_by`.
+ """
+ max_redemptions: NotRequired[int]
+ """
+ A positive integer specifying the number of times the promotion code can be redeemed. If the coupon has specified a `max_redemptions`, then this value cannot be greater than the coupon's `max_redemptions`.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ promotion: "PromotionCodeCreateParamsPromotion"
+ """
+ The promotion referenced by this promotion code.
+ """
+ restrictions: NotRequired["PromotionCodeCreateParamsRestrictions"]
+ """
+ Settings that restrict the redemption of the promotion code.
+ """
+
+
+class PromotionCodeCreateParamsPromotion(TypedDict):
+ coupon: NotRequired[str]
+ """
+ If promotion `type` is `coupon`, the coupon for this promotion code.
+ """
+ type: Literal["coupon"]
+ """
+ Specifies the type of promotion.
+ """
+
+
+class PromotionCodeCreateParamsRestrictions(TypedDict):
+ currency_options: NotRequired[
+ Dict[str, "PromotionCodeCreateParamsRestrictionsCurrencyOptions"]
+ ]
+ """
+ Promotion codes defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+ first_time_transaction: NotRequired[bool]
+ """
+ A Boolean indicating if the Promotion Code should only be redeemed for Customers without any successful payments or invoices
+ """
+ minimum_amount: NotRequired[int]
+ """
+ Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
+ """
+ minimum_amount_currency: NotRequired[str]
+ """
+ Three-letter [ISO code](https://stripe.com/docs/currencies) for minimum_amount
+ """
+
+
+class PromotionCodeCreateParamsRestrictionsCurrencyOptions(TypedDict):
+ minimum_amount: NotRequired[int]
+ """
+ Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
+ """
diff --git a/stripe/params/_promotion_code_list_params.py b/stripe/params/_promotion_code_list_params.py
new file mode 100644
index 000000000..693f319af
--- /dev/null
+++ b/stripe/params/_promotion_code_list_params.py
@@ -0,0 +1,63 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class PromotionCodeListParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Filter promotion codes by whether they are active.
+ """
+ code: NotRequired[str]
+ """
+ Only return promotion codes that have this case-insensitive code.
+ """
+ coupon: NotRequired[str]
+ """
+ Only return promotion codes for this coupon.
+ """
+ created: NotRequired["PromotionCodeListParamsCreated|int"]
+ """
+ A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
+ """
+ customer: NotRequired[str]
+ """
+ Only return promotion codes that are restricted to this customer.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class PromotionCodeListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_promotion_code_modify_params.py b/stripe/params/_promotion_code_modify_params.py
new file mode 100644
index 000000000..671f7047d
--- /dev/null
+++ b/stripe/params/_promotion_code_modify_params.py
@@ -0,0 +1,40 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PromotionCodeModifyParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Whether the promotion code is currently active. A promotion code can only be reactivated when the coupon is still valid and the promotion code is otherwise redeemable.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ restrictions: NotRequired["PromotionCodeModifyParamsRestrictions"]
+ """
+ Settings that restrict the redemption of the promotion code.
+ """
+
+
+class PromotionCodeModifyParamsRestrictions(TypedDict):
+ currency_options: NotRequired[
+ Dict[str, "PromotionCodeModifyParamsRestrictionsCurrencyOptions"]
+ ]
+ """
+ Promotion codes defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+
+
+class PromotionCodeModifyParamsRestrictionsCurrencyOptions(TypedDict):
+ minimum_amount: NotRequired[int]
+ """
+ Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
+ """
diff --git a/stripe/params/_promotion_code_retrieve_params.py b/stripe/params/_promotion_code_retrieve_params.py
new file mode 100644
index 000000000..5129081a2
--- /dev/null
+++ b/stripe/params/_promotion_code_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PromotionCodeRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_promotion_code_update_params.py b/stripe/params/_promotion_code_update_params.py
new file mode 100644
index 000000000..9f05b1a79
--- /dev/null
+++ b/stripe/params/_promotion_code_update_params.py
@@ -0,0 +1,39 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PromotionCodeUpdateParams(TypedDict):
+ active: NotRequired[bool]
+ """
+ Whether the promotion code is currently active. A promotion code can only be reactivated when the coupon is still valid and the promotion code is otherwise redeemable.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ restrictions: NotRequired["PromotionCodeUpdateParamsRestrictions"]
+ """
+ Settings that restrict the redemption of the promotion code.
+ """
+
+
+class PromotionCodeUpdateParamsRestrictions(TypedDict):
+ currency_options: NotRequired[
+ Dict[str, "PromotionCodeUpdateParamsRestrictionsCurrencyOptions"]
+ ]
+ """
+ Promotion codes defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+
+
+class PromotionCodeUpdateParamsRestrictionsCurrencyOptions(TypedDict):
+ minimum_amount: NotRequired[int]
+ """
+ Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
+ """
diff --git a/stripe/params/_quote_accept_params.py b/stripe/params/_quote_accept_params.py
new file mode 100644
index 000000000..5199188cc
--- /dev/null
+++ b/stripe/params/_quote_accept_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class QuoteAcceptParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_quote_cancel_params.py b/stripe/params/_quote_cancel_params.py
new file mode 100644
index 000000000..1797e4651
--- /dev/null
+++ b/stripe/params/_quote_cancel_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class QuoteCancelParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_quote_computed_upfront_line_items_list_params.py b/stripe/params/_quote_computed_upfront_line_items_list_params.py
new file mode 100644
index 000000000..6106ebe9e
--- /dev/null
+++ b/stripe/params/_quote_computed_upfront_line_items_list_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class QuoteComputedUpfrontLineItemsListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_quote_create_params.py b/stripe/params/_quote_create_params.py
new file mode 100644
index 000000000..13b910faa
--- /dev/null
+++ b/stripe/params/_quote_create_params.py
@@ -0,0 +1,298 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class QuoteCreateParams(RequestOptions):
+ application_fee_amount: NotRequired["Literal['']|int"]
+ """
+ The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field.
+ """
+ application_fee_percent: NotRequired["Literal['']|float"]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
+ """
+ automatic_tax: NotRequired["QuoteCreateParamsAutomaticTax"]
+ """
+ Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
+ """
+ customer: NotRequired[str]
+ """
+ The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
+ """
+ default_tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates that will apply to any line item that does not have `tax_rates` set.
+ """
+ description: NotRequired["Literal['']|str"]
+ """
+ A description that will be displayed on the quote PDF. If no value is passed, the default description configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
+ """
+ discounts: NotRequired["Literal['']|List[QuoteCreateParamsDiscount]"]
+ """
+ The discounts applied to the quote.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired[int]
+ """
+ A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch. If no value is passed, the default expiration date configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
+ """
+ footer: NotRequired["Literal['']|str"]
+ """
+ A footer that will be displayed on the quote PDF. If no value is passed, the default footer configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
+ """
+ from_quote: NotRequired["QuoteCreateParamsFromQuote"]
+ """
+ Clone an existing quote. The new quote will be created in `status=draft`. When using this parameter, you cannot specify any other parameters except for `expires_at`.
+ """
+ header: NotRequired["Literal['']|str"]
+ """
+ A header that will be displayed on the quote PDF. If no value is passed, the default header configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
+ """
+ invoice_settings: NotRequired["QuoteCreateParamsInvoiceSettings"]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ line_items: NotRequired[List["QuoteCreateParamsLineItem"]]
+ """
+ A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ on_behalf_of: NotRequired["Literal['']|str"]
+ """
+ The account on behalf of which to charge.
+ """
+ subscription_data: NotRequired["QuoteCreateParamsSubscriptionData"]
+ """
+ When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if `subscription_data[effective_date]` is present and in the future, otherwise a subscription is created.
+ """
+ test_clock: NotRequired[str]
+ """
+ ID of the test clock to attach to the quote.
+ """
+ transfer_data: NotRequired["Literal['']|QuoteCreateParamsTransferData"]
+ """
+ The data with which to automatically create a Transfer for each of the invoices.
+ """
+
+
+class QuoteCreateParamsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Controls whether Stripe will automatically compute tax on the resulting invoices or subscriptions as well as the quote itself.
+ """
+ liability: NotRequired["QuoteCreateParamsAutomaticTaxLiability"]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class QuoteCreateParamsAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class QuoteCreateParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class QuoteCreateParamsFromQuote(TypedDict):
+ is_revision: NotRequired[bool]
+ """
+ Whether this quote is a revision of the previous quote.
+ """
+ quote: str
+ """
+ The `id` of the quote that will be cloned.
+ """
+
+
+class QuoteCreateParamsInvoiceSettings(TypedDict):
+ days_until_due: NotRequired[int]
+ """
+ Number of days within which a customer must pay the invoice generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
+ """
+ issuer: NotRequired["QuoteCreateParamsInvoiceSettingsIssuer"]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class QuoteCreateParamsInvoiceSettingsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class QuoteCreateParamsLineItem(TypedDict):
+ discounts: NotRequired[
+ "Literal['']|List[QuoteCreateParamsLineItemDiscount]"
+ ]
+ """
+ The discounts applied to this line item.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required.
+ """
+ price_data: NotRequired["QuoteCreateParamsLineItemPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: NotRequired[int]
+ """
+ The quantity of the line item.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the line item. When set, the `default_tax_rates` on the quote do not apply to this line item.
+ """
+
+
+class QuoteCreateParamsLineItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class QuoteCreateParamsLineItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ recurring: NotRequired["QuoteCreateParamsLineItemPriceDataRecurring"]
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class QuoteCreateParamsLineItemPriceDataRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
+
+
+class QuoteCreateParamsSubscriptionData(TypedDict):
+ billing_mode: NotRequired["QuoteCreateParamsSubscriptionDataBillingMode"]
+ """
+ Controls how prorations and invoices for subscriptions are calculated and orchestrated.
+ """
+ description: NotRequired[str]
+ """
+ The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
+ """
+ effective_date: NotRequired[
+ "Literal['']|Literal['current_period_end']|int"
+ ]
+ """
+ When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. The `effective_date` is ignored if it is in the past when the quote is accepted.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
+ """
+ trial_period_days: NotRequired["Literal['']|int"]
+ """
+ Integer representing the number of trial period days before the customer is charged for the first time.
+ """
+
+
+class QuoteCreateParamsSubscriptionDataBillingMode(TypedDict):
+ flexible: NotRequired[
+ "QuoteCreateParamsSubscriptionDataBillingModeFlexible"
+ ]
+ """
+ Configure behavior for flexible billing mode.
+ """
+ type: Literal["classic", "flexible"]
+ """
+ Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
+ """
+
+
+class QuoteCreateParamsSubscriptionDataBillingModeFlexible(TypedDict):
+ proration_discounts: NotRequired[Literal["included", "itemized"]]
+ """
+ Controls how invoices and invoice items display proration amounts and discount amounts.
+ """
+
+
+class QuoteCreateParamsTransferData(TypedDict):
+ amount: NotRequired[int]
+ """
+ The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
+ """
+ amount_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination. There must be at least 1 line item with a recurring price to use this field.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
diff --git a/stripe/params/_quote_finalize_quote_params.py b/stripe/params/_quote_finalize_quote_params.py
new file mode 100644
index 000000000..e07b0558d
--- /dev/null
+++ b/stripe/params/_quote_finalize_quote_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class QuoteFinalizeQuoteParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired[int]
+ """
+ A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.
+ """
diff --git a/stripe/params/_quote_line_item_list_params.py b/stripe/params/_quote_line_item_list_params.py
new file mode 100644
index 000000000..b08ec8ec5
--- /dev/null
+++ b/stripe/params/_quote_line_item_list_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class QuoteLineItemListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_quote_list_computed_upfront_line_items_params.py b/stripe/params/_quote_list_computed_upfront_line_items_params.py
new file mode 100644
index 000000000..4f38ee12b
--- /dev/null
+++ b/stripe/params/_quote_list_computed_upfront_line_items_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class QuoteListComputedUpfrontLineItemsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_quote_list_line_items_params.py b/stripe/params/_quote_list_line_items_params.py
new file mode 100644
index 000000000..1cbaa9e3b
--- /dev/null
+++ b/stripe/params/_quote_list_line_items_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class QuoteListLineItemsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_quote_list_params.py b/stripe/params/_quote_list_params.py
new file mode 100644
index 000000000..cb888202d
--- /dev/null
+++ b/stripe/params/_quote_list_params.py
@@ -0,0 +1,36 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class QuoteListParams(RequestOptions):
+ customer: NotRequired[str]
+ """
+ The ID of the customer whose quotes will be retrieved.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["accepted", "canceled", "draft", "open"]]
+ """
+ The status of the quote.
+ """
+ test_clock: NotRequired[str]
+ """
+ Provides a list of quotes that are associated with the specified test clock. The response will not include quotes with test clocks if this and the customer parameter is not set.
+ """
diff --git a/stripe/params/_quote_modify_params.py b/stripe/params/_quote_modify_params.py
new file mode 100644
index 000000000..9a66752a9
--- /dev/null
+++ b/stripe/params/_quote_modify_params.py
@@ -0,0 +1,259 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class QuoteModifyParams(RequestOptions):
+ application_fee_amount: NotRequired["Literal['']|int"]
+ """
+ The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field.
+ """
+ application_fee_percent: NotRequired["Literal['']|float"]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
+ """
+ automatic_tax: NotRequired["QuoteModifyParamsAutomaticTax"]
+ """
+ Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
+ """
+ customer: NotRequired[str]
+ """
+ The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
+ """
+ default_tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates that will apply to any line item that does not have `tax_rates` set.
+ """
+ description: NotRequired["Literal['']|str"]
+ """
+ A description that will be displayed on the quote PDF.
+ """
+ discounts: NotRequired["Literal['']|List[QuoteModifyParamsDiscount]"]
+ """
+ The discounts applied to the quote.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired[int]
+ """
+ A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.
+ """
+ footer: NotRequired["Literal['']|str"]
+ """
+ A footer that will be displayed on the quote PDF.
+ """
+ header: NotRequired["Literal['']|str"]
+ """
+ A header that will be displayed on the quote PDF.
+ """
+ invoice_settings: NotRequired["QuoteModifyParamsInvoiceSettings"]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ line_items: NotRequired[List["QuoteModifyParamsLineItem"]]
+ """
+ A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ on_behalf_of: NotRequired["Literal['']|str"]
+ """
+ The account on behalf of which to charge.
+ """
+ subscription_data: NotRequired["QuoteModifyParamsSubscriptionData"]
+ """
+ When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if `subscription_data[effective_date]` is present and in the future, otherwise a subscription is created.
+ """
+ transfer_data: NotRequired["Literal['']|QuoteModifyParamsTransferData"]
+ """
+ The data with which to automatically create a Transfer for each of the invoices.
+ """
+
+
+class QuoteModifyParamsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Controls whether Stripe will automatically compute tax on the resulting invoices or subscriptions as well as the quote itself.
+ """
+ liability: NotRequired["QuoteModifyParamsAutomaticTaxLiability"]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class QuoteModifyParamsAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class QuoteModifyParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class QuoteModifyParamsInvoiceSettings(TypedDict):
+ days_until_due: NotRequired[int]
+ """
+ Number of days within which a customer must pay the invoice generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
+ """
+ issuer: NotRequired["QuoteModifyParamsInvoiceSettingsIssuer"]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class QuoteModifyParamsInvoiceSettingsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class QuoteModifyParamsLineItem(TypedDict):
+ discounts: NotRequired[
+ "Literal['']|List[QuoteModifyParamsLineItemDiscount]"
+ ]
+ """
+ The discounts applied to this line item.
+ """
+ id: NotRequired[str]
+ """
+ The ID of an existing line item on the quote.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required.
+ """
+ price_data: NotRequired["QuoteModifyParamsLineItemPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: NotRequired[int]
+ """
+ The quantity of the line item.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the line item. When set, the `default_tax_rates` on the quote do not apply to this line item.
+ """
+
+
+class QuoteModifyParamsLineItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class QuoteModifyParamsLineItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ recurring: NotRequired["QuoteModifyParamsLineItemPriceDataRecurring"]
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class QuoteModifyParamsLineItemPriceDataRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
+
+
+class QuoteModifyParamsSubscriptionData(TypedDict):
+ description: NotRequired["Literal['']|str"]
+ """
+ The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
+ """
+ effective_date: NotRequired[
+ "Literal['']|Literal['current_period_end']|int"
+ ]
+ """
+ When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. The `effective_date` is ignored if it is in the past when the quote is accepted.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
+ """
+ trial_period_days: NotRequired["Literal['']|int"]
+ """
+ Integer representing the number of trial period days before the customer is charged for the first time.
+ """
+
+
+class QuoteModifyParamsTransferData(TypedDict):
+ amount: NotRequired[int]
+ """
+ The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
+ """
+ amount_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination. There must be at least 1 line item with a recurring price to use this field.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
diff --git a/stripe/params/_quote_pdf_params.py b/stripe/params/_quote_pdf_params.py
new file mode 100644
index 000000000..2ac05dbfb
--- /dev/null
+++ b/stripe/params/_quote_pdf_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class QuotePdfParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_quote_retrieve_params.py b/stripe/params/_quote_retrieve_params.py
new file mode 100644
index 000000000..744ea9ed3
--- /dev/null
+++ b/stripe/params/_quote_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class QuoteRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_quote_update_params.py b/stripe/params/_quote_update_params.py
new file mode 100644
index 000000000..630d474e3
--- /dev/null
+++ b/stripe/params/_quote_update_params.py
@@ -0,0 +1,258 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class QuoteUpdateParams(TypedDict):
+ application_fee_amount: NotRequired["Literal['']|int"]
+ """
+ The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field.
+ """
+ application_fee_percent: NotRequired["Literal['']|float"]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
+ """
+ automatic_tax: NotRequired["QuoteUpdateParamsAutomaticTax"]
+ """
+ Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
+ """
+ customer: NotRequired[str]
+ """
+ The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
+ """
+ default_tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates that will apply to any line item that does not have `tax_rates` set.
+ """
+ description: NotRequired["Literal['']|str"]
+ """
+ A description that will be displayed on the quote PDF.
+ """
+ discounts: NotRequired["Literal['']|List[QuoteUpdateParamsDiscount]"]
+ """
+ The discounts applied to the quote.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired[int]
+ """
+ A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.
+ """
+ footer: NotRequired["Literal['']|str"]
+ """
+ A footer that will be displayed on the quote PDF.
+ """
+ header: NotRequired["Literal['']|str"]
+ """
+ A header that will be displayed on the quote PDF.
+ """
+ invoice_settings: NotRequired["QuoteUpdateParamsInvoiceSettings"]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ line_items: NotRequired[List["QuoteUpdateParamsLineItem"]]
+ """
+ A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ on_behalf_of: NotRequired["Literal['']|str"]
+ """
+ The account on behalf of which to charge.
+ """
+ subscription_data: NotRequired["QuoteUpdateParamsSubscriptionData"]
+ """
+ When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if `subscription_data[effective_date]` is present and in the future, otherwise a subscription is created.
+ """
+ transfer_data: NotRequired["Literal['']|QuoteUpdateParamsTransferData"]
+ """
+ The data with which to automatically create a Transfer for each of the invoices.
+ """
+
+
+class QuoteUpdateParamsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Controls whether Stripe will automatically compute tax on the resulting invoices or subscriptions as well as the quote itself.
+ """
+ liability: NotRequired["QuoteUpdateParamsAutomaticTaxLiability"]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class QuoteUpdateParamsAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class QuoteUpdateParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class QuoteUpdateParamsInvoiceSettings(TypedDict):
+ days_until_due: NotRequired[int]
+ """
+ Number of days within which a customer must pay the invoice generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
+ """
+ issuer: NotRequired["QuoteUpdateParamsInvoiceSettingsIssuer"]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class QuoteUpdateParamsInvoiceSettingsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class QuoteUpdateParamsLineItem(TypedDict):
+ discounts: NotRequired[
+ "Literal['']|List[QuoteUpdateParamsLineItemDiscount]"
+ ]
+ """
+ The discounts applied to this line item.
+ """
+ id: NotRequired[str]
+ """
+ The ID of an existing line item on the quote.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required.
+ """
+ price_data: NotRequired["QuoteUpdateParamsLineItemPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: NotRequired[int]
+ """
+ The quantity of the line item.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the line item. When set, the `default_tax_rates` on the quote do not apply to this line item.
+ """
+
+
+class QuoteUpdateParamsLineItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class QuoteUpdateParamsLineItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ recurring: NotRequired["QuoteUpdateParamsLineItemPriceDataRecurring"]
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class QuoteUpdateParamsLineItemPriceDataRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
+
+
+class QuoteUpdateParamsSubscriptionData(TypedDict):
+ description: NotRequired["Literal['']|str"]
+ """
+ The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
+ """
+ effective_date: NotRequired[
+ "Literal['']|Literal['current_period_end']|int"
+ ]
+ """
+ When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. The `effective_date` is ignored if it is in the past when the quote is accepted.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
+ """
+ trial_period_days: NotRequired["Literal['']|int"]
+ """
+ Integer representing the number of trial period days before the customer is charged for the first time.
+ """
+
+
+class QuoteUpdateParamsTransferData(TypedDict):
+ amount: NotRequired[int]
+ """
+ The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
+ """
+ amount_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination. There must be at least 1 line item with a recurring price to use this field.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
diff --git a/stripe/params/_refund_cancel_params.py b/stripe/params/_refund_cancel_params.py
new file mode 100644
index 000000000..277b3294e
--- /dev/null
+++ b/stripe/params/_refund_cancel_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class RefundCancelParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_refund_create_params.py b/stripe/params/_refund_create_params.py
new file mode 100644
index 000000000..c8d7eac1b
--- /dev/null
+++ b/stripe/params/_refund_create_params.py
@@ -0,0 +1,57 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class RefundCreateParams(RequestOptions):
+ amount: NotRequired[int]
+ charge: NotRequired[str]
+ """
+ The identifier of the charge to refund.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ customer: NotRequired[str]
+ """
+ Customer whose customer balance to refund from.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ instructions_email: NotRequired[str]
+ """
+ For payment methods without native refund support (e.g., Konbini, PromptPay), use this email from the customer to receive refund instructions.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ origin: NotRequired[Literal["customer_balance"]]
+ """
+ Origin of the refund
+ """
+ payment_intent: NotRequired[str]
+ """
+ The identifier of the PaymentIntent to refund.
+ """
+ reason: NotRequired[
+ Literal["duplicate", "fraudulent", "requested_by_customer"]
+ ]
+ """
+ String indicating the reason for the refund. If set, possible values are `duplicate`, `fraudulent`, and `requested_by_customer`. If you believe the charge to be fraudulent, specifying `fraudulent` as the reason will add the associated card and email to your [block lists](https://stripe.com/docs/radar/lists), and will also help us improve our fraud detection algorithms.
+ """
+ refund_application_fee: NotRequired[bool]
+ """
+ Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.
+ """
+ reverse_transfer: NotRequired[bool]
+ """
+ Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount).
+
+ A transfer can be reversed only by the application that created the charge.
+ """
diff --git a/stripe/params/_refund_expire_params.py b/stripe/params/_refund_expire_params.py
new file mode 100644
index 000000000..ae2ce2cc8
--- /dev/null
+++ b/stripe/params/_refund_expire_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class RefundExpireParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_refund_list_params.py b/stripe/params/_refund_list_params.py
new file mode 100644
index 000000000..e1d8aa2b2
--- /dev/null
+++ b/stripe/params/_refund_list_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class RefundListParams(RequestOptions):
+ charge: NotRequired[str]
+ """
+ Only return refunds for the charge specified by this charge ID.
+ """
+ created: NotRequired["RefundListParamsCreated|int"]
+ """
+ Only return refunds that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ payment_intent: NotRequired[str]
+ """
+ Only return refunds for the PaymentIntent specified by this ID.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class RefundListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_refund_modify_params.py b/stripe/params/_refund_modify_params.py
new file mode 100644
index 000000000..86df6e4ff
--- /dev/null
+++ b/stripe/params/_refund_modify_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class RefundModifyParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_refund_retrieve_params.py b/stripe/params/_refund_retrieve_params.py
new file mode 100644
index 000000000..56741a7d1
--- /dev/null
+++ b/stripe/params/_refund_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class RefundRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_refund_update_params.py b/stripe/params/_refund_update_params.py
new file mode 100644
index 000000000..615d175a3
--- /dev/null
+++ b/stripe/params/_refund_update_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class RefundUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_review_approve_params.py b/stripe/params/_review_approve_params.py
new file mode 100644
index 000000000..c26e9f5b3
--- /dev/null
+++ b/stripe/params/_review_approve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ReviewApproveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_review_list_params.py b/stripe/params/_review_list_params.py
new file mode 100644
index 000000000..8590693df
--- /dev/null
+++ b/stripe/params/_review_list_params.py
@@ -0,0 +1,47 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ReviewListParams(RequestOptions):
+ created: NotRequired["ReviewListParamsCreated|int"]
+ """
+ Only return reviews that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class ReviewListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_review_retrieve_params.py b/stripe/params/_review_retrieve_params.py
new file mode 100644
index 000000000..7a1a3cabd
--- /dev/null
+++ b/stripe/params/_review_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ReviewRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_setup_attempt_list_params.py b/stripe/params/_setup_attempt_list_params.py
new file mode 100644
index 000000000..afd60a4c6
--- /dev/null
+++ b/stripe/params/_setup_attempt_list_params.py
@@ -0,0 +1,54 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class SetupAttemptListParams(RequestOptions):
+ created: NotRequired["SetupAttemptListParamsCreated|int"]
+ """
+ A filter on the list, based on the object `created` field. The value
+ can be a string with an integer Unix timestamp or a
+ dictionary with a number of different query options.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ setup_intent: str
+ """
+ Only return SetupAttempts created by the SetupIntent specified by
+ this ID.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class SetupAttemptListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_setup_intent_cancel_params.py b/stripe/params/_setup_intent_cancel_params.py
new file mode 100644
index 000000000..76c796898
--- /dev/null
+++ b/stripe/params/_setup_intent_cancel_params.py
@@ -0,0 +1,18 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class SetupIntentCancelParams(RequestOptions):
+ cancellation_reason: NotRequired[
+ Literal["abandoned", "duplicate", "requested_by_customer"]
+ ]
+ """
+ Reason for canceling this SetupIntent. Possible values are: `abandoned`, `requested_by_customer`, or `duplicate`
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_setup_intent_confirm_params.py b/stripe/params/_setup_intent_confirm_params.py
new file mode 100644
index 000000000..bb3a5b025
--- /dev/null
+++ b/stripe/params/_setup_intent_confirm_params.py
@@ -0,0 +1,1418 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SetupIntentConfirmParams(RequestOptions):
+ confirmation_token: NotRequired[str]
+ """
+ ID of the ConfirmationToken used to confirm this SetupIntent.
+
+ If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ mandate_data: NotRequired[
+ "Literal['']|SetupIntentConfirmParamsMandateData"
+ ]
+ payment_method: NotRequired[str]
+ """
+ ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.
+ """
+ payment_method_data: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodData"
+ ]
+ """
+ When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
+ value in the SetupIntent.
+ """
+ payment_method_options: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptions"
+ ]
+ """
+ Payment method-specific configuration for this SetupIntent.
+ """
+ return_url: NotRequired[str]
+ """
+ The URL to redirect your customer back to after they authenticate on the payment method's app or site.
+ If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
+ This parameter is only used for cards and other redirect-based payment methods.
+ """
+ use_stripe_sdk: NotRequired[bool]
+ """
+ Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
+ """
+
+
+class SetupIntentConfirmParamsMandateData(TypedDict):
+ customer_acceptance: NotRequired[
+ "SetupIntentConfirmParamsMandateDataCustomerAcceptance"
+ ]
+ """
+ This hash contains details about the customer acceptance of the Mandate.
+ """
+
+
+class SetupIntentConfirmParamsMandateDataCustomerAcceptance(TypedDict):
+ accepted_at: NotRequired[int]
+ """
+ The time at which the customer accepted the Mandate.
+ """
+ offline: NotRequired[
+ "SetupIntentConfirmParamsMandateDataCustomerAcceptanceOffline"
+ ]
+ """
+ If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
+ """
+ online: NotRequired[
+ "SetupIntentConfirmParamsMandateDataCustomerAcceptanceOnline"
+ ]
+ """
+ If this is a Mandate accepted online, this hash contains details about the online acceptance.
+ """
+ type: Literal["offline", "online"]
+ """
+ The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
+ """
+
+
+class SetupIntentConfirmParamsMandateDataCustomerAcceptanceOffline(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsMandateDataCustomerAcceptanceOnline(TypedDict):
+ ip_address: NotRequired[str]
+ """
+ The IP address from which the Mandate was accepted by the customer.
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the Mandate was accepted by the customer.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodData(TypedDict):
+ acss_debit: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataAcssDebit"
+ ]
+ """
+ If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
+ """
+ affirm: NotRequired["SetupIntentConfirmParamsPaymentMethodDataAffirm"]
+ """
+ If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
+ """
+ afterpay_clearpay: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataAfterpayClearpay"
+ ]
+ """
+ If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
+ """
+ alipay: NotRequired["SetupIntentConfirmParamsPaymentMethodDataAlipay"]
+ """
+ If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
+ """
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
+ """
+ alma: NotRequired["SetupIntentConfirmParamsPaymentMethodDataAlma"]
+ """
+ If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
+ """
+ amazon_pay: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataAmazonPay"
+ ]
+ """
+ If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
+ """
+ au_becs_debit: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataAuBecsDebit"
+ ]
+ """
+ If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
+ """
+ bacs_debit: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
+ """
+ bancontact: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataBancontact"
+ ]
+ """
+ If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
+ """
+ billie: NotRequired["SetupIntentConfirmParamsPaymentMethodDataBillie"]
+ """
+ If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
+ """
+ billing_details: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataBillingDetails"
+ ]
+ """
+ Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+ """
+ blik: NotRequired["SetupIntentConfirmParamsPaymentMethodDataBlik"]
+ """
+ If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
+ """
+ boleto: NotRequired["SetupIntentConfirmParamsPaymentMethodDataBoleto"]
+ """
+ If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
+ """
+ cashapp: NotRequired["SetupIntentConfirmParamsPaymentMethodDataCashapp"]
+ """
+ If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
+ """
+ crypto: NotRequired["SetupIntentConfirmParamsPaymentMethodDataCrypto"]
+ """
+ If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
+ """
+ customer_balance: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataCustomerBalance"
+ ]
+ """
+ If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
+ """
+ eps: NotRequired["SetupIntentConfirmParamsPaymentMethodDataEps"]
+ """
+ If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
+ """
+ fpx: NotRequired["SetupIntentConfirmParamsPaymentMethodDataFpx"]
+ """
+ If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
+ """
+ giropay: NotRequired["SetupIntentConfirmParamsPaymentMethodDataGiropay"]
+ """
+ If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
+ """
+ grabpay: NotRequired["SetupIntentConfirmParamsPaymentMethodDataGrabpay"]
+ """
+ If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
+ """
+ ideal: NotRequired["SetupIntentConfirmParamsPaymentMethodDataIdeal"]
+ """
+ If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
+ """
+ interac_present: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataInteracPresent"
+ ]
+ """
+ If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
+ """
+ kakao_pay: NotRequired["SetupIntentConfirmParamsPaymentMethodDataKakaoPay"]
+ """
+ If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
+ """
+ klarna: NotRequired["SetupIntentConfirmParamsPaymentMethodDataKlarna"]
+ """
+ If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
+ """
+ konbini: NotRequired["SetupIntentConfirmParamsPaymentMethodDataKonbini"]
+ """
+ If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
+ """
+ kr_card: NotRequired["SetupIntentConfirmParamsPaymentMethodDataKrCard"]
+ """
+ If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
+ """
+ link: NotRequired["SetupIntentConfirmParamsPaymentMethodDataLink"]
+ """
+ If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
+ """
+ mb_way: NotRequired["SetupIntentConfirmParamsPaymentMethodDataMbWay"]
+ """
+ If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ mobilepay: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataMobilepay"
+ ]
+ """
+ If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
+ """
+ multibanco: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataMultibanco"
+ ]
+ """
+ If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
+ """
+ naver_pay: NotRequired["SetupIntentConfirmParamsPaymentMethodDataNaverPay"]
+ """
+ If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
+ """
+ nz_bank_account: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataNzBankAccount"
+ ]
+ """
+ If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
+ """
+ oxxo: NotRequired["SetupIntentConfirmParamsPaymentMethodDataOxxo"]
+ """
+ If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
+ """
+ p24: NotRequired["SetupIntentConfirmParamsPaymentMethodDataP24"]
+ """
+ If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
+ """
+ pay_by_bank: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataPayByBank"
+ ]
+ """
+ If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
+ """
+ payco: NotRequired["SetupIntentConfirmParamsPaymentMethodDataPayco"]
+ """
+ If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
+ """
+ paynow: NotRequired["SetupIntentConfirmParamsPaymentMethodDataPaynow"]
+ """
+ If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
+ """
+ paypal: NotRequired["SetupIntentConfirmParamsPaymentMethodDataPaypal"]
+ """
+ If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
+ """
+ pix: NotRequired["SetupIntentConfirmParamsPaymentMethodDataPix"]
+ """
+ If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
+ """
+ promptpay: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataPromptpay"
+ ]
+ """
+ If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
+ """
+ radar_options: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataRadarOptions"
+ ]
+ """
+ Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
+ """
+ revolut_pay: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataRevolutPay"
+ ]
+ """
+ If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
+ """
+ samsung_pay: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataSamsungPay"
+ ]
+ """
+ If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
+ """
+ satispay: NotRequired["SetupIntentConfirmParamsPaymentMethodDataSatispay"]
+ """
+ If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
+ """
+ sepa_debit: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
+ """
+ sofort: NotRequired["SetupIntentConfirmParamsPaymentMethodDataSofort"]
+ """
+ If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
+ """
+ swish: NotRequired["SetupIntentConfirmParamsPaymentMethodDataSwish"]
+ """
+ If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
+ """
+ twint: NotRequired["SetupIntentConfirmParamsPaymentMethodDataTwint"]
+ """
+ If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
+ """
+ type: Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "link",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ """
+ The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
+ """
+ us_bank_account: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataUsBankAccount"
+ ]
+ """
+ If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
+ """
+ wechat_pay: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodDataWechatPay"
+ ]
+ """
+ If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
+ """
+ zip: NotRequired["SetupIntentConfirmParamsPaymentMethodDataZip"]
+ """
+ If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataAcssDebit(TypedDict):
+ account_number: str
+ """
+ Customer's bank account number.
+ """
+ institution_number: str
+ """
+ Institution number of the customer's bank.
+ """
+ transit_number: str
+ """
+ Transit number of the customer's bank.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataAffirm(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataAfterpayClearpay(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataAlipay(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataAlma(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataAmazonPay(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataAuBecsDebit(TypedDict):
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bsb_number: str
+ """
+ Bank-State-Branch number of the bank account.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataBacsDebit(TypedDict):
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account that the funds will be debited from.
+ """
+ sort_code: NotRequired[str]
+ """
+ Sort code of the bank account. (e.g., `10-20-30`)
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataBancontact(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataBillie(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataBillingDetails(TypedDict):
+ address: NotRequired[
+ "Literal['']|SetupIntentConfirmParamsPaymentMethodDataBillingDetailsAddress"
+ ]
+ """
+ Billing address.
+ """
+ email: NotRequired["Literal['']|str"]
+ """
+ Email address.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Full name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Billing phone number (including extension).
+ """
+ tax_id: NotRequired[str]
+ """
+ Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataBillingDetailsAddress(
+ TypedDict
+):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataBlik(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataBoleto(TypedDict):
+ tax_id: str
+ """
+ The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataCashapp(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataCrypto(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataCustomerBalance(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataEps(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "arzte_und_apotheker_bank",
+ "austrian_anadi_bank_ag",
+ "bank_austria",
+ "bankhaus_carl_spangler",
+ "bankhaus_schelhammer_und_schattera_ag",
+ "bawag_psk_ag",
+ "bks_bank_ag",
+ "brull_kallmus_bank_ag",
+ "btv_vier_lander_bank",
+ "capital_bank_grawe_gruppe_ag",
+ "deutsche_bank_ag",
+ "dolomitenbank",
+ "easybank_ag",
+ "erste_bank_und_sparkassen",
+ "hypo_alpeadriabank_international_ag",
+ "hypo_bank_burgenland_aktiengesellschaft",
+ "hypo_noe_lb_fur_niederosterreich_u_wien",
+ "hypo_oberosterreich_salzburg_steiermark",
+ "hypo_tirol_bank_ag",
+ "hypo_vorarlberg_bank_ag",
+ "marchfelder_bank",
+ "oberbank_ag",
+ "raiffeisen_bankengruppe_osterreich",
+ "schoellerbank_ag",
+ "sparda_bank_wien",
+ "volksbank_gruppe",
+ "volkskreditbank_ag",
+ "vr_bank_braunau",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataFpx(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type for FPX transaction
+ """
+ bank: Literal[
+ "affin_bank",
+ "agrobank",
+ "alliance_bank",
+ "ambank",
+ "bank_islam",
+ "bank_muamalat",
+ "bank_of_china",
+ "bank_rakyat",
+ "bsn",
+ "cimb",
+ "deutsche_bank",
+ "hong_leong_bank",
+ "hsbc",
+ "kfh",
+ "maybank2e",
+ "maybank2u",
+ "ocbc",
+ "pb_enterprise",
+ "public_bank",
+ "rhb",
+ "standard_chartered",
+ "uob",
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataGiropay(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataGrabpay(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataIdeal(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "abn_amro",
+ "asn_bank",
+ "bunq",
+ "buut",
+ "handelsbanken",
+ "ing",
+ "knab",
+ "moneyou",
+ "n26",
+ "nn",
+ "rabobank",
+ "regiobank",
+ "revolut",
+ "sns_bank",
+ "triodos_bank",
+ "van_lanschot",
+ "yoursafe",
+ ]
+ ]
+ """
+ The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataInteracPresent(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataKakaoPay(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataKlarna(TypedDict):
+ dob: NotRequired["SetupIntentConfirmParamsPaymentMethodDataKlarnaDob"]
+ """
+ Customer's date of birth
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataKlarnaDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataKonbini(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataKrCard(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataLink(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataMbWay(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataMobilepay(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataMultibanco(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataNaverPay(TypedDict):
+ funding: NotRequired[Literal["card", "points"]]
+ """
+ Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataNzBankAccount(TypedDict):
+ account_holder_name: NotRequired[str]
+ """
+ The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
+ """
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bank_code: str
+ """
+ The numeric code for the bank account's bank.
+ """
+ branch_code: str
+ """
+ The numeric code for the bank account's bank branch.
+ """
+ reference: NotRequired[str]
+ suffix: str
+ """
+ The suffix of the bank account number.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataOxxo(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataP24(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "alior_bank",
+ "bank_millennium",
+ "bank_nowy_bfg_sa",
+ "bank_pekao_sa",
+ "banki_spbdzielcze",
+ "blik",
+ "bnp_paribas",
+ "boz",
+ "citi_handlowy",
+ "credit_agricole",
+ "envelobank",
+ "etransfer_pocztowy24",
+ "getin_bank",
+ "ideabank",
+ "ing",
+ "inteligo",
+ "mbank_mtransfer",
+ "nest_przelew",
+ "noble_pay",
+ "pbac_z_ipko",
+ "plus_bank",
+ "santander_przelew24",
+ "tmobile_usbugi_bankowe",
+ "toyota_bank",
+ "velobank",
+ "volkswagen_bank",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataPayByBank(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataPayco(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataPaynow(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataPaypal(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataPix(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataPromptpay(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataRadarOptions(TypedDict):
+ session: NotRequired[str]
+ """
+ A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataRevolutPay(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataSamsungPay(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataSatispay(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataSepaDebit(TypedDict):
+ iban: str
+ """
+ IBAN of the bank account.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataSofort(TypedDict):
+ country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
+ """
+ Two-letter ISO code representing the country the bank account is located in.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataSwish(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataTwint(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataUsBankAccount(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type: individual or company.
+ """
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account.
+ """
+ account_type: NotRequired[Literal["checking", "savings"]]
+ """
+ Account type: checkings or savings. Defaults to checking if omitted.
+ """
+ financial_connections_account: NotRequired[str]
+ """
+ The ID of a Financial Connections Account to use as a payment method.
+ """
+ routing_number: NotRequired[str]
+ """
+ Routing number of the bank account.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodDataWechatPay(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodDataZip(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodOptions(TypedDict):
+ acss_debit: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsAcssDebit"
+ ]
+ """
+ If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
+ """
+ amazon_pay: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsAmazonPay"
+ ]
+ """
+ If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
+ """
+ bacs_debit: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
+ """
+ card: NotRequired["SetupIntentConfirmParamsPaymentMethodOptionsCard"]
+ """
+ Configuration for any card setup attempted on this SetupIntent.
+ """
+ card_present: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsCardPresent"
+ ]
+ """
+ If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
+ """
+ klarna: NotRequired["SetupIntentConfirmParamsPaymentMethodOptionsKlarna"]
+ """
+ If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method options.
+ """
+ link: NotRequired["SetupIntentConfirmParamsPaymentMethodOptionsLink"]
+ """
+ If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
+ """
+ paypal: NotRequired["SetupIntentConfirmParamsPaymentMethodOptionsPaypal"]
+ """
+ If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
+ """
+ sepa_debit: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
+ """
+ us_bank_account: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsAcssDebit(TypedDict):
+ currency: NotRequired[Literal["cad", "usd"]]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ mandate_options: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsAcssDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsAcssDebitMandateOptions(
+ TypedDict,
+):
+ custom_mandate_url: NotRequired["Literal['']|str"]
+ """
+ A URL for custom mandate text to render during confirmation step.
+ The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
+ or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
+ """
+ default_for: NotRequired[List[Literal["invoice", "subscription"]]]
+ """
+ List of Stripe products where this mandate can be selected automatically.
+ """
+ interval_description: NotRequired[str]
+ """
+ Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
+ """
+ payment_schedule: NotRequired[Literal["combined", "interval", "sporadic"]]
+ """
+ Payment schedule for the mandate.
+ """
+ transaction_type: NotRequired[Literal["business", "personal"]]
+ """
+ Transaction type of the mandate.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsAmazonPay(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsBacsDebit(TypedDict):
+ mandate_options: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsBacsDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsBacsDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsCard(TypedDict):
+ mandate_options: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsCardMandateOptions"
+ ]
+ """
+ Configuration options for setting up an eMandate for cards issued in India.
+ """
+ moto: NotRequired[bool]
+ """
+ When specified, this parameter signals that a card has been collected
+ as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
+ parameter can only be provided during confirmation.
+ """
+ network: NotRequired[
+ Literal[
+ "amex",
+ "cartes_bancaires",
+ "diners",
+ "discover",
+ "eftpos_au",
+ "girocard",
+ "interac",
+ "jcb",
+ "link",
+ "mastercard",
+ "unionpay",
+ "unknown",
+ "visa",
+ ]
+ ]
+ """
+ Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
+ """
+ request_three_d_secure: NotRequired[
+ Literal["any", "automatic", "challenge"]
+ ]
+ """
+ We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
+ """
+ three_d_secure: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsCardThreeDSecure"
+ ]
+ """
+ If 3D Secure authentication was performed with a third-party provider,
+ the authentication details to use for this setup.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsCardMandateOptions(
+ TypedDict
+):
+ amount: int
+ """
+ Amount to be charged for future payments.
+ """
+ amount_type: Literal["fixed", "maximum"]
+ """
+ One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
+ """
+ currency: str
+ """
+ Currency in which future payments will be charged. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ description: NotRequired[str]
+ """
+ A description of the mandate or subscription that is meant to be displayed to the customer.
+ """
+ end_date: NotRequired[int]
+ """
+ End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
+ """
+ interval: Literal["day", "month", "sporadic", "week", "year"]
+ """
+ Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
+ """
+ reference: str
+ """
+ Unique identifier for the mandate or subscription.
+ """
+ start_date: int
+ """
+ Start date of the mandate or subscription. Start date should not be lesser than yesterday.
+ """
+ supported_types: NotRequired[List[Literal["india"]]]
+ """
+ Specifies the type of mandates supported. Possible values are `india`.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
+ ares_trans_status: NotRequired[Literal["A", "C", "I", "N", "R", "U", "Y"]]
+ """
+ The `transStatus` returned from the card Issuer's ACS in the ARes.
+ """
+ cryptogram: NotRequired[str]
+ """
+ The cryptogram, also known as the "authentication value" (AAV, CAVV or
+ AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
+ (Most 3D Secure providers will return the base64-encoded version, which
+ is what you should specify here.)
+ """
+ electronic_commerce_indicator: NotRequired[
+ Literal["01", "02", "05", "06", "07"]
+ ]
+ """
+ The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
+ provider and indicates what degree of authentication was performed.
+ """
+ network_options: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
+ ]
+ """
+ Network specific 3DS fields. Network specific arguments require an
+ explicit card brand choice. The parameter `payment_method_options.card.network``
+ must be populated accordingly
+ """
+ requestor_challenge_indicator: NotRequired[str]
+ """
+ The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
+ AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
+ """
+ transaction_id: NotRequired[str]
+ """
+ For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
+ Transaction ID (dsTransID).
+ """
+ version: NotRequired[Literal["1.0.2", "2.1.0", "2.2.0"]]
+ """
+ The version of 3D Secure that was performed.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
+ TypedDict,
+):
+ cartes_bancaires: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
+ ]
+ """
+ Cartes Bancaires-specific 3DS fields.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
+ TypedDict,
+):
+ cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
+ """
+ The cryptogram calculation algorithm used by the card Issuer's ACS
+ to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
+ messageExtension: CB-AVALGO
+ """
+ cb_exemption: NotRequired[str]
+ """
+ The exemption indicator returned from Cartes Bancaires in the ARes.
+ message extension: CB-EXEMPTION; string (4 characters)
+ This is a 3 byte bitmap (low significant byte first and most significant
+ bit first) that has been Base64 encoded
+ """
+ cb_score: NotRequired[int]
+ """
+ The risk score returned from Cartes Bancaires in the ARes.
+ message extension: CB-SCORE; numeric value 0-99
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsCardPresent(TypedDict):
+ pass
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsKlarna(TypedDict):
+ currency: NotRequired[str]
+ """
+ The currency of the SetupIntent. Three letter ISO currency code.
+ """
+ on_demand: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsKlarnaOnDemand"
+ ]
+ """
+ On-demand details if setting up a payment method for on-demand payments.
+ """
+ preferred_locale: NotRequired[
+ Literal[
+ "cs-CZ",
+ "da-DK",
+ "de-AT",
+ "de-CH",
+ "de-DE",
+ "el-GR",
+ "en-AT",
+ "en-AU",
+ "en-BE",
+ "en-CA",
+ "en-CH",
+ "en-CZ",
+ "en-DE",
+ "en-DK",
+ "en-ES",
+ "en-FI",
+ "en-FR",
+ "en-GB",
+ "en-GR",
+ "en-IE",
+ "en-IT",
+ "en-NL",
+ "en-NO",
+ "en-NZ",
+ "en-PL",
+ "en-PT",
+ "en-RO",
+ "en-SE",
+ "en-US",
+ "es-ES",
+ "es-US",
+ "fi-FI",
+ "fr-BE",
+ "fr-CA",
+ "fr-CH",
+ "fr-FR",
+ "it-CH",
+ "it-IT",
+ "nb-NO",
+ "nl-BE",
+ "nl-NL",
+ "pl-PL",
+ "pt-PT",
+ "ro-RO",
+ "sv-FI",
+ "sv-SE",
+ ]
+ ]
+ """
+ Preferred language of the Klarna authorization page that the customer is redirected to
+ """
+ subscriptions: NotRequired[
+ "Literal['']|List[SetupIntentConfirmParamsPaymentMethodOptionsKlarnaSubscription]"
+ ]
+ """
+ Subscription details if setting up or charging a subscription
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
+ average_amount: NotRequired[int]
+ """
+ Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ maximum_amount: NotRequired[int]
+ """
+ The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ minimum_amount: NotRequired[int]
+ """
+ The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
+ """
+ Interval at which the customer is making purchases
+ """
+ purchase_interval_count: NotRequired[int]
+ """
+ The number of `purchase_interval` between charges
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsKlarnaSubscription(
+ TypedDict
+):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Unit of time between subscription charges.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
+ """
+ name: NotRequired[str]
+ """
+ Name for subscription.
+ """
+ next_billing: "SetupIntentConfirmParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
+ """
+ Describes the upcoming charge for this subscription.
+ """
+ reference: str
+ """
+ A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
+ TypedDict,
+):
+ amount: int
+ """
+ The amount of the next charge for the subscription.
+ """
+ date: str
+ """
+ The date of the next charge for the subscription in YYYY-MM-DD format.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsLink(TypedDict):
+ persistent_token: NotRequired[str]
+ """
+ [Deprecated] This is a legacy parameter that no longer has any function.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsPaypal(TypedDict):
+ billing_agreement_id: NotRequired[str]
+ """
+ The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsSepaDebit(TypedDict):
+ mandate_options: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsSepaDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsSepaDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsUsBankAccount(TypedDict):
+ financial_connections: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
+ ]
+ """
+ Additional fields for Financial Connections Session creation
+ """
+ mandate_options: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsUsBankAccountMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ networks: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsUsBankAccountNetworks"
+ ]
+ """
+ Additional fields for network related functions
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
+ TypedDict,
+):
+ filters: NotRequired[
+ "SetupIntentConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
+ ]
+ """
+ Provide filters for the linked accounts that the customer can select for the payment method.
+ """
+ permissions: NotRequired[
+ List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ ]
+ """
+ The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+ return_url: NotRequired[str]
+ """
+ For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
+ TypedDict,
+):
+ account_subcategories: NotRequired[List[Literal["checking", "savings"]]]
+ """
+ The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsUsBankAccountMandateOptions(
+ TypedDict,
+):
+ collection_method: NotRequired["Literal['']|Literal['paper']"]
+ """
+ The method used to collect offline mandate customer acceptance.
+ """
+
+
+class SetupIntentConfirmParamsPaymentMethodOptionsUsBankAccountNetworks(
+ TypedDict,
+):
+ requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
+ """
+ Triggers validations to run across the selected networks
+ """
diff --git a/stripe/params/_setup_intent_create_params.py b/stripe/params/_setup_intent_create_params.py
new file mode 100644
index 000000000..0f269a43b
--- /dev/null
+++ b/stripe/params/_setup_intent_create_params.py
@@ -0,0 +1,1487 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SetupIntentCreateParams(RequestOptions):
+ attach_to_self: NotRequired[bool]
+ """
+ If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
+
+ It can only be used for this Stripe Account's own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
+ """
+ automatic_payment_methods: NotRequired[
+ "SetupIntentCreateParamsAutomaticPaymentMethods"
+ ]
+ """
+ When you enable this parameter, this SetupIntent accepts payment methods that you enable in the Dashboard and that are compatible with its other parameters.
+ """
+ confirm: NotRequired[bool]
+ """
+ Set to `true` to attempt to confirm this SetupIntent immediately. This parameter defaults to `false`. If a card is the attached payment method, you can provide a `return_url` in case further authentication is necessary.
+ """
+ confirmation_token: NotRequired[str]
+ """
+ ID of the ConfirmationToken used to confirm this SetupIntent.
+
+ If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
+ """
+ customer: NotRequired[str]
+ """
+ ID of the Customer this SetupIntent belongs to, if one exists.
+
+ If present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ flow_directions: NotRequired[List[Literal["inbound", "outbound"]]]
+ """
+ Indicates the directions of money movement for which this payment method is intended to be used.
+
+ Include `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.
+ """
+ mandate_data: NotRequired["Literal['']|SetupIntentCreateParamsMandateData"]
+ """
+ This hash contains details about the mandate to create. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/setup_intents/create#create_setup_intent-confirm).
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ on_behalf_of: NotRequired[str]
+ """
+ The Stripe account ID created for this SetupIntent.
+ """
+ payment_method: NotRequired[str]
+ """
+ ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.
+ """
+ payment_method_configuration: NotRequired[str]
+ """
+ The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this SetupIntent.
+ """
+ payment_method_data: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodData"
+ ]
+ """
+ When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
+ value in the SetupIntent.
+ """
+ payment_method_options: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptions"
+ ]
+ """
+ Payment method-specific configuration for this SetupIntent.
+ """
+ payment_method_types: NotRequired[List[str]]
+ """
+ The list of payment method types (for example, card) that this SetupIntent can use. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
+ """
+ return_url: NotRequired[str]
+ """
+ The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. To redirect to a mobile application, you can alternatively supply an application URI scheme. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/setup_intents/create#create_setup_intent-confirm).
+ """
+ single_use: NotRequired["SetupIntentCreateParamsSingleUse"]
+ """
+ If you populate this hash, this SetupIntent generates a `single_use` mandate after successful completion.
+
+ Single-use mandates are only valid for the following payment methods: `acss_debit`, `alipay`, `au_becs_debit`, `bacs_debit`, `bancontact`, `boleto`, `ideal`, `link`, `sepa_debit`, and `us_bank_account`.
+ """
+ usage: NotRequired[Literal["off_session", "on_session"]]
+ """
+ Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`.
+ """
+ use_stripe_sdk: NotRequired[bool]
+ """
+ Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
+ """
+
+
+class SetupIntentCreateParamsAutomaticPaymentMethods(TypedDict):
+ allow_redirects: NotRequired[Literal["always", "never"]]
+ """
+ Controls whether this SetupIntent will accept redirect-based payment methods.
+
+ Redirect-based payment methods may require your customer to be redirected to a payment method's app or site for authentication or additional steps. To [confirm](https://stripe.com/docs/api/setup_intents/confirm) this SetupIntent, you may be required to provide a `return_url` to redirect customers back to your site after they authenticate or complete the setup.
+ """
+ enabled: bool
+ """
+ Whether this feature is enabled.
+ """
+
+
+class SetupIntentCreateParamsMandateData(TypedDict):
+ customer_acceptance: "SetupIntentCreateParamsMandateDataCustomerAcceptance"
+ """
+ This hash contains details about the customer acceptance of the Mandate.
+ """
+
+
+class SetupIntentCreateParamsMandateDataCustomerAcceptance(TypedDict):
+ accepted_at: NotRequired[int]
+ """
+ The time at which the customer accepted the Mandate.
+ """
+ offline: NotRequired[
+ "SetupIntentCreateParamsMandateDataCustomerAcceptanceOffline"
+ ]
+ """
+ If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
+ """
+ online: NotRequired[
+ "SetupIntentCreateParamsMandateDataCustomerAcceptanceOnline"
+ ]
+ """
+ If this is a Mandate accepted online, this hash contains details about the online acceptance.
+ """
+ type: Literal["offline", "online"]
+ """
+ The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
+ """
+
+
+class SetupIntentCreateParamsMandateDataCustomerAcceptanceOffline(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsMandateDataCustomerAcceptanceOnline(TypedDict):
+ ip_address: str
+ """
+ The IP address from which the Mandate was accepted by the customer.
+ """
+ user_agent: str
+ """
+ The user agent of the browser from which the Mandate was accepted by the customer.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodData(TypedDict):
+ acss_debit: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataAcssDebit"
+ ]
+ """
+ If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
+ """
+ affirm: NotRequired["SetupIntentCreateParamsPaymentMethodDataAffirm"]
+ """
+ If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
+ """
+ afterpay_clearpay: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataAfterpayClearpay"
+ ]
+ """
+ If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
+ """
+ alipay: NotRequired["SetupIntentCreateParamsPaymentMethodDataAlipay"]
+ """
+ If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
+ """
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
+ """
+ alma: NotRequired["SetupIntentCreateParamsPaymentMethodDataAlma"]
+ """
+ If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
+ """
+ amazon_pay: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataAmazonPay"
+ ]
+ """
+ If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
+ """
+ au_becs_debit: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataAuBecsDebit"
+ ]
+ """
+ If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
+ """
+ bacs_debit: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
+ """
+ bancontact: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataBancontact"
+ ]
+ """
+ If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
+ """
+ billie: NotRequired["SetupIntentCreateParamsPaymentMethodDataBillie"]
+ """
+ If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
+ """
+ billing_details: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataBillingDetails"
+ ]
+ """
+ Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+ """
+ blik: NotRequired["SetupIntentCreateParamsPaymentMethodDataBlik"]
+ """
+ If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
+ """
+ boleto: NotRequired["SetupIntentCreateParamsPaymentMethodDataBoleto"]
+ """
+ If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
+ """
+ cashapp: NotRequired["SetupIntentCreateParamsPaymentMethodDataCashapp"]
+ """
+ If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
+ """
+ crypto: NotRequired["SetupIntentCreateParamsPaymentMethodDataCrypto"]
+ """
+ If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
+ """
+ customer_balance: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataCustomerBalance"
+ ]
+ """
+ If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
+ """
+ eps: NotRequired["SetupIntentCreateParamsPaymentMethodDataEps"]
+ """
+ If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
+ """
+ fpx: NotRequired["SetupIntentCreateParamsPaymentMethodDataFpx"]
+ """
+ If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
+ """
+ giropay: NotRequired["SetupIntentCreateParamsPaymentMethodDataGiropay"]
+ """
+ If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
+ """
+ grabpay: NotRequired["SetupIntentCreateParamsPaymentMethodDataGrabpay"]
+ """
+ If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
+ """
+ ideal: NotRequired["SetupIntentCreateParamsPaymentMethodDataIdeal"]
+ """
+ If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
+ """
+ interac_present: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataInteracPresent"
+ ]
+ """
+ If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
+ """
+ kakao_pay: NotRequired["SetupIntentCreateParamsPaymentMethodDataKakaoPay"]
+ """
+ If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
+ """
+ klarna: NotRequired["SetupIntentCreateParamsPaymentMethodDataKlarna"]
+ """
+ If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
+ """
+ konbini: NotRequired["SetupIntentCreateParamsPaymentMethodDataKonbini"]
+ """
+ If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
+ """
+ kr_card: NotRequired["SetupIntentCreateParamsPaymentMethodDataKrCard"]
+ """
+ If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
+ """
+ link: NotRequired["SetupIntentCreateParamsPaymentMethodDataLink"]
+ """
+ If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
+ """
+ mb_way: NotRequired["SetupIntentCreateParamsPaymentMethodDataMbWay"]
+ """
+ If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ mobilepay: NotRequired["SetupIntentCreateParamsPaymentMethodDataMobilepay"]
+ """
+ If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
+ """
+ multibanco: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataMultibanco"
+ ]
+ """
+ If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
+ """
+ naver_pay: NotRequired["SetupIntentCreateParamsPaymentMethodDataNaverPay"]
+ """
+ If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
+ """
+ nz_bank_account: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataNzBankAccount"
+ ]
+ """
+ If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
+ """
+ oxxo: NotRequired["SetupIntentCreateParamsPaymentMethodDataOxxo"]
+ """
+ If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
+ """
+ p24: NotRequired["SetupIntentCreateParamsPaymentMethodDataP24"]
+ """
+ If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
+ """
+ pay_by_bank: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataPayByBank"
+ ]
+ """
+ If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
+ """
+ payco: NotRequired["SetupIntentCreateParamsPaymentMethodDataPayco"]
+ """
+ If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
+ """
+ paynow: NotRequired["SetupIntentCreateParamsPaymentMethodDataPaynow"]
+ """
+ If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
+ """
+ paypal: NotRequired["SetupIntentCreateParamsPaymentMethodDataPaypal"]
+ """
+ If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
+ """
+ pix: NotRequired["SetupIntentCreateParamsPaymentMethodDataPix"]
+ """
+ If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
+ """
+ promptpay: NotRequired["SetupIntentCreateParamsPaymentMethodDataPromptpay"]
+ """
+ If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
+ """
+ radar_options: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataRadarOptions"
+ ]
+ """
+ Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
+ """
+ revolut_pay: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataRevolutPay"
+ ]
+ """
+ If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
+ """
+ samsung_pay: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataSamsungPay"
+ ]
+ """
+ If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
+ """
+ satispay: NotRequired["SetupIntentCreateParamsPaymentMethodDataSatispay"]
+ """
+ If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
+ """
+ sepa_debit: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
+ """
+ sofort: NotRequired["SetupIntentCreateParamsPaymentMethodDataSofort"]
+ """
+ If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
+ """
+ swish: NotRequired["SetupIntentCreateParamsPaymentMethodDataSwish"]
+ """
+ If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
+ """
+ twint: NotRequired["SetupIntentCreateParamsPaymentMethodDataTwint"]
+ """
+ If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
+ """
+ type: Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "link",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ """
+ The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
+ """
+ us_bank_account: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataUsBankAccount"
+ ]
+ """
+ If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
+ """
+ wechat_pay: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodDataWechatPay"
+ ]
+ """
+ If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
+ """
+ zip: NotRequired["SetupIntentCreateParamsPaymentMethodDataZip"]
+ """
+ If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataAcssDebit(TypedDict):
+ account_number: str
+ """
+ Customer's bank account number.
+ """
+ institution_number: str
+ """
+ Institution number of the customer's bank.
+ """
+ transit_number: str
+ """
+ Transit number of the customer's bank.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataAffirm(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataAfterpayClearpay(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataAlipay(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataAlma(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataAmazonPay(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataAuBecsDebit(TypedDict):
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bsb_number: str
+ """
+ Bank-State-Branch number of the bank account.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataBacsDebit(TypedDict):
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account that the funds will be debited from.
+ """
+ sort_code: NotRequired[str]
+ """
+ Sort code of the bank account. (e.g., `10-20-30`)
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataBancontact(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataBillie(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataBillingDetails(TypedDict):
+ address: NotRequired[
+ "Literal['']|SetupIntentCreateParamsPaymentMethodDataBillingDetailsAddress"
+ ]
+ """
+ Billing address.
+ """
+ email: NotRequired["Literal['']|str"]
+ """
+ Email address.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Full name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Billing phone number (including extension).
+ """
+ tax_id: NotRequired[str]
+ """
+ Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataBlik(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataBoleto(TypedDict):
+ tax_id: str
+ """
+ The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataCashapp(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataCrypto(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataCustomerBalance(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataEps(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "arzte_und_apotheker_bank",
+ "austrian_anadi_bank_ag",
+ "bank_austria",
+ "bankhaus_carl_spangler",
+ "bankhaus_schelhammer_und_schattera_ag",
+ "bawag_psk_ag",
+ "bks_bank_ag",
+ "brull_kallmus_bank_ag",
+ "btv_vier_lander_bank",
+ "capital_bank_grawe_gruppe_ag",
+ "deutsche_bank_ag",
+ "dolomitenbank",
+ "easybank_ag",
+ "erste_bank_und_sparkassen",
+ "hypo_alpeadriabank_international_ag",
+ "hypo_bank_burgenland_aktiengesellschaft",
+ "hypo_noe_lb_fur_niederosterreich_u_wien",
+ "hypo_oberosterreich_salzburg_steiermark",
+ "hypo_tirol_bank_ag",
+ "hypo_vorarlberg_bank_ag",
+ "marchfelder_bank",
+ "oberbank_ag",
+ "raiffeisen_bankengruppe_osterreich",
+ "schoellerbank_ag",
+ "sparda_bank_wien",
+ "volksbank_gruppe",
+ "volkskreditbank_ag",
+ "vr_bank_braunau",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataFpx(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type for FPX transaction
+ """
+ bank: Literal[
+ "affin_bank",
+ "agrobank",
+ "alliance_bank",
+ "ambank",
+ "bank_islam",
+ "bank_muamalat",
+ "bank_of_china",
+ "bank_rakyat",
+ "bsn",
+ "cimb",
+ "deutsche_bank",
+ "hong_leong_bank",
+ "hsbc",
+ "kfh",
+ "maybank2e",
+ "maybank2u",
+ "ocbc",
+ "pb_enterprise",
+ "public_bank",
+ "rhb",
+ "standard_chartered",
+ "uob",
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataGiropay(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataGrabpay(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataIdeal(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "abn_amro",
+ "asn_bank",
+ "bunq",
+ "buut",
+ "handelsbanken",
+ "ing",
+ "knab",
+ "moneyou",
+ "n26",
+ "nn",
+ "rabobank",
+ "regiobank",
+ "revolut",
+ "sns_bank",
+ "triodos_bank",
+ "van_lanschot",
+ "yoursafe",
+ ]
+ ]
+ """
+ The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataInteracPresent(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataKakaoPay(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataKlarna(TypedDict):
+ dob: NotRequired["SetupIntentCreateParamsPaymentMethodDataKlarnaDob"]
+ """
+ Customer's date of birth
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataKlarnaDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataKonbini(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataKrCard(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataLink(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataMbWay(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataMobilepay(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataMultibanco(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataNaverPay(TypedDict):
+ funding: NotRequired[Literal["card", "points"]]
+ """
+ Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataNzBankAccount(TypedDict):
+ account_holder_name: NotRequired[str]
+ """
+ The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
+ """
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bank_code: str
+ """
+ The numeric code for the bank account's bank.
+ """
+ branch_code: str
+ """
+ The numeric code for the bank account's bank branch.
+ """
+ reference: NotRequired[str]
+ suffix: str
+ """
+ The suffix of the bank account number.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataOxxo(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataP24(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "alior_bank",
+ "bank_millennium",
+ "bank_nowy_bfg_sa",
+ "bank_pekao_sa",
+ "banki_spbdzielcze",
+ "blik",
+ "bnp_paribas",
+ "boz",
+ "citi_handlowy",
+ "credit_agricole",
+ "envelobank",
+ "etransfer_pocztowy24",
+ "getin_bank",
+ "ideabank",
+ "ing",
+ "inteligo",
+ "mbank_mtransfer",
+ "nest_przelew",
+ "noble_pay",
+ "pbac_z_ipko",
+ "plus_bank",
+ "santander_przelew24",
+ "tmobile_usbugi_bankowe",
+ "toyota_bank",
+ "velobank",
+ "volkswagen_bank",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataPayByBank(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataPayco(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataPaynow(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataPaypal(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataPix(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataPromptpay(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataRadarOptions(TypedDict):
+ session: NotRequired[str]
+ """
+ A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataRevolutPay(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataSamsungPay(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataSatispay(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataSepaDebit(TypedDict):
+ iban: str
+ """
+ IBAN of the bank account.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataSofort(TypedDict):
+ country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
+ """
+ Two-letter ISO code representing the country the bank account is located in.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataSwish(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataTwint(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataUsBankAccount(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type: individual or company.
+ """
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account.
+ """
+ account_type: NotRequired[Literal["checking", "savings"]]
+ """
+ Account type: checkings or savings. Defaults to checking if omitted.
+ """
+ financial_connections_account: NotRequired[str]
+ """
+ The ID of a Financial Connections Account to use as a payment method.
+ """
+ routing_number: NotRequired[str]
+ """
+ Routing number of the bank account.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodDataWechatPay(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodDataZip(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodOptions(TypedDict):
+ acss_debit: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsAcssDebit"
+ ]
+ """
+ If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
+ """
+ amazon_pay: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsAmazonPay"
+ ]
+ """
+ If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
+ """
+ bacs_debit: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
+ """
+ card: NotRequired["SetupIntentCreateParamsPaymentMethodOptionsCard"]
+ """
+ Configuration for any card setup attempted on this SetupIntent.
+ """
+ card_present: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsCardPresent"
+ ]
+ """
+ If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
+ """
+ klarna: NotRequired["SetupIntentCreateParamsPaymentMethodOptionsKlarna"]
+ """
+ If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method options.
+ """
+ link: NotRequired["SetupIntentCreateParamsPaymentMethodOptionsLink"]
+ """
+ If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
+ """
+ paypal: NotRequired["SetupIntentCreateParamsPaymentMethodOptionsPaypal"]
+ """
+ If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
+ """
+ sepa_debit: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
+ """
+ us_bank_account: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsAcssDebit(TypedDict):
+ currency: NotRequired[Literal["cad", "usd"]]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ mandate_options: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsAcssDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsAcssDebitMandateOptions(
+ TypedDict,
+):
+ custom_mandate_url: NotRequired["Literal['']|str"]
+ """
+ A URL for custom mandate text to render during confirmation step.
+ The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
+ or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
+ """
+ default_for: NotRequired[List[Literal["invoice", "subscription"]]]
+ """
+ List of Stripe products where this mandate can be selected automatically.
+ """
+ interval_description: NotRequired[str]
+ """
+ Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
+ """
+ payment_schedule: NotRequired[Literal["combined", "interval", "sporadic"]]
+ """
+ Payment schedule for the mandate.
+ """
+ transaction_type: NotRequired[Literal["business", "personal"]]
+ """
+ Transaction type of the mandate.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsAmazonPay(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsBacsDebit(TypedDict):
+ mandate_options: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsBacsDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsBacsDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsCard(TypedDict):
+ mandate_options: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsCardMandateOptions"
+ ]
+ """
+ Configuration options for setting up an eMandate for cards issued in India.
+ """
+ moto: NotRequired[bool]
+ """
+ When specified, this parameter signals that a card has been collected
+ as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
+ parameter can only be provided during confirmation.
+ """
+ network: NotRequired[
+ Literal[
+ "amex",
+ "cartes_bancaires",
+ "diners",
+ "discover",
+ "eftpos_au",
+ "girocard",
+ "interac",
+ "jcb",
+ "link",
+ "mastercard",
+ "unionpay",
+ "unknown",
+ "visa",
+ ]
+ ]
+ """
+ Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
+ """
+ request_three_d_secure: NotRequired[
+ Literal["any", "automatic", "challenge"]
+ ]
+ """
+ We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
+ """
+ three_d_secure: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsCardThreeDSecure"
+ ]
+ """
+ If 3D Secure authentication was performed with a third-party provider,
+ the authentication details to use for this setup.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsCardMandateOptions(TypedDict):
+ amount: int
+ """
+ Amount to be charged for future payments.
+ """
+ amount_type: Literal["fixed", "maximum"]
+ """
+ One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
+ """
+ currency: str
+ """
+ Currency in which future payments will be charged. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ description: NotRequired[str]
+ """
+ A description of the mandate or subscription that is meant to be displayed to the customer.
+ """
+ end_date: NotRequired[int]
+ """
+ End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
+ """
+ interval: Literal["day", "month", "sporadic", "week", "year"]
+ """
+ Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
+ """
+ reference: str
+ """
+ Unique identifier for the mandate or subscription.
+ """
+ start_date: int
+ """
+ Start date of the mandate or subscription. Start date should not be lesser than yesterday.
+ """
+ supported_types: NotRequired[List[Literal["india"]]]
+ """
+ Specifies the type of mandates supported. Possible values are `india`.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
+ ares_trans_status: NotRequired[Literal["A", "C", "I", "N", "R", "U", "Y"]]
+ """
+ The `transStatus` returned from the card Issuer's ACS in the ARes.
+ """
+ cryptogram: NotRequired[str]
+ """
+ The cryptogram, also known as the "authentication value" (AAV, CAVV or
+ AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
+ (Most 3D Secure providers will return the base64-encoded version, which
+ is what you should specify here.)
+ """
+ electronic_commerce_indicator: NotRequired[
+ Literal["01", "02", "05", "06", "07"]
+ ]
+ """
+ The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
+ provider and indicates what degree of authentication was performed.
+ """
+ network_options: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
+ ]
+ """
+ Network specific 3DS fields. Network specific arguments require an
+ explicit card brand choice. The parameter `payment_method_options.card.network``
+ must be populated accordingly
+ """
+ requestor_challenge_indicator: NotRequired[str]
+ """
+ The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
+ AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
+ """
+ transaction_id: NotRequired[str]
+ """
+ For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
+ Transaction ID (dsTransID).
+ """
+ version: NotRequired[Literal["1.0.2", "2.1.0", "2.2.0"]]
+ """
+ The version of 3D Secure that was performed.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
+ TypedDict,
+):
+ cartes_bancaires: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
+ ]
+ """
+ Cartes Bancaires-specific 3DS fields.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
+ TypedDict,
+):
+ cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
+ """
+ The cryptogram calculation algorithm used by the card Issuer's ACS
+ to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
+ messageExtension: CB-AVALGO
+ """
+ cb_exemption: NotRequired[str]
+ """
+ The exemption indicator returned from Cartes Bancaires in the ARes.
+ message extension: CB-EXEMPTION; string (4 characters)
+ This is a 3 byte bitmap (low significant byte first and most significant
+ bit first) that has been Base64 encoded
+ """
+ cb_score: NotRequired[int]
+ """
+ The risk score returned from Cartes Bancaires in the ARes.
+ message extension: CB-SCORE; numeric value 0-99
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsCardPresent(TypedDict):
+ pass
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsKlarna(TypedDict):
+ currency: NotRequired[str]
+ """
+ The currency of the SetupIntent. Three letter ISO currency code.
+ """
+ on_demand: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsKlarnaOnDemand"
+ ]
+ """
+ On-demand details if setting up a payment method for on-demand payments.
+ """
+ preferred_locale: NotRequired[
+ Literal[
+ "cs-CZ",
+ "da-DK",
+ "de-AT",
+ "de-CH",
+ "de-DE",
+ "el-GR",
+ "en-AT",
+ "en-AU",
+ "en-BE",
+ "en-CA",
+ "en-CH",
+ "en-CZ",
+ "en-DE",
+ "en-DK",
+ "en-ES",
+ "en-FI",
+ "en-FR",
+ "en-GB",
+ "en-GR",
+ "en-IE",
+ "en-IT",
+ "en-NL",
+ "en-NO",
+ "en-NZ",
+ "en-PL",
+ "en-PT",
+ "en-RO",
+ "en-SE",
+ "en-US",
+ "es-ES",
+ "es-US",
+ "fi-FI",
+ "fr-BE",
+ "fr-CA",
+ "fr-CH",
+ "fr-FR",
+ "it-CH",
+ "it-IT",
+ "nb-NO",
+ "nl-BE",
+ "nl-NL",
+ "pl-PL",
+ "pt-PT",
+ "ro-RO",
+ "sv-FI",
+ "sv-SE",
+ ]
+ ]
+ """
+ Preferred language of the Klarna authorization page that the customer is redirected to
+ """
+ subscriptions: NotRequired[
+ "Literal['']|List[SetupIntentCreateParamsPaymentMethodOptionsKlarnaSubscription]"
+ ]
+ """
+ Subscription details if setting up or charging a subscription
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
+ average_amount: NotRequired[int]
+ """
+ Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ maximum_amount: NotRequired[int]
+ """
+ The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ minimum_amount: NotRequired[int]
+ """
+ The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
+ """
+ Interval at which the customer is making purchases
+ """
+ purchase_interval_count: NotRequired[int]
+ """
+ The number of `purchase_interval` between charges
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Unit of time between subscription charges.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
+ """
+ name: NotRequired[str]
+ """
+ Name for subscription.
+ """
+ next_billing: "SetupIntentCreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
+ """
+ Describes the upcoming charge for this subscription.
+ """
+ reference: str
+ """
+ A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
+ TypedDict,
+):
+ amount: int
+ """
+ The amount of the next charge for the subscription.
+ """
+ date: str
+ """
+ The date of the next charge for the subscription in YYYY-MM-DD format.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsLink(TypedDict):
+ persistent_token: NotRequired[str]
+ """
+ [Deprecated] This is a legacy parameter that no longer has any function.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsPaypal(TypedDict):
+ billing_agreement_id: NotRequired[str]
+ """
+ The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsSepaDebit(TypedDict):
+ mandate_options: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsSepaDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsSepaDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsUsBankAccount(TypedDict):
+ financial_connections: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
+ ]
+ """
+ Additional fields for Financial Connections Session creation
+ """
+ mandate_options: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsUsBankAccountMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ networks: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsUsBankAccountNetworks"
+ ]
+ """
+ Additional fields for network related functions
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
+ TypedDict,
+):
+ filters: NotRequired[
+ "SetupIntentCreateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
+ ]
+ """
+ Provide filters for the linked accounts that the customer can select for the payment method.
+ """
+ permissions: NotRequired[
+ List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ ]
+ """
+ The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+ return_url: NotRequired[str]
+ """
+ For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
+ TypedDict,
+):
+ account_subcategories: NotRequired[List[Literal["checking", "savings"]]]
+ """
+ The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsUsBankAccountMandateOptions(
+ TypedDict,
+):
+ collection_method: NotRequired["Literal['']|Literal['paper']"]
+ """
+ The method used to collect offline mandate customer acceptance.
+ """
+
+
+class SetupIntentCreateParamsPaymentMethodOptionsUsBankAccountNetworks(
+ TypedDict,
+):
+ requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
+ """
+ Triggers validations to run across the selected networks
+ """
+
+
+class SetupIntentCreateParamsSingleUse(TypedDict):
+ amount: int
+ """
+ Amount the customer is granting permission to collect later. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
diff --git a/stripe/params/_setup_intent_list_params.py b/stripe/params/_setup_intent_list_params.py
new file mode 100644
index 000000000..4363dd605
--- /dev/null
+++ b/stripe/params/_setup_intent_list_params.py
@@ -0,0 +1,61 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class SetupIntentListParams(RequestOptions):
+ attach_to_self: NotRequired[bool]
+ """
+ If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
+
+ It can only be used for this Stripe Account's own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
+ """
+ created: NotRequired["SetupIntentListParamsCreated|int"]
+ """
+ A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
+ """
+ customer: NotRequired[str]
+ """
+ Only return SetupIntents for the customer specified by this customer ID.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ payment_method: NotRequired[str]
+ """
+ Only return SetupIntents that associate with the specified payment method.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class SetupIntentListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_setup_intent_modify_params.py b/stripe/params/_setup_intent_modify_params.py
new file mode 100644
index 000000000..40720f186
--- /dev/null
+++ b/stripe/params/_setup_intent_modify_params.py
@@ -0,0 +1,1376 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SetupIntentModifyParams(RequestOptions):
+ attach_to_self: NotRequired[bool]
+ """
+ If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
+
+ It can only be used for this Stripe Account's own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
+ """
+ customer: NotRequired[str]
+ """
+ ID of the Customer this SetupIntent belongs to, if one exists.
+
+ If present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ flow_directions: NotRequired[List[Literal["inbound", "outbound"]]]
+ """
+ Indicates the directions of money movement for which this payment method is intended to be used.
+
+ Include `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ payment_method: NotRequired[str]
+ """
+ ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent. To unset this field to null, pass in an empty string.
+ """
+ payment_method_configuration: NotRequired[str]
+ """
+ The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this SetupIntent.
+ """
+ payment_method_data: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodData"
+ ]
+ """
+ When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
+ value in the SetupIntent.
+ """
+ payment_method_options: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptions"
+ ]
+ """
+ Payment method-specific configuration for this SetupIntent.
+ """
+ payment_method_types: NotRequired[List[str]]
+ """
+ The list of payment method types (for example, card) that this SetupIntent can set up. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodData(TypedDict):
+ acss_debit: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataAcssDebit"
+ ]
+ """
+ If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
+ """
+ affirm: NotRequired["SetupIntentModifyParamsPaymentMethodDataAffirm"]
+ """
+ If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
+ """
+ afterpay_clearpay: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataAfterpayClearpay"
+ ]
+ """
+ If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
+ """
+ alipay: NotRequired["SetupIntentModifyParamsPaymentMethodDataAlipay"]
+ """
+ If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
+ """
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
+ """
+ alma: NotRequired["SetupIntentModifyParamsPaymentMethodDataAlma"]
+ """
+ If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
+ """
+ amazon_pay: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataAmazonPay"
+ ]
+ """
+ If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
+ """
+ au_becs_debit: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataAuBecsDebit"
+ ]
+ """
+ If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
+ """
+ bacs_debit: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
+ """
+ bancontact: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataBancontact"
+ ]
+ """
+ If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
+ """
+ billie: NotRequired["SetupIntentModifyParamsPaymentMethodDataBillie"]
+ """
+ If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
+ """
+ billing_details: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataBillingDetails"
+ ]
+ """
+ Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+ """
+ blik: NotRequired["SetupIntentModifyParamsPaymentMethodDataBlik"]
+ """
+ If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
+ """
+ boleto: NotRequired["SetupIntentModifyParamsPaymentMethodDataBoleto"]
+ """
+ If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
+ """
+ cashapp: NotRequired["SetupIntentModifyParamsPaymentMethodDataCashapp"]
+ """
+ If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
+ """
+ crypto: NotRequired["SetupIntentModifyParamsPaymentMethodDataCrypto"]
+ """
+ If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
+ """
+ customer_balance: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataCustomerBalance"
+ ]
+ """
+ If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
+ """
+ eps: NotRequired["SetupIntentModifyParamsPaymentMethodDataEps"]
+ """
+ If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
+ """
+ fpx: NotRequired["SetupIntentModifyParamsPaymentMethodDataFpx"]
+ """
+ If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
+ """
+ giropay: NotRequired["SetupIntentModifyParamsPaymentMethodDataGiropay"]
+ """
+ If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
+ """
+ grabpay: NotRequired["SetupIntentModifyParamsPaymentMethodDataGrabpay"]
+ """
+ If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
+ """
+ ideal: NotRequired["SetupIntentModifyParamsPaymentMethodDataIdeal"]
+ """
+ If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
+ """
+ interac_present: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataInteracPresent"
+ ]
+ """
+ If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
+ """
+ kakao_pay: NotRequired["SetupIntentModifyParamsPaymentMethodDataKakaoPay"]
+ """
+ If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
+ """
+ klarna: NotRequired["SetupIntentModifyParamsPaymentMethodDataKlarna"]
+ """
+ If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
+ """
+ konbini: NotRequired["SetupIntentModifyParamsPaymentMethodDataKonbini"]
+ """
+ If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
+ """
+ kr_card: NotRequired["SetupIntentModifyParamsPaymentMethodDataKrCard"]
+ """
+ If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
+ """
+ link: NotRequired["SetupIntentModifyParamsPaymentMethodDataLink"]
+ """
+ If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
+ """
+ mb_way: NotRequired["SetupIntentModifyParamsPaymentMethodDataMbWay"]
+ """
+ If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ mobilepay: NotRequired["SetupIntentModifyParamsPaymentMethodDataMobilepay"]
+ """
+ If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
+ """
+ multibanco: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataMultibanco"
+ ]
+ """
+ If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
+ """
+ naver_pay: NotRequired["SetupIntentModifyParamsPaymentMethodDataNaverPay"]
+ """
+ If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
+ """
+ nz_bank_account: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataNzBankAccount"
+ ]
+ """
+ If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
+ """
+ oxxo: NotRequired["SetupIntentModifyParamsPaymentMethodDataOxxo"]
+ """
+ If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
+ """
+ p24: NotRequired["SetupIntentModifyParamsPaymentMethodDataP24"]
+ """
+ If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
+ """
+ pay_by_bank: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataPayByBank"
+ ]
+ """
+ If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
+ """
+ payco: NotRequired["SetupIntentModifyParamsPaymentMethodDataPayco"]
+ """
+ If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
+ """
+ paynow: NotRequired["SetupIntentModifyParamsPaymentMethodDataPaynow"]
+ """
+ If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
+ """
+ paypal: NotRequired["SetupIntentModifyParamsPaymentMethodDataPaypal"]
+ """
+ If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
+ """
+ pix: NotRequired["SetupIntentModifyParamsPaymentMethodDataPix"]
+ """
+ If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
+ """
+ promptpay: NotRequired["SetupIntentModifyParamsPaymentMethodDataPromptpay"]
+ """
+ If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
+ """
+ radar_options: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataRadarOptions"
+ ]
+ """
+ Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
+ """
+ revolut_pay: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataRevolutPay"
+ ]
+ """
+ If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
+ """
+ samsung_pay: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataSamsungPay"
+ ]
+ """
+ If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
+ """
+ satispay: NotRequired["SetupIntentModifyParamsPaymentMethodDataSatispay"]
+ """
+ If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
+ """
+ sepa_debit: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
+ """
+ sofort: NotRequired["SetupIntentModifyParamsPaymentMethodDataSofort"]
+ """
+ If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
+ """
+ swish: NotRequired["SetupIntentModifyParamsPaymentMethodDataSwish"]
+ """
+ If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
+ """
+ twint: NotRequired["SetupIntentModifyParamsPaymentMethodDataTwint"]
+ """
+ If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
+ """
+ type: Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "link",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ """
+ The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
+ """
+ us_bank_account: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataUsBankAccount"
+ ]
+ """
+ If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
+ """
+ wechat_pay: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodDataWechatPay"
+ ]
+ """
+ If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
+ """
+ zip: NotRequired["SetupIntentModifyParamsPaymentMethodDataZip"]
+ """
+ If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataAcssDebit(TypedDict):
+ account_number: str
+ """
+ Customer's bank account number.
+ """
+ institution_number: str
+ """
+ Institution number of the customer's bank.
+ """
+ transit_number: str
+ """
+ Transit number of the customer's bank.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataAffirm(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataAfterpayClearpay(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataAlipay(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataAlma(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataAmazonPay(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataAuBecsDebit(TypedDict):
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bsb_number: str
+ """
+ Bank-State-Branch number of the bank account.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataBacsDebit(TypedDict):
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account that the funds will be debited from.
+ """
+ sort_code: NotRequired[str]
+ """
+ Sort code of the bank account. (e.g., `10-20-30`)
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataBancontact(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataBillie(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataBillingDetails(TypedDict):
+ address: NotRequired[
+ "Literal['']|SetupIntentModifyParamsPaymentMethodDataBillingDetailsAddress"
+ ]
+ """
+ Billing address.
+ """
+ email: NotRequired["Literal['']|str"]
+ """
+ Email address.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Full name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Billing phone number (including extension).
+ """
+ tax_id: NotRequired[str]
+ """
+ Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataBlik(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataBoleto(TypedDict):
+ tax_id: str
+ """
+ The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataCashapp(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataCrypto(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataCustomerBalance(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataEps(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "arzte_und_apotheker_bank",
+ "austrian_anadi_bank_ag",
+ "bank_austria",
+ "bankhaus_carl_spangler",
+ "bankhaus_schelhammer_und_schattera_ag",
+ "bawag_psk_ag",
+ "bks_bank_ag",
+ "brull_kallmus_bank_ag",
+ "btv_vier_lander_bank",
+ "capital_bank_grawe_gruppe_ag",
+ "deutsche_bank_ag",
+ "dolomitenbank",
+ "easybank_ag",
+ "erste_bank_und_sparkassen",
+ "hypo_alpeadriabank_international_ag",
+ "hypo_bank_burgenland_aktiengesellschaft",
+ "hypo_noe_lb_fur_niederosterreich_u_wien",
+ "hypo_oberosterreich_salzburg_steiermark",
+ "hypo_tirol_bank_ag",
+ "hypo_vorarlberg_bank_ag",
+ "marchfelder_bank",
+ "oberbank_ag",
+ "raiffeisen_bankengruppe_osterreich",
+ "schoellerbank_ag",
+ "sparda_bank_wien",
+ "volksbank_gruppe",
+ "volkskreditbank_ag",
+ "vr_bank_braunau",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataFpx(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type for FPX transaction
+ """
+ bank: Literal[
+ "affin_bank",
+ "agrobank",
+ "alliance_bank",
+ "ambank",
+ "bank_islam",
+ "bank_muamalat",
+ "bank_of_china",
+ "bank_rakyat",
+ "bsn",
+ "cimb",
+ "deutsche_bank",
+ "hong_leong_bank",
+ "hsbc",
+ "kfh",
+ "maybank2e",
+ "maybank2u",
+ "ocbc",
+ "pb_enterprise",
+ "public_bank",
+ "rhb",
+ "standard_chartered",
+ "uob",
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataGiropay(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataGrabpay(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataIdeal(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "abn_amro",
+ "asn_bank",
+ "bunq",
+ "buut",
+ "handelsbanken",
+ "ing",
+ "knab",
+ "moneyou",
+ "n26",
+ "nn",
+ "rabobank",
+ "regiobank",
+ "revolut",
+ "sns_bank",
+ "triodos_bank",
+ "van_lanschot",
+ "yoursafe",
+ ]
+ ]
+ """
+ The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataInteracPresent(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataKakaoPay(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataKlarna(TypedDict):
+ dob: NotRequired["SetupIntentModifyParamsPaymentMethodDataKlarnaDob"]
+ """
+ Customer's date of birth
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataKlarnaDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataKonbini(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataKrCard(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataLink(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataMbWay(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataMobilepay(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataMultibanco(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataNaverPay(TypedDict):
+ funding: NotRequired[Literal["card", "points"]]
+ """
+ Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataNzBankAccount(TypedDict):
+ account_holder_name: NotRequired[str]
+ """
+ The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
+ """
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bank_code: str
+ """
+ The numeric code for the bank account's bank.
+ """
+ branch_code: str
+ """
+ The numeric code for the bank account's bank branch.
+ """
+ reference: NotRequired[str]
+ suffix: str
+ """
+ The suffix of the bank account number.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataOxxo(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataP24(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "alior_bank",
+ "bank_millennium",
+ "bank_nowy_bfg_sa",
+ "bank_pekao_sa",
+ "banki_spbdzielcze",
+ "blik",
+ "bnp_paribas",
+ "boz",
+ "citi_handlowy",
+ "credit_agricole",
+ "envelobank",
+ "etransfer_pocztowy24",
+ "getin_bank",
+ "ideabank",
+ "ing",
+ "inteligo",
+ "mbank_mtransfer",
+ "nest_przelew",
+ "noble_pay",
+ "pbac_z_ipko",
+ "plus_bank",
+ "santander_przelew24",
+ "tmobile_usbugi_bankowe",
+ "toyota_bank",
+ "velobank",
+ "volkswagen_bank",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataPayByBank(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataPayco(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataPaynow(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataPaypal(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataPix(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataPromptpay(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataRadarOptions(TypedDict):
+ session: NotRequired[str]
+ """
+ A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataRevolutPay(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataSamsungPay(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataSatispay(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataSepaDebit(TypedDict):
+ iban: str
+ """
+ IBAN of the bank account.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataSofort(TypedDict):
+ country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
+ """
+ Two-letter ISO code representing the country the bank account is located in.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataSwish(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataTwint(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataUsBankAccount(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type: individual or company.
+ """
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account.
+ """
+ account_type: NotRequired[Literal["checking", "savings"]]
+ """
+ Account type: checkings or savings. Defaults to checking if omitted.
+ """
+ financial_connections_account: NotRequired[str]
+ """
+ The ID of a Financial Connections Account to use as a payment method.
+ """
+ routing_number: NotRequired[str]
+ """
+ Routing number of the bank account.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodDataWechatPay(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodDataZip(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodOptions(TypedDict):
+ acss_debit: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsAcssDebit"
+ ]
+ """
+ If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
+ """
+ amazon_pay: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsAmazonPay"
+ ]
+ """
+ If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
+ """
+ bacs_debit: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
+ """
+ card: NotRequired["SetupIntentModifyParamsPaymentMethodOptionsCard"]
+ """
+ Configuration for any card setup attempted on this SetupIntent.
+ """
+ card_present: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsCardPresent"
+ ]
+ """
+ If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
+ """
+ klarna: NotRequired["SetupIntentModifyParamsPaymentMethodOptionsKlarna"]
+ """
+ If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method options.
+ """
+ link: NotRequired["SetupIntentModifyParamsPaymentMethodOptionsLink"]
+ """
+ If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
+ """
+ paypal: NotRequired["SetupIntentModifyParamsPaymentMethodOptionsPaypal"]
+ """
+ If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
+ """
+ sepa_debit: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
+ """
+ us_bank_account: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsAcssDebit(TypedDict):
+ currency: NotRequired[Literal["cad", "usd"]]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ mandate_options: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsAcssDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsAcssDebitMandateOptions(
+ TypedDict,
+):
+ custom_mandate_url: NotRequired["Literal['']|str"]
+ """
+ A URL for custom mandate text to render during confirmation step.
+ The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
+ or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
+ """
+ default_for: NotRequired[List[Literal["invoice", "subscription"]]]
+ """
+ List of Stripe products where this mandate can be selected automatically.
+ """
+ interval_description: NotRequired[str]
+ """
+ Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
+ """
+ payment_schedule: NotRequired[Literal["combined", "interval", "sporadic"]]
+ """
+ Payment schedule for the mandate.
+ """
+ transaction_type: NotRequired[Literal["business", "personal"]]
+ """
+ Transaction type of the mandate.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsAmazonPay(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsBacsDebit(TypedDict):
+ mandate_options: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsBacsDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsBacsDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsCard(TypedDict):
+ mandate_options: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsCardMandateOptions"
+ ]
+ """
+ Configuration options for setting up an eMandate for cards issued in India.
+ """
+ moto: NotRequired[bool]
+ """
+ When specified, this parameter signals that a card has been collected
+ as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
+ parameter can only be provided during confirmation.
+ """
+ network: NotRequired[
+ Literal[
+ "amex",
+ "cartes_bancaires",
+ "diners",
+ "discover",
+ "eftpos_au",
+ "girocard",
+ "interac",
+ "jcb",
+ "link",
+ "mastercard",
+ "unionpay",
+ "unknown",
+ "visa",
+ ]
+ ]
+ """
+ Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
+ """
+ request_three_d_secure: NotRequired[
+ Literal["any", "automatic", "challenge"]
+ ]
+ """
+ We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
+ """
+ three_d_secure: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsCardThreeDSecure"
+ ]
+ """
+ If 3D Secure authentication was performed with a third-party provider,
+ the authentication details to use for this setup.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsCardMandateOptions(TypedDict):
+ amount: int
+ """
+ Amount to be charged for future payments.
+ """
+ amount_type: Literal["fixed", "maximum"]
+ """
+ One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
+ """
+ currency: str
+ """
+ Currency in which future payments will be charged. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ description: NotRequired[str]
+ """
+ A description of the mandate or subscription that is meant to be displayed to the customer.
+ """
+ end_date: NotRequired[int]
+ """
+ End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
+ """
+ interval: Literal["day", "month", "sporadic", "week", "year"]
+ """
+ Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
+ """
+ reference: str
+ """
+ Unique identifier for the mandate or subscription.
+ """
+ start_date: int
+ """
+ Start date of the mandate or subscription. Start date should not be lesser than yesterday.
+ """
+ supported_types: NotRequired[List[Literal["india"]]]
+ """
+ Specifies the type of mandates supported. Possible values are `india`.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
+ ares_trans_status: NotRequired[Literal["A", "C", "I", "N", "R", "U", "Y"]]
+ """
+ The `transStatus` returned from the card Issuer's ACS in the ARes.
+ """
+ cryptogram: NotRequired[str]
+ """
+ The cryptogram, also known as the "authentication value" (AAV, CAVV or
+ AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
+ (Most 3D Secure providers will return the base64-encoded version, which
+ is what you should specify here.)
+ """
+ electronic_commerce_indicator: NotRequired[
+ Literal["01", "02", "05", "06", "07"]
+ ]
+ """
+ The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
+ provider and indicates what degree of authentication was performed.
+ """
+ network_options: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
+ ]
+ """
+ Network specific 3DS fields. Network specific arguments require an
+ explicit card brand choice. The parameter `payment_method_options.card.network``
+ must be populated accordingly
+ """
+ requestor_challenge_indicator: NotRequired[str]
+ """
+ The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
+ AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
+ """
+ transaction_id: NotRequired[str]
+ """
+ For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
+ Transaction ID (dsTransID).
+ """
+ version: NotRequired[Literal["1.0.2", "2.1.0", "2.2.0"]]
+ """
+ The version of 3D Secure that was performed.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
+ TypedDict,
+):
+ cartes_bancaires: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
+ ]
+ """
+ Cartes Bancaires-specific 3DS fields.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
+ TypedDict,
+):
+ cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
+ """
+ The cryptogram calculation algorithm used by the card Issuer's ACS
+ to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
+ messageExtension: CB-AVALGO
+ """
+ cb_exemption: NotRequired[str]
+ """
+ The exemption indicator returned from Cartes Bancaires in the ARes.
+ message extension: CB-EXEMPTION; string (4 characters)
+ This is a 3 byte bitmap (low significant byte first and most significant
+ bit first) that has been Base64 encoded
+ """
+ cb_score: NotRequired[int]
+ """
+ The risk score returned from Cartes Bancaires in the ARes.
+ message extension: CB-SCORE; numeric value 0-99
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsCardPresent(TypedDict):
+ pass
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsKlarna(TypedDict):
+ currency: NotRequired[str]
+ """
+ The currency of the SetupIntent. Three letter ISO currency code.
+ """
+ on_demand: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsKlarnaOnDemand"
+ ]
+ """
+ On-demand details if setting up a payment method for on-demand payments.
+ """
+ preferred_locale: NotRequired[
+ Literal[
+ "cs-CZ",
+ "da-DK",
+ "de-AT",
+ "de-CH",
+ "de-DE",
+ "el-GR",
+ "en-AT",
+ "en-AU",
+ "en-BE",
+ "en-CA",
+ "en-CH",
+ "en-CZ",
+ "en-DE",
+ "en-DK",
+ "en-ES",
+ "en-FI",
+ "en-FR",
+ "en-GB",
+ "en-GR",
+ "en-IE",
+ "en-IT",
+ "en-NL",
+ "en-NO",
+ "en-NZ",
+ "en-PL",
+ "en-PT",
+ "en-RO",
+ "en-SE",
+ "en-US",
+ "es-ES",
+ "es-US",
+ "fi-FI",
+ "fr-BE",
+ "fr-CA",
+ "fr-CH",
+ "fr-FR",
+ "it-CH",
+ "it-IT",
+ "nb-NO",
+ "nl-BE",
+ "nl-NL",
+ "pl-PL",
+ "pt-PT",
+ "ro-RO",
+ "sv-FI",
+ "sv-SE",
+ ]
+ ]
+ """
+ Preferred language of the Klarna authorization page that the customer is redirected to
+ """
+ subscriptions: NotRequired[
+ "Literal['']|List[SetupIntentModifyParamsPaymentMethodOptionsKlarnaSubscription]"
+ ]
+ """
+ Subscription details if setting up or charging a subscription
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
+ average_amount: NotRequired[int]
+ """
+ Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ maximum_amount: NotRequired[int]
+ """
+ The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ minimum_amount: NotRequired[int]
+ """
+ The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
+ """
+ Interval at which the customer is making purchases
+ """
+ purchase_interval_count: NotRequired[int]
+ """
+ The number of `purchase_interval` between charges
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Unit of time between subscription charges.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
+ """
+ name: NotRequired[str]
+ """
+ Name for subscription.
+ """
+ next_billing: "SetupIntentModifyParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
+ """
+ Describes the upcoming charge for this subscription.
+ """
+ reference: str
+ """
+ A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
+ TypedDict,
+):
+ amount: int
+ """
+ The amount of the next charge for the subscription.
+ """
+ date: str
+ """
+ The date of the next charge for the subscription in YYYY-MM-DD format.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsLink(TypedDict):
+ persistent_token: NotRequired[str]
+ """
+ [Deprecated] This is a legacy parameter that no longer has any function.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsPaypal(TypedDict):
+ billing_agreement_id: NotRequired[str]
+ """
+ The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsSepaDebit(TypedDict):
+ mandate_options: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsSepaDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsSepaDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsUsBankAccount(TypedDict):
+ financial_connections: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
+ ]
+ """
+ Additional fields for Financial Connections Session creation
+ """
+ mandate_options: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsUsBankAccountMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ networks: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsUsBankAccountNetworks"
+ ]
+ """
+ Additional fields for network related functions
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
+ TypedDict,
+):
+ filters: NotRequired[
+ "SetupIntentModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
+ ]
+ """
+ Provide filters for the linked accounts that the customer can select for the payment method.
+ """
+ permissions: NotRequired[
+ List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ ]
+ """
+ The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+ return_url: NotRequired[str]
+ """
+ For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
+ TypedDict,
+):
+ account_subcategories: NotRequired[List[Literal["checking", "savings"]]]
+ """
+ The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsUsBankAccountMandateOptions(
+ TypedDict,
+):
+ collection_method: NotRequired["Literal['']|Literal['paper']"]
+ """
+ The method used to collect offline mandate customer acceptance.
+ """
+
+
+class SetupIntentModifyParamsPaymentMethodOptionsUsBankAccountNetworks(
+ TypedDict,
+):
+ requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
+ """
+ Triggers validations to run across the selected networks
+ """
diff --git a/stripe/params/_setup_intent_retrieve_params.py b/stripe/params/_setup_intent_retrieve_params.py
new file mode 100644
index 000000000..88c235d7c
--- /dev/null
+++ b/stripe/params/_setup_intent_retrieve_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SetupIntentRetrieveParams(RequestOptions):
+ client_secret: NotRequired[str]
+ """
+ The client secret of the SetupIntent. We require this string if you use a publishable key to retrieve the SetupIntent.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_setup_intent_update_params.py b/stripe/params/_setup_intent_update_params.py
new file mode 100644
index 000000000..1507359b9
--- /dev/null
+++ b/stripe/params/_setup_intent_update_params.py
@@ -0,0 +1,1375 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SetupIntentUpdateParams(TypedDict):
+ attach_to_self: NotRequired[bool]
+ """
+ If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
+
+ It can only be used for this Stripe Account's own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
+ """
+ customer: NotRequired[str]
+ """
+ ID of the Customer this SetupIntent belongs to, if one exists.
+
+ If present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ flow_directions: NotRequired[List[Literal["inbound", "outbound"]]]
+ """
+ Indicates the directions of money movement for which this payment method is intended to be used.
+
+ Include `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ payment_method: NotRequired[str]
+ """
+ ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent. To unset this field to null, pass in an empty string.
+ """
+ payment_method_configuration: NotRequired[str]
+ """
+ The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this SetupIntent.
+ """
+ payment_method_data: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodData"
+ ]
+ """
+ When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
+ value in the SetupIntent.
+ """
+ payment_method_options: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptions"
+ ]
+ """
+ Payment method-specific configuration for this SetupIntent.
+ """
+ payment_method_types: NotRequired[List[str]]
+ """
+ The list of payment method types (for example, card) that this SetupIntent can set up. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods). A list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodData(TypedDict):
+ acss_debit: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataAcssDebit"
+ ]
+ """
+ If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
+ """
+ affirm: NotRequired["SetupIntentUpdateParamsPaymentMethodDataAffirm"]
+ """
+ If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
+ """
+ afterpay_clearpay: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataAfterpayClearpay"
+ ]
+ """
+ If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
+ """
+ alipay: NotRequired["SetupIntentUpdateParamsPaymentMethodDataAlipay"]
+ """
+ If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
+ """
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
+ """
+ alma: NotRequired["SetupIntentUpdateParamsPaymentMethodDataAlma"]
+ """
+ If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
+ """
+ amazon_pay: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataAmazonPay"
+ ]
+ """
+ If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
+ """
+ au_becs_debit: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataAuBecsDebit"
+ ]
+ """
+ If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
+ """
+ bacs_debit: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
+ """
+ bancontact: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataBancontact"
+ ]
+ """
+ If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
+ """
+ billie: NotRequired["SetupIntentUpdateParamsPaymentMethodDataBillie"]
+ """
+ If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
+ """
+ billing_details: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataBillingDetails"
+ ]
+ """
+ Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+ """
+ blik: NotRequired["SetupIntentUpdateParamsPaymentMethodDataBlik"]
+ """
+ If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
+ """
+ boleto: NotRequired["SetupIntentUpdateParamsPaymentMethodDataBoleto"]
+ """
+ If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
+ """
+ cashapp: NotRequired["SetupIntentUpdateParamsPaymentMethodDataCashapp"]
+ """
+ If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
+ """
+ crypto: NotRequired["SetupIntentUpdateParamsPaymentMethodDataCrypto"]
+ """
+ If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
+ """
+ customer_balance: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataCustomerBalance"
+ ]
+ """
+ If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
+ """
+ eps: NotRequired["SetupIntentUpdateParamsPaymentMethodDataEps"]
+ """
+ If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
+ """
+ fpx: NotRequired["SetupIntentUpdateParamsPaymentMethodDataFpx"]
+ """
+ If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
+ """
+ giropay: NotRequired["SetupIntentUpdateParamsPaymentMethodDataGiropay"]
+ """
+ If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
+ """
+ grabpay: NotRequired["SetupIntentUpdateParamsPaymentMethodDataGrabpay"]
+ """
+ If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
+ """
+ ideal: NotRequired["SetupIntentUpdateParamsPaymentMethodDataIdeal"]
+ """
+ If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
+ """
+ interac_present: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataInteracPresent"
+ ]
+ """
+ If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
+ """
+ kakao_pay: NotRequired["SetupIntentUpdateParamsPaymentMethodDataKakaoPay"]
+ """
+ If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
+ """
+ klarna: NotRequired["SetupIntentUpdateParamsPaymentMethodDataKlarna"]
+ """
+ If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
+ """
+ konbini: NotRequired["SetupIntentUpdateParamsPaymentMethodDataKonbini"]
+ """
+ If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
+ """
+ kr_card: NotRequired["SetupIntentUpdateParamsPaymentMethodDataKrCard"]
+ """
+ If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
+ """
+ link: NotRequired["SetupIntentUpdateParamsPaymentMethodDataLink"]
+ """
+ If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
+ """
+ mb_way: NotRequired["SetupIntentUpdateParamsPaymentMethodDataMbWay"]
+ """
+ If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ mobilepay: NotRequired["SetupIntentUpdateParamsPaymentMethodDataMobilepay"]
+ """
+ If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
+ """
+ multibanco: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataMultibanco"
+ ]
+ """
+ If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
+ """
+ naver_pay: NotRequired["SetupIntentUpdateParamsPaymentMethodDataNaverPay"]
+ """
+ If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
+ """
+ nz_bank_account: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataNzBankAccount"
+ ]
+ """
+ If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
+ """
+ oxxo: NotRequired["SetupIntentUpdateParamsPaymentMethodDataOxxo"]
+ """
+ If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
+ """
+ p24: NotRequired["SetupIntentUpdateParamsPaymentMethodDataP24"]
+ """
+ If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
+ """
+ pay_by_bank: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataPayByBank"
+ ]
+ """
+ If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
+ """
+ payco: NotRequired["SetupIntentUpdateParamsPaymentMethodDataPayco"]
+ """
+ If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
+ """
+ paynow: NotRequired["SetupIntentUpdateParamsPaymentMethodDataPaynow"]
+ """
+ If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
+ """
+ paypal: NotRequired["SetupIntentUpdateParamsPaymentMethodDataPaypal"]
+ """
+ If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
+ """
+ pix: NotRequired["SetupIntentUpdateParamsPaymentMethodDataPix"]
+ """
+ If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
+ """
+ promptpay: NotRequired["SetupIntentUpdateParamsPaymentMethodDataPromptpay"]
+ """
+ If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
+ """
+ radar_options: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataRadarOptions"
+ ]
+ """
+ Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
+ """
+ revolut_pay: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataRevolutPay"
+ ]
+ """
+ If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
+ """
+ samsung_pay: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataSamsungPay"
+ ]
+ """
+ If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
+ """
+ satispay: NotRequired["SetupIntentUpdateParamsPaymentMethodDataSatispay"]
+ """
+ If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
+ """
+ sepa_debit: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
+ """
+ sofort: NotRequired["SetupIntentUpdateParamsPaymentMethodDataSofort"]
+ """
+ If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
+ """
+ swish: NotRequired["SetupIntentUpdateParamsPaymentMethodDataSwish"]
+ """
+ If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
+ """
+ twint: NotRequired["SetupIntentUpdateParamsPaymentMethodDataTwint"]
+ """
+ If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
+ """
+ type: Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "link",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ """
+ The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
+ """
+ us_bank_account: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataUsBankAccount"
+ ]
+ """
+ If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
+ """
+ wechat_pay: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodDataWechatPay"
+ ]
+ """
+ If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
+ """
+ zip: NotRequired["SetupIntentUpdateParamsPaymentMethodDataZip"]
+ """
+ If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataAcssDebit(TypedDict):
+ account_number: str
+ """
+ Customer's bank account number.
+ """
+ institution_number: str
+ """
+ Institution number of the customer's bank.
+ """
+ transit_number: str
+ """
+ Transit number of the customer's bank.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataAffirm(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataAfterpayClearpay(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataAlipay(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataAlma(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataAmazonPay(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataAuBecsDebit(TypedDict):
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bsb_number: str
+ """
+ Bank-State-Branch number of the bank account.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataBacsDebit(TypedDict):
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account that the funds will be debited from.
+ """
+ sort_code: NotRequired[str]
+ """
+ Sort code of the bank account. (e.g., `10-20-30`)
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataBancontact(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataBillie(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataBillingDetails(TypedDict):
+ address: NotRequired[
+ "Literal['']|SetupIntentUpdateParamsPaymentMethodDataBillingDetailsAddress"
+ ]
+ """
+ Billing address.
+ """
+ email: NotRequired["Literal['']|str"]
+ """
+ Email address.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Full name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Billing phone number (including extension).
+ """
+ tax_id: NotRequired[str]
+ """
+ Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataBlik(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataBoleto(TypedDict):
+ tax_id: str
+ """
+ The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataCashapp(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataCrypto(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataCustomerBalance(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataEps(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "arzte_und_apotheker_bank",
+ "austrian_anadi_bank_ag",
+ "bank_austria",
+ "bankhaus_carl_spangler",
+ "bankhaus_schelhammer_und_schattera_ag",
+ "bawag_psk_ag",
+ "bks_bank_ag",
+ "brull_kallmus_bank_ag",
+ "btv_vier_lander_bank",
+ "capital_bank_grawe_gruppe_ag",
+ "deutsche_bank_ag",
+ "dolomitenbank",
+ "easybank_ag",
+ "erste_bank_und_sparkassen",
+ "hypo_alpeadriabank_international_ag",
+ "hypo_bank_burgenland_aktiengesellschaft",
+ "hypo_noe_lb_fur_niederosterreich_u_wien",
+ "hypo_oberosterreich_salzburg_steiermark",
+ "hypo_tirol_bank_ag",
+ "hypo_vorarlberg_bank_ag",
+ "marchfelder_bank",
+ "oberbank_ag",
+ "raiffeisen_bankengruppe_osterreich",
+ "schoellerbank_ag",
+ "sparda_bank_wien",
+ "volksbank_gruppe",
+ "volkskreditbank_ag",
+ "vr_bank_braunau",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataFpx(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type for FPX transaction
+ """
+ bank: Literal[
+ "affin_bank",
+ "agrobank",
+ "alliance_bank",
+ "ambank",
+ "bank_islam",
+ "bank_muamalat",
+ "bank_of_china",
+ "bank_rakyat",
+ "bsn",
+ "cimb",
+ "deutsche_bank",
+ "hong_leong_bank",
+ "hsbc",
+ "kfh",
+ "maybank2e",
+ "maybank2u",
+ "ocbc",
+ "pb_enterprise",
+ "public_bank",
+ "rhb",
+ "standard_chartered",
+ "uob",
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataGiropay(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataGrabpay(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataIdeal(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "abn_amro",
+ "asn_bank",
+ "bunq",
+ "buut",
+ "handelsbanken",
+ "ing",
+ "knab",
+ "moneyou",
+ "n26",
+ "nn",
+ "rabobank",
+ "regiobank",
+ "revolut",
+ "sns_bank",
+ "triodos_bank",
+ "van_lanschot",
+ "yoursafe",
+ ]
+ ]
+ """
+ The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataInteracPresent(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataKakaoPay(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataKlarna(TypedDict):
+ dob: NotRequired["SetupIntentUpdateParamsPaymentMethodDataKlarnaDob"]
+ """
+ Customer's date of birth
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataKlarnaDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataKonbini(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataKrCard(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataLink(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataMbWay(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataMobilepay(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataMultibanco(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataNaverPay(TypedDict):
+ funding: NotRequired[Literal["card", "points"]]
+ """
+ Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataNzBankAccount(TypedDict):
+ account_holder_name: NotRequired[str]
+ """
+ The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
+ """
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bank_code: str
+ """
+ The numeric code for the bank account's bank.
+ """
+ branch_code: str
+ """
+ The numeric code for the bank account's bank branch.
+ """
+ reference: NotRequired[str]
+ suffix: str
+ """
+ The suffix of the bank account number.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataOxxo(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataP24(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "alior_bank",
+ "bank_millennium",
+ "bank_nowy_bfg_sa",
+ "bank_pekao_sa",
+ "banki_spbdzielcze",
+ "blik",
+ "bnp_paribas",
+ "boz",
+ "citi_handlowy",
+ "credit_agricole",
+ "envelobank",
+ "etransfer_pocztowy24",
+ "getin_bank",
+ "ideabank",
+ "ing",
+ "inteligo",
+ "mbank_mtransfer",
+ "nest_przelew",
+ "noble_pay",
+ "pbac_z_ipko",
+ "plus_bank",
+ "santander_przelew24",
+ "tmobile_usbugi_bankowe",
+ "toyota_bank",
+ "velobank",
+ "volkswagen_bank",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataPayByBank(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataPayco(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataPaynow(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataPaypal(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataPix(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataPromptpay(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataRadarOptions(TypedDict):
+ session: NotRequired[str]
+ """
+ A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataRevolutPay(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataSamsungPay(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataSatispay(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataSepaDebit(TypedDict):
+ iban: str
+ """
+ IBAN of the bank account.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataSofort(TypedDict):
+ country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
+ """
+ Two-letter ISO code representing the country the bank account is located in.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataSwish(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataTwint(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataUsBankAccount(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type: individual or company.
+ """
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account.
+ """
+ account_type: NotRequired[Literal["checking", "savings"]]
+ """
+ Account type: checkings or savings. Defaults to checking if omitted.
+ """
+ financial_connections_account: NotRequired[str]
+ """
+ The ID of a Financial Connections Account to use as a payment method.
+ """
+ routing_number: NotRequired[str]
+ """
+ Routing number of the bank account.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodDataWechatPay(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodDataZip(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodOptions(TypedDict):
+ acss_debit: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsAcssDebit"
+ ]
+ """
+ If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
+ """
+ amazon_pay: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsAmazonPay"
+ ]
+ """
+ If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
+ """
+ bacs_debit: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
+ """
+ card: NotRequired["SetupIntentUpdateParamsPaymentMethodOptionsCard"]
+ """
+ Configuration for any card setup attempted on this SetupIntent.
+ """
+ card_present: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsCardPresent"
+ ]
+ """
+ If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
+ """
+ klarna: NotRequired["SetupIntentUpdateParamsPaymentMethodOptionsKlarna"]
+ """
+ If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method options.
+ """
+ link: NotRequired["SetupIntentUpdateParamsPaymentMethodOptionsLink"]
+ """
+ If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
+ """
+ paypal: NotRequired["SetupIntentUpdateParamsPaymentMethodOptionsPaypal"]
+ """
+ If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
+ """
+ sepa_debit: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
+ """
+ us_bank_account: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsAcssDebit(TypedDict):
+ currency: NotRequired[Literal["cad", "usd"]]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ mandate_options: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsAcssDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsAcssDebitMandateOptions(
+ TypedDict,
+):
+ custom_mandate_url: NotRequired["Literal['']|str"]
+ """
+ A URL for custom mandate text to render during confirmation step.
+ The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
+ or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
+ """
+ default_for: NotRequired[List[Literal["invoice", "subscription"]]]
+ """
+ List of Stripe products where this mandate can be selected automatically.
+ """
+ interval_description: NotRequired[str]
+ """
+ Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
+ """
+ payment_schedule: NotRequired[Literal["combined", "interval", "sporadic"]]
+ """
+ Payment schedule for the mandate.
+ """
+ transaction_type: NotRequired[Literal["business", "personal"]]
+ """
+ Transaction type of the mandate.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsAmazonPay(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsBacsDebit(TypedDict):
+ mandate_options: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsBacsDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsBacsDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsCard(TypedDict):
+ mandate_options: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsCardMandateOptions"
+ ]
+ """
+ Configuration options for setting up an eMandate for cards issued in India.
+ """
+ moto: NotRequired[bool]
+ """
+ When specified, this parameter signals that a card has been collected
+ as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
+ parameter can only be provided during confirmation.
+ """
+ network: NotRequired[
+ Literal[
+ "amex",
+ "cartes_bancaires",
+ "diners",
+ "discover",
+ "eftpos_au",
+ "girocard",
+ "interac",
+ "jcb",
+ "link",
+ "mastercard",
+ "unionpay",
+ "unknown",
+ "visa",
+ ]
+ ]
+ """
+ Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
+ """
+ request_three_d_secure: NotRequired[
+ Literal["any", "automatic", "challenge"]
+ ]
+ """
+ We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
+ """
+ three_d_secure: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsCardThreeDSecure"
+ ]
+ """
+ If 3D Secure authentication was performed with a third-party provider,
+ the authentication details to use for this setup.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsCardMandateOptions(TypedDict):
+ amount: int
+ """
+ Amount to be charged for future payments.
+ """
+ amount_type: Literal["fixed", "maximum"]
+ """
+ One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
+ """
+ currency: str
+ """
+ Currency in which future payments will be charged. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ description: NotRequired[str]
+ """
+ A description of the mandate or subscription that is meant to be displayed to the customer.
+ """
+ end_date: NotRequired[int]
+ """
+ End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
+ """
+ interval: Literal["day", "month", "sporadic", "week", "year"]
+ """
+ Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
+ """
+ reference: str
+ """
+ Unique identifier for the mandate or subscription.
+ """
+ start_date: int
+ """
+ Start date of the mandate or subscription. Start date should not be lesser than yesterday.
+ """
+ supported_types: NotRequired[List[Literal["india"]]]
+ """
+ Specifies the type of mandates supported. Possible values are `india`.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsCardThreeDSecure(TypedDict):
+ ares_trans_status: NotRequired[Literal["A", "C", "I", "N", "R", "U", "Y"]]
+ """
+ The `transStatus` returned from the card Issuer's ACS in the ARes.
+ """
+ cryptogram: NotRequired[str]
+ """
+ The cryptogram, also known as the "authentication value" (AAV, CAVV or
+ AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
+ (Most 3D Secure providers will return the base64-encoded version, which
+ is what you should specify here.)
+ """
+ electronic_commerce_indicator: NotRequired[
+ Literal["01", "02", "05", "06", "07"]
+ ]
+ """
+ The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
+ provider and indicates what degree of authentication was performed.
+ """
+ network_options: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions"
+ ]
+ """
+ Network specific 3DS fields. Network specific arguments require an
+ explicit card brand choice. The parameter `payment_method_options.card.network``
+ must be populated accordingly
+ """
+ requestor_challenge_indicator: NotRequired[str]
+ """
+ The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
+ AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
+ """
+ transaction_id: NotRequired[str]
+ """
+ For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
+ Transaction ID (dsTransID).
+ """
+ version: NotRequired[Literal["1.0.2", "2.1.0", "2.2.0"]]
+ """
+ The version of 3D Secure that was performed.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptions(
+ TypedDict,
+):
+ cartes_bancaires: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires"
+ ]
+ """
+ Cartes Bancaires-specific 3DS fields.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOptionsCartesBancaires(
+ TypedDict,
+):
+ cb_avalgo: Literal["0", "1", "2", "3", "4", "A"]
+ """
+ The cryptogram calculation algorithm used by the card Issuer's ACS
+ to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
+ messageExtension: CB-AVALGO
+ """
+ cb_exemption: NotRequired[str]
+ """
+ The exemption indicator returned from Cartes Bancaires in the ARes.
+ message extension: CB-EXEMPTION; string (4 characters)
+ This is a 3 byte bitmap (low significant byte first and most significant
+ bit first) that has been Base64 encoded
+ """
+ cb_score: NotRequired[int]
+ """
+ The risk score returned from Cartes Bancaires in the ARes.
+ message extension: CB-SCORE; numeric value 0-99
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsCardPresent(TypedDict):
+ pass
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsKlarna(TypedDict):
+ currency: NotRequired[str]
+ """
+ The currency of the SetupIntent. Three letter ISO currency code.
+ """
+ on_demand: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsKlarnaOnDemand"
+ ]
+ """
+ On-demand details if setting up a payment method for on-demand payments.
+ """
+ preferred_locale: NotRequired[
+ Literal[
+ "cs-CZ",
+ "da-DK",
+ "de-AT",
+ "de-CH",
+ "de-DE",
+ "el-GR",
+ "en-AT",
+ "en-AU",
+ "en-BE",
+ "en-CA",
+ "en-CH",
+ "en-CZ",
+ "en-DE",
+ "en-DK",
+ "en-ES",
+ "en-FI",
+ "en-FR",
+ "en-GB",
+ "en-GR",
+ "en-IE",
+ "en-IT",
+ "en-NL",
+ "en-NO",
+ "en-NZ",
+ "en-PL",
+ "en-PT",
+ "en-RO",
+ "en-SE",
+ "en-US",
+ "es-ES",
+ "es-US",
+ "fi-FI",
+ "fr-BE",
+ "fr-CA",
+ "fr-CH",
+ "fr-FR",
+ "it-CH",
+ "it-IT",
+ "nb-NO",
+ "nl-BE",
+ "nl-NL",
+ "pl-PL",
+ "pt-PT",
+ "ro-RO",
+ "sv-FI",
+ "sv-SE",
+ ]
+ ]
+ """
+ Preferred language of the Klarna authorization page that the customer is redirected to
+ """
+ subscriptions: NotRequired[
+ "Literal['']|List[SetupIntentUpdateParamsPaymentMethodOptionsKlarnaSubscription]"
+ ]
+ """
+ Subscription details if setting up or charging a subscription
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsKlarnaOnDemand(TypedDict):
+ average_amount: NotRequired[int]
+ """
+ Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ maximum_amount: NotRequired[int]
+ """
+ The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ minimum_amount: NotRequired[int]
+ """
+ The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
+ """
+ purchase_interval: NotRequired[Literal["day", "month", "week", "year"]]
+ """
+ Interval at which the customer is making purchases
+ """
+ purchase_interval_count: NotRequired[int]
+ """
+ The number of `purchase_interval` between charges
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Unit of time between subscription charges.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
+ """
+ name: NotRequired[str]
+ """
+ Name for subscription.
+ """
+ next_billing: "SetupIntentUpdateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
+ """
+ Describes the upcoming charge for this subscription.
+ """
+ reference: str
+ """
+ A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
+ TypedDict,
+):
+ amount: int
+ """
+ The amount of the next charge for the subscription.
+ """
+ date: str
+ """
+ The date of the next charge for the subscription in YYYY-MM-DD format.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsLink(TypedDict):
+ persistent_token: NotRequired[str]
+ """
+ [Deprecated] This is a legacy parameter that no longer has any function.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsPaypal(TypedDict):
+ billing_agreement_id: NotRequired[str]
+ """
+ The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsSepaDebit(TypedDict):
+ mandate_options: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsSepaDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsSepaDebitMandateOptions(
+ TypedDict,
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsUsBankAccount(TypedDict):
+ financial_connections: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
+ ]
+ """
+ Additional fields for Financial Connections Session creation
+ """
+ mandate_options: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsUsBankAccountMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ networks: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsUsBankAccountNetworks"
+ ]
+ """
+ Additional fields for network related functions
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Bank account verification method.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
+ TypedDict,
+):
+ filters: NotRequired[
+ "SetupIntentUpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
+ ]
+ """
+ Provide filters for the linked accounts that the customer can select for the payment method.
+ """
+ permissions: NotRequired[
+ List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ ]
+ """
+ The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+ return_url: NotRequired[str]
+ """
+ For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
+ TypedDict,
+):
+ account_subcategories: NotRequired[List[Literal["checking", "savings"]]]
+ """
+ The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsUsBankAccountMandateOptions(
+ TypedDict,
+):
+ collection_method: NotRequired["Literal['']|Literal['paper']"]
+ """
+ The method used to collect offline mandate customer acceptance.
+ """
+
+
+class SetupIntentUpdateParamsPaymentMethodOptionsUsBankAccountNetworks(
+ TypedDict,
+):
+ requested: NotRequired[List[Literal["ach", "us_domestic_wire"]]]
+ """
+ Triggers validations to run across the selected networks
+ """
diff --git a/stripe/params/_setup_intent_verify_microdeposits_params.py b/stripe/params/_setup_intent_verify_microdeposits_params.py
new file mode 100644
index 000000000..c53bc852c
--- /dev/null
+++ b/stripe/params/_setup_intent_verify_microdeposits_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SetupIntentVerifyMicrodepositsParams(RequestOptions):
+ amounts: NotRequired[List[int]]
+ """
+ Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.
+ """
+ descriptor_code: NotRequired[str]
+ """
+ A six-character code starting with SM present in the microdeposit sent to the bank account.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_shipping_rate_create_params.py b/stripe/params/_shipping_rate_create_params.py
new file mode 100644
index 000000000..8697e7138
--- /dev/null
+++ b/stripe/params/_shipping_rate_create_params.py
@@ -0,0 +1,101 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ShippingRateCreateParams(RequestOptions):
+ delivery_estimate: NotRequired["ShippingRateCreateParamsDeliveryEstimate"]
+ """
+ The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
+ """
+ display_name: str
+ """
+ The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ fixed_amount: NotRequired["ShippingRateCreateParamsFixedAmount"]
+ """
+ Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
+ """
+ type: NotRequired[Literal["fixed_amount"]]
+ """
+ The type of calculation to use on the shipping rate.
+ """
+
+
+class ShippingRateCreateParamsDeliveryEstimate(TypedDict):
+ maximum: NotRequired["ShippingRateCreateParamsDeliveryEstimateMaximum"]
+ """
+ The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
+ """
+ minimum: NotRequired["ShippingRateCreateParamsDeliveryEstimateMinimum"]
+ """
+ The lower bound of the estimated range. If empty, represents no lower bound.
+ """
+
+
+class ShippingRateCreateParamsDeliveryEstimateMaximum(TypedDict):
+ unit: Literal["business_day", "day", "hour", "month", "week"]
+ """
+ A unit of time.
+ """
+ value: int
+ """
+ Must be greater than 0.
+ """
+
+
+class ShippingRateCreateParamsDeliveryEstimateMinimum(TypedDict):
+ unit: Literal["business_day", "day", "hour", "month", "week"]
+ """
+ A unit of time.
+ """
+ value: int
+ """
+ Must be greater than 0.
+ """
+
+
+class ShippingRateCreateParamsFixedAmount(TypedDict):
+ amount: int
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ currency_options: NotRequired[
+ Dict[str, "ShippingRateCreateParamsFixedAmountCurrencyOptions"]
+ ]
+ """
+ Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+
+
+class ShippingRateCreateParamsFixedAmountCurrencyOptions(TypedDict):
+ amount: int
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
diff --git a/stripe/params/_shipping_rate_list_params.py b/stripe/params/_shipping_rate_list_params.py
new file mode 100644
index 000000000..4a0a8baa5
--- /dev/null
+++ b/stripe/params/_shipping_rate_list_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ShippingRateListParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Only return shipping rates that are active or inactive.
+ """
+ created: NotRequired["ShippingRateListParamsCreated|int"]
+ """
+ A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
+ """
+ currency: NotRequired[str]
+ """
+ Only return shipping rates for the given currency.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class ShippingRateListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_shipping_rate_modify_params.py b/stripe/params/_shipping_rate_modify_params.py
new file mode 100644
index 000000000..85f84f4bb
--- /dev/null
+++ b/stripe/params/_shipping_rate_modify_params.py
@@ -0,0 +1,48 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ShippingRateModifyParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Whether the shipping rate can be used for new purchases. Defaults to `true`.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ fixed_amount: NotRequired["ShippingRateModifyParamsFixedAmount"]
+ """
+ Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
+
+
+class ShippingRateModifyParamsFixedAmount(TypedDict):
+ currency_options: NotRequired[
+ Dict[str, "ShippingRateModifyParamsFixedAmountCurrencyOptions"]
+ ]
+ """
+ Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+
+
+class ShippingRateModifyParamsFixedAmountCurrencyOptions(TypedDict):
+ amount: NotRequired[int]
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
diff --git a/stripe/params/_shipping_rate_retrieve_params.py b/stripe/params/_shipping_rate_retrieve_params.py
new file mode 100644
index 000000000..2cdc3e78b
--- /dev/null
+++ b/stripe/params/_shipping_rate_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ShippingRateRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_shipping_rate_update_params.py b/stripe/params/_shipping_rate_update_params.py
new file mode 100644
index 000000000..bdfb36dc7
--- /dev/null
+++ b/stripe/params/_shipping_rate_update_params.py
@@ -0,0 +1,47 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ShippingRateUpdateParams(TypedDict):
+ active: NotRequired[bool]
+ """
+ Whether the shipping rate can be used for new purchases. Defaults to `true`.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ fixed_amount: NotRequired["ShippingRateUpdateParamsFixedAmount"]
+ """
+ Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
+
+
+class ShippingRateUpdateParamsFixedAmount(TypedDict):
+ currency_options: NotRequired[
+ Dict[str, "ShippingRateUpdateParamsFixedAmountCurrencyOptions"]
+ ]
+ """
+ Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+
+
+class ShippingRateUpdateParamsFixedAmountCurrencyOptions(TypedDict):
+ amount: NotRequired[int]
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
diff --git a/stripe/params/_source_create_params.py b/stripe/params/_source_create_params.py
new file mode 100644
index 000000000..013849e76
--- /dev/null
+++ b/stripe/params/_source_create_params.py
@@ -0,0 +1,282 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SourceCreateParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ Amount associated with the source. This is the amount for which the source will be chargeable once ready. Required for `single_use` sources. Not supported for `receiver` type sources, where charge amount may not be specified until funds land.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) associated with the source. This is the currency for which the source will be chargeable once ready.
+ """
+ customer: NotRequired[str]
+ """
+ The `Customer` to whom the original source is attached to. Must be set when the original source is not a `Source` (e.g., `Card`).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ flow: NotRequired[
+ Literal["code_verification", "none", "receiver", "redirect"]
+ ]
+ """
+ The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows.
+ """
+ mandate: NotRequired["SourceCreateParamsMandate"]
+ """
+ Information about a mandate possibility attached to a source object (generally for bank debits) as well as its acceptance status.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ original_source: NotRequired[str]
+ """
+ The source to share.
+ """
+ owner: NotRequired["SourceCreateParamsOwner"]
+ """
+ Information about the owner of the payment instrument that may be used or required by particular source types.
+ """
+ receiver: NotRequired["SourceCreateParamsReceiver"]
+ """
+ Optional parameters for the receiver flow. Can be set only if the source is a receiver (`flow` is `receiver`).
+ """
+ redirect: NotRequired["SourceCreateParamsRedirect"]
+ """
+ Parameters required for the redirect flow. Required if the source is authenticated by a redirect (`flow` is `redirect`).
+ """
+ source_order: NotRequired["SourceCreateParamsSourceOrder"]
+ """
+ Information about the items and shipping associated with the source. Required for transactional credit (for example Klarna) sources before you can charge it.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ An arbitrary string to be displayed on your customer's statement. As an example, if your website is `RunClub` and the item you're charging for is a race ticket, you may want to specify a `statement_descriptor` of `RunClub 5K race ticket.` While many payment types will display this information, some may not display it at all.
+ """
+ token: NotRequired[str]
+ """
+ An optional token used to create the source. When passed, token properties will override source parameters.
+ """
+ type: NotRequired[str]
+ """
+ The `type` of the source to create. Required unless `customer` and `original_source` are specified (see the [Cloning card Sources](https://stripe.com/docs/sources/connect#cloning-card-sources) guide)
+ """
+ usage: NotRequired[Literal["reusable", "single_use"]]
+
+
+class SourceCreateParamsMandate(TypedDict):
+ acceptance: NotRequired["SourceCreateParamsMandateAcceptance"]
+ """
+ The parameters required to notify Stripe of a mandate acceptance or refusal by the customer.
+ """
+ amount: NotRequired["Literal['']|int"]
+ """
+ The amount specified by the mandate. (Leave null for a mandate covering all amounts)
+ """
+ currency: NotRequired[str]
+ """
+ The currency specified by the mandate. (Must match `currency` of the source)
+ """
+ interval: NotRequired[Literal["one_time", "scheduled", "variable"]]
+ """
+ The interval of debits permitted by the mandate. Either `one_time` (just permitting a single debit), `scheduled` (with debits on an agreed schedule or for clearly-defined events), or `variable`(for debits with any frequency)
+ """
+ notification_method: NotRequired[
+ Literal["deprecated_none", "email", "manual", "none", "stripe_email"]
+ ]
+ """
+ The method Stripe should use to notify the customer of upcoming debit instructions and/or mandate confirmation as required by the underlying debit network. Either `email` (an email is sent directly to the customer), `manual` (a `source.mandate_notification` event is sent to your webhooks endpoint and you should handle the notification) or `none` (the underlying debit network does not require any notification).
+ """
+
+
+class SourceCreateParamsMandateAcceptance(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the mandate was accepted or refused by the customer.
+ """
+ offline: NotRequired["SourceCreateParamsMandateAcceptanceOffline"]
+ """
+ The parameters required to store a mandate accepted offline. Should only be set if `mandate[type]` is `offline`
+ """
+ online: NotRequired["SourceCreateParamsMandateAcceptanceOnline"]
+ """
+ The parameters required to store a mandate accepted online. Should only be set if `mandate[type]` is `online`
+ """
+ status: Literal["accepted", "pending", "refused", "revoked"]
+ """
+ The status of the mandate acceptance. Either `accepted` (the mandate was accepted) or `refused` (the mandate was refused).
+ """
+ type: NotRequired[Literal["offline", "online"]]
+ """
+ The type of acceptance information included with the mandate. Either `online` or `offline`
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the mandate was accepted or refused by the customer.
+ """
+
+
+class SourceCreateParamsMandateAcceptanceOffline(TypedDict):
+ contact_email: str
+ """
+ An email to contact you with if a copy of the mandate is requested, required if `type` is `offline`.
+ """
+
+
+class SourceCreateParamsMandateAcceptanceOnline(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the mandate was accepted or refused by the customer.
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the mandate was accepted or refused by the customer.
+ """
+
+
+class SourceCreateParamsOwner(TypedDict):
+ address: NotRequired["SourceCreateParamsOwnerAddress"]
+ """
+ Owner's address.
+ """
+ email: NotRequired[str]
+ """
+ Owner's email address.
+ """
+ name: NotRequired[str]
+ """
+ Owner's full name.
+ """
+ phone: NotRequired[str]
+ """
+ Owner's phone number.
+ """
+
+
+class SourceCreateParamsOwnerAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class SourceCreateParamsReceiver(TypedDict):
+ refund_attributes_method: NotRequired[Literal["email", "manual", "none"]]
+ """
+ The method Stripe should use to request information needed to process a refund or mispayment. Either `email` (an email is sent directly to the customer) or `manual` (a `source.refund_attributes_required` event is sent to your webhooks endpoint). Refer to each payment method's documentation to learn which refund attributes may be required.
+ """
+
+
+class SourceCreateParamsRedirect(TypedDict):
+ return_url: str
+ """
+ The URL you provide to redirect the customer back to you after they authenticated their payment. It can use your application URI scheme in the context of a mobile application.
+ """
+
+
+class SourceCreateParamsSourceOrder(TypedDict):
+ items: NotRequired[List["SourceCreateParamsSourceOrderItem"]]
+ """
+ List of items constituting the order.
+ """
+ shipping: NotRequired["SourceCreateParamsSourceOrderShipping"]
+ """
+ Shipping address for the order. Required if any of the SKUs are for products that have `shippable` set to true.
+ """
+
+
+class SourceCreateParamsSourceOrderItem(TypedDict):
+ amount: NotRequired[int]
+ currency: NotRequired[str]
+ description: NotRequired[str]
+ parent: NotRequired[str]
+ """
+ The ID of the SKU being ordered.
+ """
+ quantity: NotRequired[int]
+ """
+ The quantity of this order item. When type is `sku`, this is the number of instances of the SKU to be ordered.
+ """
+ type: NotRequired[Literal["discount", "shipping", "sku", "tax"]]
+
+
+class SourceCreateParamsSourceOrderShipping(TypedDict):
+ address: "SourceCreateParamsSourceOrderShippingAddress"
+ """
+ Shipping address.
+ """
+ carrier: NotRequired[str]
+ """
+ The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
+ """
+ name: NotRequired[str]
+ """
+ Recipient name.
+ """
+ phone: NotRequired[str]
+ """
+ Recipient phone (including extension).
+ """
+ tracking_number: NotRequired[str]
+ """
+ The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
+ """
+
+
+class SourceCreateParamsSourceOrderShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: str
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
diff --git a/stripe/params/_source_detach_params.py b/stripe/params/_source_detach_params.py
new file mode 100644
index 000000000..854bb41db
--- /dev/null
+++ b/stripe/params/_source_detach_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class SourceDetachParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_source_list_source_transactions_params.py b/stripe/params/_source_list_source_transactions_params.py
new file mode 100644
index 000000000..67310857c
--- /dev/null
+++ b/stripe/params/_source_list_source_transactions_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SourceListSourceTransactionsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_source_modify_params.py b/stripe/params/_source_modify_params.py
new file mode 100644
index 000000000..f57584e1d
--- /dev/null
+++ b/stripe/params/_source_modify_params.py
@@ -0,0 +1,232 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SourceModifyParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ Amount associated with the source.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ mandate: NotRequired["SourceModifyParamsMandate"]
+ """
+ Information about a mandate possibility attached to a source object (generally for bank debits) as well as its acceptance status.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ owner: NotRequired["SourceModifyParamsOwner"]
+ """
+ Information about the owner of the payment instrument that may be used or required by particular source types.
+ """
+ source_order: NotRequired["SourceModifyParamsSourceOrder"]
+ """
+ Information about the items and shipping associated with the source. Required for transactional credit (for example Klarna) sources before you can charge it.
+ """
+
+
+class SourceModifyParamsMandate(TypedDict):
+ acceptance: NotRequired["SourceModifyParamsMandateAcceptance"]
+ """
+ The parameters required to notify Stripe of a mandate acceptance or refusal by the customer.
+ """
+ amount: NotRequired["Literal['']|int"]
+ """
+ The amount specified by the mandate. (Leave null for a mandate covering all amounts)
+ """
+ currency: NotRequired[str]
+ """
+ The currency specified by the mandate. (Must match `currency` of the source)
+ """
+ interval: NotRequired[Literal["one_time", "scheduled", "variable"]]
+ """
+ The interval of debits permitted by the mandate. Either `one_time` (just permitting a single debit), `scheduled` (with debits on an agreed schedule or for clearly-defined events), or `variable`(for debits with any frequency)
+ """
+ notification_method: NotRequired[
+ Literal["deprecated_none", "email", "manual", "none", "stripe_email"]
+ ]
+ """
+ The method Stripe should use to notify the customer of upcoming debit instructions and/or mandate confirmation as required by the underlying debit network. Either `email` (an email is sent directly to the customer), `manual` (a `source.mandate_notification` event is sent to your webhooks endpoint and you should handle the notification) or `none` (the underlying debit network does not require any notification).
+ """
+
+
+class SourceModifyParamsMandateAcceptance(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the mandate was accepted or refused by the customer.
+ """
+ offline: NotRequired["SourceModifyParamsMandateAcceptanceOffline"]
+ """
+ The parameters required to store a mandate accepted offline. Should only be set if `mandate[type]` is `offline`
+ """
+ online: NotRequired["SourceModifyParamsMandateAcceptanceOnline"]
+ """
+ The parameters required to store a mandate accepted online. Should only be set if `mandate[type]` is `online`
+ """
+ status: Literal["accepted", "pending", "refused", "revoked"]
+ """
+ The status of the mandate acceptance. Either `accepted` (the mandate was accepted) or `refused` (the mandate was refused).
+ """
+ type: NotRequired[Literal["offline", "online"]]
+ """
+ The type of acceptance information included with the mandate. Either `online` or `offline`
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the mandate was accepted or refused by the customer.
+ """
+
+
+class SourceModifyParamsMandateAcceptanceOffline(TypedDict):
+ contact_email: str
+ """
+ An email to contact you with if a copy of the mandate is requested, required if `type` is `offline`.
+ """
+
+
+class SourceModifyParamsMandateAcceptanceOnline(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the mandate was accepted or refused by the customer.
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the mandate was accepted or refused by the customer.
+ """
+
+
+class SourceModifyParamsOwner(TypedDict):
+ address: NotRequired["SourceModifyParamsOwnerAddress"]
+ """
+ Owner's address.
+ """
+ email: NotRequired[str]
+ """
+ Owner's email address.
+ """
+ name: NotRequired[str]
+ """
+ Owner's full name.
+ """
+ phone: NotRequired[str]
+ """
+ Owner's phone number.
+ """
+
+
+class SourceModifyParamsOwnerAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class SourceModifyParamsSourceOrder(TypedDict):
+ items: NotRequired[List["SourceModifyParamsSourceOrderItem"]]
+ """
+ List of items constituting the order.
+ """
+ shipping: NotRequired["SourceModifyParamsSourceOrderShipping"]
+ """
+ Shipping address for the order. Required if any of the SKUs are for products that have `shippable` set to true.
+ """
+
+
+class SourceModifyParamsSourceOrderItem(TypedDict):
+ amount: NotRequired[int]
+ currency: NotRequired[str]
+ description: NotRequired[str]
+ parent: NotRequired[str]
+ """
+ The ID of the SKU being ordered.
+ """
+ quantity: NotRequired[int]
+ """
+ The quantity of this order item. When type is `sku`, this is the number of instances of the SKU to be ordered.
+ """
+ type: NotRequired[Literal["discount", "shipping", "sku", "tax"]]
+
+
+class SourceModifyParamsSourceOrderShipping(TypedDict):
+ address: "SourceModifyParamsSourceOrderShippingAddress"
+ """
+ Shipping address.
+ """
+ carrier: NotRequired[str]
+ """
+ The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
+ """
+ name: NotRequired[str]
+ """
+ Recipient name.
+ """
+ phone: NotRequired[str]
+ """
+ Recipient phone (including extension).
+ """
+ tracking_number: NotRequired[str]
+ """
+ The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
+ """
+
+
+class SourceModifyParamsSourceOrderShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: str
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
diff --git a/stripe/params/_source_retrieve_params.py b/stripe/params/_source_retrieve_params.py
new file mode 100644
index 000000000..cea482bde
--- /dev/null
+++ b/stripe/params/_source_retrieve_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SourceRetrieveParams(RequestOptions):
+ client_secret: NotRequired[str]
+ """
+ The client secret of the source. Required if a publishable key is used to retrieve the source.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_source_transaction_list_params.py b/stripe/params/_source_transaction_list_params.py
new file mode 100644
index 000000000..bdc215da3
--- /dev/null
+++ b/stripe/params/_source_transaction_list_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class SourceTransactionListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_source_update_params.py b/stripe/params/_source_update_params.py
new file mode 100644
index 000000000..ff800484c
--- /dev/null
+++ b/stripe/params/_source_update_params.py
@@ -0,0 +1,231 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SourceUpdateParams(TypedDict):
+ amount: NotRequired[int]
+ """
+ Amount associated with the source.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ mandate: NotRequired["SourceUpdateParamsMandate"]
+ """
+ Information about a mandate possibility attached to a source object (generally for bank debits) as well as its acceptance status.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ owner: NotRequired["SourceUpdateParamsOwner"]
+ """
+ Information about the owner of the payment instrument that may be used or required by particular source types.
+ """
+ source_order: NotRequired["SourceUpdateParamsSourceOrder"]
+ """
+ Information about the items and shipping associated with the source. Required for transactional credit (for example Klarna) sources before you can charge it.
+ """
+
+
+class SourceUpdateParamsMandate(TypedDict):
+ acceptance: NotRequired["SourceUpdateParamsMandateAcceptance"]
+ """
+ The parameters required to notify Stripe of a mandate acceptance or refusal by the customer.
+ """
+ amount: NotRequired["Literal['']|int"]
+ """
+ The amount specified by the mandate. (Leave null for a mandate covering all amounts)
+ """
+ currency: NotRequired[str]
+ """
+ The currency specified by the mandate. (Must match `currency` of the source)
+ """
+ interval: NotRequired[Literal["one_time", "scheduled", "variable"]]
+ """
+ The interval of debits permitted by the mandate. Either `one_time` (just permitting a single debit), `scheduled` (with debits on an agreed schedule or for clearly-defined events), or `variable`(for debits with any frequency)
+ """
+ notification_method: NotRequired[
+ Literal["deprecated_none", "email", "manual", "none", "stripe_email"]
+ ]
+ """
+ The method Stripe should use to notify the customer of upcoming debit instructions and/or mandate confirmation as required by the underlying debit network. Either `email` (an email is sent directly to the customer), `manual` (a `source.mandate_notification` event is sent to your webhooks endpoint and you should handle the notification) or `none` (the underlying debit network does not require any notification).
+ """
+
+
+class SourceUpdateParamsMandateAcceptance(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the mandate was accepted or refused by the customer.
+ """
+ offline: NotRequired["SourceUpdateParamsMandateAcceptanceOffline"]
+ """
+ The parameters required to store a mandate accepted offline. Should only be set if `mandate[type]` is `offline`
+ """
+ online: NotRequired["SourceUpdateParamsMandateAcceptanceOnline"]
+ """
+ The parameters required to store a mandate accepted online. Should only be set if `mandate[type]` is `online`
+ """
+ status: Literal["accepted", "pending", "refused", "revoked"]
+ """
+ The status of the mandate acceptance. Either `accepted` (the mandate was accepted) or `refused` (the mandate was refused).
+ """
+ type: NotRequired[Literal["offline", "online"]]
+ """
+ The type of acceptance information included with the mandate. Either `online` or `offline`
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the mandate was accepted or refused by the customer.
+ """
+
+
+class SourceUpdateParamsMandateAcceptanceOffline(TypedDict):
+ contact_email: str
+ """
+ An email to contact you with if a copy of the mandate is requested, required if `type` is `offline`.
+ """
+
+
+class SourceUpdateParamsMandateAcceptanceOnline(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the mandate was accepted or refused by the customer.
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the mandate was accepted or refused by the customer.
+ """
+
+
+class SourceUpdateParamsOwner(TypedDict):
+ address: NotRequired["SourceUpdateParamsOwnerAddress"]
+ """
+ Owner's address.
+ """
+ email: NotRequired[str]
+ """
+ Owner's email address.
+ """
+ name: NotRequired[str]
+ """
+ Owner's full name.
+ """
+ phone: NotRequired[str]
+ """
+ Owner's phone number.
+ """
+
+
+class SourceUpdateParamsOwnerAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class SourceUpdateParamsSourceOrder(TypedDict):
+ items: NotRequired[List["SourceUpdateParamsSourceOrderItem"]]
+ """
+ List of items constituting the order.
+ """
+ shipping: NotRequired["SourceUpdateParamsSourceOrderShipping"]
+ """
+ Shipping address for the order. Required if any of the SKUs are for products that have `shippable` set to true.
+ """
+
+
+class SourceUpdateParamsSourceOrderItem(TypedDict):
+ amount: NotRequired[int]
+ currency: NotRequired[str]
+ description: NotRequired[str]
+ parent: NotRequired[str]
+ """
+ The ID of the SKU being ordered.
+ """
+ quantity: NotRequired[int]
+ """
+ The quantity of this order item. When type is `sku`, this is the number of instances of the SKU to be ordered.
+ """
+ type: NotRequired[Literal["discount", "shipping", "sku", "tax"]]
+
+
+class SourceUpdateParamsSourceOrderShipping(TypedDict):
+ address: "SourceUpdateParamsSourceOrderShippingAddress"
+ """
+ Shipping address.
+ """
+ carrier: NotRequired[str]
+ """
+ The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
+ """
+ name: NotRequired[str]
+ """
+ Recipient name.
+ """
+ phone: NotRequired[str]
+ """
+ Recipient phone (including extension).
+ """
+ tracking_number: NotRequired[str]
+ """
+ The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
+ """
+
+
+class SourceUpdateParamsSourceOrderShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: str
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
diff --git a/stripe/params/_source_verify_params.py b/stripe/params/_source_verify_params.py
new file mode 100644
index 000000000..81b9e83cc
--- /dev/null
+++ b/stripe/params/_source_verify_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SourceVerifyParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ values: List[str]
+ """
+ The values needed to verify the source.
+ """
diff --git a/stripe/params/_subscription_cancel_params.py b/stripe/params/_subscription_cancel_params.py
new file mode 100644
index 000000000..503bdb00e
--- /dev/null
+++ b/stripe/params/_subscription_cancel_params.py
@@ -0,0 +1,39 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SubscriptionCancelParams(RequestOptions):
+ cancellation_details: NotRequired[
+ "SubscriptionCancelParamsCancellationDetails"
+ ]
+ """
+ Details about why this subscription was cancelled
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice_now: NotRequired[bool]
+ """
+ Will generate a final invoice that invoices for any un-invoiced metered usage and new/pending proration invoice items. Defaults to `false`.
+ """
+ prorate: NotRequired[bool]
+ """
+ Will generate a proration invoice item that credits remaining unused time until the subscription period end. Defaults to `false`.
+ """
+
+
+class SubscriptionCancelParamsCancellationDetails(TypedDict):
+ comment: NotRequired["Literal['']|str"]
+ """
+ Additional comments about why the user canceled the subscription, if the subscription was canceled explicitly by the user.
+ """
+ feedback: NotRequired[
+ "Literal['']|Literal['customer_service', 'low_quality', 'missing_features', 'other', 'switched_service', 'too_complex', 'too_expensive', 'unused']"
+ ]
+ """
+ The customer submitted reason for why they canceled, if the subscription was canceled explicitly by the user.
+ """
diff --git a/stripe/params/_subscription_create_params.py b/stripe/params/_subscription_create_params.py
new file mode 100644
index 000000000..c6b648146
--- /dev/null
+++ b/stripe/params/_subscription_create_params.py
@@ -0,0 +1,780 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SubscriptionCreateParams(RequestOptions):
+ add_invoice_items: NotRequired[
+ List["SubscriptionCreateParamsAddInvoiceItem"]
+ ]
+ """
+ A list of prices and quantities that will generate invoice items appended to the next invoice for this subscription. You may pass up to 20 items.
+ """
+ application_fee_percent: NotRequired["Literal['']|float"]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
+ """
+ automatic_tax: NotRequired["SubscriptionCreateParamsAutomaticTax"]
+ """
+ Automatic tax settings for this subscription.
+ """
+ backdate_start_date: NotRequired[int]
+ """
+ A past timestamp to backdate the subscription's start date to. If set, the first invoice will contain line items for the timespan between the start date and the current time. Can be combined with trials and the billing cycle anchor.
+ """
+ billing_cycle_anchor: NotRequired[int]
+ """
+ A future timestamp in UTC format to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). The anchor is the reference point that aligns future billing cycle dates. It sets the day of week for `week` intervals, the day of month for `month` and `year` intervals, and the month of year for `year` intervals.
+ """
+ billing_cycle_anchor_config: NotRequired[
+ "SubscriptionCreateParamsBillingCycleAnchorConfig"
+ ]
+ """
+ Mutually exclusive with billing_cycle_anchor and only valid with monthly and yearly price intervals. When provided, the billing_cycle_anchor is set to the next occurrence of the day_of_month at the hour, minute, and second UTC.
+ """
+ billing_mode: NotRequired["SubscriptionCreateParamsBillingMode"]
+ """
+ Controls how prorations and invoices for subscriptions are calculated and orchestrated.
+ """
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionCreateParamsBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds.
+ """
+ cancel_at: NotRequired["int|Literal['max_period_end', 'min_period_end']"]
+ """
+ A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
+ """
+ cancel_at_period_end: NotRequired[bool]
+ """
+ Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`.
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ customer: str
+ """
+ The identifier of the customer to subscribe.
+ """
+ days_until_due: NotRequired[int]
+ """
+ Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
+ """
+ default_source: NotRequired[str]
+ """
+ ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
+ """
+ default_tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription.
+ """
+ description: NotRequired[str]
+ """
+ The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[SubscriptionCreateParamsDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the subscription. If not specified or empty, inherits the discount from the subscription's customer.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice_settings: NotRequired["SubscriptionCreateParamsInvoiceSettings"]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ items: NotRequired[List["SubscriptionCreateParamsItem"]]
+ """
+ A list of up to 20 subscription items, each with an attached price.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ off_session: NotRequired[bool]
+ """
+ Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
+ """
+ on_behalf_of: NotRequired["Literal['']|str"]
+ """
+ The account on behalf of which to charge, for each of the subscription's invoices.
+ """
+ payment_behavior: NotRequired[
+ Literal[
+ "allow_incomplete",
+ "default_incomplete",
+ "error_if_incomplete",
+ "pending_if_incomplete",
+ ]
+ ]
+ """
+ Only applies to subscriptions with `collection_method=charge_automatically`.
+
+ Use `allow_incomplete` to create Subscriptions with `status=incomplete` if the first invoice can't be paid. Creating Subscriptions with this status allows you to manage scenarios where additional customer actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
+
+ Use `default_incomplete` to create Subscriptions with `status=incomplete` when the first invoice requires payment, otherwise start as active. Subscriptions transition to `status=active` when successfully confirming the PaymentIntent on the first invoice. This allows simpler management of scenarios where additional customer actions are needed to pay a subscription's invoice, such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method. If the PaymentIntent is not confirmed within 23 hours Subscriptions transition to `status=incomplete_expired`, which is a terminal state.
+
+ Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice can't be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further customer action is needed, this parameter doesn't create a Subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.
+
+ `pending_if_incomplete` is only used with updates and cannot be passed when creating a Subscription.
+
+ Subscriptions with `collection_method=send_invoice` are automatically activated regardless of the first Invoice status.
+ """
+ payment_settings: NotRequired["SubscriptionCreateParamsPaymentSettings"]
+ """
+ Payment settings to pass to invoices created by the subscription.
+ """
+ pending_invoice_item_interval: NotRequired[
+ "Literal['']|SubscriptionCreateParamsPendingInvoiceItemInterval"
+ ]
+ """
+ Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) resulting from the `billing_cycle_anchor`. If no value is passed, the default is `create_prorations`.
+ """
+ transfer_data: NotRequired["SubscriptionCreateParamsTransferData"]
+ """
+ If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges.
+ """
+ trial_end: NotRequired["Literal['now']|int"]
+ """
+ Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
+ """
+ trial_from_plan: NotRequired[bool]
+ """
+ Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
+ """
+ trial_period_days: NotRequired[int]
+ """
+ Integer representing the number of trial period days before the customer is charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
+ """
+ trial_settings: NotRequired["SubscriptionCreateParamsTrialSettings"]
+ """
+ Settings related to subscription trials.
+ """
+
+
+class SubscriptionCreateParamsAddInvoiceItem(TypedDict):
+ discounts: NotRequired[
+ List["SubscriptionCreateParamsAddInvoiceItemDiscount"]
+ ]
+ """
+ The coupons to redeem into discounts for the item.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ period: NotRequired["SubscriptionCreateParamsAddInvoiceItemPeriod"]
+ """
+ The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required.
+ """
+ price_data: NotRequired["SubscriptionCreateParamsAddInvoiceItemPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: NotRequired[int]
+ """
+ Quantity for this item. Defaults to 1.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
+ """
+
+
+class SubscriptionCreateParamsAddInvoiceItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionCreateParamsAddInvoiceItemPeriod(TypedDict):
+ end: "SubscriptionCreateParamsAddInvoiceItemPeriodEnd"
+ """
+ End of the invoice item period.
+ """
+ start: "SubscriptionCreateParamsAddInvoiceItemPeriodStart"
+ """
+ Start of the invoice item period.
+ """
+
+
+class SubscriptionCreateParamsAddInvoiceItemPeriodEnd(TypedDict):
+ timestamp: NotRequired[int]
+ """
+ A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
+ """
+ type: Literal["min_item_period_end", "timestamp"]
+ """
+ Select how to calculate the end of the invoice item period.
+ """
+
+
+class SubscriptionCreateParamsAddInvoiceItemPeriodStart(TypedDict):
+ timestamp: NotRequired[int]
+ """
+ A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
+ """
+ type: Literal["max_item_period_start", "now", "timestamp"]
+ """
+ Select how to calculate the start of the invoice item period.
+ """
+
+
+class SubscriptionCreateParamsAddInvoiceItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SubscriptionCreateParamsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
+ """
+ liability: NotRequired["SubscriptionCreateParamsAutomaticTaxLiability"]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class SubscriptionCreateParamsAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionCreateParamsBillingCycleAnchorConfig(TypedDict):
+ day_of_month: int
+ """
+ The day of the month the anchor should be. Ranges from 1 to 31.
+ """
+ hour: NotRequired[int]
+ """
+ The hour of the day the anchor should be. Ranges from 0 to 23.
+ """
+ minute: NotRequired[int]
+ """
+ The minute of the hour the anchor should be. Ranges from 0 to 59.
+ """
+ month: NotRequired[int]
+ """
+ The month to start full cycle periods. Ranges from 1 to 12.
+ """
+ second: NotRequired[int]
+ """
+ The second of the minute the anchor should be. Ranges from 0 to 59.
+ """
+
+
+class SubscriptionCreateParamsBillingMode(TypedDict):
+ flexible: NotRequired["SubscriptionCreateParamsBillingModeFlexible"]
+ """
+ Configure behavior for flexible billing mode.
+ """
+ type: Literal["classic", "flexible"]
+ """
+ Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
+ """
+
+
+class SubscriptionCreateParamsBillingModeFlexible(TypedDict):
+ proration_discounts: NotRequired[Literal["included", "itemized"]]
+ """
+ Controls how invoices and invoice items display proration amounts and discount amounts.
+ """
+
+
+class SubscriptionCreateParamsBillingThresholds(TypedDict):
+ amount_gte: NotRequired[int]
+ """
+ Monetary threshold that triggers the subscription to advance to a new billing period
+ """
+ reset_billing_cycle_anchor: NotRequired[bool]
+ """
+ Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
+ """
+
+
+class SubscriptionCreateParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionCreateParamsInvoiceSettings(TypedDict):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with the subscription. Will be set on invoices generated by the subscription.
+ """
+ issuer: NotRequired["SubscriptionCreateParamsInvoiceSettingsIssuer"]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class SubscriptionCreateParamsInvoiceSettingsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionCreateParamsItem(TypedDict):
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionCreateParamsItemBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[SubscriptionCreateParamsItemDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the subscription item.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ plan: NotRequired[str]
+ """
+ Plan ID for this item, as a string.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object.
+ """
+ price_data: NotRequired["SubscriptionCreateParamsItemPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
+ """
+ quantity: NotRequired[int]
+ """
+ Quantity for this item.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
+ """
+
+
+class SubscriptionCreateParamsItemBillingThresholds(TypedDict):
+ usage_gte: int
+ """
+ Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
+ """
+
+
+class SubscriptionCreateParamsItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionCreateParamsItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ recurring: "SubscriptionCreateParamsItemPriceDataRecurring"
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SubscriptionCreateParamsItemPriceDataRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
+
+
+class SubscriptionCreateParamsPaymentSettings(TypedDict):
+ payment_method_options: NotRequired[
+ "SubscriptionCreateParamsPaymentSettingsPaymentMethodOptions"
+ ]
+ """
+ Payment-method-specific configuration to provide to invoices created by the subscription.
+ """
+ payment_method_types: NotRequired[
+ "Literal['']|List[Literal['ach_credit_transfer', 'ach_debit', 'acss_debit', 'affirm', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'jp_credit_transfer', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'link', 'multibanco', 'naver_pay', 'nz_bank_account', 'p24', 'payco', 'paynow', 'paypal', 'promptpay', 'revolut_pay', 'sepa_credit_transfer', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
+ ]
+ """
+ The list of payment method types (e.g. card) to provide to the invoice's PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice's default payment method, the subscription's default payment method, the customer's default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice). Should not be specified with payment_method_configuration
+ """
+ save_default_payment_method: NotRequired[Literal["off", "on_subscription"]]
+ """
+ Configure whether Stripe updates `subscription.default_payment_method` when payment succeeds. Defaults to `off` if unspecified.
+ """
+
+
+class SubscriptionCreateParamsPaymentSettingsPaymentMethodOptions(TypedDict):
+ acss_debit: NotRequired[
+ "Literal['']|SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsAcssDebit"
+ ]
+ """
+ This sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice's PaymentIntent.
+ """
+ bancontact: NotRequired[
+ "Literal['']|SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsBancontact"
+ ]
+ """
+ This sub-hash contains details about the Bancontact payment method options to pass to the invoice's PaymentIntent.
+ """
+ card: NotRequired[
+ "Literal['']|SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsCard"
+ ]
+ """
+ This sub-hash contains details about the Card payment method options to pass to the invoice's PaymentIntent.
+ """
+ customer_balance: NotRequired[
+ "Literal['']|SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance"
+ ]
+ """
+ This sub-hash contains details about the Bank transfer payment method options to pass to the invoice's PaymentIntent.
+ """
+ konbini: NotRequired[
+ "Literal['']|SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsKonbini"
+ ]
+ """
+ This sub-hash contains details about the Konbini payment method options to pass to the invoice's PaymentIntent.
+ """
+ sepa_debit: NotRequired[
+ "Literal['']|SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsSepaDebit"
+ ]
+ """
+ This sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice's PaymentIntent.
+ """
+ us_bank_account: NotRequired[
+ "Literal['']|SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ This sub-hash contains details about the ACH direct debit payment method options to pass to the invoice's PaymentIntent.
+ """
+
+
+class SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsAcssDebit(
+ TypedDict,
+):
+ mandate_options: NotRequired[
+ "SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Verification method for the intent
+ """
+
+
+class SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions(
+ TypedDict,
+):
+ transaction_type: NotRequired[Literal["business", "personal"]]
+ """
+ Transaction type of the mandate.
+ """
+
+
+class SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsBancontact(
+ TypedDict,
+):
+ preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
+ """
+ Preferred language of the Bancontact authorization page that the customer is redirected to.
+ """
+
+
+class SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsCard(
+ TypedDict,
+):
+ mandate_options: NotRequired[
+ "SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsCardMandateOptions"
+ ]
+ """
+ Configuration options for setting up an eMandate for cards issued in India.
+ """
+ network: NotRequired[
+ Literal[
+ "amex",
+ "cartes_bancaires",
+ "diners",
+ "discover",
+ "eftpos_au",
+ "girocard",
+ "interac",
+ "jcb",
+ "link",
+ "mastercard",
+ "unionpay",
+ "unknown",
+ "visa",
+ ]
+ ]
+ """
+ Selected network to process this Subscription on. Depends on the available networks of the card attached to the Subscription. Can be only set confirm-time.
+ """
+ request_three_d_secure: NotRequired[
+ Literal["any", "automatic", "challenge"]
+ ]
+ """
+ We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
+ """
+
+
+class SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsCardMandateOptions(
+ TypedDict,
+):
+ amount: NotRequired[int]
+ """
+ Amount to be charged for future payments.
+ """
+ amount_type: NotRequired[Literal["fixed", "maximum"]]
+ """
+ One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
+ """
+ description: NotRequired[str]
+ """
+ A description of the mandate or subscription that is meant to be displayed to the customer.
+ """
+
+
+class SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance(
+ TypedDict,
+):
+ bank_transfer: NotRequired[
+ "SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer"
+ ]
+ """
+ Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
+ """
+ funding_type: NotRequired[str]
+ """
+ The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
+ """
+
+
+class SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer(
+ TypedDict,
+):
+ eu_bank_transfer: NotRequired[
+ "SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
+ ]
+ """
+ Configuration for eu_bank_transfer funding type.
+ """
+ type: NotRequired[str]
+ """
+ The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
+ """
+
+
+class SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
+ TypedDict,
+):
+ country: str
+ """
+ The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
+ """
+
+
+class SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsKonbini(
+ TypedDict,
+):
+ pass
+
+
+class SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsSepaDebit(
+ TypedDict,
+):
+ pass
+
+
+class SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount(
+ TypedDict,
+):
+ financial_connections: NotRequired[
+ "SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections"
+ ]
+ """
+ Additional fields for Financial Connections Session creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Verification method for the intent
+ """
+
+
+class SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections(
+ TypedDict,
+):
+ filters: NotRequired[
+ "SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
+ ]
+ """
+ Provide filters for the linked accounts that the customer can select for the payment method.
+ """
+ permissions: NotRequired[
+ List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ ]
+ """
+ The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+
+
+class SubscriptionCreateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
+ TypedDict,
+):
+ account_subcategories: NotRequired[List[Literal["checking", "savings"]]]
+ """
+ The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
+ """
+
+
+class SubscriptionCreateParamsPendingInvoiceItemInterval(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies invoicing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks).
+ """
+
+
+class SubscriptionCreateParamsTransferData(TypedDict):
+ amount_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
+
+
+class SubscriptionCreateParamsTrialSettings(TypedDict):
+ end_behavior: "SubscriptionCreateParamsTrialSettingsEndBehavior"
+ """
+ Defines how the subscription should behave when the user's free trial ends.
+ """
+
+
+class SubscriptionCreateParamsTrialSettingsEndBehavior(TypedDict):
+ missing_payment_method: Literal["cancel", "create_invoice", "pause"]
+ """
+ Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
+ """
diff --git a/stripe/params/_subscription_delete_discount_params.py b/stripe/params/_subscription_delete_discount_params.py
new file mode 100644
index 000000000..79ade64ec
--- /dev/null
+++ b/stripe/params/_subscription_delete_discount_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class SubscriptionDeleteDiscountParams(RequestOptions):
+ pass
diff --git a/stripe/params/_subscription_item_create_params.py b/stripe/params/_subscription_item_create_params.py
new file mode 100644
index 000000000..7b139d102
--- /dev/null
+++ b/stripe/params/_subscription_item_create_params.py
@@ -0,0 +1,139 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SubscriptionItemCreateParams(RequestOptions):
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionItemCreateParamsBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[SubscriptionItemCreateParamsDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the subscription item.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ payment_behavior: NotRequired[
+ Literal[
+ "allow_incomplete",
+ "default_incomplete",
+ "error_if_incomplete",
+ "pending_if_incomplete",
+ ]
+ ]
+ """
+ Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
+
+ Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription's invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
+
+ Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
+
+ Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://docs.stripe.com/changelog/2019-03-14) to learn more.
+ """
+ plan: NotRequired[str]
+ """
+ The identifier of the plan to add to the subscription.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object.
+ """
+ price_data: NotRequired["SubscriptionItemCreateParamsPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
+ """
+ proration_date: NotRequired[int]
+ """
+ If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
+ """
+ quantity: NotRequired[int]
+ """
+ The quantity you'd like to apply to the subscription item you're creating.
+ """
+ subscription: str
+ """
+ The identifier of the subscription to modify.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
+ """
+
+
+class SubscriptionItemCreateParamsBillingThresholds(TypedDict):
+ usage_gte: int
+ """
+ Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
+ """
+
+
+class SubscriptionItemCreateParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionItemCreateParamsPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ recurring: "SubscriptionItemCreateParamsPriceDataRecurring"
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SubscriptionItemCreateParamsPriceDataRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
diff --git a/stripe/params/_subscription_item_delete_params.py b/stripe/params/_subscription_item_delete_params.py
new file mode 100644
index 000000000..2355bfe58
--- /dev/null
+++ b/stripe/params/_subscription_item_delete_params.py
@@ -0,0 +1,21 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing_extensions import Literal, NotRequired
+
+
+class SubscriptionItemDeleteParams(RequestOptions):
+ clear_usage: NotRequired[bool]
+ """
+ Delete all usage for the given subscription item. Allowed only when the current plan's `usage_type` is `metered`.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
+ """
+ proration_date: NotRequired[int]
+ """
+ If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
+ """
diff --git a/stripe/params/_subscription_item_list_params.py b/stripe/params/_subscription_item_list_params.py
new file mode 100644
index 000000000..38b3a9352
--- /dev/null
+++ b/stripe/params/_subscription_item_list_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SubscriptionItemListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ subscription: str
+ """
+ The ID of the subscription whose items will be retrieved.
+ """
diff --git a/stripe/params/_subscription_item_modify_params.py b/stripe/params/_subscription_item_modify_params.py
new file mode 100644
index 000000000..9759b7211
--- /dev/null
+++ b/stripe/params/_subscription_item_modify_params.py
@@ -0,0 +1,139 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SubscriptionItemModifyParams(RequestOptions):
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionItemModifyParamsBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[SubscriptionItemModifyParamsDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the subscription item.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ off_session: NotRequired[bool]
+ """
+ Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
+ """
+ payment_behavior: NotRequired[
+ Literal[
+ "allow_incomplete",
+ "default_incomplete",
+ "error_if_incomplete",
+ "pending_if_incomplete",
+ ]
+ ]
+ """
+ Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
+
+ Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription's invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
+
+ Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
+
+ Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://docs.stripe.com/changelog/2019-03-14) to learn more.
+ """
+ plan: NotRequired[str]
+ """
+ The identifier of the new plan for this subscription item.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
+ """
+ price_data: NotRequired["SubscriptionItemModifyParamsPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
+ """
+ proration_date: NotRequired[int]
+ """
+ If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
+ """
+ quantity: NotRequired[int]
+ """
+ The quantity you'd like to apply to the subscription item you're creating.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
+ """
+
+
+class SubscriptionItemModifyParamsBillingThresholds(TypedDict):
+ usage_gte: int
+ """
+ Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
+ """
+
+
+class SubscriptionItemModifyParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionItemModifyParamsPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ recurring: "SubscriptionItemModifyParamsPriceDataRecurring"
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SubscriptionItemModifyParamsPriceDataRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
diff --git a/stripe/params/_subscription_item_retrieve_params.py b/stripe/params/_subscription_item_retrieve_params.py
new file mode 100644
index 000000000..ae8d3d8ce
--- /dev/null
+++ b/stripe/params/_subscription_item_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SubscriptionItemRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_subscription_item_update_params.py b/stripe/params/_subscription_item_update_params.py
new file mode 100644
index 000000000..bd6e0d45a
--- /dev/null
+++ b/stripe/params/_subscription_item_update_params.py
@@ -0,0 +1,138 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SubscriptionItemUpdateParams(TypedDict):
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionItemUpdateParamsBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[SubscriptionItemUpdateParamsDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the subscription item.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ off_session: NotRequired[bool]
+ """
+ Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
+ """
+ payment_behavior: NotRequired[
+ Literal[
+ "allow_incomplete",
+ "default_incomplete",
+ "error_if_incomplete",
+ "pending_if_incomplete",
+ ]
+ ]
+ """
+ Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
+
+ Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription's invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
+
+ Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
+
+ Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://docs.stripe.com/changelog/2019-03-14) to learn more.
+ """
+ plan: NotRequired[str]
+ """
+ The identifier of the new plan for this subscription item.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
+ """
+ price_data: NotRequired["SubscriptionItemUpdateParamsPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
+ """
+ proration_date: NotRequired[int]
+ """
+ If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
+ """
+ quantity: NotRequired[int]
+ """
+ The quantity you'd like to apply to the subscription item you're creating.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
+ """
+
+
+class SubscriptionItemUpdateParamsBillingThresholds(TypedDict):
+ usage_gte: int
+ """
+ Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
+ """
+
+
+class SubscriptionItemUpdateParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionItemUpdateParamsPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ recurring: "SubscriptionItemUpdateParamsPriceDataRecurring"
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SubscriptionItemUpdateParamsPriceDataRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
diff --git a/stripe/params/_subscription_list_params.py b/stripe/params/_subscription_list_params.py
new file mode 100644
index 000000000..d51baa76b
--- /dev/null
+++ b/stripe/params/_subscription_list_params.py
@@ -0,0 +1,147 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SubscriptionListParams(RequestOptions):
+ automatic_tax: NotRequired["SubscriptionListParamsAutomaticTax"]
+ """
+ Filter subscriptions by their automatic tax settings.
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ The collection method of the subscriptions to retrieve. Either `charge_automatically` or `send_invoice`.
+ """
+ created: NotRequired["SubscriptionListParamsCreated|int"]
+ """
+ Only return subscriptions that were created during the given date interval.
+ """
+ current_period_end: NotRequired[
+ "SubscriptionListParamsCurrentPeriodEnd|int"
+ ]
+ """
+ Only return subscriptions whose minimum item current_period_end falls within the given date interval.
+ """
+ current_period_start: NotRequired[
+ "SubscriptionListParamsCurrentPeriodStart|int"
+ ]
+ """
+ Only return subscriptions whose maximum item current_period_start falls within the given date interval.
+ """
+ customer: NotRequired[str]
+ """
+ The ID of the customer whose subscriptions will be retrieved.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ plan: NotRequired[str]
+ """
+ The ID of the plan whose subscriptions will be retrieved.
+ """
+ price: NotRequired[str]
+ """
+ Filter for subscriptions that contain this recurring price ID.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[
+ Literal[
+ "active",
+ "all",
+ "canceled",
+ "ended",
+ "incomplete",
+ "incomplete_expired",
+ "past_due",
+ "paused",
+ "trialing",
+ "unpaid",
+ ]
+ ]
+ """
+ The status of the subscriptions to retrieve. Passing in a value of `canceled` will return all canceled subscriptions, including those belonging to deleted customers. Pass `ended` to find subscriptions that are canceled and subscriptions that are expired due to [incomplete payment](https://stripe.com/docs/billing/subscriptions/overview#subscription-statuses). Passing in a value of `all` will return subscriptions of all statuses. If no value is supplied, all subscriptions that have not been canceled are returned.
+ """
+ test_clock: NotRequired[str]
+ """
+ Filter for subscriptions that are associated with the specified test clock. The response will not include subscriptions with test clocks if this and the customer parameter is not set.
+ """
+
+
+class SubscriptionListParamsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
+ """
+
+
+class SubscriptionListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
+
+
+class SubscriptionListParamsCurrentPeriodEnd(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
+
+
+class SubscriptionListParamsCurrentPeriodStart(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_subscription_migrate_params.py b/stripe/params/_subscription_migrate_params.py
new file mode 100644
index 000000000..fed3c5df5
--- /dev/null
+++ b/stripe/params/_subscription_migrate_params.py
@@ -0,0 +1,34 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SubscriptionMigrateParams(RequestOptions):
+ billing_mode: "SubscriptionMigrateParamsBillingMode"
+ """
+ Controls how prorations and invoices for subscriptions are calculated and orchestrated.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+
+
+class SubscriptionMigrateParamsBillingMode(TypedDict):
+ flexible: NotRequired["SubscriptionMigrateParamsBillingModeFlexible"]
+ """
+ Configure behavior for flexible billing mode.
+ """
+ type: Literal["flexible"]
+ """
+ Controls the calculation and orchestration of prorations and invoices for subscriptions.
+ """
+
+
+class SubscriptionMigrateParamsBillingModeFlexible(TypedDict):
+ proration_discounts: NotRequired[Literal["included", "itemized"]]
+ """
+ Controls how invoices and invoice items display proration amounts and discount amounts.
+ """
diff --git a/stripe/params/_subscription_modify_params.py b/stripe/params/_subscription_modify_params.py
new file mode 100644
index 000000000..3ad599d5d
--- /dev/null
+++ b/stripe/params/_subscription_modify_params.py
@@ -0,0 +1,765 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SubscriptionModifyParams(RequestOptions):
+ add_invoice_items: NotRequired[
+ List["SubscriptionModifyParamsAddInvoiceItem"]
+ ]
+ """
+ A list of prices and quantities that will generate invoice items appended to the next invoice for this subscription. You may pass up to 20 items.
+ """
+ application_fee_percent: NotRequired["Literal['']|float"]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
+ """
+ automatic_tax: NotRequired["SubscriptionModifyParamsAutomaticTax"]
+ """
+ Automatic tax settings for this subscription. We recommend you only include this parameter when the existing value is being changed.
+ """
+ billing_cycle_anchor: NotRequired[Literal["now", "unchanged"]]
+ """
+ Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time (in UTC). For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
+ """
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionModifyParamsBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds.
+ """
+ cancel_at: NotRequired[
+ "Literal['']|int|Literal['max_period_end', 'min_period_end']"
+ ]
+ """
+ A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
+ """
+ cancel_at_period_end: NotRequired[bool]
+ """
+ Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`.
+ """
+ cancellation_details: NotRequired[
+ "SubscriptionModifyParamsCancellationDetails"
+ ]
+ """
+ Details about why this subscription was cancelled
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
+ """
+ days_until_due: NotRequired[int]
+ """
+ Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
+ """
+ default_source: NotRequired["Literal['']|str"]
+ """
+ ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
+ """
+ default_tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription. Pass an empty string to remove previously-defined tax rates.
+ """
+ description: NotRequired["Literal['']|str"]
+ """
+ The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[SubscriptionModifyParamsDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the subscription. If not specified or empty, inherits the discount from the subscription's customer.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice_settings: NotRequired["SubscriptionModifyParamsInvoiceSettings"]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ items: NotRequired[List["SubscriptionModifyParamsItem"]]
+ """
+ A list of up to 20 subscription items, each with an attached price.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ off_session: NotRequired[bool]
+ """
+ Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
+ """
+ on_behalf_of: NotRequired["Literal['']|str"]
+ """
+ The account on behalf of which to charge, for each of the subscription's invoices.
+ """
+ pause_collection: NotRequired[
+ "Literal['']|SubscriptionModifyParamsPauseCollection"
+ ]
+ """
+ If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
+ """
+ payment_behavior: NotRequired[
+ Literal[
+ "allow_incomplete",
+ "default_incomplete",
+ "error_if_incomplete",
+ "pending_if_incomplete",
+ ]
+ ]
+ """
+ Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
+
+ Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription's invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
+
+ Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
+
+ Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://docs.stripe.com/changelog/2019-03-14) to learn more.
+ """
+ payment_settings: NotRequired["SubscriptionModifyParamsPaymentSettings"]
+ """
+ Payment settings to pass to invoices created by the subscription.
+ """
+ pending_invoice_item_interval: NotRequired[
+ "Literal['']|SubscriptionModifyParamsPendingInvoiceItemInterval"
+ ]
+ """
+ Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
+ """
+ proration_date: NotRequired[int]
+ """
+ If set, prorations will be calculated as though the subscription was updated at the given time. This can be used to apply exactly the same prorations that were previewed with the [create preview](https://stripe.com/docs/api/invoices/create_preview) endpoint. `proration_date` can also be used to implement custom proration logic, such as prorating by day instead of by second, by providing the time that you wish to use for proration calculations.
+ """
+ transfer_data: NotRequired[
+ "Literal['']|SubscriptionModifyParamsTransferData"
+ ]
+ """
+ If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges. This will be unset if you POST an empty value.
+ """
+ trial_end: NotRequired["Literal['now']|int"]
+ """
+ Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, `trial_end` will override the default trial period of the plan the customer is being subscribed to. The `billing_cycle_anchor` will be updated to the `trial_end` value. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`.
+ """
+ trial_from_plan: NotRequired[bool]
+ """
+ Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
+ """
+ trial_settings: NotRequired["SubscriptionModifyParamsTrialSettings"]
+ """
+ Settings related to subscription trials.
+ """
+
+
+class SubscriptionModifyParamsAddInvoiceItem(TypedDict):
+ discounts: NotRequired[
+ List["SubscriptionModifyParamsAddInvoiceItemDiscount"]
+ ]
+ """
+ The coupons to redeem into discounts for the item.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ period: NotRequired["SubscriptionModifyParamsAddInvoiceItemPeriod"]
+ """
+ The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required.
+ """
+ price_data: NotRequired["SubscriptionModifyParamsAddInvoiceItemPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: NotRequired[int]
+ """
+ Quantity for this item. Defaults to 1.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
+ """
+
+
+class SubscriptionModifyParamsAddInvoiceItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionModifyParamsAddInvoiceItemPeriod(TypedDict):
+ end: "SubscriptionModifyParamsAddInvoiceItemPeriodEnd"
+ """
+ End of the invoice item period.
+ """
+ start: "SubscriptionModifyParamsAddInvoiceItemPeriodStart"
+ """
+ Start of the invoice item period.
+ """
+
+
+class SubscriptionModifyParamsAddInvoiceItemPeriodEnd(TypedDict):
+ timestamp: NotRequired[int]
+ """
+ A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
+ """
+ type: Literal["min_item_period_end", "timestamp"]
+ """
+ Select how to calculate the end of the invoice item period.
+ """
+
+
+class SubscriptionModifyParamsAddInvoiceItemPeriodStart(TypedDict):
+ timestamp: NotRequired[int]
+ """
+ A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
+ """
+ type: Literal["max_item_period_start", "now", "timestamp"]
+ """
+ Select how to calculate the start of the invoice item period.
+ """
+
+
+class SubscriptionModifyParamsAddInvoiceItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SubscriptionModifyParamsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
+ """
+ liability: NotRequired["SubscriptionModifyParamsAutomaticTaxLiability"]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class SubscriptionModifyParamsAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionModifyParamsBillingThresholds(TypedDict):
+ amount_gte: NotRequired[int]
+ """
+ Monetary threshold that triggers the subscription to advance to a new billing period
+ """
+ reset_billing_cycle_anchor: NotRequired[bool]
+ """
+ Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
+ """
+
+
+class SubscriptionModifyParamsCancellationDetails(TypedDict):
+ comment: NotRequired["Literal['']|str"]
+ """
+ Additional comments about why the user canceled the subscription, if the subscription was canceled explicitly by the user.
+ """
+ feedback: NotRequired[
+ "Literal['']|Literal['customer_service', 'low_quality', 'missing_features', 'other', 'switched_service', 'too_complex', 'too_expensive', 'unused']"
+ ]
+ """
+ The customer submitted reason for why they canceled, if the subscription was canceled explicitly by the user.
+ """
+
+
+class SubscriptionModifyParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionModifyParamsInvoiceSettings(TypedDict):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with the subscription. Will be set on invoices generated by the subscription.
+ """
+ issuer: NotRequired["SubscriptionModifyParamsInvoiceSettingsIssuer"]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class SubscriptionModifyParamsInvoiceSettingsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionModifyParamsItem(TypedDict):
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionModifyParamsItemBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ clear_usage: NotRequired[bool]
+ """
+ Delete all usage for a given subscription item. You must pass this when deleting a usage records subscription item. `clear_usage` has no effect if the plan has a billing meter attached.
+ """
+ deleted: NotRequired[bool]
+ """
+ A flag that, if set to `true`, will delete the specified item.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[SubscriptionModifyParamsItemDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the subscription item.
+ """
+ id: NotRequired[str]
+ """
+ Subscription item to update.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ plan: NotRequired[str]
+ """
+ Plan ID for this item, as a string.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
+ """
+ price_data: NotRequired["SubscriptionModifyParamsItemPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: NotRequired[int]
+ """
+ Quantity for this item.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
+ """
+
+
+class SubscriptionModifyParamsItemBillingThresholds(TypedDict):
+ usage_gte: int
+ """
+ Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
+ """
+
+
+class SubscriptionModifyParamsItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionModifyParamsItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ recurring: "SubscriptionModifyParamsItemPriceDataRecurring"
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SubscriptionModifyParamsItemPriceDataRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
+
+
+class SubscriptionModifyParamsPauseCollection(TypedDict):
+ behavior: Literal["keep_as_draft", "mark_uncollectible", "void"]
+ """
+ The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
+ """
+ resumes_at: NotRequired[int]
+ """
+ The time after which the subscription will resume collecting payments.
+ """
+
+
+class SubscriptionModifyParamsPaymentSettings(TypedDict):
+ payment_method_options: NotRequired[
+ "SubscriptionModifyParamsPaymentSettingsPaymentMethodOptions"
+ ]
+ """
+ Payment-method-specific configuration to provide to invoices created by the subscription.
+ """
+ payment_method_types: NotRequired[
+ "Literal['']|List[Literal['ach_credit_transfer', 'ach_debit', 'acss_debit', 'affirm', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'jp_credit_transfer', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'link', 'multibanco', 'naver_pay', 'nz_bank_account', 'p24', 'payco', 'paynow', 'paypal', 'promptpay', 'revolut_pay', 'sepa_credit_transfer', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
+ ]
+ """
+ The list of payment method types (e.g. card) to provide to the invoice's PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice's default payment method, the subscription's default payment method, the customer's default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice). Should not be specified with payment_method_configuration
+ """
+ save_default_payment_method: NotRequired[Literal["off", "on_subscription"]]
+ """
+ Configure whether Stripe updates `subscription.default_payment_method` when payment succeeds. Defaults to `off` if unspecified.
+ """
+
+
+class SubscriptionModifyParamsPaymentSettingsPaymentMethodOptions(TypedDict):
+ acss_debit: NotRequired[
+ "Literal['']|SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebit"
+ ]
+ """
+ This sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice's PaymentIntent.
+ """
+ bancontact: NotRequired[
+ "Literal['']|SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsBancontact"
+ ]
+ """
+ This sub-hash contains details about the Bancontact payment method options to pass to the invoice's PaymentIntent.
+ """
+ card: NotRequired[
+ "Literal['']|SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsCard"
+ ]
+ """
+ This sub-hash contains details about the Card payment method options to pass to the invoice's PaymentIntent.
+ """
+ customer_balance: NotRequired[
+ "Literal['']|SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalance"
+ ]
+ """
+ This sub-hash contains details about the Bank transfer payment method options to pass to the invoice's PaymentIntent.
+ """
+ konbini: NotRequired[
+ "Literal['']|SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsKonbini"
+ ]
+ """
+ This sub-hash contains details about the Konbini payment method options to pass to the invoice's PaymentIntent.
+ """
+ sepa_debit: NotRequired[
+ "Literal['']|SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsSepaDebit"
+ ]
+ """
+ This sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice's PaymentIntent.
+ """
+ us_bank_account: NotRequired[
+ "Literal['']|SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ This sub-hash contains details about the ACH direct debit payment method options to pass to the invoice's PaymentIntent.
+ """
+
+
+class SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebit(
+ TypedDict,
+):
+ mandate_options: NotRequired[
+ "SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Verification method for the intent
+ """
+
+
+class SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions(
+ TypedDict,
+):
+ transaction_type: NotRequired[Literal["business", "personal"]]
+ """
+ Transaction type of the mandate.
+ """
+
+
+class SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsBancontact(
+ TypedDict,
+):
+ preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
+ """
+ Preferred language of the Bancontact authorization page that the customer is redirected to.
+ """
+
+
+class SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsCard(
+ TypedDict,
+):
+ mandate_options: NotRequired[
+ "SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsCardMandateOptions"
+ ]
+ """
+ Configuration options for setting up an eMandate for cards issued in India.
+ """
+ network: NotRequired[
+ Literal[
+ "amex",
+ "cartes_bancaires",
+ "diners",
+ "discover",
+ "eftpos_au",
+ "girocard",
+ "interac",
+ "jcb",
+ "link",
+ "mastercard",
+ "unionpay",
+ "unknown",
+ "visa",
+ ]
+ ]
+ """
+ Selected network to process this Subscription on. Depends on the available networks of the card attached to the Subscription. Can be only set confirm-time.
+ """
+ request_three_d_secure: NotRequired[
+ Literal["any", "automatic", "challenge"]
+ ]
+ """
+ We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
+ """
+
+
+class SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsCardMandateOptions(
+ TypedDict,
+):
+ amount: NotRequired[int]
+ """
+ Amount to be charged for future payments.
+ """
+ amount_type: NotRequired[Literal["fixed", "maximum"]]
+ """
+ One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
+ """
+ description: NotRequired[str]
+ """
+ A description of the mandate or subscription that is meant to be displayed to the customer.
+ """
+
+
+class SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalance(
+ TypedDict,
+):
+ bank_transfer: NotRequired[
+ "SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer"
+ ]
+ """
+ Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
+ """
+ funding_type: NotRequired[str]
+ """
+ The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
+ """
+
+
+class SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer(
+ TypedDict,
+):
+ eu_bank_transfer: NotRequired[
+ "SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
+ ]
+ """
+ Configuration for eu_bank_transfer funding type.
+ """
+ type: NotRequired[str]
+ """
+ The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
+ """
+
+
+class SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
+ TypedDict,
+):
+ country: str
+ """
+ The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
+ """
+
+
+class SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsKonbini(
+ TypedDict,
+):
+ pass
+
+
+class SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsSepaDebit(
+ TypedDict,
+):
+ pass
+
+
+class SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccount(
+ TypedDict,
+):
+ financial_connections: NotRequired[
+ "SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections"
+ ]
+ """
+ Additional fields for Financial Connections Session creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Verification method for the intent
+ """
+
+
+class SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections(
+ TypedDict,
+):
+ filters: NotRequired[
+ "SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
+ ]
+ """
+ Provide filters for the linked accounts that the customer can select for the payment method.
+ """
+ permissions: NotRequired[
+ List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ ]
+ """
+ The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+
+
+class SubscriptionModifyParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
+ TypedDict,
+):
+ account_subcategories: NotRequired[List[Literal["checking", "savings"]]]
+ """
+ The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
+ """
+
+
+class SubscriptionModifyParamsPendingInvoiceItemInterval(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies invoicing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks).
+ """
+
+
+class SubscriptionModifyParamsTransferData(TypedDict):
+ amount_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
+
+
+class SubscriptionModifyParamsTrialSettings(TypedDict):
+ end_behavior: "SubscriptionModifyParamsTrialSettingsEndBehavior"
+ """
+ Defines how the subscription should behave when the user's free trial ends.
+ """
+
+
+class SubscriptionModifyParamsTrialSettingsEndBehavior(TypedDict):
+ missing_payment_method: Literal["cancel", "create_invoice", "pause"]
+ """
+ Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
+ """
diff --git a/stripe/params/_subscription_resume_params.py b/stripe/params/_subscription_resume_params.py
new file mode 100644
index 000000000..a74e3c7bb
--- /dev/null
+++ b/stripe/params/_subscription_resume_params.py
@@ -0,0 +1,26 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class SubscriptionResumeParams(RequestOptions):
+ billing_cycle_anchor: NotRequired[Literal["now", "unchanged"]]
+ """
+ The billing cycle anchor that applies when the subscription is resumed. Either `now` or `unchanged`. The default is `now`. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) resulting from the `billing_cycle_anchor` being `unchanged`. When the `billing_cycle_anchor` is set to `now` (default value), no prorations are generated. If no value is passed, the default is `create_prorations`.
+ """
+ proration_date: NotRequired[int]
+ """
+ If set, prorations will be calculated as though the subscription was resumed at the given time. This can be used to apply exactly the same prorations that were previewed with the [create preview](https://stripe.com/docs/api/invoices/create_preview) endpoint.
+ """
diff --git a/stripe/params/_subscription_retrieve_params.py b/stripe/params/_subscription_retrieve_params.py
new file mode 100644
index 000000000..17751ff49
--- /dev/null
+++ b/stripe/params/_subscription_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SubscriptionRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_subscription_schedule_cancel_params.py b/stripe/params/_subscription_schedule_cancel_params.py
new file mode 100644
index 000000000..dc84eac03
--- /dev/null
+++ b/stripe/params/_subscription_schedule_cancel_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SubscriptionScheduleCancelParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice_now: NotRequired[bool]
+ """
+ If the subscription schedule is `active`, indicates if a final invoice will be generated that contains any un-invoiced metered usage and new/pending proration invoice items. Defaults to `true`.
+ """
+ prorate: NotRequired[bool]
+ """
+ If the subscription schedule is `active`, indicates if the cancellation should be prorated. Defaults to `true`.
+ """
diff --git a/stripe/params/_subscription_schedule_create_params.py b/stripe/params/_subscription_schedule_create_params.py
new file mode 100644
index 000000000..c27662147
--- /dev/null
+++ b/stripe/params/_subscription_schedule_create_params.py
@@ -0,0 +1,615 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SubscriptionScheduleCreateParams(RequestOptions):
+ billing_mode: NotRequired["SubscriptionScheduleCreateParamsBillingMode"]
+ """
+ Controls how prorations and invoices for subscriptions are calculated and orchestrated.
+ """
+ customer: NotRequired[str]
+ """
+ The identifier of the customer to create the subscription schedule for.
+ """
+ default_settings: NotRequired[
+ "SubscriptionScheduleCreateParamsDefaultSettings"
+ ]
+ """
+ Object representing the subscription schedule's default settings.
+ """
+ end_behavior: NotRequired[Literal["cancel", "none", "release", "renew"]]
+ """
+ Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ from_subscription: NotRequired[str]
+ """
+ Migrate an existing subscription to be managed by a subscription schedule. If this parameter is set, a subscription schedule will be created using the subscription's item(s), set to auto-renew using the subscription's interval. When using this parameter, other parameters (such as phase values) cannot be set. To create a subscription schedule with other modifications, we recommend making two separate API calls.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ phases: NotRequired[List["SubscriptionScheduleCreateParamsPhase"]]
+ """
+ List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.
+ """
+ start_date: NotRequired["int|Literal['now']"]
+ """
+ When the subscription schedule starts. We recommend using `now` so that it starts the subscription immediately. You can also use a Unix timestamp to backdate the subscription so that it starts on a past date, or set a future date for the subscription to start on.
+ """
+
+
+class SubscriptionScheduleCreateParamsBillingMode(TypedDict):
+ flexible: NotRequired[
+ "SubscriptionScheduleCreateParamsBillingModeFlexible"
+ ]
+ """
+ Configure behavior for flexible billing mode.
+ """
+ type: Literal["classic", "flexible"]
+ """
+ Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
+ """
+
+
+class SubscriptionScheduleCreateParamsBillingModeFlexible(TypedDict):
+ proration_discounts: NotRequired[Literal["included", "itemized"]]
+ """
+ Controls how invoices and invoice items display proration amounts and discount amounts.
+ """
+
+
+class SubscriptionScheduleCreateParamsDefaultSettings(TypedDict):
+ application_fee_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
+ """
+ automatic_tax: NotRequired[
+ "SubscriptionScheduleCreateParamsDefaultSettingsAutomaticTax"
+ ]
+ """
+ Default settings for automatic tax computation.
+ """
+ billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
+ """
+ Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
+ """
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionScheduleCreateParamsDefaultSettingsBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
+ """
+ description: NotRequired["Literal['']|str"]
+ """
+ Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
+ """
+ invoice_settings: NotRequired[
+ "SubscriptionScheduleCreateParamsDefaultSettingsInvoiceSettings"
+ ]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ on_behalf_of: NotRequired["Literal['']|str"]
+ """
+ The account on behalf of which to charge, for each of the associated subscription's invoices.
+ """
+ transfer_data: NotRequired[
+ "Literal['']|SubscriptionScheduleCreateParamsDefaultSettingsTransferData"
+ ]
+ """
+ The data with which to automatically create a Transfer for each of the associated subscription's invoices.
+ """
+
+
+class SubscriptionScheduleCreateParamsDefaultSettingsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
+ """
+ liability: NotRequired[
+ "SubscriptionScheduleCreateParamsDefaultSettingsAutomaticTaxLiability"
+ ]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class SubscriptionScheduleCreateParamsDefaultSettingsAutomaticTaxLiability(
+ TypedDict,
+):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionScheduleCreateParamsDefaultSettingsBillingThresholds(
+ TypedDict,
+):
+ amount_gte: NotRequired[int]
+ """
+ Monetary threshold that triggers the subscription to advance to a new billing period
+ """
+ reset_billing_cycle_anchor: NotRequired[bool]
+ """
+ Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
+ """
+
+
+class SubscriptionScheduleCreateParamsDefaultSettingsInvoiceSettings(
+ TypedDict
+):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with the subscription schedule. Will be set on invoices generated by the subscription schedule.
+ """
+ days_until_due: NotRequired[int]
+ """
+ Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `collection_method=charge_automatically`.
+ """
+ issuer: NotRequired[
+ "SubscriptionScheduleCreateParamsDefaultSettingsInvoiceSettingsIssuer"
+ ]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class SubscriptionScheduleCreateParamsDefaultSettingsInvoiceSettingsIssuer(
+ TypedDict,
+):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionScheduleCreateParamsDefaultSettingsTransferData(TypedDict):
+ amount_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhase(TypedDict):
+ add_invoice_items: NotRequired[
+ List["SubscriptionScheduleCreateParamsPhaseAddInvoiceItem"]
+ ]
+ """
+ A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
+ """
+ application_fee_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
+ """
+ automatic_tax: NotRequired[
+ "SubscriptionScheduleCreateParamsPhaseAutomaticTax"
+ ]
+ """
+ Automatic tax settings for this phase.
+ """
+ billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
+ """
+ Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
+ """
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionScheduleCreateParamsPhaseBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
+ """
+ default_tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
+ """
+ description: NotRequired["Literal['']|str"]
+ """
+ Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[SubscriptionScheduleCreateParamsPhaseDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
+ """
+ duration: NotRequired["SubscriptionScheduleCreateParamsPhaseDuration"]
+ """
+ The number of intervals the phase should last. If set, `end_date` must not be set.
+ """
+ end_date: NotRequired[int]
+ """
+ The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
+ """
+ invoice_settings: NotRequired[
+ "SubscriptionScheduleCreateParamsPhaseInvoiceSettings"
+ ]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ items: List["SubscriptionScheduleCreateParamsPhaseItem"]
+ """
+ List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
+ """
+ on_behalf_of: NotRequired[str]
+ """
+ The account on behalf of which to charge, for each of the associated subscription's invoices.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. It's different from the request-level [proration_behavior](https://stripe.com/docs/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration (item price, quantity, etc.) of the current phase.
+ """
+ transfer_data: NotRequired[
+ "SubscriptionScheduleCreateParamsPhaseTransferData"
+ ]
+ """
+ The data with which to automatically create a Transfer for each of the associated subscription's invoices.
+ """
+ trial: NotRequired[bool]
+ """
+ If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
+ """
+ trial_end: NotRequired[int]
+ """
+ Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseAddInvoiceItem(TypedDict):
+ discounts: NotRequired[
+ List["SubscriptionScheduleCreateParamsPhaseAddInvoiceItemDiscount"]
+ ]
+ """
+ The coupons to redeem into discounts for the item.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ period: NotRequired[
+ "SubscriptionScheduleCreateParamsPhaseAddInvoiceItemPeriod"
+ ]
+ """
+ The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required.
+ """
+ price_data: NotRequired[
+ "SubscriptionScheduleCreateParamsPhaseAddInvoiceItemPriceData"
+ ]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: NotRequired[int]
+ """
+ Quantity for this item. Defaults to 1.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseAddInvoiceItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseAddInvoiceItemPeriod(TypedDict):
+ end: "SubscriptionScheduleCreateParamsPhaseAddInvoiceItemPeriodEnd"
+ """
+ End of the invoice item period.
+ """
+ start: "SubscriptionScheduleCreateParamsPhaseAddInvoiceItemPeriodStart"
+ """
+ Start of the invoice item period.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseAddInvoiceItemPeriodEnd(TypedDict):
+ timestamp: NotRequired[int]
+ """
+ A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
+ """
+ type: Literal["min_item_period_end", "phase_end", "timestamp"]
+ """
+ Select how to calculate the end of the invoice item period.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseAddInvoiceItemPeriodStart(
+ TypedDict
+):
+ timestamp: NotRequired[int]
+ """
+ A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
+ """
+ type: Literal["max_item_period_start", "phase_start", "timestamp"]
+ """
+ Select how to calculate the start of the invoice item period.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseAddInvoiceItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
+ """
+ liability: NotRequired[
+ "SubscriptionScheduleCreateParamsPhaseAutomaticTaxLiability"
+ ]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseBillingThresholds(TypedDict):
+ amount_gte: NotRequired[int]
+ """
+ Monetary threshold that triggers the subscription to advance to a new billing period
+ """
+ reset_billing_cycle_anchor: NotRequired[bool]
+ """
+ Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseDuration(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies phase duration. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The multiplier applied to the interval.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseInvoiceSettings(TypedDict):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
+ """
+ days_until_due: NotRequired[int]
+ """
+ Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
+ """
+ issuer: NotRequired[
+ "SubscriptionScheduleCreateParamsPhaseInvoiceSettingsIssuer"
+ ]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseInvoiceSettingsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseItem(TypedDict):
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionScheduleCreateParamsPhaseItemBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[SubscriptionScheduleCreateParamsPhaseItemDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the subscription item.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
+ """
+ plan: NotRequired[str]
+ """
+ The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object.
+ """
+ price_data: NotRequired[
+ "SubscriptionScheduleCreateParamsPhaseItemPriceData"
+ ]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
+ """
+ quantity: NotRequired[int]
+ """
+ Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseItemBillingThresholds(TypedDict):
+ usage_gte: int
+ """
+ Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ recurring: "SubscriptionScheduleCreateParamsPhaseItemPriceDataRecurring"
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseItemPriceDataRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
+
+
+class SubscriptionScheduleCreateParamsPhaseTransferData(TypedDict):
+ amount_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
diff --git a/stripe/params/_subscription_schedule_list_params.py b/stripe/params/_subscription_schedule_list_params.py
new file mode 100644
index 000000000..2f3b91e9f
--- /dev/null
+++ b/stripe/params/_subscription_schedule_list_params.py
@@ -0,0 +1,124 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class SubscriptionScheduleListParams(RequestOptions):
+ canceled_at: NotRequired["SubscriptionScheduleListParamsCanceledAt|int"]
+ """
+ Only return subscription schedules that were created canceled the given date interval.
+ """
+ completed_at: NotRequired["SubscriptionScheduleListParamsCompletedAt|int"]
+ """
+ Only return subscription schedules that completed during the given date interval.
+ """
+ created: NotRequired["SubscriptionScheduleListParamsCreated|int"]
+ """
+ Only return subscription schedules that were created during the given date interval.
+ """
+ customer: NotRequired[str]
+ """
+ Only return subscription schedules for the given customer.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ released_at: NotRequired["SubscriptionScheduleListParamsReleasedAt|int"]
+ """
+ Only return subscription schedules that were released during the given date interval.
+ """
+ scheduled: NotRequired[bool]
+ """
+ Only return subscription schedules that have not started yet.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class SubscriptionScheduleListParamsCanceledAt(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
+
+
+class SubscriptionScheduleListParamsCompletedAt(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
+
+
+class SubscriptionScheduleListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
+
+
+class SubscriptionScheduleListParamsReleasedAt(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_subscription_schedule_modify_params.py b/stripe/params/_subscription_schedule_modify_params.py
new file mode 100644
index 000000000..04d91b096
--- /dev/null
+++ b/stripe/params/_subscription_schedule_modify_params.py
@@ -0,0 +1,589 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SubscriptionScheduleModifyParams(RequestOptions):
+ default_settings: NotRequired[
+ "SubscriptionScheduleModifyParamsDefaultSettings"
+ ]
+ """
+ Object representing the subscription schedule's default settings.
+ """
+ end_behavior: NotRequired[Literal["cancel", "none", "release", "renew"]]
+ """
+ Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ phases: NotRequired[List["SubscriptionScheduleModifyParamsPhase"]]
+ """
+ List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase. Note that past phases can be omitted.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ If the update changes the billing configuration (item price, quantity, etc.) of the current phase, indicates how prorations from this change should be handled. The default value is `create_prorations`.
+ """
+
+
+class SubscriptionScheduleModifyParamsDefaultSettings(TypedDict):
+ application_fee_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
+ """
+ automatic_tax: NotRequired[
+ "SubscriptionScheduleModifyParamsDefaultSettingsAutomaticTax"
+ ]
+ """
+ Default settings for automatic tax computation.
+ """
+ billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
+ """
+ Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
+ """
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionScheduleModifyParamsDefaultSettingsBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
+ """
+ description: NotRequired["Literal['']|str"]
+ """
+ Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
+ """
+ invoice_settings: NotRequired[
+ "SubscriptionScheduleModifyParamsDefaultSettingsInvoiceSettings"
+ ]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ on_behalf_of: NotRequired["Literal['']|str"]
+ """
+ The account on behalf of which to charge, for each of the associated subscription's invoices.
+ """
+ transfer_data: NotRequired[
+ "Literal['']|SubscriptionScheduleModifyParamsDefaultSettingsTransferData"
+ ]
+ """
+ The data with which to automatically create a Transfer for each of the associated subscription's invoices.
+ """
+
+
+class SubscriptionScheduleModifyParamsDefaultSettingsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
+ """
+ liability: NotRequired[
+ "SubscriptionScheduleModifyParamsDefaultSettingsAutomaticTaxLiability"
+ ]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class SubscriptionScheduleModifyParamsDefaultSettingsAutomaticTaxLiability(
+ TypedDict,
+):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionScheduleModifyParamsDefaultSettingsBillingThresholds(
+ TypedDict,
+):
+ amount_gte: NotRequired[int]
+ """
+ Monetary threshold that triggers the subscription to advance to a new billing period
+ """
+ reset_billing_cycle_anchor: NotRequired[bool]
+ """
+ Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
+ """
+
+
+class SubscriptionScheduleModifyParamsDefaultSettingsInvoiceSettings(
+ TypedDict
+):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with the subscription schedule. Will be set on invoices generated by the subscription schedule.
+ """
+ days_until_due: NotRequired[int]
+ """
+ Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `collection_method=charge_automatically`.
+ """
+ issuer: NotRequired[
+ "SubscriptionScheduleModifyParamsDefaultSettingsInvoiceSettingsIssuer"
+ ]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class SubscriptionScheduleModifyParamsDefaultSettingsInvoiceSettingsIssuer(
+ TypedDict,
+):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionScheduleModifyParamsDefaultSettingsTransferData(TypedDict):
+ amount_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhase(TypedDict):
+ add_invoice_items: NotRequired[
+ List["SubscriptionScheduleModifyParamsPhaseAddInvoiceItem"]
+ ]
+ """
+ A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
+ """
+ application_fee_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
+ """
+ automatic_tax: NotRequired[
+ "SubscriptionScheduleModifyParamsPhaseAutomaticTax"
+ ]
+ """
+ Automatic tax settings for this phase.
+ """
+ billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
+ """
+ Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
+ """
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionScheduleModifyParamsPhaseBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
+ """
+ default_tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
+ """
+ description: NotRequired["Literal['']|str"]
+ """
+ Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[SubscriptionScheduleModifyParamsPhaseDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
+ """
+ duration: NotRequired["SubscriptionScheduleModifyParamsPhaseDuration"]
+ """
+ The number of intervals the phase should last. If set, `end_date` must not be set.
+ """
+ end_date: NotRequired["int|Literal['now']"]
+ """
+ The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
+ """
+ invoice_settings: NotRequired[
+ "SubscriptionScheduleModifyParamsPhaseInvoiceSettings"
+ ]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ items: List["SubscriptionScheduleModifyParamsPhaseItem"]
+ """
+ List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
+ """
+ on_behalf_of: NotRequired[str]
+ """
+ The account on behalf of which to charge, for each of the associated subscription's invoices.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. It's different from the request-level [proration_behavior](https://stripe.com/docs/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration (item price, quantity, etc.) of the current phase.
+ """
+ start_date: NotRequired["int|Literal['now']"]
+ """
+ The date at which this phase of the subscription schedule starts or `now`. Must be set on the first phase.
+ """
+ transfer_data: NotRequired[
+ "SubscriptionScheduleModifyParamsPhaseTransferData"
+ ]
+ """
+ The data with which to automatically create a Transfer for each of the associated subscription's invoices.
+ """
+ trial: NotRequired[bool]
+ """
+ If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
+ """
+ trial_end: NotRequired["int|Literal['now']"]
+ """
+ Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseAddInvoiceItem(TypedDict):
+ discounts: NotRequired[
+ List["SubscriptionScheduleModifyParamsPhaseAddInvoiceItemDiscount"]
+ ]
+ """
+ The coupons to redeem into discounts for the item.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ period: NotRequired[
+ "SubscriptionScheduleModifyParamsPhaseAddInvoiceItemPeriod"
+ ]
+ """
+ The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required.
+ """
+ price_data: NotRequired[
+ "SubscriptionScheduleModifyParamsPhaseAddInvoiceItemPriceData"
+ ]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: NotRequired[int]
+ """
+ Quantity for this item. Defaults to 1.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseAddInvoiceItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseAddInvoiceItemPeriod(TypedDict):
+ end: "SubscriptionScheduleModifyParamsPhaseAddInvoiceItemPeriodEnd"
+ """
+ End of the invoice item period.
+ """
+ start: "SubscriptionScheduleModifyParamsPhaseAddInvoiceItemPeriodStart"
+ """
+ Start of the invoice item period.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseAddInvoiceItemPeriodEnd(TypedDict):
+ timestamp: NotRequired[int]
+ """
+ A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
+ """
+ type: Literal["min_item_period_end", "phase_end", "timestamp"]
+ """
+ Select how to calculate the end of the invoice item period.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseAddInvoiceItemPeriodStart(
+ TypedDict
+):
+ timestamp: NotRequired[int]
+ """
+ A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
+ """
+ type: Literal["max_item_period_start", "phase_start", "timestamp"]
+ """
+ Select how to calculate the start of the invoice item period.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseAddInvoiceItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
+ """
+ liability: NotRequired[
+ "SubscriptionScheduleModifyParamsPhaseAutomaticTaxLiability"
+ ]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseBillingThresholds(TypedDict):
+ amount_gte: NotRequired[int]
+ """
+ Monetary threshold that triggers the subscription to advance to a new billing period
+ """
+ reset_billing_cycle_anchor: NotRequired[bool]
+ """
+ Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseDuration(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies phase duration. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The multiplier applied to the interval.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseInvoiceSettings(TypedDict):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
+ """
+ days_until_due: NotRequired[int]
+ """
+ Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
+ """
+ issuer: NotRequired[
+ "SubscriptionScheduleModifyParamsPhaseInvoiceSettingsIssuer"
+ ]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseInvoiceSettingsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseItem(TypedDict):
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionScheduleModifyParamsPhaseItemBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[SubscriptionScheduleModifyParamsPhaseItemDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the subscription item.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
+ """
+ plan: NotRequired[str]
+ """
+ The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object.
+ """
+ price_data: NotRequired[
+ "SubscriptionScheduleModifyParamsPhaseItemPriceData"
+ ]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
+ """
+ quantity: NotRequired[int]
+ """
+ Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseItemBillingThresholds(TypedDict):
+ usage_gte: int
+ """
+ Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ recurring: "SubscriptionScheduleModifyParamsPhaseItemPriceDataRecurring"
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseItemPriceDataRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
+
+
+class SubscriptionScheduleModifyParamsPhaseTransferData(TypedDict):
+ amount_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
diff --git a/stripe/params/_subscription_schedule_release_params.py b/stripe/params/_subscription_schedule_release_params.py
new file mode 100644
index 000000000..1c5e4aa98
--- /dev/null
+++ b/stripe/params/_subscription_schedule_release_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SubscriptionScheduleReleaseParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ preserve_cancel_date: NotRequired[bool]
+ """
+ Keep any cancellation on the subscription that the schedule has set
+ """
diff --git a/stripe/params/_subscription_schedule_retrieve_params.py b/stripe/params/_subscription_schedule_retrieve_params.py
new file mode 100644
index 000000000..8b7f12569
--- /dev/null
+++ b/stripe/params/_subscription_schedule_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SubscriptionScheduleRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_subscription_schedule_update_params.py b/stripe/params/_subscription_schedule_update_params.py
new file mode 100644
index 000000000..165534710
--- /dev/null
+++ b/stripe/params/_subscription_schedule_update_params.py
@@ -0,0 +1,588 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SubscriptionScheduleUpdateParams(TypedDict):
+ default_settings: NotRequired[
+ "SubscriptionScheduleUpdateParamsDefaultSettings"
+ ]
+ """
+ Object representing the subscription schedule's default settings.
+ """
+ end_behavior: NotRequired[Literal["cancel", "none", "release", "renew"]]
+ """
+ Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ phases: NotRequired[List["SubscriptionScheduleUpdateParamsPhase"]]
+ """
+ List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase. Note that past phases can be omitted.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ If the update changes the billing configuration (item price, quantity, etc.) of the current phase, indicates how prorations from this change should be handled. The default value is `create_prorations`.
+ """
+
+
+class SubscriptionScheduleUpdateParamsDefaultSettings(TypedDict):
+ application_fee_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
+ """
+ automatic_tax: NotRequired[
+ "SubscriptionScheduleUpdateParamsDefaultSettingsAutomaticTax"
+ ]
+ """
+ Default settings for automatic tax computation.
+ """
+ billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
+ """
+ Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
+ """
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionScheduleUpdateParamsDefaultSettingsBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
+ """
+ description: NotRequired["Literal['']|str"]
+ """
+ Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
+ """
+ invoice_settings: NotRequired[
+ "SubscriptionScheduleUpdateParamsDefaultSettingsInvoiceSettings"
+ ]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ on_behalf_of: NotRequired["Literal['']|str"]
+ """
+ The account on behalf of which to charge, for each of the associated subscription's invoices.
+ """
+ transfer_data: NotRequired[
+ "Literal['']|SubscriptionScheduleUpdateParamsDefaultSettingsTransferData"
+ ]
+ """
+ The data with which to automatically create a Transfer for each of the associated subscription's invoices.
+ """
+
+
+class SubscriptionScheduleUpdateParamsDefaultSettingsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
+ """
+ liability: NotRequired[
+ "SubscriptionScheduleUpdateParamsDefaultSettingsAutomaticTaxLiability"
+ ]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class SubscriptionScheduleUpdateParamsDefaultSettingsAutomaticTaxLiability(
+ TypedDict,
+):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionScheduleUpdateParamsDefaultSettingsBillingThresholds(
+ TypedDict,
+):
+ amount_gte: NotRequired[int]
+ """
+ Monetary threshold that triggers the subscription to advance to a new billing period
+ """
+ reset_billing_cycle_anchor: NotRequired[bool]
+ """
+ Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
+ """
+
+
+class SubscriptionScheduleUpdateParamsDefaultSettingsInvoiceSettings(
+ TypedDict
+):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with the subscription schedule. Will be set on invoices generated by the subscription schedule.
+ """
+ days_until_due: NotRequired[int]
+ """
+ Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `collection_method=charge_automatically`.
+ """
+ issuer: NotRequired[
+ "SubscriptionScheduleUpdateParamsDefaultSettingsInvoiceSettingsIssuer"
+ ]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class SubscriptionScheduleUpdateParamsDefaultSettingsInvoiceSettingsIssuer(
+ TypedDict,
+):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionScheduleUpdateParamsDefaultSettingsTransferData(TypedDict):
+ amount_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhase(TypedDict):
+ add_invoice_items: NotRequired[
+ List["SubscriptionScheduleUpdateParamsPhaseAddInvoiceItem"]
+ ]
+ """
+ A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
+ """
+ application_fee_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
+ """
+ automatic_tax: NotRequired[
+ "SubscriptionScheduleUpdateParamsPhaseAutomaticTax"
+ ]
+ """
+ Automatic tax settings for this phase.
+ """
+ billing_cycle_anchor: NotRequired[Literal["automatic", "phase_start"]]
+ """
+ Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
+ """
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionScheduleUpdateParamsPhaseBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
+ """
+ default_tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
+ """
+ description: NotRequired["Literal['']|str"]
+ """
+ Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[SubscriptionScheduleUpdateParamsPhaseDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
+ """
+ duration: NotRequired["SubscriptionScheduleUpdateParamsPhaseDuration"]
+ """
+ The number of intervals the phase should last. If set, `end_date` must not be set.
+ """
+ end_date: NotRequired["int|Literal['now']"]
+ """
+ The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
+ """
+ invoice_settings: NotRequired[
+ "SubscriptionScheduleUpdateParamsPhaseInvoiceSettings"
+ ]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ items: List["SubscriptionScheduleUpdateParamsPhaseItem"]
+ """
+ List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
+ """
+ on_behalf_of: NotRequired[str]
+ """
+ The account on behalf of which to charge, for each of the associated subscription's invoices.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. It's different from the request-level [proration_behavior](https://stripe.com/docs/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration (item price, quantity, etc.) of the current phase.
+ """
+ start_date: NotRequired["int|Literal['now']"]
+ """
+ The date at which this phase of the subscription schedule starts or `now`. Must be set on the first phase.
+ """
+ transfer_data: NotRequired[
+ "SubscriptionScheduleUpdateParamsPhaseTransferData"
+ ]
+ """
+ The data with which to automatically create a Transfer for each of the associated subscription's invoices.
+ """
+ trial: NotRequired[bool]
+ """
+ If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
+ """
+ trial_end: NotRequired["int|Literal['now']"]
+ """
+ Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseAddInvoiceItem(TypedDict):
+ discounts: NotRequired[
+ List["SubscriptionScheduleUpdateParamsPhaseAddInvoiceItemDiscount"]
+ ]
+ """
+ The coupons to redeem into discounts for the item.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ period: NotRequired[
+ "SubscriptionScheduleUpdateParamsPhaseAddInvoiceItemPeriod"
+ ]
+ """
+ The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required.
+ """
+ price_data: NotRequired[
+ "SubscriptionScheduleUpdateParamsPhaseAddInvoiceItemPriceData"
+ ]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: NotRequired[int]
+ """
+ Quantity for this item. Defaults to 1.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseAddInvoiceItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseAddInvoiceItemPeriod(TypedDict):
+ end: "SubscriptionScheduleUpdateParamsPhaseAddInvoiceItemPeriodEnd"
+ """
+ End of the invoice item period.
+ """
+ start: "SubscriptionScheduleUpdateParamsPhaseAddInvoiceItemPeriodStart"
+ """
+ Start of the invoice item period.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseAddInvoiceItemPeriodEnd(TypedDict):
+ timestamp: NotRequired[int]
+ """
+ A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
+ """
+ type: Literal["min_item_period_end", "phase_end", "timestamp"]
+ """
+ Select how to calculate the end of the invoice item period.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseAddInvoiceItemPeriodStart(
+ TypedDict
+):
+ timestamp: NotRequired[int]
+ """
+ A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
+ """
+ type: Literal["max_item_period_start", "phase_start", "timestamp"]
+ """
+ Select how to calculate the start of the invoice item period.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseAddInvoiceItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
+ """
+ liability: NotRequired[
+ "SubscriptionScheduleUpdateParamsPhaseAutomaticTaxLiability"
+ ]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseBillingThresholds(TypedDict):
+ amount_gte: NotRequired[int]
+ """
+ Monetary threshold that triggers the subscription to advance to a new billing period
+ """
+ reset_billing_cycle_anchor: NotRequired[bool]
+ """
+ Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseDuration(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies phase duration. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The multiplier applied to the interval.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseInvoiceSettings(TypedDict):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
+ """
+ days_until_due: NotRequired[int]
+ """
+ Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
+ """
+ issuer: NotRequired[
+ "SubscriptionScheduleUpdateParamsPhaseInvoiceSettingsIssuer"
+ ]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseInvoiceSettingsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseItem(TypedDict):
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionScheduleUpdateParamsPhaseItemBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[SubscriptionScheduleUpdateParamsPhaseItemDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the subscription item.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
+ """
+ plan: NotRequired[str]
+ """
+ The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object.
+ """
+ price_data: NotRequired[
+ "SubscriptionScheduleUpdateParamsPhaseItemPriceData"
+ ]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
+ """
+ quantity: NotRequired[int]
+ """
+ Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseItemBillingThresholds(TypedDict):
+ usage_gte: int
+ """
+ Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ recurring: "SubscriptionScheduleUpdateParamsPhaseItemPriceDataRecurring"
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseItemPriceDataRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
+
+
+class SubscriptionScheduleUpdateParamsPhaseTransferData(TypedDict):
+ amount_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
diff --git a/stripe/params/_subscription_search_params.py b/stripe/params/_subscription_search_params.py
new file mode 100644
index 000000000..7930e586c
--- /dev/null
+++ b/stripe/params/_subscription_search_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SubscriptionSearchParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ page: NotRequired[str]
+ """
+ A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
+ """
+ query: str
+ """
+ The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for subscriptions](https://stripe.com/docs/search#query-fields-for-subscriptions).
+ """
diff --git a/stripe/params/_subscription_update_params.py b/stripe/params/_subscription_update_params.py
new file mode 100644
index 000000000..6ef68fed2
--- /dev/null
+++ b/stripe/params/_subscription_update_params.py
@@ -0,0 +1,764 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SubscriptionUpdateParams(TypedDict):
+ add_invoice_items: NotRequired[
+ List["SubscriptionUpdateParamsAddInvoiceItem"]
+ ]
+ """
+ A list of prices and quantities that will generate invoice items appended to the next invoice for this subscription. You may pass up to 20 items.
+ """
+ application_fee_percent: NotRequired["Literal['']|float"]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
+ """
+ automatic_tax: NotRequired["SubscriptionUpdateParamsAutomaticTax"]
+ """
+ Automatic tax settings for this subscription. We recommend you only include this parameter when the existing value is being changed.
+ """
+ billing_cycle_anchor: NotRequired[Literal["now", "unchanged"]]
+ """
+ Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time (in UTC). For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
+ """
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionUpdateParamsBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds.
+ """
+ cancel_at: NotRequired[
+ "Literal['']|int|Literal['max_period_end', 'min_period_end']"
+ ]
+ """
+ A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
+ """
+ cancel_at_period_end: NotRequired[bool]
+ """
+ Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`.
+ """
+ cancellation_details: NotRequired[
+ "SubscriptionUpdateParamsCancellationDetails"
+ ]
+ """
+ Details about why this subscription was cancelled
+ """
+ collection_method: NotRequired[
+ Literal["charge_automatically", "send_invoice"]
+ ]
+ """
+ Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
+ """
+ days_until_due: NotRequired[int]
+ """
+ Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.
+ """
+ default_payment_method: NotRequired[str]
+ """
+ ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
+ """
+ default_source: NotRequired["Literal['']|str"]
+ """
+ ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
+ """
+ default_tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription. Pass an empty string to remove previously-defined tax rates.
+ """
+ description: NotRequired["Literal['']|str"]
+ """
+ The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[SubscriptionUpdateParamsDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the subscription. If not specified or empty, inherits the discount from the subscription's customer.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ invoice_settings: NotRequired["SubscriptionUpdateParamsInvoiceSettings"]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ items: NotRequired[List["SubscriptionUpdateParamsItem"]]
+ """
+ A list of up to 20 subscription items, each with an attached price.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ off_session: NotRequired[bool]
+ """
+ Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
+ """
+ on_behalf_of: NotRequired["Literal['']|str"]
+ """
+ The account on behalf of which to charge, for each of the subscription's invoices.
+ """
+ pause_collection: NotRequired[
+ "Literal['']|SubscriptionUpdateParamsPauseCollection"
+ ]
+ """
+ If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
+ """
+ payment_behavior: NotRequired[
+ Literal[
+ "allow_incomplete",
+ "default_incomplete",
+ "error_if_incomplete",
+ "pending_if_incomplete",
+ ]
+ ]
+ """
+ Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
+
+ Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription's invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
+
+ Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
+
+ Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://docs.stripe.com/changelog/2019-03-14) to learn more.
+ """
+ payment_settings: NotRequired["SubscriptionUpdateParamsPaymentSettings"]
+ """
+ Payment settings to pass to invoices created by the subscription.
+ """
+ pending_invoice_item_interval: NotRequired[
+ "Literal['']|SubscriptionUpdateParamsPendingInvoiceItemInterval"
+ ]
+ """
+ Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.
+ """
+ proration_date: NotRequired[int]
+ """
+ If set, prorations will be calculated as though the subscription was updated at the given time. This can be used to apply exactly the same prorations that were previewed with the [create preview](https://stripe.com/docs/api/invoices/create_preview) endpoint. `proration_date` can also be used to implement custom proration logic, such as prorating by day instead of by second, by providing the time that you wish to use for proration calculations.
+ """
+ transfer_data: NotRequired[
+ "Literal['']|SubscriptionUpdateParamsTransferData"
+ ]
+ """
+ If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges. This will be unset if you POST an empty value.
+ """
+ trial_end: NotRequired["Literal['now']|int"]
+ """
+ Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, `trial_end` will override the default trial period of the plan the customer is being subscribed to. The `billing_cycle_anchor` will be updated to the `trial_end` value. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`.
+ """
+ trial_from_plan: NotRequired[bool]
+ """
+ Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
+ """
+ trial_settings: NotRequired["SubscriptionUpdateParamsTrialSettings"]
+ """
+ Settings related to subscription trials.
+ """
+
+
+class SubscriptionUpdateParamsAddInvoiceItem(TypedDict):
+ discounts: NotRequired[
+ List["SubscriptionUpdateParamsAddInvoiceItemDiscount"]
+ ]
+ """
+ The coupons to redeem into discounts for the item.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ period: NotRequired["SubscriptionUpdateParamsAddInvoiceItemPeriod"]
+ """
+ The period associated with this invoice item. If not set, `period.start.type` defaults to `max_item_period_start` and `period.end.type` defaults to `min_item_period_end`.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required.
+ """
+ price_data: NotRequired["SubscriptionUpdateParamsAddInvoiceItemPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: NotRequired[int]
+ """
+ Quantity for this item. Defaults to 1.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
+ """
+
+
+class SubscriptionUpdateParamsAddInvoiceItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionUpdateParamsAddInvoiceItemPeriod(TypedDict):
+ end: "SubscriptionUpdateParamsAddInvoiceItemPeriodEnd"
+ """
+ End of the invoice item period.
+ """
+ start: "SubscriptionUpdateParamsAddInvoiceItemPeriodStart"
+ """
+ Start of the invoice item period.
+ """
+
+
+class SubscriptionUpdateParamsAddInvoiceItemPeriodEnd(TypedDict):
+ timestamp: NotRequired[int]
+ """
+ A precise Unix timestamp for the end of the invoice item period. Must be greater than or equal to `period.start`.
+ """
+ type: Literal["min_item_period_end", "timestamp"]
+ """
+ Select how to calculate the end of the invoice item period.
+ """
+
+
+class SubscriptionUpdateParamsAddInvoiceItemPeriodStart(TypedDict):
+ timestamp: NotRequired[int]
+ """
+ A precise Unix timestamp for the start of the invoice item period. Must be less than or equal to `period.end`.
+ """
+ type: Literal["max_item_period_start", "now", "timestamp"]
+ """
+ Select how to calculate the start of the invoice item period.
+ """
+
+
+class SubscriptionUpdateParamsAddInvoiceItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SubscriptionUpdateParamsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
+ """
+ liability: NotRequired["SubscriptionUpdateParamsAutomaticTaxLiability"]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class SubscriptionUpdateParamsAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionUpdateParamsBillingThresholds(TypedDict):
+ amount_gte: NotRequired[int]
+ """
+ Monetary threshold that triggers the subscription to advance to a new billing period
+ """
+ reset_billing_cycle_anchor: NotRequired[bool]
+ """
+ Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
+ """
+
+
+class SubscriptionUpdateParamsCancellationDetails(TypedDict):
+ comment: NotRequired["Literal['']|str"]
+ """
+ Additional comments about why the user canceled the subscription, if the subscription was canceled explicitly by the user.
+ """
+ feedback: NotRequired[
+ "Literal['']|Literal['customer_service', 'low_quality', 'missing_features', 'other', 'switched_service', 'too_complex', 'too_expensive', 'unused']"
+ ]
+ """
+ The customer submitted reason for why they canceled, if the subscription was canceled explicitly by the user.
+ """
+
+
+class SubscriptionUpdateParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionUpdateParamsInvoiceSettings(TypedDict):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with the subscription. Will be set on invoices generated by the subscription.
+ """
+ issuer: NotRequired["SubscriptionUpdateParamsInvoiceSettingsIssuer"]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class SubscriptionUpdateParamsInvoiceSettingsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SubscriptionUpdateParamsItem(TypedDict):
+ billing_thresholds: NotRequired[
+ "Literal['']|SubscriptionUpdateParamsItemBillingThresholds"
+ ]
+ """
+ Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
+ """
+ clear_usage: NotRequired[bool]
+ """
+ Delete all usage for a given subscription item. You must pass this when deleting a usage records subscription item. `clear_usage` has no effect if the plan has a billing meter attached.
+ """
+ deleted: NotRequired[bool]
+ """
+ A flag that, if set to `true`, will delete the specified item.
+ """
+ discounts: NotRequired[
+ "Literal['']|List[SubscriptionUpdateParamsItemDiscount]"
+ ]
+ """
+ The coupons to redeem into discounts for the subscription item.
+ """
+ id: NotRequired[str]
+ """
+ Subscription item to update.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ plan: NotRequired[str]
+ """
+ Plan ID for this item, as a string.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
+ """
+ price_data: NotRequired["SubscriptionUpdateParamsItemPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: NotRequired[int]
+ """
+ Quantity for this item.
+ """
+ tax_rates: NotRequired["Literal['']|List[str]"]
+ """
+ A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
+ """
+
+
+class SubscriptionUpdateParamsItemBillingThresholds(TypedDict):
+ usage_gte: int
+ """
+ Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
+ """
+
+
+class SubscriptionUpdateParamsItemDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ ID of the coupon to create a new discount for.
+ """
+ discount: NotRequired[str]
+ """
+ ID of an existing discount on the object (or one of its ancestors) to reuse.
+ """
+ promotion_code: NotRequired[str]
+ """
+ ID of the promotion code to create a new discount for.
+ """
+
+
+class SubscriptionUpdateParamsItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: str
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
+ """
+ recurring: "SubscriptionUpdateParamsItemPriceDataRecurring"
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SubscriptionUpdateParamsItemPriceDataRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
+
+
+class SubscriptionUpdateParamsPauseCollection(TypedDict):
+ behavior: Literal["keep_as_draft", "mark_uncollectible", "void"]
+ """
+ The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
+ """
+ resumes_at: NotRequired[int]
+ """
+ The time after which the subscription will resume collecting payments.
+ """
+
+
+class SubscriptionUpdateParamsPaymentSettings(TypedDict):
+ payment_method_options: NotRequired[
+ "SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptions"
+ ]
+ """
+ Payment-method-specific configuration to provide to invoices created by the subscription.
+ """
+ payment_method_types: NotRequired[
+ "Literal['']|List[Literal['ach_credit_transfer', 'ach_debit', 'acss_debit', 'affirm', 'amazon_pay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'boleto', 'card', 'cashapp', 'crypto', 'customer_balance', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'jp_credit_transfer', 'kakao_pay', 'klarna', 'konbini', 'kr_card', 'link', 'multibanco', 'naver_pay', 'nz_bank_account', 'p24', 'payco', 'paynow', 'paypal', 'promptpay', 'revolut_pay', 'sepa_credit_transfer', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
+ ]
+ """
+ The list of payment method types (e.g. card) to provide to the invoice's PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice's default payment method, the subscription's default payment method, the customer's default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice). Should not be specified with payment_method_configuration
+ """
+ save_default_payment_method: NotRequired[Literal["off", "on_subscription"]]
+ """
+ Configure whether Stripe updates `subscription.default_payment_method` when payment succeeds. Defaults to `off` if unspecified.
+ """
+
+
+class SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptions(TypedDict):
+ acss_debit: NotRequired[
+ "Literal['']|SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebit"
+ ]
+ """
+ This sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice's PaymentIntent.
+ """
+ bancontact: NotRequired[
+ "Literal['']|SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsBancontact"
+ ]
+ """
+ This sub-hash contains details about the Bancontact payment method options to pass to the invoice's PaymentIntent.
+ """
+ card: NotRequired[
+ "Literal['']|SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsCard"
+ ]
+ """
+ This sub-hash contains details about the Card payment method options to pass to the invoice's PaymentIntent.
+ """
+ customer_balance: NotRequired[
+ "Literal['']|SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance"
+ ]
+ """
+ This sub-hash contains details about the Bank transfer payment method options to pass to the invoice's PaymentIntent.
+ """
+ konbini: NotRequired[
+ "Literal['']|SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsKonbini"
+ ]
+ """
+ This sub-hash contains details about the Konbini payment method options to pass to the invoice's PaymentIntent.
+ """
+ sepa_debit: NotRequired[
+ "Literal['']|SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsSepaDebit"
+ ]
+ """
+ This sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice's PaymentIntent.
+ """
+ us_bank_account: NotRequired[
+ "Literal['']|SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ This sub-hash contains details about the ACH direct debit payment method options to pass to the invoice's PaymentIntent.
+ """
+
+
+class SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebit(
+ TypedDict,
+):
+ mandate_options: NotRequired[
+ "SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Verification method for the intent
+ """
+
+
+class SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsAcssDebitMandateOptions(
+ TypedDict,
+):
+ transaction_type: NotRequired[Literal["business", "personal"]]
+ """
+ Transaction type of the mandate.
+ """
+
+
+class SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsBancontact(
+ TypedDict,
+):
+ preferred_language: NotRequired[Literal["de", "en", "fr", "nl"]]
+ """
+ Preferred language of the Bancontact authorization page that the customer is redirected to.
+ """
+
+
+class SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsCard(
+ TypedDict,
+):
+ mandate_options: NotRequired[
+ "SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsCardMandateOptions"
+ ]
+ """
+ Configuration options for setting up an eMandate for cards issued in India.
+ """
+ network: NotRequired[
+ Literal[
+ "amex",
+ "cartes_bancaires",
+ "diners",
+ "discover",
+ "eftpos_au",
+ "girocard",
+ "interac",
+ "jcb",
+ "link",
+ "mastercard",
+ "unionpay",
+ "unknown",
+ "visa",
+ ]
+ ]
+ """
+ Selected network to process this Subscription on. Depends on the available networks of the card attached to the Subscription. Can be only set confirm-time.
+ """
+ request_three_d_secure: NotRequired[
+ Literal["any", "automatic", "challenge"]
+ ]
+ """
+ We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
+ """
+
+
+class SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsCardMandateOptions(
+ TypedDict,
+):
+ amount: NotRequired[int]
+ """
+ Amount to be charged for future payments.
+ """
+ amount_type: NotRequired[Literal["fixed", "maximum"]]
+ """
+ One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
+ """
+ description: NotRequired[str]
+ """
+ A description of the mandate or subscription that is meant to be displayed to the customer.
+ """
+
+
+class SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalance(
+ TypedDict,
+):
+ bank_transfer: NotRequired[
+ "SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer"
+ ]
+ """
+ Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
+ """
+ funding_type: NotRequired[str]
+ """
+ The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
+ """
+
+
+class SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer(
+ TypedDict,
+):
+ eu_bank_transfer: NotRequired[
+ "SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
+ ]
+ """
+ Configuration for eu_bank_transfer funding type.
+ """
+ type: NotRequired[str]
+ """
+ The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
+ """
+
+
+class SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
+ TypedDict,
+):
+ country: str
+ """
+ The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
+ """
+
+
+class SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsKonbini(
+ TypedDict,
+):
+ pass
+
+
+class SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsSepaDebit(
+ TypedDict,
+):
+ pass
+
+
+class SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccount(
+ TypedDict,
+):
+ financial_connections: NotRequired[
+ "SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections"
+ ]
+ """
+ Additional fields for Financial Connections Session creation
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Verification method for the intent
+ """
+
+
+class SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnections(
+ TypedDict,
+):
+ filters: NotRequired[
+ "SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters"
+ ]
+ """
+ Provide filters for the linked accounts that the customer can select for the payment method.
+ """
+ permissions: NotRequired[
+ List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ ]
+ """
+ The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+
+
+class SubscriptionUpdateParamsPaymentSettingsPaymentMethodOptionsUsBankAccountFinancialConnectionsFilters(
+ TypedDict,
+):
+ account_subcategories: NotRequired[List[Literal["checking", "savings"]]]
+ """
+ The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
+ """
+
+
+class SubscriptionUpdateParamsPendingInvoiceItemInterval(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies invoicing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks).
+ """
+
+
+class SubscriptionUpdateParamsTransferData(TypedDict):
+ amount_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
+
+
+class SubscriptionUpdateParamsTrialSettings(TypedDict):
+ end_behavior: "SubscriptionUpdateParamsTrialSettingsEndBehavior"
+ """
+ Defines how the subscription should behave when the user's free trial ends.
+ """
+
+
+class SubscriptionUpdateParamsTrialSettingsEndBehavior(TypedDict):
+ missing_payment_method: Literal["cancel", "create_invoice", "pause"]
+ """
+ Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
+ """
diff --git a/stripe/params/_tax_code_list_params.py b/stripe/params/_tax_code_list_params.py
new file mode 100644
index 000000000..931bee2bc
--- /dev/null
+++ b/stripe/params/_tax_code_list_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TaxCodeListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_tax_code_retrieve_params.py b/stripe/params/_tax_code_retrieve_params.py
new file mode 100644
index 000000000..df4670f94
--- /dev/null
+++ b/stripe/params/_tax_code_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TaxCodeRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_tax_id_create_params.py b/stripe/params/_tax_id_create_params.py
new file mode 100644
index 000000000..9cd1071d8
--- /dev/null
+++ b/stripe/params/_tax_id_create_params.py
@@ -0,0 +1,150 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TaxIdCreateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ owner: NotRequired["TaxIdCreateParamsOwner"]
+ """
+ The account or customer the tax ID belongs to. Defaults to `owner[type]=self`.
+ """
+ type: Literal[
+ "ad_nrt",
+ "ae_trn",
+ "al_tin",
+ "am_tin",
+ "ao_tin",
+ "ar_cuit",
+ "au_abn",
+ "au_arn",
+ "aw_tin",
+ "az_tin",
+ "ba_tin",
+ "bb_tin",
+ "bd_bin",
+ "bf_ifu",
+ "bg_uic",
+ "bh_vat",
+ "bj_ifu",
+ "bo_tin",
+ "br_cnpj",
+ "br_cpf",
+ "bs_tin",
+ "by_tin",
+ "ca_bn",
+ "ca_gst_hst",
+ "ca_pst_bc",
+ "ca_pst_mb",
+ "ca_pst_sk",
+ "ca_qst",
+ "cd_nif",
+ "ch_uid",
+ "ch_vat",
+ "cl_tin",
+ "cm_niu",
+ "cn_tin",
+ "co_nit",
+ "cr_tin",
+ "cv_nif",
+ "de_stn",
+ "do_rcn",
+ "ec_ruc",
+ "eg_tin",
+ "es_cif",
+ "et_tin",
+ "eu_oss_vat",
+ "eu_vat",
+ "gb_vat",
+ "ge_vat",
+ "gn_nif",
+ "hk_br",
+ "hr_oib",
+ "hu_tin",
+ "id_npwp",
+ "il_vat",
+ "in_gst",
+ "is_vat",
+ "jp_cn",
+ "jp_rn",
+ "jp_trn",
+ "ke_pin",
+ "kg_tin",
+ "kh_tin",
+ "kr_brn",
+ "kz_bin",
+ "la_tin",
+ "li_uid",
+ "li_vat",
+ "ma_vat",
+ "md_vat",
+ "me_pib",
+ "mk_vat",
+ "mr_nif",
+ "mx_rfc",
+ "my_frp",
+ "my_itn",
+ "my_sst",
+ "ng_tin",
+ "no_vat",
+ "no_voec",
+ "np_pan",
+ "nz_gst",
+ "om_vat",
+ "pe_ruc",
+ "ph_tin",
+ "ro_tin",
+ "rs_pib",
+ "ru_inn",
+ "ru_kpp",
+ "sa_vat",
+ "sg_gst",
+ "sg_uen",
+ "si_tin",
+ "sn_ninea",
+ "sr_fin",
+ "sv_nit",
+ "th_vat",
+ "tj_tin",
+ "tr_tin",
+ "tw_vat",
+ "tz_vat",
+ "ua_vat",
+ "ug_tin",
+ "us_ein",
+ "uy_ruc",
+ "uz_tin",
+ "uz_vat",
+ "ve_rif",
+ "vn_tin",
+ "za_vat",
+ "zm_tin",
+ "zw_tin",
+ ]
+ """
+ Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
+ """
+ value: str
+ """
+ Value of the tax ID.
+ """
+
+
+class TaxIdCreateParamsOwner(TypedDict):
+ account: NotRequired[str]
+ """
+ Account the tax ID belongs to. Required when `type=account`
+ """
+ customer: NotRequired[str]
+ """
+ Customer the tax ID belongs to. Required when `type=customer`
+ """
+ type: Literal["account", "application", "customer", "self"]
+ """
+ Type of owner referenced.
+ """
diff --git a/stripe/params/_tax_id_delete_params.py b/stripe/params/_tax_id_delete_params.py
new file mode 100644
index 000000000..3428e7f61
--- /dev/null
+++ b/stripe/params/_tax_id_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class TaxIdDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/_tax_id_list_params.py b/stripe/params/_tax_id_list_params.py
new file mode 100644
index 000000000..9c841c25c
--- /dev/null
+++ b/stripe/params/_tax_id_list_params.py
@@ -0,0 +1,43 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TaxIdListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ owner: NotRequired["TaxIdListParamsOwner"]
+ """
+ The account or customer the tax ID belongs to. Defaults to `owner[type]=self`.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class TaxIdListParamsOwner(TypedDict):
+ account: NotRequired[str]
+ """
+ Account the tax ID belongs to. Required when `type=account`
+ """
+ customer: NotRequired[str]
+ """
+ Customer the tax ID belongs to. Required when `type=customer`
+ """
+ type: Literal["account", "application", "customer", "self"]
+ """
+ Type of owner referenced.
+ """
diff --git a/stripe/params/_tax_id_retrieve_params.py b/stripe/params/_tax_id_retrieve_params.py
new file mode 100644
index 000000000..6e030d656
--- /dev/null
+++ b/stripe/params/_tax_id_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TaxIdRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_tax_rate_create_params.py b/stripe/params/_tax_rate_create_params.py
new file mode 100644
index 000000000..e92785e0c
--- /dev/null
+++ b/stripe/params/_tax_rate_create_params.py
@@ -0,0 +1,69 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class TaxRateCreateParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
+ """
+ display_name: str
+ """
+ The display name of the tax rate, which will be shown to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ inclusive: bool
+ """
+ This specifies if the tax rate is inclusive or exclusive.
+ """
+ jurisdiction: NotRequired[str]
+ """
+ The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer's invoice.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ percentage: float
+ """
+ This represents the tax rate percent out of 100.
+ """
+ state: NotRequired[str]
+ """
+ [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2), without country prefix. For example, "NY" for New York, United States.
+ """
+ tax_type: NotRequired[
+ Literal[
+ "amusement_tax",
+ "communications_tax",
+ "gst",
+ "hst",
+ "igst",
+ "jct",
+ "lease_tax",
+ "pst",
+ "qst",
+ "retail_delivery_fee",
+ "rst",
+ "sales_tax",
+ "service_tax",
+ "vat",
+ ]
+ ]
+ """
+ The high-level tax type, such as `vat` or `sales_tax`.
+ """
diff --git a/stripe/params/_tax_rate_list_params.py b/stripe/params/_tax_rate_list_params.py
new file mode 100644
index 000000000..b4c5704a1
--- /dev/null
+++ b/stripe/params/_tax_rate_list_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class TaxRateListParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Optional flag to filter by tax rates that are either active or inactive (archived).
+ """
+ created: NotRequired["TaxRateListParamsCreated|int"]
+ """
+ Optional range for filtering created date.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ inclusive: NotRequired[bool]
+ """
+ Optional flag to filter by tax rates that are inclusive (or those that are not inclusive).
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class TaxRateListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_tax_rate_modify_params.py b/stripe/params/_tax_rate_modify_params.py
new file mode 100644
index 000000000..04473b12d
--- /dev/null
+++ b/stripe/params/_tax_rate_modify_params.py
@@ -0,0 +1,61 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class TaxRateModifyParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
+ """
+ display_name: NotRequired[str]
+ """
+ The display name of the tax rate, which will be shown to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ jurisdiction: NotRequired[str]
+ """
+ The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer's invoice.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ state: NotRequired[str]
+ """
+ [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2), without country prefix. For example, "NY" for New York, United States.
+ """
+ tax_type: NotRequired[
+ Literal[
+ "amusement_tax",
+ "communications_tax",
+ "gst",
+ "hst",
+ "igst",
+ "jct",
+ "lease_tax",
+ "pst",
+ "qst",
+ "retail_delivery_fee",
+ "rst",
+ "sales_tax",
+ "service_tax",
+ "vat",
+ ]
+ ]
+ """
+ The high-level tax type, such as `vat` or `sales_tax`.
+ """
diff --git a/stripe/params/_tax_rate_retrieve_params.py b/stripe/params/_tax_rate_retrieve_params.py
new file mode 100644
index 000000000..374786b07
--- /dev/null
+++ b/stripe/params/_tax_rate_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TaxRateRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_tax_rate_update_params.py b/stripe/params/_tax_rate_update_params.py
new file mode 100644
index 000000000..c049176ad
--- /dev/null
+++ b/stripe/params/_tax_rate_update_params.py
@@ -0,0 +1,60 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TaxRateUpdateParams(TypedDict):
+ active: NotRequired[bool]
+ """
+ Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
+ """
+ display_name: NotRequired[str]
+ """
+ The display name of the tax rate, which will be shown to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ jurisdiction: NotRequired[str]
+ """
+ The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer's invoice.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ state: NotRequired[str]
+ """
+ [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2), without country prefix. For example, "NY" for New York, United States.
+ """
+ tax_type: NotRequired[
+ Literal[
+ "amusement_tax",
+ "communications_tax",
+ "gst",
+ "hst",
+ "igst",
+ "jct",
+ "lease_tax",
+ "pst",
+ "qst",
+ "retail_delivery_fee",
+ "rst",
+ "sales_tax",
+ "service_tax",
+ "vat",
+ ]
+ ]
+ """
+ The high-level tax type, such as `vat` or `sales_tax`.
+ """
diff --git a/stripe/params/_token_create_params.py b/stripe/params/_token_create_params.py
new file mode 100644
index 000000000..26976f7be
--- /dev/null
+++ b/stripe/params/_token_create_params.py
@@ -0,0 +1,1179 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TokenCreateParams(RequestOptions):
+ account: NotRequired["TokenCreateParamsAccount"]
+ """
+ Information for the account this token represents.
+ """
+ bank_account: NotRequired["TokenCreateParamsBankAccount"]
+ """
+ The bank account this token will represent.
+ """
+ card: NotRequired["TokenCreateParamsCard|str"]
+ """
+ The card this token will represent. If you also pass in a customer, the card must be the ID of a card belonging to the customer. Otherwise, if you do not pass in a customer, this is a dictionary containing a user's credit card details, with the options described below.
+ """
+ customer: NotRequired[str]
+ """
+ Create a token for the customer, which is owned by the application's account. You can only use this with an [OAuth access token](https://stripe.com/docs/connect/standard-accounts) or [Stripe-Account header](https://stripe.com/docs/connect/authentication). Learn more about [cloning saved payment methods](https://stripe.com/docs/connect/cloning-saved-payment-methods).
+ """
+ cvc_update: NotRequired["TokenCreateParamsCvcUpdate"]
+ """
+ The updated CVC value this token represents.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ person: NotRequired["TokenCreateParamsPerson"]
+ """
+ Information for the person this token represents.
+ """
+ pii: NotRequired["TokenCreateParamsPii"]
+ """
+ The PII this token represents.
+ """
+
+
+class TokenCreateParamsAccount(TypedDict):
+ business_type: NotRequired[
+ Literal["company", "government_entity", "individual", "non_profit"]
+ ]
+ """
+ The business type.
+ """
+ company: NotRequired["TokenCreateParamsAccountCompany"]
+ """
+ Information about the company or business.
+ """
+ individual: NotRequired["TokenCreateParamsAccountIndividual"]
+ """
+ Information about the person represented by the account.
+ """
+ tos_shown_and_accepted: NotRequired[bool]
+ """
+ Whether the user described by the data in the token has been shown [the Stripe Connected Account Agreement](https://docs.stripe.com/connect/account-tokens#stripe-connected-account-agreement). When creating an account token to create a new Connect account, this value must be `true`.
+ """
+
+
+class TokenCreateParamsAccountCompany(TypedDict):
+ address: NotRequired["TokenCreateParamsAccountCompanyAddress"]
+ """
+ The company's primary address.
+ """
+ address_kana: NotRequired["TokenCreateParamsAccountCompanyAddressKana"]
+ """
+ The Kana variation of the company's primary address (Japan only).
+ """
+ address_kanji: NotRequired["TokenCreateParamsAccountCompanyAddressKanji"]
+ """
+ The Kanji variation of the company's primary address (Japan only).
+ """
+ directors_provided: NotRequired[bool]
+ """
+ Whether the company's directors have been provided. Set this Boolean to `true` after creating all the company's directors with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.director` requirement. This value is not automatically set to `true` after creating directors, so it needs to be updated to indicate all directors have been provided.
+ """
+ directorship_declaration: NotRequired[
+ "TokenCreateParamsAccountCompanyDirectorshipDeclaration"
+ ]
+ """
+ This hash is used to attest that the directors information provided to Stripe is both current and correct.
+ """
+ executives_provided: NotRequired[bool]
+ """
+ Whether the company's executives have been provided. Set this Boolean to `true` after creating all the company's executives with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.executive` requirement.
+ """
+ export_license_id: NotRequired[str]
+ """
+ The export license ID number of the company, also referred as Import Export Code (India only).
+ """
+ export_purpose_code: NotRequired[str]
+ """
+ The purpose code to use for export transactions (India only).
+ """
+ name: NotRequired[str]
+ """
+ The company's legal name.
+ """
+ name_kana: NotRequired[str]
+ """
+ The Kana variation of the company's legal name (Japan only).
+ """
+ name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the company's legal name (Japan only).
+ """
+ owners_provided: NotRequired[bool]
+ """
+ Whether the company's owners have been provided. Set this Boolean to `true` after creating all the company's owners with [the Persons API](https://docs.stripe.com/api/persons) for accounts with a `relationship.owner` requirement.
+ """
+ ownership_declaration: NotRequired[
+ "TokenCreateParamsAccountCompanyOwnershipDeclaration"
+ ]
+ """
+ This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
+ """
+ ownership_declaration_shown_and_signed: NotRequired[bool]
+ """
+ Whether the user described by the data in the token has been shown the Ownership Declaration and indicated that it is correct.
+ """
+ ownership_exemption_reason: NotRequired[
+ "Literal['']|Literal['qualified_entity_exceeds_ownership_threshold', 'qualifies_as_financial_institution']"
+ ]
+ """
+ This value is used to determine if a business is exempt from providing ultimate beneficial owners. See [this support article](https://support.stripe.com/questions/exemption-from-providing-ownership-details) and [changelog](https://docs.stripe.com/changelog/acacia/2025-01-27/ownership-exemption-reason-accounts-api) for more details.
+ """
+ phone: NotRequired[str]
+ """
+ The company's phone number (used for verification).
+ """
+ registration_date: NotRequired[
+ "Literal['']|TokenCreateParamsAccountCompanyRegistrationDate"
+ ]
+ """
+ When the business was incorporated or registered.
+ """
+ registration_number: NotRequired[str]
+ """
+ The identification number given to a company when it is registered or incorporated, if distinct from the identification number used for filing taxes. (Examples are the CIN for companies and LLP IN for partnerships in India, and the Company Registration Number in Hong Kong).
+ """
+ structure: NotRequired[
+ "Literal['']|Literal['free_zone_establishment', 'free_zone_llc', 'government_instrumentality', 'governmental_unit', 'incorporated_non_profit', 'incorporated_partnership', 'limited_liability_partnership', 'llc', 'multi_member_llc', 'private_company', 'private_corporation', 'private_partnership', 'public_company', 'public_corporation', 'public_partnership', 'registered_charity', 'single_member_llc', 'sole_establishment', 'sole_proprietorship', 'tax_exempt_government_instrumentality', 'unincorporated_association', 'unincorporated_non_profit', 'unincorporated_partnership']"
+ ]
+ """
+ The category identifying the legal structure of the company or legal entity. See [Business structure](https://docs.stripe.com/connect/identity-verification#business-structure) for more details. Pass an empty string to unset this value.
+ """
+ tax_id: NotRequired[str]
+ """
+ The business ID number of the company, as appropriate for the company's country. (Examples are an Employer ID Number in the U.S., a Business Number in Canada, or a Company Number in the UK.)
+ """
+ tax_id_registrar: NotRequired[str]
+ """
+ The jurisdiction in which the `tax_id` is registered (Germany-based companies only).
+ """
+ vat_id: NotRequired[str]
+ """
+ The VAT number of the company.
+ """
+ verification: NotRequired["TokenCreateParamsAccountCompanyVerification"]
+ """
+ Information on the verification state of the company.
+ """
+
+
+class TokenCreateParamsAccountCompanyAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class TokenCreateParamsAccountCompanyAddressKana(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class TokenCreateParamsAccountCompanyAddressKanji(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class TokenCreateParamsAccountCompanyDirectorshipDeclaration(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the directorship declaration attestation was made.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the directorship declaration attestation was made.
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the directorship declaration attestation was made.
+ """
+
+
+class TokenCreateParamsAccountCompanyOwnershipDeclaration(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the beneficial owner attestation was made.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the beneficial owner attestation was made.
+ """
+ user_agent: NotRequired[str]
+ """
+ The user agent of the browser from which the beneficial owner attestation was made.
+ """
+
+
+class TokenCreateParamsAccountCompanyRegistrationDate(TypedDict):
+ day: int
+ """
+ The day of registration, between 1 and 31.
+ """
+ month: int
+ """
+ The month of registration, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of registration.
+ """
+
+
+class TokenCreateParamsAccountCompanyVerification(TypedDict):
+ document: NotRequired[
+ "TokenCreateParamsAccountCompanyVerificationDocument"
+ ]
+ """
+ A document verifying the business.
+ """
+
+
+class TokenCreateParamsAccountCompanyVerificationDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+
+
+class TokenCreateParamsAccountIndividual(TypedDict):
+ address: NotRequired["TokenCreateParamsAccountIndividualAddress"]
+ """
+ The individual's primary address.
+ """
+ address_kana: NotRequired["TokenCreateParamsAccountIndividualAddressKana"]
+ """
+ The Kana variation of the individual's primary address (Japan only).
+ """
+ address_kanji: NotRequired[
+ "TokenCreateParamsAccountIndividualAddressKanji"
+ ]
+ """
+ The Kanji variation of the individual's primary address (Japan only).
+ """
+ dob: NotRequired["Literal['']|TokenCreateParamsAccountIndividualDob"]
+ """
+ The individual's date of birth.
+ """
+ email: NotRequired[str]
+ """
+ The individual's email address.
+ """
+ first_name: NotRequired[str]
+ """
+ The individual's first name.
+ """
+ first_name_kana: NotRequired[str]
+ """
+ The Kana variation of the individual's first name (Japan only).
+ """
+ first_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the individual's first name (Japan only).
+ """
+ full_name_aliases: NotRequired["Literal['']|List[str]"]
+ """
+ A list of alternate names or aliases that the individual is known by.
+ """
+ gender: NotRequired[str]
+ """
+ The individual's gender
+ """
+ id_number: NotRequired[str]
+ """
+ The government-issued ID number of the individual, as appropriate for the representative's country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in Canada). Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ id_number_secondary: NotRequired[str]
+ """
+ The government-issued secondary ID number of the individual, as appropriate for the representative's country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token created with Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ last_name: NotRequired[str]
+ """
+ The individual's last name.
+ """
+ last_name_kana: NotRequired[str]
+ """
+ The Kana variation of the individual's last name (Japan only).
+ """
+ last_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the individual's last name (Japan only).
+ """
+ maiden_name: NotRequired[str]
+ """
+ The individual's maiden name.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ phone: NotRequired[str]
+ """
+ The individual's phone number.
+ """
+ political_exposure: NotRequired[Literal["existing", "none"]]
+ """
+ Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
+ """
+ registered_address: NotRequired[
+ "TokenCreateParamsAccountIndividualRegisteredAddress"
+ ]
+ """
+ The individual's registered address.
+ """
+ relationship: NotRequired["TokenCreateParamsAccountIndividualRelationship"]
+ """
+ Describes the person's relationship to the account.
+ """
+ ssn_last_4: NotRequired[str]
+ """
+ The last four digits of the individual's Social Security Number (U.S. only).
+ """
+ verification: NotRequired["TokenCreateParamsAccountIndividualVerification"]
+ """
+ The individual's verification document information.
+ """
+
+
+class TokenCreateParamsAccountIndividualAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class TokenCreateParamsAccountIndividualAddressKana(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class TokenCreateParamsAccountIndividualAddressKanji(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class TokenCreateParamsAccountIndividualDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class TokenCreateParamsAccountIndividualRegisteredAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class TokenCreateParamsAccountIndividualRelationship(TypedDict):
+ director: NotRequired[bool]
+ """
+ Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
+ """
+ executive: NotRequired[bool]
+ """
+ Whether the person has significant responsibility to control, manage, or direct the organization.
+ """
+ owner: NotRequired[bool]
+ """
+ Whether the person is an owner of the account's legal entity.
+ """
+ percent_ownership: NotRequired["Literal['']|float"]
+ """
+ The percent owned by the person of the account's legal entity.
+ """
+ title: NotRequired[str]
+ """
+ The person's title (e.g., CEO, Support Engineer).
+ """
+
+
+class TokenCreateParamsAccountIndividualVerification(TypedDict):
+ additional_document: NotRequired[
+ "TokenCreateParamsAccountIndividualVerificationAdditionalDocument"
+ ]
+ """
+ A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
+ """
+ document: NotRequired[
+ "TokenCreateParamsAccountIndividualVerificationDocument"
+ ]
+ """
+ An identifying document, either a passport or local ID card.
+ """
+
+
+class TokenCreateParamsAccountIndividualVerificationAdditionalDocument(
+ TypedDict,
+):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+
+
+class TokenCreateParamsAccountIndividualVerificationDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+
+
+class TokenCreateParamsBankAccount(TypedDict):
+ account_holder_name: NotRequired[str]
+ """
+ The name of the person or business that owns the bank account. This field is required when attaching the bank account to a `Customer` object.
+ """
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
+ """
+ account_number: str
+ """
+ The account number for the bank account, in string form. Must be a checking account.
+ """
+ account_type: NotRequired[Literal["checking", "futsu", "savings", "toza"]]
+ """
+ The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`.
+ """
+ country: str
+ """
+ The country in which the bank account is located.
+ """
+ currency: NotRequired[str]
+ """
+ The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](https://stripe.com/docs/payouts)
+ """
+ payment_method: NotRequired[str]
+ """
+ The ID of a Payment Method with a `type` of `us_bank_account`. The Payment Method's bank account information will be copied and returned as a Bank Account Token. This parameter is exclusive with respect to all other parameters in the `bank_account` hash. You must include the top-level `customer` parameter if the Payment Method is attached to a `Customer` object. If the Payment Method is not attached to a `Customer` object, it will be consumed and cannot be used again. You may not use Payment Methods which were created by a Setup Intent with `attach_to_self=true`.
+ """
+ routing_number: NotRequired[str]
+ """
+ The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
+ """
+
+
+class TokenCreateParamsCard(TypedDict):
+ address_city: NotRequired[str]
+ """
+ City / District / Suburb / Town / Village.
+ """
+ address_country: NotRequired[str]
+ """
+ Billing address country, if provided.
+ """
+ address_line1: NotRequired[str]
+ """
+ Address line 1 (Street address / PO Box / Company name).
+ """
+ address_line2: NotRequired[str]
+ """
+ Address line 2 (Apartment / Suite / Unit / Building).
+ """
+ address_state: NotRequired[str]
+ """
+ State / County / Province / Region.
+ """
+ address_zip: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ currency: NotRequired[str]
+ """
+ Required in order to add the card to an account; in all other cases, this parameter is not used. When added to an account, the card (which must be a debit card) can be used as a transfer destination for funds in this currency.
+ """
+ cvc: NotRequired[str]
+ """
+ Card security code. Highly recommended to always include this value.
+ """
+ exp_month: str
+ """
+ Two-digit number representing the card's expiration month.
+ """
+ exp_year: str
+ """
+ Two- or four-digit number representing the card's expiration year.
+ """
+ name: NotRequired[str]
+ """
+ Cardholder's full name.
+ """
+ networks: NotRequired["TokenCreateParamsCardNetworks"]
+ """
+ Contains information about card networks used to process the payment.
+ """
+ number: str
+ """
+ The card number, as a string without any separators.
+ """
+
+
+class TokenCreateParamsCardNetworks(TypedDict):
+ preferred: NotRequired[Literal["cartes_bancaires", "mastercard", "visa"]]
+ """
+ The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
+ """
+
+
+class TokenCreateParamsCvcUpdate(TypedDict):
+ cvc: str
+ """
+ The CVC value, in string form.
+ """
+
+
+class TokenCreateParamsPerson(TypedDict):
+ additional_tos_acceptances: NotRequired[
+ "TokenCreateParamsPersonAdditionalTosAcceptances"
+ ]
+ """
+ Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.
+ """
+ address: NotRequired["TokenCreateParamsPersonAddress"]
+ """
+ The person's address.
+ """
+ address_kana: NotRequired["TokenCreateParamsPersonAddressKana"]
+ """
+ The Kana variation of the person's address (Japan only).
+ """
+ address_kanji: NotRequired["TokenCreateParamsPersonAddressKanji"]
+ """
+ The Kanji variation of the person's address (Japan only).
+ """
+ dob: NotRequired["Literal['']|TokenCreateParamsPersonDob"]
+ """
+ The person's date of birth.
+ """
+ documents: NotRequired["TokenCreateParamsPersonDocuments"]
+ """
+ Documents that may be submitted to satisfy various informational requests.
+ """
+ email: NotRequired[str]
+ """
+ The person's email address.
+ """
+ first_name: NotRequired[str]
+ """
+ The person's first name.
+ """
+ first_name_kana: NotRequired[str]
+ """
+ The Kana variation of the person's first name (Japan only).
+ """
+ first_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the person's first name (Japan only).
+ """
+ full_name_aliases: NotRequired["Literal['']|List[str]"]
+ """
+ A list of alternate names or aliases that the person is known by.
+ """
+ gender: NotRequired[str]
+ """
+ The person's gender (International regulations require either "male" or "female").
+ """
+ id_number: NotRequired[str]
+ """
+ The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ id_number_secondary: NotRequired[str]
+ """
+ The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
+ """
+ last_name: NotRequired[str]
+ """
+ The person's last name.
+ """
+ last_name_kana: NotRequired[str]
+ """
+ The Kana variation of the person's last name (Japan only).
+ """
+ last_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the person's last name (Japan only).
+ """
+ maiden_name: NotRequired[str]
+ """
+ The person's maiden name.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ nationality: NotRequired[str]
+ """
+ The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or "XX" if unavailable.
+ """
+ phone: NotRequired[str]
+ """
+ The person's phone number.
+ """
+ political_exposure: NotRequired[Literal["existing", "none"]]
+ """
+ Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
+ """
+ registered_address: NotRequired["TokenCreateParamsPersonRegisteredAddress"]
+ """
+ The person's registered address.
+ """
+ relationship: NotRequired["TokenCreateParamsPersonRelationship"]
+ """
+ The relationship that this person has with the account's legal entity.
+ """
+ ssn_last_4: NotRequired[str]
+ """
+ The last four digits of the person's Social Security number (U.S. only).
+ """
+ us_cfpb_data: NotRequired["TokenCreateParamsPersonUsCfpbData"]
+ """
+ Demographic data related to the person.
+ """
+ verification: NotRequired["TokenCreateParamsPersonVerification"]
+ """
+ The person's verification status.
+ """
+
+
+class TokenCreateParamsPersonAdditionalTosAcceptances(TypedDict):
+ account: NotRequired[
+ "TokenCreateParamsPersonAdditionalTosAcceptancesAccount"
+ ]
+ """
+ Details on the legal guardian's acceptance of the main Stripe service agreement.
+ """
+
+
+class TokenCreateParamsPersonAdditionalTosAcceptancesAccount(TypedDict):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the account representative accepted the service agreement.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the account representative accepted the service agreement.
+ """
+ user_agent: NotRequired["Literal['']|str"]
+ """
+ The user agent of the browser from which the account representative accepted the service agreement.
+ """
+
+
+class TokenCreateParamsPersonAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class TokenCreateParamsPersonAddressKana(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class TokenCreateParamsPersonAddressKanji(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class TokenCreateParamsPersonDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class TokenCreateParamsPersonDocuments(TypedDict):
+ company_authorization: NotRequired[
+ "TokenCreateParamsPersonDocumentsCompanyAuthorization"
+ ]
+ """
+ One or more documents that demonstrate proof that this person is authorized to represent the company.
+ """
+ passport: NotRequired["TokenCreateParamsPersonDocumentsPassport"]
+ """
+ One or more documents showing the person's passport page with photo and personal data.
+ """
+ visa: NotRequired["TokenCreateParamsPersonDocumentsVisa"]
+ """
+ One or more documents showing the person's visa required for living in the country where they are residing.
+ """
+
+
+class TokenCreateParamsPersonDocumentsCompanyAuthorization(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class TokenCreateParamsPersonDocumentsPassport(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class TokenCreateParamsPersonDocumentsVisa(TypedDict):
+ files: NotRequired[List[str]]
+ """
+ One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
+ """
+
+
+class TokenCreateParamsPersonRegisteredAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class TokenCreateParamsPersonRelationship(TypedDict):
+ authorizer: NotRequired[bool]
+ """
+ Whether the person is the authorizer of the account's representative.
+ """
+ director: NotRequired[bool]
+ """
+ Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
+ """
+ executive: NotRequired[bool]
+ """
+ Whether the person has significant responsibility to control, manage, or direct the organization.
+ """
+ legal_guardian: NotRequired[bool]
+ """
+ Whether the person is the legal guardian of the account's representative.
+ """
+ owner: NotRequired[bool]
+ """
+ Whether the person is an owner of the account's legal entity.
+ """
+ percent_ownership: NotRequired["Literal['']|float"]
+ """
+ The percent owned by the person of the account's legal entity.
+ """
+ representative: NotRequired[bool]
+ """
+ Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
+ """
+ title: NotRequired[str]
+ """
+ The person's title (e.g., CEO, Support Engineer).
+ """
+
+
+class TokenCreateParamsPersonUsCfpbData(TypedDict):
+ ethnicity_details: NotRequired[
+ "TokenCreateParamsPersonUsCfpbDataEthnicityDetails"
+ ]
+ """
+ The persons ethnicity details
+ """
+ race_details: NotRequired["TokenCreateParamsPersonUsCfpbDataRaceDetails"]
+ """
+ The persons race details
+ """
+ self_identified_gender: NotRequired[str]
+ """
+ The persons self-identified gender
+ """
+
+
+class TokenCreateParamsPersonUsCfpbDataEthnicityDetails(TypedDict):
+ ethnicity: NotRequired[
+ List[
+ Literal[
+ "cuban",
+ "hispanic_or_latino",
+ "mexican",
+ "not_hispanic_or_latino",
+ "other_hispanic_or_latino",
+ "prefer_not_to_answer",
+ "puerto_rican",
+ ]
+ ]
+ ]
+ """
+ The persons ethnicity
+ """
+ ethnicity_other: NotRequired[str]
+ """
+ Please specify your origin, when other is selected.
+ """
+
+
+class TokenCreateParamsPersonUsCfpbDataRaceDetails(TypedDict):
+ race: NotRequired[
+ List[
+ Literal[
+ "african_american",
+ "american_indian_or_alaska_native",
+ "asian",
+ "asian_indian",
+ "black_or_african_american",
+ "chinese",
+ "ethiopian",
+ "filipino",
+ "guamanian_or_chamorro",
+ "haitian",
+ "jamaican",
+ "japanese",
+ "korean",
+ "native_hawaiian",
+ "native_hawaiian_or_other_pacific_islander",
+ "nigerian",
+ "other_asian",
+ "other_black_or_african_american",
+ "other_pacific_islander",
+ "prefer_not_to_answer",
+ "samoan",
+ "somali",
+ "vietnamese",
+ "white",
+ ]
+ ]
+ ]
+ """
+ The persons race.
+ """
+ race_other: NotRequired[str]
+ """
+ Please specify your race, when other is selected.
+ """
+
+
+class TokenCreateParamsPersonVerification(TypedDict):
+ additional_document: NotRequired[
+ "TokenCreateParamsPersonVerificationAdditionalDocument"
+ ]
+ """
+ A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
+ """
+ document: NotRequired["TokenCreateParamsPersonVerificationDocument"]
+ """
+ An identifying document, either a passport or local ID card.
+ """
+
+
+class TokenCreateParamsPersonVerificationAdditionalDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+
+
+class TokenCreateParamsPersonVerificationDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
+ """
+
+
+class TokenCreateParamsPii(TypedDict):
+ id_number: NotRequired[str]
+ """
+ The `id_number` for the PII, in string form.
+ """
diff --git a/stripe/params/_token_retrieve_params.py b/stripe/params/_token_retrieve_params.py
new file mode 100644
index 000000000..a8e659fc6
--- /dev/null
+++ b/stripe/params/_token_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TokenRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_topup_cancel_params.py b/stripe/params/_topup_cancel_params.py
new file mode 100644
index 000000000..619d448a2
--- /dev/null
+++ b/stripe/params/_topup_cancel_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TopupCancelParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_topup_create_params.py b/stripe/params/_topup_create_params.py
new file mode 100644
index 000000000..e7d682ace
--- /dev/null
+++ b/stripe/params/_topup_create_params.py
@@ -0,0 +1,40 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class TopupCreateParams(RequestOptions):
+ amount: int
+ """
+ A positive integer representing how much to transfer.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ source: NotRequired[str]
+ """
+ The ID of a source to transfer funds from. For most users, this should be left unspecified which will use the bank account that was set up in the dashboard for the specified currency. In test mode, this can be a test bank token (see [Testing Top-ups](https://stripe.com/docs/connect/testing#testing-top-ups)).
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ Extra information about a top-up for the source's bank statement. Limited to 15 ASCII characters.
+ """
+ transfer_group: NotRequired[str]
+ """
+ A string that identifies this top-up as part of a group.
+ """
diff --git a/stripe/params/_topup_list_params.py b/stripe/params/_topup_list_params.py
new file mode 100644
index 000000000..1bac955d2
--- /dev/null
+++ b/stripe/params/_topup_list_params.py
@@ -0,0 +1,74 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TopupListParams(RequestOptions):
+ amount: NotRequired["TopupListParamsAmount|int"]
+ """
+ A positive integer representing how much to transfer.
+ """
+ created: NotRequired["TopupListParamsCreated|int"]
+ """
+ A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["canceled", "failed", "pending", "succeeded"]]
+ """
+ Only return top-ups that have the given status. One of `canceled`, `failed`, `pending` or `succeeded`.
+ """
+
+
+class TopupListParamsAmount(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
+
+
+class TopupListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_topup_modify_params.py b/stripe/params/_topup_modify_params.py
new file mode 100644
index 000000000..1886a84fc
--- /dev/null
+++ b/stripe/params/_topup_modify_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class TopupModifyParams(RequestOptions):
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_topup_retrieve_params.py b/stripe/params/_topup_retrieve_params.py
new file mode 100644
index 000000000..6ae1b2bf4
--- /dev/null
+++ b/stripe/params/_topup_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TopupRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_topup_update_params.py b/stripe/params/_topup_update_params.py
new file mode 100644
index 000000000..e4f803fda
--- /dev/null
+++ b/stripe/params/_topup_update_params.py
@@ -0,0 +1,19 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TopupUpdateParams(TypedDict):
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_transfer_create_params.py b/stripe/params/_transfer_create_params.py
new file mode 100644
index 000000000..b2fb8d596
--- /dev/null
+++ b/stripe/params/_transfer_create_params.py
@@ -0,0 +1,44 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class TransferCreateParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) representing how much to transfer.
+ """
+ currency: str
+ """
+ Three-letter [ISO code for currency](https://www.iso.org/iso-4217-currency-codes.html) in lowercase. Must be a [supported currency](https://docs.stripe.com/currencies).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ destination: str
+ """
+ The ID of a connected Stripe account. [See the Connect documentation](https://docs.stripe.com/docs/connect/separate-charges-and-transfers) for details.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ source_transaction: NotRequired[str]
+ """
+ You can use this parameter to transfer funds from a charge before they are added to your available balance. A pending balance will transfer immediately but the funds will not become available until the original charge becomes available. [See the Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-availability) for details.
+ """
+ source_type: NotRequired[Literal["bank_account", "card", "fpx"]]
+ """
+ The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`.
+ """
+ transfer_group: NotRequired[str]
+ """
+ A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
+ """
diff --git a/stripe/params/_transfer_create_reversal_params.py b/stripe/params/_transfer_create_reversal_params.py
new file mode 100644
index 000000000..e59069fd1
--- /dev/null
+++ b/stripe/params/_transfer_create_reversal_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class TransferCreateReversalParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) representing how much of this transfer to reverse. Can only reverse up to the unreversed amount remaining of the transfer. Partial transfer reversals are only allowed for transfers to Stripe Accounts. Defaults to the entire transfer amount.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string which you can attach to a reversal object. This will be unset if you POST an empty value.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ refund_application_fee: NotRequired[bool]
+ """
+ Boolean indicating whether the application fee should be refunded when reversing this transfer. If a full transfer reversal is given, the full application fee will be refunded. Otherwise, the application fee will be refunded with an amount proportional to the amount of the transfer reversed.
+ """
diff --git a/stripe/params/_transfer_list_params.py b/stripe/params/_transfer_list_params.py
new file mode 100644
index 000000000..e131cd5a0
--- /dev/null
+++ b/stripe/params/_transfer_list_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class TransferListParams(RequestOptions):
+ created: NotRequired["TransferListParamsCreated|int"]
+ """
+ Only return transfers that were created during the given date interval.
+ """
+ destination: NotRequired[str]
+ """
+ Only return transfers for the destination specified by this account ID.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ transfer_group: NotRequired[str]
+ """
+ Only return transfers with the specified transfer group.
+ """
+
+
+class TransferListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/_transfer_list_reversals_params.py b/stripe/params/_transfer_list_reversals_params.py
new file mode 100644
index 000000000..f5aeb8eff
--- /dev/null
+++ b/stripe/params/_transfer_list_reversals_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TransferListReversalsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_transfer_modify_params.py b/stripe/params/_transfer_modify_params.py
new file mode 100644
index 000000000..bfee1cecb
--- /dev/null
+++ b/stripe/params/_transfer_modify_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class TransferModifyParams(RequestOptions):
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_transfer_modify_reversal_params.py b/stripe/params/_transfer_modify_reversal_params.py
new file mode 100644
index 000000000..ab2b0d271
--- /dev/null
+++ b/stripe/params/_transfer_modify_reversal_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class TransferModifyReversalParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_transfer_retrieve_params.py b/stripe/params/_transfer_retrieve_params.py
new file mode 100644
index 000000000..21daaac71
--- /dev/null
+++ b/stripe/params/_transfer_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TransferRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_transfer_retrieve_reversal_params.py b/stripe/params/_transfer_retrieve_reversal_params.py
new file mode 100644
index 000000000..d827a4847
--- /dev/null
+++ b/stripe/params/_transfer_retrieve_reversal_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TransferRetrieveReversalParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_transfer_reversal_create_params.py b/stripe/params/_transfer_reversal_create_params.py
new file mode 100644
index 000000000..50268c857
--- /dev/null
+++ b/stripe/params/_transfer_reversal_create_params.py
@@ -0,0 +1,27 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TransferReversalCreateParams(TypedDict):
+ amount: NotRequired[int]
+ """
+ A positive integer in cents (or local equivalent) representing how much of this transfer to reverse. Can only reverse up to the unreversed amount remaining of the transfer. Partial transfer reversals are only allowed for transfers to Stripe Accounts. Defaults to the entire transfer amount.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string which you can attach to a reversal object. This will be unset if you POST an empty value.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ refund_application_fee: NotRequired[bool]
+ """
+ Boolean indicating whether the application fee should be refunded when reversing this transfer. If a full transfer reversal is given, the full application fee will be refunded. Otherwise, the application fee will be refunded with an amount proportional to the amount of the transfer reversed.
+ """
diff --git a/stripe/params/_transfer_reversal_list_params.py b/stripe/params/_transfer_reversal_list_params.py
new file mode 100644
index 000000000..61cb435f6
--- /dev/null
+++ b/stripe/params/_transfer_reversal_list_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class TransferReversalListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_transfer_reversal_retrieve_params.py b/stripe/params/_transfer_reversal_retrieve_params.py
new file mode 100644
index 000000000..8cabccb57
--- /dev/null
+++ b/stripe/params/_transfer_reversal_retrieve_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class TransferReversalRetrieveParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_transfer_reversal_update_params.py b/stripe/params/_transfer_reversal_update_params.py
new file mode 100644
index 000000000..aebe79cc1
--- /dev/null
+++ b/stripe/params/_transfer_reversal_update_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TransferReversalUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_transfer_update_params.py b/stripe/params/_transfer_update_params.py
new file mode 100644
index 000000000..4d0452546
--- /dev/null
+++ b/stripe/params/_transfer_update_params.py
@@ -0,0 +1,19 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TransferUpdateParams(TypedDict):
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/_webhook_endpoint_create_params.py b/stripe/params/_webhook_endpoint_create_params.py
new file mode 100644
index 000000000..9e53a76b7
--- /dev/null
+++ b/stripe/params/_webhook_endpoint_create_params.py
@@ -0,0 +1,408 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class WebhookEndpointCreateParams(RequestOptions):
+ api_version: NotRequired[
+ Literal[
+ "2011-01-01",
+ "2011-06-21",
+ "2011-06-28",
+ "2011-08-01",
+ "2011-09-15",
+ "2011-11-17",
+ "2012-02-23",
+ "2012-03-25",
+ "2012-06-18",
+ "2012-06-28",
+ "2012-07-09",
+ "2012-09-24",
+ "2012-10-26",
+ "2012-11-07",
+ "2013-02-11",
+ "2013-02-13",
+ "2013-07-05",
+ "2013-08-12",
+ "2013-08-13",
+ "2013-10-29",
+ "2013-12-03",
+ "2014-01-31",
+ "2014-03-13",
+ "2014-03-28",
+ "2014-05-19",
+ "2014-06-13",
+ "2014-06-17",
+ "2014-07-22",
+ "2014-07-26",
+ "2014-08-04",
+ "2014-08-20",
+ "2014-09-08",
+ "2014-10-07",
+ "2014-11-05",
+ "2014-11-20",
+ "2014-12-08",
+ "2014-12-17",
+ "2014-12-22",
+ "2015-01-11",
+ "2015-01-26",
+ "2015-02-10",
+ "2015-02-16",
+ "2015-02-18",
+ "2015-03-24",
+ "2015-04-07",
+ "2015-06-15",
+ "2015-07-07",
+ "2015-07-13",
+ "2015-07-28",
+ "2015-08-07",
+ "2015-08-19",
+ "2015-09-03",
+ "2015-09-08",
+ "2015-09-23",
+ "2015-10-01",
+ "2015-10-12",
+ "2015-10-16",
+ "2016-02-03",
+ "2016-02-19",
+ "2016-02-22",
+ "2016-02-23",
+ "2016-02-29",
+ "2016-03-07",
+ "2016-06-15",
+ "2016-07-06",
+ "2016-10-19",
+ "2017-01-27",
+ "2017-02-14",
+ "2017-04-06",
+ "2017-05-25",
+ "2017-06-05",
+ "2017-08-15",
+ "2017-12-14",
+ "2018-01-23",
+ "2018-02-05",
+ "2018-02-06",
+ "2018-02-28",
+ "2018-05-21",
+ "2018-07-27",
+ "2018-08-23",
+ "2018-09-06",
+ "2018-09-24",
+ "2018-10-31",
+ "2018-11-08",
+ "2019-02-11",
+ "2019-02-19",
+ "2019-03-14",
+ "2019-05-16",
+ "2019-08-14",
+ "2019-09-09",
+ "2019-10-08",
+ "2019-10-17",
+ "2019-11-05",
+ "2019-12-03",
+ "2020-03-02",
+ "2020-08-27",
+ "2022-08-01",
+ "2022-11-15",
+ "2023-08-16",
+ "2023-10-16",
+ "2024-04-10",
+ "2024-06-20",
+ "2024-09-30.acacia",
+ "2024-10-28.acacia",
+ "2024-11-20.acacia",
+ "2024-12-18.acacia",
+ "2025-01-27.acacia",
+ "2025-02-24.acacia",
+ "2025-03-01.dashboard",
+ "2025-03-31.basil",
+ "2025-04-30.basil",
+ "2025-05-28.basil",
+ "2025-06-30.basil",
+ "2025-07-30.basil",
+ "2025-08-27.basil",
+ "2025-09-30.clover",
+ ]
+ ]
+ """
+ Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version.
+ """
+ connect: NotRequired[bool]
+ """
+ Whether this endpoint should receive events from connected accounts (`true`), or from your account (`false`). Defaults to `false`.
+ """
+ description: NotRequired["Literal['']|str"]
+ """
+ An optional description of what the webhook is used for.
+ """
+ enabled_events: List[
+ Literal[
+ "*",
+ "account.application.authorized",
+ "account.application.deauthorized",
+ "account.external_account.created",
+ "account.external_account.deleted",
+ "account.external_account.updated",
+ "account.updated",
+ "application_fee.created",
+ "application_fee.refund.updated",
+ "application_fee.refunded",
+ "balance.available",
+ "billing.alert.triggered",
+ "billing_portal.configuration.created",
+ "billing_portal.configuration.updated",
+ "billing_portal.session.created",
+ "capability.updated",
+ "cash_balance.funds_available",
+ "charge.captured",
+ "charge.dispute.closed",
+ "charge.dispute.created",
+ "charge.dispute.funds_reinstated",
+ "charge.dispute.funds_withdrawn",
+ "charge.dispute.updated",
+ "charge.expired",
+ "charge.failed",
+ "charge.pending",
+ "charge.refund.updated",
+ "charge.refunded",
+ "charge.succeeded",
+ "charge.updated",
+ "checkout.session.async_payment_failed",
+ "checkout.session.async_payment_succeeded",
+ "checkout.session.completed",
+ "checkout.session.expired",
+ "climate.order.canceled",
+ "climate.order.created",
+ "climate.order.delayed",
+ "climate.order.delivered",
+ "climate.order.product_substituted",
+ "climate.product.created",
+ "climate.product.pricing_updated",
+ "coupon.created",
+ "coupon.deleted",
+ "coupon.updated",
+ "credit_note.created",
+ "credit_note.updated",
+ "credit_note.voided",
+ "customer.created",
+ "customer.deleted",
+ "customer.discount.created",
+ "customer.discount.deleted",
+ "customer.discount.updated",
+ "customer.source.created",
+ "customer.source.deleted",
+ "customer.source.expiring",
+ "customer.source.updated",
+ "customer.subscription.created",
+ "customer.subscription.deleted",
+ "customer.subscription.paused",
+ "customer.subscription.pending_update_applied",
+ "customer.subscription.pending_update_expired",
+ "customer.subscription.resumed",
+ "customer.subscription.trial_will_end",
+ "customer.subscription.updated",
+ "customer.tax_id.created",
+ "customer.tax_id.deleted",
+ "customer.tax_id.updated",
+ "customer.updated",
+ "customer_cash_balance_transaction.created",
+ "entitlements.active_entitlement_summary.updated",
+ "file.created",
+ "financial_connections.account.created",
+ "financial_connections.account.deactivated",
+ "financial_connections.account.disconnected",
+ "financial_connections.account.reactivated",
+ "financial_connections.account.refreshed_balance",
+ "financial_connections.account.refreshed_ownership",
+ "financial_connections.account.refreshed_transactions",
+ "identity.verification_session.canceled",
+ "identity.verification_session.created",
+ "identity.verification_session.processing",
+ "identity.verification_session.redacted",
+ "identity.verification_session.requires_input",
+ "identity.verification_session.verified",
+ "invoice.created",
+ "invoice.deleted",
+ "invoice.finalization_failed",
+ "invoice.finalized",
+ "invoice.marked_uncollectible",
+ "invoice.overdue",
+ "invoice.overpaid",
+ "invoice.paid",
+ "invoice.payment_action_required",
+ "invoice.payment_failed",
+ "invoice.payment_succeeded",
+ "invoice.sent",
+ "invoice.upcoming",
+ "invoice.updated",
+ "invoice.voided",
+ "invoice.will_be_due",
+ "invoice_payment.paid",
+ "invoiceitem.created",
+ "invoiceitem.deleted",
+ "issuing_authorization.created",
+ "issuing_authorization.request",
+ "issuing_authorization.updated",
+ "issuing_card.created",
+ "issuing_card.updated",
+ "issuing_cardholder.created",
+ "issuing_cardholder.updated",
+ "issuing_dispute.closed",
+ "issuing_dispute.created",
+ "issuing_dispute.funds_reinstated",
+ "issuing_dispute.funds_rescinded",
+ "issuing_dispute.submitted",
+ "issuing_dispute.updated",
+ "issuing_personalization_design.activated",
+ "issuing_personalization_design.deactivated",
+ "issuing_personalization_design.rejected",
+ "issuing_personalization_design.updated",
+ "issuing_token.created",
+ "issuing_token.updated",
+ "issuing_transaction.created",
+ "issuing_transaction.purchase_details_receipt_updated",
+ "issuing_transaction.updated",
+ "mandate.updated",
+ "payment_intent.amount_capturable_updated",
+ "payment_intent.canceled",
+ "payment_intent.created",
+ "payment_intent.partially_funded",
+ "payment_intent.payment_failed",
+ "payment_intent.processing",
+ "payment_intent.requires_action",
+ "payment_intent.succeeded",
+ "payment_link.created",
+ "payment_link.updated",
+ "payment_method.attached",
+ "payment_method.automatically_updated",
+ "payment_method.detached",
+ "payment_method.updated",
+ "payout.canceled",
+ "payout.created",
+ "payout.failed",
+ "payout.paid",
+ "payout.reconciliation_completed",
+ "payout.updated",
+ "person.created",
+ "person.deleted",
+ "person.updated",
+ "plan.created",
+ "plan.deleted",
+ "plan.updated",
+ "price.created",
+ "price.deleted",
+ "price.updated",
+ "product.created",
+ "product.deleted",
+ "product.updated",
+ "promotion_code.created",
+ "promotion_code.updated",
+ "quote.accepted",
+ "quote.canceled",
+ "quote.created",
+ "quote.finalized",
+ "radar.early_fraud_warning.created",
+ "radar.early_fraud_warning.updated",
+ "refund.created",
+ "refund.failed",
+ "refund.updated",
+ "reporting.report_run.failed",
+ "reporting.report_run.succeeded",
+ "reporting.report_type.updated",
+ "review.closed",
+ "review.opened",
+ "setup_intent.canceled",
+ "setup_intent.created",
+ "setup_intent.requires_action",
+ "setup_intent.setup_failed",
+ "setup_intent.succeeded",
+ "sigma.scheduled_query_run.created",
+ "source.canceled",
+ "source.chargeable",
+ "source.failed",
+ "source.mandate_notification",
+ "source.refund_attributes_required",
+ "source.transaction.created",
+ "source.transaction.updated",
+ "subscription_schedule.aborted",
+ "subscription_schedule.canceled",
+ "subscription_schedule.completed",
+ "subscription_schedule.created",
+ "subscription_schedule.expiring",
+ "subscription_schedule.released",
+ "subscription_schedule.updated",
+ "tax.settings.updated",
+ "tax_rate.created",
+ "tax_rate.updated",
+ "terminal.reader.action_failed",
+ "terminal.reader.action_succeeded",
+ "terminal.reader.action_updated",
+ "test_helpers.test_clock.advancing",
+ "test_helpers.test_clock.created",
+ "test_helpers.test_clock.deleted",
+ "test_helpers.test_clock.internal_failure",
+ "test_helpers.test_clock.ready",
+ "topup.canceled",
+ "topup.created",
+ "topup.failed",
+ "topup.reversed",
+ "topup.succeeded",
+ "transfer.created",
+ "transfer.reversed",
+ "transfer.updated",
+ "treasury.credit_reversal.created",
+ "treasury.credit_reversal.posted",
+ "treasury.debit_reversal.completed",
+ "treasury.debit_reversal.created",
+ "treasury.debit_reversal.initial_credit_granted",
+ "treasury.financial_account.closed",
+ "treasury.financial_account.created",
+ "treasury.financial_account.features_status_updated",
+ "treasury.inbound_transfer.canceled",
+ "treasury.inbound_transfer.created",
+ "treasury.inbound_transfer.failed",
+ "treasury.inbound_transfer.succeeded",
+ "treasury.outbound_payment.canceled",
+ "treasury.outbound_payment.created",
+ "treasury.outbound_payment.expected_arrival_date_updated",
+ "treasury.outbound_payment.failed",
+ "treasury.outbound_payment.posted",
+ "treasury.outbound_payment.returned",
+ "treasury.outbound_payment.tracking_details_updated",
+ "treasury.outbound_transfer.canceled",
+ "treasury.outbound_transfer.created",
+ "treasury.outbound_transfer.expected_arrival_date_updated",
+ "treasury.outbound_transfer.failed",
+ "treasury.outbound_transfer.posted",
+ "treasury.outbound_transfer.returned",
+ "treasury.outbound_transfer.tracking_details_updated",
+ "treasury.received_credit.created",
+ "treasury.received_credit.failed",
+ "treasury.received_credit.succeeded",
+ "treasury.received_debit.created",
+ "billing.credit_balance_transaction.created",
+ "billing.credit_grant.created",
+ "billing.credit_grant.updated",
+ "billing.meter.created",
+ "billing.meter.deactivated",
+ "billing.meter.reactivated",
+ "billing.meter.updated",
+ ]
+ ]
+ """
+ The list of events to enable for this endpoint. You may specify `['*']` to enable all events, except those that require explicit selection.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ url: str
+ """
+ The URL of the webhook endpoint.
+ """
diff --git a/stripe/params/_webhook_endpoint_delete_params.py b/stripe/params/_webhook_endpoint_delete_params.py
new file mode 100644
index 000000000..8c17a5d89
--- /dev/null
+++ b/stripe/params/_webhook_endpoint_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class WebhookEndpointDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/_webhook_endpoint_list_params.py b/stripe/params/_webhook_endpoint_list_params.py
new file mode 100644
index 000000000..837e62fdb
--- /dev/null
+++ b/stripe/params/_webhook_endpoint_list_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class WebhookEndpointListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/_webhook_endpoint_modify_params.py b/stripe/params/_webhook_endpoint_modify_params.py
new file mode 100644
index 000000000..938ec9ea0
--- /dev/null
+++ b/stripe/params/_webhook_endpoint_modify_params.py
@@ -0,0 +1,287 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class WebhookEndpointModifyParams(RequestOptions):
+ description: NotRequired["Literal['']|str"]
+ """
+ An optional description of what the webhook is used for.
+ """
+ disabled: NotRequired[bool]
+ """
+ Disable the webhook endpoint if set to true.
+ """
+ enabled_events: NotRequired[
+ List[
+ Literal[
+ "*",
+ "account.application.authorized",
+ "account.application.deauthorized",
+ "account.external_account.created",
+ "account.external_account.deleted",
+ "account.external_account.updated",
+ "account.updated",
+ "application_fee.created",
+ "application_fee.refund.updated",
+ "application_fee.refunded",
+ "balance.available",
+ "billing.alert.triggered",
+ "billing_portal.configuration.created",
+ "billing_portal.configuration.updated",
+ "billing_portal.session.created",
+ "capability.updated",
+ "cash_balance.funds_available",
+ "charge.captured",
+ "charge.dispute.closed",
+ "charge.dispute.created",
+ "charge.dispute.funds_reinstated",
+ "charge.dispute.funds_withdrawn",
+ "charge.dispute.updated",
+ "charge.expired",
+ "charge.failed",
+ "charge.pending",
+ "charge.refund.updated",
+ "charge.refunded",
+ "charge.succeeded",
+ "charge.updated",
+ "checkout.session.async_payment_failed",
+ "checkout.session.async_payment_succeeded",
+ "checkout.session.completed",
+ "checkout.session.expired",
+ "climate.order.canceled",
+ "climate.order.created",
+ "climate.order.delayed",
+ "climate.order.delivered",
+ "climate.order.product_substituted",
+ "climate.product.created",
+ "climate.product.pricing_updated",
+ "coupon.created",
+ "coupon.deleted",
+ "coupon.updated",
+ "credit_note.created",
+ "credit_note.updated",
+ "credit_note.voided",
+ "customer.created",
+ "customer.deleted",
+ "customer.discount.created",
+ "customer.discount.deleted",
+ "customer.discount.updated",
+ "customer.source.created",
+ "customer.source.deleted",
+ "customer.source.expiring",
+ "customer.source.updated",
+ "customer.subscription.created",
+ "customer.subscription.deleted",
+ "customer.subscription.paused",
+ "customer.subscription.pending_update_applied",
+ "customer.subscription.pending_update_expired",
+ "customer.subscription.resumed",
+ "customer.subscription.trial_will_end",
+ "customer.subscription.updated",
+ "customer.tax_id.created",
+ "customer.tax_id.deleted",
+ "customer.tax_id.updated",
+ "customer.updated",
+ "customer_cash_balance_transaction.created",
+ "entitlements.active_entitlement_summary.updated",
+ "file.created",
+ "financial_connections.account.created",
+ "financial_connections.account.deactivated",
+ "financial_connections.account.disconnected",
+ "financial_connections.account.reactivated",
+ "financial_connections.account.refreshed_balance",
+ "financial_connections.account.refreshed_ownership",
+ "financial_connections.account.refreshed_transactions",
+ "identity.verification_session.canceled",
+ "identity.verification_session.created",
+ "identity.verification_session.processing",
+ "identity.verification_session.redacted",
+ "identity.verification_session.requires_input",
+ "identity.verification_session.verified",
+ "invoice.created",
+ "invoice.deleted",
+ "invoice.finalization_failed",
+ "invoice.finalized",
+ "invoice.marked_uncollectible",
+ "invoice.overdue",
+ "invoice.overpaid",
+ "invoice.paid",
+ "invoice.payment_action_required",
+ "invoice.payment_failed",
+ "invoice.payment_succeeded",
+ "invoice.sent",
+ "invoice.upcoming",
+ "invoice.updated",
+ "invoice.voided",
+ "invoice.will_be_due",
+ "invoice_payment.paid",
+ "invoiceitem.created",
+ "invoiceitem.deleted",
+ "issuing_authorization.created",
+ "issuing_authorization.request",
+ "issuing_authorization.updated",
+ "issuing_card.created",
+ "issuing_card.updated",
+ "issuing_cardholder.created",
+ "issuing_cardholder.updated",
+ "issuing_dispute.closed",
+ "issuing_dispute.created",
+ "issuing_dispute.funds_reinstated",
+ "issuing_dispute.funds_rescinded",
+ "issuing_dispute.submitted",
+ "issuing_dispute.updated",
+ "issuing_personalization_design.activated",
+ "issuing_personalization_design.deactivated",
+ "issuing_personalization_design.rejected",
+ "issuing_personalization_design.updated",
+ "issuing_token.created",
+ "issuing_token.updated",
+ "issuing_transaction.created",
+ "issuing_transaction.purchase_details_receipt_updated",
+ "issuing_transaction.updated",
+ "mandate.updated",
+ "payment_intent.amount_capturable_updated",
+ "payment_intent.canceled",
+ "payment_intent.created",
+ "payment_intent.partially_funded",
+ "payment_intent.payment_failed",
+ "payment_intent.processing",
+ "payment_intent.requires_action",
+ "payment_intent.succeeded",
+ "payment_link.created",
+ "payment_link.updated",
+ "payment_method.attached",
+ "payment_method.automatically_updated",
+ "payment_method.detached",
+ "payment_method.updated",
+ "payout.canceled",
+ "payout.created",
+ "payout.failed",
+ "payout.paid",
+ "payout.reconciliation_completed",
+ "payout.updated",
+ "person.created",
+ "person.deleted",
+ "person.updated",
+ "plan.created",
+ "plan.deleted",
+ "plan.updated",
+ "price.created",
+ "price.deleted",
+ "price.updated",
+ "product.created",
+ "product.deleted",
+ "product.updated",
+ "promotion_code.created",
+ "promotion_code.updated",
+ "quote.accepted",
+ "quote.canceled",
+ "quote.created",
+ "quote.finalized",
+ "radar.early_fraud_warning.created",
+ "radar.early_fraud_warning.updated",
+ "refund.created",
+ "refund.failed",
+ "refund.updated",
+ "reporting.report_run.failed",
+ "reporting.report_run.succeeded",
+ "reporting.report_type.updated",
+ "review.closed",
+ "review.opened",
+ "setup_intent.canceled",
+ "setup_intent.created",
+ "setup_intent.requires_action",
+ "setup_intent.setup_failed",
+ "setup_intent.succeeded",
+ "sigma.scheduled_query_run.created",
+ "source.canceled",
+ "source.chargeable",
+ "source.failed",
+ "source.mandate_notification",
+ "source.refund_attributes_required",
+ "source.transaction.created",
+ "source.transaction.updated",
+ "subscription_schedule.aborted",
+ "subscription_schedule.canceled",
+ "subscription_schedule.completed",
+ "subscription_schedule.created",
+ "subscription_schedule.expiring",
+ "subscription_schedule.released",
+ "subscription_schedule.updated",
+ "tax.settings.updated",
+ "tax_rate.created",
+ "tax_rate.updated",
+ "terminal.reader.action_failed",
+ "terminal.reader.action_succeeded",
+ "terminal.reader.action_updated",
+ "test_helpers.test_clock.advancing",
+ "test_helpers.test_clock.created",
+ "test_helpers.test_clock.deleted",
+ "test_helpers.test_clock.internal_failure",
+ "test_helpers.test_clock.ready",
+ "topup.canceled",
+ "topup.created",
+ "topup.failed",
+ "topup.reversed",
+ "topup.succeeded",
+ "transfer.created",
+ "transfer.reversed",
+ "transfer.updated",
+ "treasury.credit_reversal.created",
+ "treasury.credit_reversal.posted",
+ "treasury.debit_reversal.completed",
+ "treasury.debit_reversal.created",
+ "treasury.debit_reversal.initial_credit_granted",
+ "treasury.financial_account.closed",
+ "treasury.financial_account.created",
+ "treasury.financial_account.features_status_updated",
+ "treasury.inbound_transfer.canceled",
+ "treasury.inbound_transfer.created",
+ "treasury.inbound_transfer.failed",
+ "treasury.inbound_transfer.succeeded",
+ "treasury.outbound_payment.canceled",
+ "treasury.outbound_payment.created",
+ "treasury.outbound_payment.expected_arrival_date_updated",
+ "treasury.outbound_payment.failed",
+ "treasury.outbound_payment.posted",
+ "treasury.outbound_payment.returned",
+ "treasury.outbound_payment.tracking_details_updated",
+ "treasury.outbound_transfer.canceled",
+ "treasury.outbound_transfer.created",
+ "treasury.outbound_transfer.expected_arrival_date_updated",
+ "treasury.outbound_transfer.failed",
+ "treasury.outbound_transfer.posted",
+ "treasury.outbound_transfer.returned",
+ "treasury.outbound_transfer.tracking_details_updated",
+ "treasury.received_credit.created",
+ "treasury.received_credit.failed",
+ "treasury.received_credit.succeeded",
+ "treasury.received_debit.created",
+ "billing.credit_balance_transaction.created",
+ "billing.credit_grant.created",
+ "billing.credit_grant.updated",
+ "billing.meter.created",
+ "billing.meter.deactivated",
+ "billing.meter.reactivated",
+ "billing.meter.updated",
+ ]
+ ]
+ ]
+ """
+ The list of events to enable for this endpoint. You may specify `['*']` to enable all events, except those that require explicit selection.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ url: NotRequired[str]
+ """
+ The URL of the webhook endpoint.
+ """
diff --git a/stripe/params/_webhook_endpoint_retrieve_params.py b/stripe/params/_webhook_endpoint_retrieve_params.py
new file mode 100644
index 000000000..3387b0f27
--- /dev/null
+++ b/stripe/params/_webhook_endpoint_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class WebhookEndpointRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/_webhook_endpoint_update_params.py b/stripe/params/_webhook_endpoint_update_params.py
new file mode 100644
index 000000000..0eeacd198
--- /dev/null
+++ b/stripe/params/_webhook_endpoint_update_params.py
@@ -0,0 +1,286 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class WebhookEndpointUpdateParams(TypedDict):
+ description: NotRequired["Literal['']|str"]
+ """
+ An optional description of what the webhook is used for.
+ """
+ disabled: NotRequired[bool]
+ """
+ Disable the webhook endpoint if set to true.
+ """
+ enabled_events: NotRequired[
+ List[
+ Literal[
+ "*",
+ "account.application.authorized",
+ "account.application.deauthorized",
+ "account.external_account.created",
+ "account.external_account.deleted",
+ "account.external_account.updated",
+ "account.updated",
+ "application_fee.created",
+ "application_fee.refund.updated",
+ "application_fee.refunded",
+ "balance.available",
+ "billing.alert.triggered",
+ "billing_portal.configuration.created",
+ "billing_portal.configuration.updated",
+ "billing_portal.session.created",
+ "capability.updated",
+ "cash_balance.funds_available",
+ "charge.captured",
+ "charge.dispute.closed",
+ "charge.dispute.created",
+ "charge.dispute.funds_reinstated",
+ "charge.dispute.funds_withdrawn",
+ "charge.dispute.updated",
+ "charge.expired",
+ "charge.failed",
+ "charge.pending",
+ "charge.refund.updated",
+ "charge.refunded",
+ "charge.succeeded",
+ "charge.updated",
+ "checkout.session.async_payment_failed",
+ "checkout.session.async_payment_succeeded",
+ "checkout.session.completed",
+ "checkout.session.expired",
+ "climate.order.canceled",
+ "climate.order.created",
+ "climate.order.delayed",
+ "climate.order.delivered",
+ "climate.order.product_substituted",
+ "climate.product.created",
+ "climate.product.pricing_updated",
+ "coupon.created",
+ "coupon.deleted",
+ "coupon.updated",
+ "credit_note.created",
+ "credit_note.updated",
+ "credit_note.voided",
+ "customer.created",
+ "customer.deleted",
+ "customer.discount.created",
+ "customer.discount.deleted",
+ "customer.discount.updated",
+ "customer.source.created",
+ "customer.source.deleted",
+ "customer.source.expiring",
+ "customer.source.updated",
+ "customer.subscription.created",
+ "customer.subscription.deleted",
+ "customer.subscription.paused",
+ "customer.subscription.pending_update_applied",
+ "customer.subscription.pending_update_expired",
+ "customer.subscription.resumed",
+ "customer.subscription.trial_will_end",
+ "customer.subscription.updated",
+ "customer.tax_id.created",
+ "customer.tax_id.deleted",
+ "customer.tax_id.updated",
+ "customer.updated",
+ "customer_cash_balance_transaction.created",
+ "entitlements.active_entitlement_summary.updated",
+ "file.created",
+ "financial_connections.account.created",
+ "financial_connections.account.deactivated",
+ "financial_connections.account.disconnected",
+ "financial_connections.account.reactivated",
+ "financial_connections.account.refreshed_balance",
+ "financial_connections.account.refreshed_ownership",
+ "financial_connections.account.refreshed_transactions",
+ "identity.verification_session.canceled",
+ "identity.verification_session.created",
+ "identity.verification_session.processing",
+ "identity.verification_session.redacted",
+ "identity.verification_session.requires_input",
+ "identity.verification_session.verified",
+ "invoice.created",
+ "invoice.deleted",
+ "invoice.finalization_failed",
+ "invoice.finalized",
+ "invoice.marked_uncollectible",
+ "invoice.overdue",
+ "invoice.overpaid",
+ "invoice.paid",
+ "invoice.payment_action_required",
+ "invoice.payment_failed",
+ "invoice.payment_succeeded",
+ "invoice.sent",
+ "invoice.upcoming",
+ "invoice.updated",
+ "invoice.voided",
+ "invoice.will_be_due",
+ "invoice_payment.paid",
+ "invoiceitem.created",
+ "invoiceitem.deleted",
+ "issuing_authorization.created",
+ "issuing_authorization.request",
+ "issuing_authorization.updated",
+ "issuing_card.created",
+ "issuing_card.updated",
+ "issuing_cardholder.created",
+ "issuing_cardholder.updated",
+ "issuing_dispute.closed",
+ "issuing_dispute.created",
+ "issuing_dispute.funds_reinstated",
+ "issuing_dispute.funds_rescinded",
+ "issuing_dispute.submitted",
+ "issuing_dispute.updated",
+ "issuing_personalization_design.activated",
+ "issuing_personalization_design.deactivated",
+ "issuing_personalization_design.rejected",
+ "issuing_personalization_design.updated",
+ "issuing_token.created",
+ "issuing_token.updated",
+ "issuing_transaction.created",
+ "issuing_transaction.purchase_details_receipt_updated",
+ "issuing_transaction.updated",
+ "mandate.updated",
+ "payment_intent.amount_capturable_updated",
+ "payment_intent.canceled",
+ "payment_intent.created",
+ "payment_intent.partially_funded",
+ "payment_intent.payment_failed",
+ "payment_intent.processing",
+ "payment_intent.requires_action",
+ "payment_intent.succeeded",
+ "payment_link.created",
+ "payment_link.updated",
+ "payment_method.attached",
+ "payment_method.automatically_updated",
+ "payment_method.detached",
+ "payment_method.updated",
+ "payout.canceled",
+ "payout.created",
+ "payout.failed",
+ "payout.paid",
+ "payout.reconciliation_completed",
+ "payout.updated",
+ "person.created",
+ "person.deleted",
+ "person.updated",
+ "plan.created",
+ "plan.deleted",
+ "plan.updated",
+ "price.created",
+ "price.deleted",
+ "price.updated",
+ "product.created",
+ "product.deleted",
+ "product.updated",
+ "promotion_code.created",
+ "promotion_code.updated",
+ "quote.accepted",
+ "quote.canceled",
+ "quote.created",
+ "quote.finalized",
+ "radar.early_fraud_warning.created",
+ "radar.early_fraud_warning.updated",
+ "refund.created",
+ "refund.failed",
+ "refund.updated",
+ "reporting.report_run.failed",
+ "reporting.report_run.succeeded",
+ "reporting.report_type.updated",
+ "review.closed",
+ "review.opened",
+ "setup_intent.canceled",
+ "setup_intent.created",
+ "setup_intent.requires_action",
+ "setup_intent.setup_failed",
+ "setup_intent.succeeded",
+ "sigma.scheduled_query_run.created",
+ "source.canceled",
+ "source.chargeable",
+ "source.failed",
+ "source.mandate_notification",
+ "source.refund_attributes_required",
+ "source.transaction.created",
+ "source.transaction.updated",
+ "subscription_schedule.aborted",
+ "subscription_schedule.canceled",
+ "subscription_schedule.completed",
+ "subscription_schedule.created",
+ "subscription_schedule.expiring",
+ "subscription_schedule.released",
+ "subscription_schedule.updated",
+ "tax.settings.updated",
+ "tax_rate.created",
+ "tax_rate.updated",
+ "terminal.reader.action_failed",
+ "terminal.reader.action_succeeded",
+ "terminal.reader.action_updated",
+ "test_helpers.test_clock.advancing",
+ "test_helpers.test_clock.created",
+ "test_helpers.test_clock.deleted",
+ "test_helpers.test_clock.internal_failure",
+ "test_helpers.test_clock.ready",
+ "topup.canceled",
+ "topup.created",
+ "topup.failed",
+ "topup.reversed",
+ "topup.succeeded",
+ "transfer.created",
+ "transfer.reversed",
+ "transfer.updated",
+ "treasury.credit_reversal.created",
+ "treasury.credit_reversal.posted",
+ "treasury.debit_reversal.completed",
+ "treasury.debit_reversal.created",
+ "treasury.debit_reversal.initial_credit_granted",
+ "treasury.financial_account.closed",
+ "treasury.financial_account.created",
+ "treasury.financial_account.features_status_updated",
+ "treasury.inbound_transfer.canceled",
+ "treasury.inbound_transfer.created",
+ "treasury.inbound_transfer.failed",
+ "treasury.inbound_transfer.succeeded",
+ "treasury.outbound_payment.canceled",
+ "treasury.outbound_payment.created",
+ "treasury.outbound_payment.expected_arrival_date_updated",
+ "treasury.outbound_payment.failed",
+ "treasury.outbound_payment.posted",
+ "treasury.outbound_payment.returned",
+ "treasury.outbound_payment.tracking_details_updated",
+ "treasury.outbound_transfer.canceled",
+ "treasury.outbound_transfer.created",
+ "treasury.outbound_transfer.expected_arrival_date_updated",
+ "treasury.outbound_transfer.failed",
+ "treasury.outbound_transfer.posted",
+ "treasury.outbound_transfer.returned",
+ "treasury.outbound_transfer.tracking_details_updated",
+ "treasury.received_credit.created",
+ "treasury.received_credit.failed",
+ "treasury.received_credit.succeeded",
+ "treasury.received_debit.created",
+ "billing.credit_balance_transaction.created",
+ "billing.credit_grant.created",
+ "billing.credit_grant.updated",
+ "billing.meter.created",
+ "billing.meter.deactivated",
+ "billing.meter.reactivated",
+ "billing.meter.updated",
+ ]
+ ]
+ ]
+ """
+ The list of events to enable for this endpoint. You may specify `['*']` to enable all events, except those that require explicit selection.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ url: NotRequired[str]
+ """
+ The URL of the webhook endpoint.
+ """
diff --git a/stripe/params/apps/__init__.py b/stripe/params/apps/__init__.py
new file mode 100644
index 000000000..357ad6f63
--- /dev/null
+++ b/stripe/params/apps/__init__.py
@@ -0,0 +1,14 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.apps._secret_create_params import (
+ SecretCreateParams as SecretCreateParams,
+)
+from stripe.params.apps._secret_delete_where_params import (
+ SecretDeleteWhereParams as SecretDeleteWhereParams,
+)
+from stripe.params.apps._secret_find_params import (
+ SecretFindParams as SecretFindParams,
+)
+from stripe.params.apps._secret_list_params import (
+ SecretListParams as SecretListParams,
+)
diff --git a/stripe/params/apps/_secret_create_params.py b/stripe/params/apps/_secret_create_params.py
new file mode 100644
index 000000000..8fe08f4bd
--- /dev/null
+++ b/stripe/params/apps/_secret_create_params.py
@@ -0,0 +1,39 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SecretCreateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired[int]
+ """
+ The Unix timestamp for the expiry time of the secret, after which the secret deletes.
+ """
+ name: str
+ """
+ A name for the secret that's unique within the scope.
+ """
+ payload: str
+ """
+ The plaintext secret value to be stored.
+ """
+ scope: "SecretCreateParamsScope"
+ """
+ Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
+ """
+
+
+class SecretCreateParamsScope(TypedDict):
+ type: Literal["account", "user"]
+ """
+ The secret scope type.
+ """
+ user: NotRequired[str]
+ """
+ The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
+ """
diff --git a/stripe/params/apps/_secret_delete_where_params.py b/stripe/params/apps/_secret_delete_where_params.py
new file mode 100644
index 000000000..ad26f74b7
--- /dev/null
+++ b/stripe/params/apps/_secret_delete_where_params.py
@@ -0,0 +1,31 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SecretDeleteWhereParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ name: str
+ """
+ A name for the secret that's unique within the scope.
+ """
+ scope: "SecretDeleteWhereParamsScope"
+ """
+ Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
+ """
+
+
+class SecretDeleteWhereParamsScope(TypedDict):
+ type: Literal["account", "user"]
+ """
+ The secret scope type.
+ """
+ user: NotRequired[str]
+ """
+ The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
+ """
diff --git a/stripe/params/apps/_secret_find_params.py b/stripe/params/apps/_secret_find_params.py
new file mode 100644
index 000000000..4f47911bc
--- /dev/null
+++ b/stripe/params/apps/_secret_find_params.py
@@ -0,0 +1,31 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SecretFindParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ name: str
+ """
+ A name for the secret that's unique within the scope.
+ """
+ scope: "SecretFindParamsScope"
+ """
+ Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
+ """
+
+
+class SecretFindParamsScope(TypedDict):
+ type: Literal["account", "user"]
+ """
+ The secret scope type.
+ """
+ user: NotRequired[str]
+ """
+ The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
+ """
diff --git a/stripe/params/apps/_secret_list_params.py b/stripe/params/apps/_secret_list_params.py
new file mode 100644
index 000000000..b3856e859
--- /dev/null
+++ b/stripe/params/apps/_secret_list_params.py
@@ -0,0 +1,39 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SecretListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ scope: "SecretListParamsScope"
+ """
+ Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class SecretListParamsScope(TypedDict):
+ type: Literal["account", "user"]
+ """
+ The secret scope type.
+ """
+ user: NotRequired[str]
+ """
+ The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
+ """
diff --git a/stripe/params/billing/__init__.py b/stripe/params/billing/__init__.py
new file mode 100644
index 000000000..9033ba0de
--- /dev/null
+++ b/stripe/params/billing/__init__.py
@@ -0,0 +1,83 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.billing._alert_activate_params import (
+ AlertActivateParams as AlertActivateParams,
+)
+from stripe.params.billing._alert_archive_params import (
+ AlertArchiveParams as AlertArchiveParams,
+)
+from stripe.params.billing._alert_create_params import (
+ AlertCreateParams as AlertCreateParams,
+)
+from stripe.params.billing._alert_deactivate_params import (
+ AlertDeactivateParams as AlertDeactivateParams,
+)
+from stripe.params.billing._alert_list_params import (
+ AlertListParams as AlertListParams,
+)
+from stripe.params.billing._alert_retrieve_params import (
+ AlertRetrieveParams as AlertRetrieveParams,
+)
+from stripe.params.billing._credit_balance_summary_retrieve_params import (
+ CreditBalanceSummaryRetrieveParams as CreditBalanceSummaryRetrieveParams,
+)
+from stripe.params.billing._credit_balance_transaction_list_params import (
+ CreditBalanceTransactionListParams as CreditBalanceTransactionListParams,
+)
+from stripe.params.billing._credit_balance_transaction_retrieve_params import (
+ CreditBalanceTransactionRetrieveParams as CreditBalanceTransactionRetrieveParams,
+)
+from stripe.params.billing._credit_grant_create_params import (
+ CreditGrantCreateParams as CreditGrantCreateParams,
+)
+from stripe.params.billing._credit_grant_expire_params import (
+ CreditGrantExpireParams as CreditGrantExpireParams,
+)
+from stripe.params.billing._credit_grant_list_params import (
+ CreditGrantListParams as CreditGrantListParams,
+)
+from stripe.params.billing._credit_grant_modify_params import (
+ CreditGrantModifyParams as CreditGrantModifyParams,
+)
+from stripe.params.billing._credit_grant_retrieve_params import (
+ CreditGrantRetrieveParams as CreditGrantRetrieveParams,
+)
+from stripe.params.billing._credit_grant_update_params import (
+ CreditGrantUpdateParams as CreditGrantUpdateParams,
+)
+from stripe.params.billing._credit_grant_void_grant_params import (
+ CreditGrantVoidGrantParams as CreditGrantVoidGrantParams,
+)
+from stripe.params.billing._meter_create_params import (
+ MeterCreateParams as MeterCreateParams,
+)
+from stripe.params.billing._meter_deactivate_params import (
+ MeterDeactivateParams as MeterDeactivateParams,
+)
+from stripe.params.billing._meter_event_adjustment_create_params import (
+ MeterEventAdjustmentCreateParams as MeterEventAdjustmentCreateParams,
+)
+from stripe.params.billing._meter_event_create_params import (
+ MeterEventCreateParams as MeterEventCreateParams,
+)
+from stripe.params.billing._meter_event_summary_list_params import (
+ MeterEventSummaryListParams as MeterEventSummaryListParams,
+)
+from stripe.params.billing._meter_list_event_summaries_params import (
+ MeterListEventSummariesParams as MeterListEventSummariesParams,
+)
+from stripe.params.billing._meter_list_params import (
+ MeterListParams as MeterListParams,
+)
+from stripe.params.billing._meter_modify_params import (
+ MeterModifyParams as MeterModifyParams,
+)
+from stripe.params.billing._meter_reactivate_params import (
+ MeterReactivateParams as MeterReactivateParams,
+)
+from stripe.params.billing._meter_retrieve_params import (
+ MeterRetrieveParams as MeterRetrieveParams,
+)
+from stripe.params.billing._meter_update_params import (
+ MeterUpdateParams as MeterUpdateParams,
+)
diff --git a/stripe/params/billing/_alert_activate_params.py b/stripe/params/billing/_alert_activate_params.py
new file mode 100644
index 000000000..f68a2b712
--- /dev/null
+++ b/stripe/params/billing/_alert_activate_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AlertActivateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/billing/_alert_archive_params.py b/stripe/params/billing/_alert_archive_params.py
new file mode 100644
index 000000000..3213ed47f
--- /dev/null
+++ b/stripe/params/billing/_alert_archive_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AlertArchiveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/billing/_alert_create_params.py b/stripe/params/billing/_alert_create_params.py
new file mode 100644
index 000000000..95d96ca8c
--- /dev/null
+++ b/stripe/params/billing/_alert_create_params.py
@@ -0,0 +1,54 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AlertCreateParams(RequestOptions):
+ alert_type: Literal["usage_threshold"]
+ """
+ The type of alert to create.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ title: str
+ """
+ The title of the alert.
+ """
+ usage_threshold: NotRequired["AlertCreateParamsUsageThreshold"]
+ """
+ The configuration of the usage threshold.
+ """
+
+
+class AlertCreateParamsUsageThreshold(TypedDict):
+ filters: NotRequired[List["AlertCreateParamsUsageThresholdFilter"]]
+ """
+ The filters allows limiting the scope of this usage alert. You can only specify up to one filter at this time.
+ """
+ gte: int
+ """
+ Defines at which value the alert will fire.
+ """
+ meter: str
+ """
+ The [Billing Meter](https://docs.stripe.com/api/billing/meter) ID whose usage is monitored.
+ """
+ recurrence: Literal["one_time"]
+ """
+ Defines how the alert will behave.
+ """
+
+
+class AlertCreateParamsUsageThresholdFilter(TypedDict):
+ customer: NotRequired[str]
+ """
+ Limit the scope to this usage alert only to this customer.
+ """
+ type: Literal["customer"]
+ """
+ What type of filter is being applied to this usage alert.
+ """
diff --git a/stripe/params/billing/_alert_deactivate_params.py b/stripe/params/billing/_alert_deactivate_params.py
new file mode 100644
index 000000000..b69f8cbbe
--- /dev/null
+++ b/stripe/params/billing/_alert_deactivate_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AlertDeactivateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/billing/_alert_list_params.py b/stripe/params/billing/_alert_list_params.py
new file mode 100644
index 000000000..20129d2fc
--- /dev/null
+++ b/stripe/params/billing/_alert_list_params.py
@@ -0,0 +1,32 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class AlertListParams(RequestOptions):
+ alert_type: NotRequired[Literal["usage_threshold"]]
+ """
+ Filter results to only include this type of alert.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ meter: NotRequired[str]
+ """
+ Filter results to only include alerts with the given meter.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/billing/_alert_retrieve_params.py b/stripe/params/billing/_alert_retrieve_params.py
new file mode 100644
index 000000000..92df807cb
--- /dev/null
+++ b/stripe/params/billing/_alert_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AlertRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/billing/_credit_balance_summary_retrieve_params.py b/stripe/params/billing/_credit_balance_summary_retrieve_params.py
new file mode 100644
index 000000000..83568bdef
--- /dev/null
+++ b/stripe/params/billing/_credit_balance_summary_retrieve_params.py
@@ -0,0 +1,59 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CreditBalanceSummaryRetrieveParams(RequestOptions):
+ customer: str
+ """
+ The customer for which to fetch credit balance summary.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ filter: "CreditBalanceSummaryRetrieveParamsFilter"
+ """
+ The filter criteria for the credit balance summary.
+ """
+
+
+class CreditBalanceSummaryRetrieveParamsFilter(TypedDict):
+ applicability_scope: NotRequired[
+ "CreditBalanceSummaryRetrieveParamsFilterApplicabilityScope"
+ ]
+ """
+ The billing credit applicability scope for which to fetch credit balance summary.
+ """
+ credit_grant: NotRequired[str]
+ """
+ The credit grant for which to fetch credit balance summary.
+ """
+ type: Literal["applicability_scope", "credit_grant"]
+ """
+ Specify the type of this filter.
+ """
+
+
+class CreditBalanceSummaryRetrieveParamsFilterApplicabilityScope(TypedDict):
+ price_type: NotRequired[Literal["metered"]]
+ """
+ The price type that credit grants can apply to. We currently only support the `metered` price type. Cannot be used in combination with `prices`.
+ """
+ prices: NotRequired[
+ List["CreditBalanceSummaryRetrieveParamsFilterApplicabilityScopePrice"]
+ ]
+ """
+ A list of prices that the credit grant can apply to. We currently only support the `metered` prices. Cannot be used in combination with `price_type`.
+ """
+
+
+class CreditBalanceSummaryRetrieveParamsFilterApplicabilityScopePrice(
+ TypedDict,
+):
+ id: str
+ """
+ The price ID this credit grant should apply to.
+ """
diff --git a/stripe/params/billing/_credit_balance_transaction_list_params.py b/stripe/params/billing/_credit_balance_transaction_list_params.py
new file mode 100644
index 000000000..2a61839ef
--- /dev/null
+++ b/stripe/params/billing/_credit_balance_transaction_list_params.py
@@ -0,0 +1,32 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CreditBalanceTransactionListParams(RequestOptions):
+ credit_grant: NotRequired[str]
+ """
+ The credit grant for which to fetch credit balance transactions.
+ """
+ customer: str
+ """
+ The customer for which to fetch credit balance transactions.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/billing/_credit_balance_transaction_retrieve_params.py b/stripe/params/billing/_credit_balance_transaction_retrieve_params.py
new file mode 100644
index 000000000..2a5506825
--- /dev/null
+++ b/stripe/params/billing/_credit_balance_transaction_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CreditBalanceTransactionRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/billing/_credit_grant_create_params.py b/stripe/params/billing/_credit_grant_create_params.py
new file mode 100644
index 000000000..65fd1cb1a
--- /dev/null
+++ b/stripe/params/billing/_credit_grant_create_params.py
@@ -0,0 +1,97 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CreditGrantCreateParams(RequestOptions):
+ amount: "CreditGrantCreateParamsAmount"
+ """
+ Amount of this credit grant.
+ """
+ applicability_config: "CreditGrantCreateParamsApplicabilityConfig"
+ """
+ Configuration specifying what this credit grant applies to. We currently only support `metered` prices that have a [Billing Meter](https://docs.stripe.com/api/billing/meter) attached to them.
+ """
+ category: Literal["paid", "promotional"]
+ """
+ The category of this credit grant.
+ """
+ customer: str
+ """
+ ID of the customer to receive the billing credits.
+ """
+ effective_at: NotRequired[int]
+ """
+ The time when the billing credits become effective-when they're eligible for use. It defaults to the current timestamp if not specified.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired[int]
+ """
+ The time when the billing credits expire. If not specified, the billing credits don't expire.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of key-value pairs that you can attach to an object. You can use this to store additional information about the object (for example, cost basis) in a structured format.
+ """
+ name: NotRequired[str]
+ """
+ A descriptive name shown in the Dashboard.
+ """
+ priority: NotRequired[int]
+ """
+ The desired priority for applying this credit grant. If not specified, it will be set to the default value of 50. The highest priority is 0 and the lowest is 100.
+ """
+
+
+class CreditGrantCreateParamsAmount(TypedDict):
+ monetary: NotRequired["CreditGrantCreateParamsAmountMonetary"]
+ """
+ The monetary amount.
+ """
+ type: Literal["monetary"]
+ """
+ The type of this amount. We currently only support `monetary` billing credits.
+ """
+
+
+class CreditGrantCreateParamsAmountMonetary(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `value` parameter.
+ """
+ value: int
+ """
+ A positive integer representing the amount of the credit grant.
+ """
+
+
+class CreditGrantCreateParamsApplicabilityConfig(TypedDict):
+ scope: "CreditGrantCreateParamsApplicabilityConfigScope"
+ """
+ Specify the scope of this applicability config.
+ """
+
+
+class CreditGrantCreateParamsApplicabilityConfigScope(TypedDict):
+ price_type: NotRequired[Literal["metered"]]
+ """
+ The price type that credit grants can apply to. We currently only support the `metered` price type. Cannot be used in combination with `prices`.
+ """
+ prices: NotRequired[
+ List["CreditGrantCreateParamsApplicabilityConfigScopePrice"]
+ ]
+ """
+ A list of prices that the credit grant can apply to. We currently only support the `metered` prices. Cannot be used in combination with `price_type`.
+ """
+
+
+class CreditGrantCreateParamsApplicabilityConfigScopePrice(TypedDict):
+ id: str
+ """
+ The price ID this credit grant should apply to.
+ """
diff --git a/stripe/params/billing/_credit_grant_expire_params.py b/stripe/params/billing/_credit_grant_expire_params.py
new file mode 100644
index 000000000..a2e4fa63f
--- /dev/null
+++ b/stripe/params/billing/_credit_grant_expire_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CreditGrantExpireParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/billing/_credit_grant_list_params.py b/stripe/params/billing/_credit_grant_list_params.py
new file mode 100644
index 000000000..bf8ab6d0c
--- /dev/null
+++ b/stripe/params/billing/_credit_grant_list_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CreditGrantListParams(RequestOptions):
+ customer: NotRequired[str]
+ """
+ Only return credit grants for this customer.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/billing/_credit_grant_modify_params.py b/stripe/params/billing/_credit_grant_modify_params.py
new file mode 100644
index 000000000..4c02e3542
--- /dev/null
+++ b/stripe/params/billing/_credit_grant_modify_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class CreditGrantModifyParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired["Literal['']|int"]
+ """
+ The time when the billing credits created by this credit grant expire. If set to empty, the billing credits never expire.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of key-value pairs you can attach to an object. You can use this to store additional information about the object (for example, cost basis) in a structured format.
+ """
diff --git a/stripe/params/billing/_credit_grant_retrieve_params.py b/stripe/params/billing/_credit_grant_retrieve_params.py
new file mode 100644
index 000000000..5c0418e65
--- /dev/null
+++ b/stripe/params/billing/_credit_grant_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CreditGrantRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/billing/_credit_grant_update_params.py b/stripe/params/billing/_credit_grant_update_params.py
new file mode 100644
index 000000000..fc5c4e401
--- /dev/null
+++ b/stripe/params/billing/_credit_grant_update_params.py
@@ -0,0 +1,19 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CreditGrantUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired["Literal['']|int"]
+ """
+ The time when the billing credits created by this credit grant expire. If set to empty, the billing credits never expire.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of key-value pairs you can attach to an object. You can use this to store additional information about the object (for example, cost basis) in a structured format.
+ """
diff --git a/stripe/params/billing/_credit_grant_void_grant_params.py b/stripe/params/billing/_credit_grant_void_grant_params.py
new file mode 100644
index 000000000..9a411106c
--- /dev/null
+++ b/stripe/params/billing/_credit_grant_void_grant_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CreditGrantVoidGrantParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/billing/_meter_create_params.py b/stripe/params/billing/_meter_create_params.py
new file mode 100644
index 000000000..d1b7aeb47
--- /dev/null
+++ b/stripe/params/billing/_meter_create_params.py
@@ -0,0 +1,61 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class MeterCreateParams(RequestOptions):
+ customer_mapping: NotRequired["MeterCreateParamsCustomerMapping"]
+ """
+ Fields that specify how to map a meter event to a customer.
+ """
+ default_aggregation: "MeterCreateParamsDefaultAggregation"
+ """
+ The default settings to aggregate a meter's events with.
+ """
+ display_name: str
+ """
+ The meter's name. Not visible to the customer.
+ """
+ event_name: str
+ """
+ The name of the meter event to record usage for. Corresponds with the `event_name` field on meter events.
+ """
+ event_time_window: NotRequired[Literal["day", "hour"]]
+ """
+ The time window which meter events have been pre-aggregated for, if any.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ value_settings: NotRequired["MeterCreateParamsValueSettings"]
+ """
+ Fields that specify how to calculate a meter event's value.
+ """
+
+
+class MeterCreateParamsCustomerMapping(TypedDict):
+ event_payload_key: str
+ """
+ The key in the meter event payload to use for mapping the event to a customer.
+ """
+ type: Literal["by_id"]
+ """
+ The method for mapping a meter event to a customer. Must be `by_id`.
+ """
+
+
+class MeterCreateParamsDefaultAggregation(TypedDict):
+ formula: Literal["count", "last", "sum"]
+ """
+ Specifies how events are aggregated. Allowed values are `count` to count the number of events, `sum` to sum each event's value and `last` to take the last event's value in the window.
+ """
+
+
+class MeterCreateParamsValueSettings(TypedDict):
+ event_payload_key: str
+ """
+ The key in the usage event payload to use as the value for this meter. For example, if the event payload contains usage on a `bytes_used` field, then set the event_payload_key to "bytes_used".
+ """
diff --git a/stripe/params/billing/_meter_deactivate_params.py b/stripe/params/billing/_meter_deactivate_params.py
new file mode 100644
index 000000000..9ad26f4bb
--- /dev/null
+++ b/stripe/params/billing/_meter_deactivate_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class MeterDeactivateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/billing/_meter_event_adjustment_create_params.py b/stripe/params/billing/_meter_event_adjustment_create_params.py
new file mode 100644
index 000000000..fd7595b11
--- /dev/null
+++ b/stripe/params/billing/_meter_event_adjustment_create_params.py
@@ -0,0 +1,31 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class MeterEventAdjustmentCreateParams(RequestOptions):
+ cancel: NotRequired["MeterEventAdjustmentCreateParamsCancel"]
+ """
+ Specifies which event to cancel.
+ """
+ event_name: str
+ """
+ The name of the meter event. Corresponds with the `event_name` field on a meter.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ type: Literal["cancel"]
+ """
+ Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet.
+ """
+
+
+class MeterEventAdjustmentCreateParamsCancel(TypedDict):
+ identifier: NotRequired[str]
+ """
+ Unique identifier for the event. You can only cancel events within 24 hours of Stripe receiving them.
+ """
diff --git a/stripe/params/billing/_meter_event_create_params.py b/stripe/params/billing/_meter_event_create_params.py
new file mode 100644
index 000000000..6a65963e3
--- /dev/null
+++ b/stripe/params/billing/_meter_event_create_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import NotRequired
+
+
+class MeterEventCreateParams(RequestOptions):
+ event_name: str
+ """
+ The name of the meter event. Corresponds with the `event_name` field on a meter.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ identifier: NotRequired[str]
+ """
+ A unique identifier for the event. If not provided, one is generated. We recommend using UUID-like identifiers. We will enforce uniqueness within a rolling period of at least 24 hours. The enforcement of uniqueness primarily addresses issues arising from accidental retries or other problems occurring within extremely brief time intervals. This approach helps prevent duplicate entries and ensures data integrity in high-frequency operations.
+ """
+ payload: Dict[str, str]
+ """
+ The payload of the event. This must contain the fields corresponding to a meter's `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and `value_settings.event_payload_key` (default is `value`). Read more about the [payload](https://docs.stripe.com/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).
+ """
+ timestamp: NotRequired[int]
+ """
+ The time of the event. Measured in seconds since the Unix epoch. Must be within the past 35 calendar days or up to 5 minutes in the future. Defaults to current timestamp if not specified.
+ """
diff --git a/stripe/params/billing/_meter_event_summary_list_params.py b/stripe/params/billing/_meter_event_summary_list_params.py
new file mode 100644
index 000000000..3c5d49a64
--- /dev/null
+++ b/stripe/params/billing/_meter_event_summary_list_params.py
@@ -0,0 +1,39 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class MeterEventSummaryListParams(TypedDict):
+ customer: str
+ """
+ The customer for which to fetch event summaries.
+ """
+ end_time: int
+ """
+ The timestamp from when to stop aggregating meter events (exclusive). Must be aligned with minute boundaries.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ start_time: int
+ """
+ The timestamp from when to start aggregating meter events (inclusive). Must be aligned with minute boundaries.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ value_grouping_window: NotRequired[Literal["day", "hour"]]
+ """
+ Specifies what granularity to use when generating event summaries. If not specified, a single event summary would be returned for the specified time range. For hourly granularity, start and end times must align with hour boundaries (e.g., 00:00, 01:00, ..., 23:00). For daily granularity, start and end times must align with UTC day boundaries (00:00 UTC).
+ """
diff --git a/stripe/params/billing/_meter_list_event_summaries_params.py b/stripe/params/billing/_meter_list_event_summaries_params.py
new file mode 100644
index 000000000..ac858160e
--- /dev/null
+++ b/stripe/params/billing/_meter_list_event_summaries_params.py
@@ -0,0 +1,40 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class MeterListEventSummariesParams(RequestOptions):
+ customer: str
+ """
+ The customer for which to fetch event summaries.
+ """
+ end_time: int
+ """
+ The timestamp from when to stop aggregating meter events (exclusive). Must be aligned with minute boundaries.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ start_time: int
+ """
+ The timestamp from when to start aggregating meter events (inclusive). Must be aligned with minute boundaries.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ value_grouping_window: NotRequired[Literal["day", "hour"]]
+ """
+ Specifies what granularity to use when generating event summaries. If not specified, a single event summary would be returned for the specified time range. For hourly granularity, start and end times must align with hour boundaries (e.g., 00:00, 01:00, ..., 23:00). For daily granularity, start and end times must align with UTC day boundaries (00:00 UTC).
+ """
diff --git a/stripe/params/billing/_meter_list_params.py b/stripe/params/billing/_meter_list_params.py
new file mode 100644
index 000000000..4de12600d
--- /dev/null
+++ b/stripe/params/billing/_meter_list_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class MeterListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["active", "inactive"]]
+ """
+ Filter results to only include meters with the given status.
+ """
diff --git a/stripe/params/billing/_meter_modify_params.py b/stripe/params/billing/_meter_modify_params.py
new file mode 100644
index 000000000..1a6251ba6
--- /dev/null
+++ b/stripe/params/billing/_meter_modify_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class MeterModifyParams(RequestOptions):
+ display_name: NotRequired[str]
+ """
+ The meter's name. Not visible to the customer.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/billing/_meter_reactivate_params.py b/stripe/params/billing/_meter_reactivate_params.py
new file mode 100644
index 000000000..fba5db176
--- /dev/null
+++ b/stripe/params/billing/_meter_reactivate_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class MeterReactivateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/billing/_meter_retrieve_params.py b/stripe/params/billing/_meter_retrieve_params.py
new file mode 100644
index 000000000..0c1bb88e1
--- /dev/null
+++ b/stripe/params/billing/_meter_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class MeterRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/billing/_meter_update_params.py b/stripe/params/billing/_meter_update_params.py
new file mode 100644
index 000000000..8d8c0069d
--- /dev/null
+++ b/stripe/params/billing/_meter_update_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class MeterUpdateParams(TypedDict):
+ display_name: NotRequired[str]
+ """
+ The meter's name. Not visible to the customer.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/billing_portal/__init__.py b/stripe/params/billing_portal/__init__.py
new file mode 100644
index 000000000..5fc34d130
--- /dev/null
+++ b/stripe/params/billing_portal/__init__.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.billing_portal._configuration_create_params import (
+ ConfigurationCreateParams as ConfigurationCreateParams,
+)
+from stripe.params.billing_portal._configuration_list_params import (
+ ConfigurationListParams as ConfigurationListParams,
+)
+from stripe.params.billing_portal._configuration_modify_params import (
+ ConfigurationModifyParams as ConfigurationModifyParams,
+)
+from stripe.params.billing_portal._configuration_retrieve_params import (
+ ConfigurationRetrieveParams as ConfigurationRetrieveParams,
+)
+from stripe.params.billing_portal._configuration_update_params import (
+ ConfigurationUpdateParams as ConfigurationUpdateParams,
+)
+from stripe.params.billing_portal._session_create_params import (
+ SessionCreateParams as SessionCreateParams,
+)
diff --git a/stripe/params/billing_portal/_configuration_create_params.py b/stripe/params/billing_portal/_configuration_create_params.py
new file mode 100644
index 000000000..54501c2df
--- /dev/null
+++ b/stripe/params/billing_portal/_configuration_create_params.py
@@ -0,0 +1,259 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List, Union
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ConfigurationCreateParams(RequestOptions):
+ business_profile: NotRequired["ConfigurationCreateParamsBusinessProfile"]
+ """
+ The business information shown to customers in the portal.
+ """
+ default_return_url: NotRequired["Literal['']|str"]
+ """
+ The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ features: "ConfigurationCreateParamsFeatures"
+ """
+ Information about the features available in the portal.
+ """
+ login_page: NotRequired["ConfigurationCreateParamsLoginPage"]
+ """
+ The hosted login page for this configuration. Learn more about the portal login page in our [integration docs](https://stripe.com/docs/billing/subscriptions/integrating-customer-portal#share).
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ The name of the configuration.
+ """
+
+
+class ConfigurationCreateParamsBusinessProfile(TypedDict):
+ headline: NotRequired["Literal['']|str"]
+ """
+ The messaging shown to customers in the portal.
+ """
+ privacy_policy_url: NotRequired[str]
+ """
+ A link to the business's publicly available privacy policy.
+ """
+ terms_of_service_url: NotRequired[str]
+ """
+ A link to the business's publicly available terms of service.
+ """
+
+
+class ConfigurationCreateParamsFeatures(TypedDict):
+ customer_update: NotRequired[
+ "ConfigurationCreateParamsFeaturesCustomerUpdate"
+ ]
+ """
+ Information about updating the customer details in the portal.
+ """
+ invoice_history: NotRequired[
+ "ConfigurationCreateParamsFeaturesInvoiceHistory"
+ ]
+ """
+ Information about showing the billing history in the portal.
+ """
+ payment_method_update: NotRequired[
+ "ConfigurationCreateParamsFeaturesPaymentMethodUpdate"
+ ]
+ """
+ Information about updating payment methods in the portal.
+ """
+ subscription_cancel: NotRequired[
+ "ConfigurationCreateParamsFeaturesSubscriptionCancel"
+ ]
+ """
+ Information about canceling subscriptions in the portal.
+ """
+ subscription_update: NotRequired[
+ "ConfigurationCreateParamsFeaturesSubscriptionUpdate"
+ ]
+ """
+ Information about updating subscriptions in the portal.
+ """
+
+
+class ConfigurationCreateParamsFeaturesCustomerUpdate(TypedDict):
+ allowed_updates: NotRequired[
+ "Literal['']|List[Literal['address', 'email', 'name', 'phone', 'shipping', 'tax_id']]"
+ ]
+ """
+ The types of customer updates that are supported. When empty, customers are not updateable.
+ """
+ enabled: bool
+ """
+ Whether the feature is enabled.
+ """
+
+
+class ConfigurationCreateParamsFeaturesInvoiceHistory(TypedDict):
+ enabled: bool
+ """
+ Whether the feature is enabled.
+ """
+
+
+class ConfigurationCreateParamsFeaturesPaymentMethodUpdate(TypedDict):
+ enabled: bool
+ """
+ Whether the feature is enabled.
+ """
+
+
+class ConfigurationCreateParamsFeaturesSubscriptionCancel(TypedDict):
+ cancellation_reason: NotRequired[
+ "ConfigurationCreateParamsFeaturesSubscriptionCancelCancellationReason"
+ ]
+ """
+ Whether the cancellation reasons will be collected in the portal and which options are exposed to the customer
+ """
+ enabled: bool
+ """
+ Whether the feature is enabled.
+ """
+ mode: NotRequired[Literal["at_period_end", "immediately"]]
+ """
+ Whether to cancel subscriptions immediately or at the end of the billing period.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Whether to create prorations when canceling subscriptions. Possible values are `none` and `create_prorations`, which is only compatible with `mode=immediately`. Passing `always_invoice` will result in an error. No prorations are generated when canceling a subscription at the end of its natural billing period.
+ """
+
+
+class ConfigurationCreateParamsFeaturesSubscriptionCancelCancellationReason(
+ TypedDict,
+):
+ enabled: bool
+ """
+ Whether the feature is enabled.
+ """
+ options: Union[
+ Literal[""],
+ List[
+ Literal[
+ "customer_service",
+ "low_quality",
+ "missing_features",
+ "other",
+ "switched_service",
+ "too_complex",
+ "too_expensive",
+ "unused",
+ ]
+ ],
+ ]
+ """
+ Which cancellation reasons will be given as options to the customer.
+ """
+
+
+class ConfigurationCreateParamsFeaturesSubscriptionUpdate(TypedDict):
+ default_allowed_updates: NotRequired[
+ "Literal['']|List[Literal['price', 'promotion_code', 'quantity']]"
+ ]
+ """
+ The types of subscription updates that are supported. When empty, subscriptions are not updateable.
+ """
+ enabled: bool
+ """
+ Whether the feature is enabled.
+ """
+ products: NotRequired[
+ "Literal['']|List[ConfigurationCreateParamsFeaturesSubscriptionUpdateProduct]"
+ ]
+ """
+ The list of up to 10 products that support subscription updates.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Determines how to handle prorations resulting from subscription updates. Valid values are `none`, `create_prorations`, and `always_invoice`.
+ """
+ schedule_at_period_end: NotRequired[
+ "ConfigurationCreateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEnd"
+ ]
+ """
+ Setting to control when an update should be scheduled at the end of the period instead of applying immediately.
+ """
+ trial_update_behavior: NotRequired[Literal["continue_trial", "end_trial"]]
+ """
+ The behavior when updating a subscription that is trialing.
+ """
+
+
+class ConfigurationCreateParamsFeaturesSubscriptionUpdateProduct(TypedDict):
+ adjustable_quantity: NotRequired[
+ "ConfigurationCreateParamsFeaturesSubscriptionUpdateProductAdjustableQuantity"
+ ]
+ """
+ Control whether the quantity of the product can be adjusted.
+ """
+ prices: List[str]
+ """
+ The list of price IDs for the product that a subscription can be updated to.
+ """
+ product: str
+ """
+ The product id.
+ """
+
+
+class ConfigurationCreateParamsFeaturesSubscriptionUpdateProductAdjustableQuantity(
+ TypedDict,
+):
+ enabled: bool
+ """
+ Set to true if the quantity can be adjusted to any non-negative integer.
+ """
+ maximum: NotRequired[int]
+ """
+ The maximum quantity that can be set for the product.
+ """
+ minimum: NotRequired[int]
+ """
+ The minimum quantity that can be set for the product.
+ """
+
+
+class ConfigurationCreateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEnd(
+ TypedDict,
+):
+ conditions: NotRequired[
+ List[
+ "ConfigurationCreateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEndCondition"
+ ]
+ ]
+ """
+ List of conditions. When any condition is true, the update will be scheduled at the end of the current period.
+ """
+
+
+class ConfigurationCreateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEndCondition(
+ TypedDict,
+):
+ type: Literal["decreasing_item_amount", "shortening_interval"]
+ """
+ The type of condition.
+ """
+
+
+class ConfigurationCreateParamsLoginPage(TypedDict):
+ enabled: bool
+ """
+ Set to `true` to generate a shareable URL [`login_page.url`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-login_page-url) that will take your customers to a hosted login page for the customer portal.
+ """
diff --git a/stripe/params/billing_portal/_configuration_list_params.py b/stripe/params/billing_portal/_configuration_list_params.py
new file mode 100644
index 000000000..e1566f7c5
--- /dev/null
+++ b/stripe/params/billing_portal/_configuration_list_params.py
@@ -0,0 +1,32 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ConfigurationListParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Only return configurations that are active or inactive (e.g., pass `true` to only list active configurations).
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ is_default: NotRequired[bool]
+ """
+ Only return the default or non-default configurations (e.g., pass `true` to only list the default configuration).
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/billing_portal/_configuration_modify_params.py b/stripe/params/billing_portal/_configuration_modify_params.py
new file mode 100644
index 000000000..8b48f3425
--- /dev/null
+++ b/stripe/params/billing_portal/_configuration_modify_params.py
@@ -0,0 +1,251 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ConfigurationModifyParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Whether the configuration is active and can be used to create portal sessions.
+ """
+ business_profile: NotRequired["ConfigurationModifyParamsBusinessProfile"]
+ """
+ The business information shown to customers in the portal.
+ """
+ default_return_url: NotRequired["Literal['']|str"]
+ """
+ The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ features: NotRequired["ConfigurationModifyParamsFeatures"]
+ """
+ Information about the features available in the portal.
+ """
+ login_page: NotRequired["ConfigurationModifyParamsLoginPage"]
+ """
+ The hosted login page for this configuration. Learn more about the portal login page in our [integration docs](https://stripe.com/docs/billing/subscriptions/integrating-customer-portal#share).
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ The name of the configuration.
+ """
+
+
+class ConfigurationModifyParamsBusinessProfile(TypedDict):
+ headline: NotRequired["Literal['']|str"]
+ """
+ The messaging shown to customers in the portal.
+ """
+ privacy_policy_url: NotRequired["Literal['']|str"]
+ """
+ A link to the business's publicly available privacy policy.
+ """
+ terms_of_service_url: NotRequired["Literal['']|str"]
+ """
+ A link to the business's publicly available terms of service.
+ """
+
+
+class ConfigurationModifyParamsFeatures(TypedDict):
+ customer_update: NotRequired[
+ "ConfigurationModifyParamsFeaturesCustomerUpdate"
+ ]
+ """
+ Information about updating the customer details in the portal.
+ """
+ invoice_history: NotRequired[
+ "ConfigurationModifyParamsFeaturesInvoiceHistory"
+ ]
+ """
+ Information about showing the billing history in the portal.
+ """
+ payment_method_update: NotRequired[
+ "ConfigurationModifyParamsFeaturesPaymentMethodUpdate"
+ ]
+ """
+ Information about updating payment methods in the portal.
+ """
+ subscription_cancel: NotRequired[
+ "ConfigurationModifyParamsFeaturesSubscriptionCancel"
+ ]
+ """
+ Information about canceling subscriptions in the portal.
+ """
+ subscription_update: NotRequired[
+ "ConfigurationModifyParamsFeaturesSubscriptionUpdate"
+ ]
+ """
+ Information about updating subscriptions in the portal.
+ """
+
+
+class ConfigurationModifyParamsFeaturesCustomerUpdate(TypedDict):
+ allowed_updates: NotRequired[
+ "Literal['']|List[Literal['address', 'email', 'name', 'phone', 'shipping', 'tax_id']]"
+ ]
+ """
+ The types of customer updates that are supported. When empty, customers are not updateable.
+ """
+ enabled: NotRequired[bool]
+ """
+ Whether the feature is enabled.
+ """
+
+
+class ConfigurationModifyParamsFeaturesInvoiceHistory(TypedDict):
+ enabled: bool
+ """
+ Whether the feature is enabled.
+ """
+
+
+class ConfigurationModifyParamsFeaturesPaymentMethodUpdate(TypedDict):
+ enabled: bool
+ """
+ Whether the feature is enabled.
+ """
+
+
+class ConfigurationModifyParamsFeaturesSubscriptionCancel(TypedDict):
+ cancellation_reason: NotRequired[
+ "ConfigurationModifyParamsFeaturesSubscriptionCancelCancellationReason"
+ ]
+ """
+ Whether the cancellation reasons will be collected in the portal and which options are exposed to the customer
+ """
+ enabled: NotRequired[bool]
+ """
+ Whether the feature is enabled.
+ """
+ mode: NotRequired[Literal["at_period_end", "immediately"]]
+ """
+ Whether to cancel subscriptions immediately or at the end of the billing period.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Whether to create prorations when canceling subscriptions. Possible values are `none` and `create_prorations`, which is only compatible with `mode=immediately`. Passing `always_invoice` will result in an error. No prorations are generated when canceling a subscription at the end of its natural billing period.
+ """
+
+
+class ConfigurationModifyParamsFeaturesSubscriptionCancelCancellationReason(
+ TypedDict,
+):
+ enabled: bool
+ """
+ Whether the feature is enabled.
+ """
+ options: NotRequired[
+ "Literal['']|List[Literal['customer_service', 'low_quality', 'missing_features', 'other', 'switched_service', 'too_complex', 'too_expensive', 'unused']]"
+ ]
+ """
+ Which cancellation reasons will be given as options to the customer.
+ """
+
+
+class ConfigurationModifyParamsFeaturesSubscriptionUpdate(TypedDict):
+ default_allowed_updates: NotRequired[
+ "Literal['']|List[Literal['price', 'promotion_code', 'quantity']]"
+ ]
+ """
+ The types of subscription updates that are supported. When empty, subscriptions are not updateable.
+ """
+ enabled: NotRequired[bool]
+ """
+ Whether the feature is enabled.
+ """
+ products: NotRequired[
+ "Literal['']|List[ConfigurationModifyParamsFeaturesSubscriptionUpdateProduct]"
+ ]
+ """
+ The list of up to 10 products that support subscription updates.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Determines how to handle prorations resulting from subscription updates. Valid values are `none`, `create_prorations`, and `always_invoice`.
+ """
+ schedule_at_period_end: NotRequired[
+ "ConfigurationModifyParamsFeaturesSubscriptionUpdateScheduleAtPeriodEnd"
+ ]
+ """
+ Setting to control when an update should be scheduled at the end of the period instead of applying immediately.
+ """
+ trial_update_behavior: NotRequired[Literal["continue_trial", "end_trial"]]
+ """
+ The behavior when updating a subscription that is trialing.
+ """
+
+
+class ConfigurationModifyParamsFeaturesSubscriptionUpdateProduct(TypedDict):
+ adjustable_quantity: NotRequired[
+ "ConfigurationModifyParamsFeaturesSubscriptionUpdateProductAdjustableQuantity"
+ ]
+ """
+ Control whether the quantity of the product can be adjusted.
+ """
+ prices: List[str]
+ """
+ The list of price IDs for the product that a subscription can be updated to.
+ """
+ product: str
+ """
+ The product id.
+ """
+
+
+class ConfigurationModifyParamsFeaturesSubscriptionUpdateProductAdjustableQuantity(
+ TypedDict,
+):
+ enabled: bool
+ """
+ Set to true if the quantity can be adjusted to any non-negative integer.
+ """
+ maximum: NotRequired[int]
+ """
+ The maximum quantity that can be set for the product.
+ """
+ minimum: NotRequired[int]
+ """
+ The minimum quantity that can be set for the product.
+ """
+
+
+class ConfigurationModifyParamsFeaturesSubscriptionUpdateScheduleAtPeriodEnd(
+ TypedDict,
+):
+ conditions: NotRequired[
+ "Literal['']|List[ConfigurationModifyParamsFeaturesSubscriptionUpdateScheduleAtPeriodEndCondition]"
+ ]
+ """
+ List of conditions. When any condition is true, the update will be scheduled at the end of the current period.
+ """
+
+
+class ConfigurationModifyParamsFeaturesSubscriptionUpdateScheduleAtPeriodEndCondition(
+ TypedDict,
+):
+ type: Literal["decreasing_item_amount", "shortening_interval"]
+ """
+ The type of condition.
+ """
+
+
+class ConfigurationModifyParamsLoginPage(TypedDict):
+ enabled: bool
+ """
+ Set to `true` to generate a shareable URL [`login_page.url`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-login_page-url) that will take your customers to a hosted login page for the customer portal.
+
+ Set to `false` to deactivate the `login_page.url`.
+ """
diff --git a/stripe/params/billing_portal/_configuration_retrieve_params.py b/stripe/params/billing_portal/_configuration_retrieve_params.py
new file mode 100644
index 000000000..95f024ac8
--- /dev/null
+++ b/stripe/params/billing_portal/_configuration_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ConfigurationRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/billing_portal/_configuration_update_params.py b/stripe/params/billing_portal/_configuration_update_params.py
new file mode 100644
index 000000000..f8ab8ae22
--- /dev/null
+++ b/stripe/params/billing_portal/_configuration_update_params.py
@@ -0,0 +1,250 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ConfigurationUpdateParams(TypedDict):
+ active: NotRequired[bool]
+ """
+ Whether the configuration is active and can be used to create portal sessions.
+ """
+ business_profile: NotRequired["ConfigurationUpdateParamsBusinessProfile"]
+ """
+ The business information shown to customers in the portal.
+ """
+ default_return_url: NotRequired["Literal['']|str"]
+ """
+ The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ features: NotRequired["ConfigurationUpdateParamsFeatures"]
+ """
+ Information about the features available in the portal.
+ """
+ login_page: NotRequired["ConfigurationUpdateParamsLoginPage"]
+ """
+ The hosted login page for this configuration. Learn more about the portal login page in our [integration docs](https://stripe.com/docs/billing/subscriptions/integrating-customer-portal#share).
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ The name of the configuration.
+ """
+
+
+class ConfigurationUpdateParamsBusinessProfile(TypedDict):
+ headline: NotRequired["Literal['']|str"]
+ """
+ The messaging shown to customers in the portal.
+ """
+ privacy_policy_url: NotRequired["Literal['']|str"]
+ """
+ A link to the business's publicly available privacy policy.
+ """
+ terms_of_service_url: NotRequired["Literal['']|str"]
+ """
+ A link to the business's publicly available terms of service.
+ """
+
+
+class ConfigurationUpdateParamsFeatures(TypedDict):
+ customer_update: NotRequired[
+ "ConfigurationUpdateParamsFeaturesCustomerUpdate"
+ ]
+ """
+ Information about updating the customer details in the portal.
+ """
+ invoice_history: NotRequired[
+ "ConfigurationUpdateParamsFeaturesInvoiceHistory"
+ ]
+ """
+ Information about showing the billing history in the portal.
+ """
+ payment_method_update: NotRequired[
+ "ConfigurationUpdateParamsFeaturesPaymentMethodUpdate"
+ ]
+ """
+ Information about updating payment methods in the portal.
+ """
+ subscription_cancel: NotRequired[
+ "ConfigurationUpdateParamsFeaturesSubscriptionCancel"
+ ]
+ """
+ Information about canceling subscriptions in the portal.
+ """
+ subscription_update: NotRequired[
+ "ConfigurationUpdateParamsFeaturesSubscriptionUpdate"
+ ]
+ """
+ Information about updating subscriptions in the portal.
+ """
+
+
+class ConfigurationUpdateParamsFeaturesCustomerUpdate(TypedDict):
+ allowed_updates: NotRequired[
+ "Literal['']|List[Literal['address', 'email', 'name', 'phone', 'shipping', 'tax_id']]"
+ ]
+ """
+ The types of customer updates that are supported. When empty, customers are not updateable.
+ """
+ enabled: NotRequired[bool]
+ """
+ Whether the feature is enabled.
+ """
+
+
+class ConfigurationUpdateParamsFeaturesInvoiceHistory(TypedDict):
+ enabled: bool
+ """
+ Whether the feature is enabled.
+ """
+
+
+class ConfigurationUpdateParamsFeaturesPaymentMethodUpdate(TypedDict):
+ enabled: bool
+ """
+ Whether the feature is enabled.
+ """
+
+
+class ConfigurationUpdateParamsFeaturesSubscriptionCancel(TypedDict):
+ cancellation_reason: NotRequired[
+ "ConfigurationUpdateParamsFeaturesSubscriptionCancelCancellationReason"
+ ]
+ """
+ Whether the cancellation reasons will be collected in the portal and which options are exposed to the customer
+ """
+ enabled: NotRequired[bool]
+ """
+ Whether the feature is enabled.
+ """
+ mode: NotRequired[Literal["at_period_end", "immediately"]]
+ """
+ Whether to cancel subscriptions immediately or at the end of the billing period.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Whether to create prorations when canceling subscriptions. Possible values are `none` and `create_prorations`, which is only compatible with `mode=immediately`. Passing `always_invoice` will result in an error. No prorations are generated when canceling a subscription at the end of its natural billing period.
+ """
+
+
+class ConfigurationUpdateParamsFeaturesSubscriptionCancelCancellationReason(
+ TypedDict,
+):
+ enabled: bool
+ """
+ Whether the feature is enabled.
+ """
+ options: NotRequired[
+ "Literal['']|List[Literal['customer_service', 'low_quality', 'missing_features', 'other', 'switched_service', 'too_complex', 'too_expensive', 'unused']]"
+ ]
+ """
+ Which cancellation reasons will be given as options to the customer.
+ """
+
+
+class ConfigurationUpdateParamsFeaturesSubscriptionUpdate(TypedDict):
+ default_allowed_updates: NotRequired[
+ "Literal['']|List[Literal['price', 'promotion_code', 'quantity']]"
+ ]
+ """
+ The types of subscription updates that are supported. When empty, subscriptions are not updateable.
+ """
+ enabled: NotRequired[bool]
+ """
+ Whether the feature is enabled.
+ """
+ products: NotRequired[
+ "Literal['']|List[ConfigurationUpdateParamsFeaturesSubscriptionUpdateProduct]"
+ ]
+ """
+ The list of up to 10 products that support subscription updates.
+ """
+ proration_behavior: NotRequired[
+ Literal["always_invoice", "create_prorations", "none"]
+ ]
+ """
+ Determines how to handle prorations resulting from subscription updates. Valid values are `none`, `create_prorations`, and `always_invoice`.
+ """
+ schedule_at_period_end: NotRequired[
+ "ConfigurationUpdateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEnd"
+ ]
+ """
+ Setting to control when an update should be scheduled at the end of the period instead of applying immediately.
+ """
+ trial_update_behavior: NotRequired[Literal["continue_trial", "end_trial"]]
+ """
+ The behavior when updating a subscription that is trialing.
+ """
+
+
+class ConfigurationUpdateParamsFeaturesSubscriptionUpdateProduct(TypedDict):
+ adjustable_quantity: NotRequired[
+ "ConfigurationUpdateParamsFeaturesSubscriptionUpdateProductAdjustableQuantity"
+ ]
+ """
+ Control whether the quantity of the product can be adjusted.
+ """
+ prices: List[str]
+ """
+ The list of price IDs for the product that a subscription can be updated to.
+ """
+ product: str
+ """
+ The product id.
+ """
+
+
+class ConfigurationUpdateParamsFeaturesSubscriptionUpdateProductAdjustableQuantity(
+ TypedDict,
+):
+ enabled: bool
+ """
+ Set to true if the quantity can be adjusted to any non-negative integer.
+ """
+ maximum: NotRequired[int]
+ """
+ The maximum quantity that can be set for the product.
+ """
+ minimum: NotRequired[int]
+ """
+ The minimum quantity that can be set for the product.
+ """
+
+
+class ConfigurationUpdateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEnd(
+ TypedDict,
+):
+ conditions: NotRequired[
+ "Literal['']|List[ConfigurationUpdateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEndCondition]"
+ ]
+ """
+ List of conditions. When any condition is true, the update will be scheduled at the end of the current period.
+ """
+
+
+class ConfigurationUpdateParamsFeaturesSubscriptionUpdateScheduleAtPeriodEndCondition(
+ TypedDict,
+):
+ type: Literal["decreasing_item_amount", "shortening_interval"]
+ """
+ The type of condition.
+ """
+
+
+class ConfigurationUpdateParamsLoginPage(TypedDict):
+ enabled: bool
+ """
+ Set to `true` to generate a shareable URL [`login_page.url`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-login_page-url) that will take your customers to a hosted login page for the customer portal.
+
+ Set to `false` to deactivate the `login_page.url`.
+ """
diff --git a/stripe/params/billing_portal/_session_create_params.py b/stripe/params/billing_portal/_session_create_params.py
new file mode 100644
index 000000000..f16942ae6
--- /dev/null
+++ b/stripe/params/billing_portal/_session_create_params.py
@@ -0,0 +1,236 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SessionCreateParams(RequestOptions):
+ configuration: NotRequired[str]
+ """
+ The ID of an existing [configuration](https://stripe.com/docs/api/customer_portal/configuration) to use for this session, describing its functionality and features. If not specified, the session uses the default configuration.
+ """
+ customer: str
+ """
+ The ID of an existing customer.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ flow_data: NotRequired["SessionCreateParamsFlowData"]
+ """
+ Information about a specific flow for the customer to go through. See the [docs](https://stripe.com/docs/customer-management/portal-deep-links) to learn more about using customer portal deep links and flows.
+ """
+ locale: NotRequired[
+ Literal[
+ "auto",
+ "bg",
+ "cs",
+ "da",
+ "de",
+ "el",
+ "en",
+ "en-AU",
+ "en-CA",
+ "en-GB",
+ "en-IE",
+ "en-IN",
+ "en-NZ",
+ "en-SG",
+ "es",
+ "es-419",
+ "et",
+ "fi",
+ "fil",
+ "fr",
+ "fr-CA",
+ "hr",
+ "hu",
+ "id",
+ "it",
+ "ja",
+ "ko",
+ "lt",
+ "lv",
+ "ms",
+ "mt",
+ "nb",
+ "nl",
+ "pl",
+ "pt",
+ "pt-BR",
+ "ro",
+ "ru",
+ "sk",
+ "sl",
+ "sv",
+ "th",
+ "tr",
+ "vi",
+ "zh",
+ "zh-HK",
+ "zh-TW",
+ ]
+ ]
+ """
+ The IETF language tag of the locale customer portal is displayed in. If blank or auto, the customer's `preferred_locales` or browser's locale is used.
+ """
+ on_behalf_of: NotRequired[str]
+ """
+ The `on_behalf_of` account to use for this session. When specified, only subscriptions and invoices with this `on_behalf_of` account appear in the portal. For more information, see the [docs](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant). Use the [Accounts API](https://stripe.com/docs/api/accounts/object#account_object-settings-branding) to modify the `on_behalf_of` account's branding settings, which the portal displays.
+ """
+ return_url: NotRequired[str]
+ """
+ The default URL to redirect customers to when they click on the portal's link to return to your website.
+ """
+
+
+class SessionCreateParamsFlowData(TypedDict):
+ after_completion: NotRequired["SessionCreateParamsFlowDataAfterCompletion"]
+ """
+ Behavior after the flow is completed.
+ """
+ subscription_cancel: NotRequired[
+ "SessionCreateParamsFlowDataSubscriptionCancel"
+ ]
+ """
+ Configuration when `flow_data.type=subscription_cancel`.
+ """
+ subscription_update: NotRequired[
+ "SessionCreateParamsFlowDataSubscriptionUpdate"
+ ]
+ """
+ Configuration when `flow_data.type=subscription_update`.
+ """
+ subscription_update_confirm: NotRequired[
+ "SessionCreateParamsFlowDataSubscriptionUpdateConfirm"
+ ]
+ """
+ Configuration when `flow_data.type=subscription_update_confirm`.
+ """
+ type: Literal[
+ "payment_method_update",
+ "subscription_cancel",
+ "subscription_update",
+ "subscription_update_confirm",
+ ]
+ """
+ Type of flow that the customer will go through.
+ """
+
+
+class SessionCreateParamsFlowDataAfterCompletion(TypedDict):
+ hosted_confirmation: NotRequired[
+ "SessionCreateParamsFlowDataAfterCompletionHostedConfirmation"
+ ]
+ """
+ Configuration when `after_completion.type=hosted_confirmation`.
+ """
+ redirect: NotRequired["SessionCreateParamsFlowDataAfterCompletionRedirect"]
+ """
+ Configuration when `after_completion.type=redirect`.
+ """
+ type: Literal["hosted_confirmation", "portal_homepage", "redirect"]
+ """
+ The specified behavior after the flow is completed.
+ """
+
+
+class SessionCreateParamsFlowDataAfterCompletionHostedConfirmation(TypedDict):
+ custom_message: NotRequired[str]
+ """
+ A custom message to display to the customer after the flow is completed.
+ """
+
+
+class SessionCreateParamsFlowDataAfterCompletionRedirect(TypedDict):
+ return_url: str
+ """
+ The URL the customer will be redirected to after the flow is completed.
+ """
+
+
+class SessionCreateParamsFlowDataSubscriptionCancel(TypedDict):
+ retention: NotRequired[
+ "SessionCreateParamsFlowDataSubscriptionCancelRetention"
+ ]
+ """
+ Specify a retention strategy to be used in the cancellation flow.
+ """
+ subscription: str
+ """
+ The ID of the subscription to be canceled.
+ """
+
+
+class SessionCreateParamsFlowDataSubscriptionCancelRetention(TypedDict):
+ coupon_offer: (
+ "SessionCreateParamsFlowDataSubscriptionCancelRetentionCouponOffer"
+ )
+ """
+ Configuration when `retention.type=coupon_offer`.
+ """
+ type: Literal["coupon_offer"]
+ """
+ Type of retention strategy to use with the customer.
+ """
+
+
+class SessionCreateParamsFlowDataSubscriptionCancelRetentionCouponOffer(
+ TypedDict,
+):
+ coupon: str
+ """
+ The ID of the coupon to be offered.
+ """
+
+
+class SessionCreateParamsFlowDataSubscriptionUpdate(TypedDict):
+ subscription: str
+ """
+ The ID of the subscription to be updated.
+ """
+
+
+class SessionCreateParamsFlowDataSubscriptionUpdateConfirm(TypedDict):
+ discounts: NotRequired[
+ List["SessionCreateParamsFlowDataSubscriptionUpdateConfirmDiscount"]
+ ]
+ """
+ The coupon or promotion code to apply to this subscription update.
+ """
+ items: List["SessionCreateParamsFlowDataSubscriptionUpdateConfirmItem"]
+ """
+ The [subscription item](https://stripe.com/docs/api/subscription_items) to be updated through this flow. Currently, only up to one may be specified and subscriptions with multiple items are not updatable.
+ """
+ subscription: str
+ """
+ The ID of the subscription to be updated.
+ """
+
+
+class SessionCreateParamsFlowDataSubscriptionUpdateConfirmDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ The ID of the coupon to apply to this subscription update.
+ """
+ promotion_code: NotRequired[str]
+ """
+ The ID of a promotion code to apply to this subscription update.
+ """
+
+
+class SessionCreateParamsFlowDataSubscriptionUpdateConfirmItem(TypedDict):
+ id: str
+ """
+ The ID of the [subscription item](https://stripe.com/docs/api/subscriptions/object#subscription_object-items-data-id) to be updated.
+ """
+ price: NotRequired[str]
+ """
+ The price the customer should subscribe to through this flow. The price must also be included in the configuration's [`features.subscription_update.products`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-features-subscription_update-products).
+ """
+ quantity: NotRequired[int]
+ """
+ [Quantity](https://stripe.com/docs/subscriptions/quantities) for this item that the customer should subscribe to through this flow.
+ """
diff --git a/stripe/params/checkout/__init__.py b/stripe/params/checkout/__init__.py
new file mode 100644
index 000000000..48634f0ab
--- /dev/null
+++ b/stripe/params/checkout/__init__.py
@@ -0,0 +1,26 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.checkout._session_create_params import (
+ SessionCreateParams as SessionCreateParams,
+)
+from stripe.params.checkout._session_expire_params import (
+ SessionExpireParams as SessionExpireParams,
+)
+from stripe.params.checkout._session_line_item_list_params import (
+ SessionLineItemListParams as SessionLineItemListParams,
+)
+from stripe.params.checkout._session_list_line_items_params import (
+ SessionListLineItemsParams as SessionListLineItemsParams,
+)
+from stripe.params.checkout._session_list_params import (
+ SessionListParams as SessionListParams,
+)
+from stripe.params.checkout._session_modify_params import (
+ SessionModifyParams as SessionModifyParams,
+)
+from stripe.params.checkout._session_retrieve_params import (
+ SessionRetrieveParams as SessionRetrieveParams,
+)
+from stripe.params.checkout._session_update_params import (
+ SessionUpdateParams as SessionUpdateParams,
+)
diff --git a/stripe/params/checkout/_session_create_params.py b/stripe/params/checkout/_session_create_params.py
new file mode 100644
index 000000000..ca3586676
--- /dev/null
+++ b/stripe/params/checkout/_session_create_params.py
@@ -0,0 +1,2871 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SessionCreateParams(RequestOptions):
+ adaptive_pricing: NotRequired["SessionCreateParamsAdaptivePricing"]
+ """
+ Settings for price localization with [Adaptive Pricing](https://docs.stripe.com/payments/checkout/adaptive-pricing).
+ """
+ after_expiration: NotRequired["SessionCreateParamsAfterExpiration"]
+ """
+ Configure actions after a Checkout Session has expired.
+ """
+ allow_promotion_codes: NotRequired[bool]
+ """
+ Enables user redeemable promotion codes.
+ """
+ automatic_tax: NotRequired["SessionCreateParamsAutomaticTax"]
+ """
+ Settings for automatic tax lookup for this session and resulting payments, invoices, and subscriptions.
+ """
+ billing_address_collection: NotRequired[Literal["auto", "required"]]
+ """
+ Specify whether Checkout should collect the customer's billing address. Defaults to `auto`.
+ """
+ branding_settings: NotRequired["SessionCreateParamsBrandingSettings"]
+ """
+ The branding settings for the Checkout Session. This parameter is not allowed if ui_mode is `custom`.
+ """
+ cancel_url: NotRequired[str]
+ """
+ If set, Checkout displays a back button and customers will be directed to this URL if they decide to cancel payment and return to your website. This parameter is not allowed if ui_mode is `embedded` or `custom`.
+ """
+ client_reference_id: NotRequired[str]
+ """
+ A unique string to reference the Checkout Session. This can be a
+ customer ID, a cart ID, or similar, and can be used to reconcile the
+ session with your internal systems.
+ """
+ consent_collection: NotRequired["SessionCreateParamsConsentCollection"]
+ """
+ Configure fields for the Checkout Session to gather active consent from customers.
+ """
+ currency: NotRequired[str]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Required in `setup` mode when `payment_method_types` is not set.
+ """
+ custom_fields: NotRequired[List["SessionCreateParamsCustomField"]]
+ """
+ Collect additional information from your customer using custom fields. Up to 3 fields are supported.
+ """
+ custom_text: NotRequired["SessionCreateParamsCustomText"]
+ """
+ Display additional text for your customers using custom text.
+ """
+ customer: NotRequired[str]
+ """
+ ID of an existing Customer, if one exists. In `payment` mode, the customer's most recently saved card
+ payment method will be used to prefill the email, name, card details, and billing address
+ on the Checkout page. In `subscription` mode, the customer's [default payment method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method)
+ will be used if it's a card, otherwise the most recently saved card will be used. A valid billing address, billing name and billing email are required on the payment method for Checkout to prefill the customer's card details.
+
+ If the Customer already has a valid [email](https://stripe.com/docs/api/customers/object#customer_object-email) set, the email will be prefilled and not editable in Checkout.
+ If the Customer does not have a valid `email`, Checkout will set the email entered during the session on the Customer.
+
+ If blank for Checkout Sessions in `subscription` mode or with `customer_creation` set as `always` in `payment` mode, Checkout will create a new Customer object based on information provided during the payment flow.
+
+ You can set [`payment_intent_data.setup_future_usage`](https://stripe.com/docs/api/checkout/sessions/create#create_checkout_session-payment_intent_data-setup_future_usage) to have Checkout automatically attach the payment method to the Customer you pass in for future reuse.
+ """
+ customer_creation: NotRequired[Literal["always", "if_required"]]
+ """
+ Configure whether a Checkout Session creates a [Customer](https://stripe.com/docs/api/customers) during Session confirmation.
+
+ When a Customer is not created, you can still retrieve email, address, and other customer data entered in Checkout
+ with [customer_details](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-customer_details).
+
+ Sessions that don't create Customers instead are grouped by [guest customers](https://stripe.com/docs/payments/checkout/guest-customers)
+ in the Dashboard. Promotion codes limited to first time customers will return invalid for these Sessions.
+
+ Can only be set in `payment` and `setup` mode.
+ """
+ customer_email: NotRequired[str]
+ """
+ If provided, this value will be used when the Customer object is created.
+ If not provided, customers will be asked to enter their email address.
+ Use this parameter to prefill customer data if you already have an email
+ on file. To access information about the customer once a session is
+ complete, use the `customer` field.
+ """
+ customer_update: NotRequired["SessionCreateParamsCustomerUpdate"]
+ """
+ Controls what fields on Customer can be updated by the Checkout Session. Can only be provided when `customer` is provided.
+ """
+ discounts: NotRequired[List["SessionCreateParamsDiscount"]]
+ """
+ The coupon or promotion code to apply to this Session. Currently, only up to one may be specified.
+ """
+ excluded_payment_method_types: NotRequired[
+ List[
+ Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "card",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ ]
+ ]
+ """
+ A list of the types of payment methods (e.g., `card`) that should be excluded from this Checkout Session. This should only be used when payment methods for this Checkout Session are managed through the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired[int]
+ """
+ The Epoch time in seconds at which the Checkout Session will expire. It can be anywhere from 30 minutes to 24 hours after Checkout Session creation. By default, this value is 24 hours from creation.
+ """
+ invoice_creation: NotRequired["SessionCreateParamsInvoiceCreation"]
+ """
+ Generate a post-purchase Invoice for one-time payments.
+ """
+ line_items: NotRequired[List["SessionCreateParamsLineItem"]]
+ """
+ A list of items the customer is purchasing. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices). The parameter is required for `payment` and `subscription` mode.
+
+ For `payment` mode, there is a maximum of 100 line items, however it is recommended to consolidate line items if there are more than a few dozen.
+
+ For `subscription` mode, there is a maximum of 20 line items with recurring Prices and 20 line items with one-time Prices. Line items with one-time Prices will be on the initial invoice only.
+ """
+ locale: NotRequired[
+ Literal[
+ "auto",
+ "bg",
+ "cs",
+ "da",
+ "de",
+ "el",
+ "en",
+ "en-GB",
+ "es",
+ "es-419",
+ "et",
+ "fi",
+ "fil",
+ "fr",
+ "fr-CA",
+ "hr",
+ "hu",
+ "id",
+ "it",
+ "ja",
+ "ko",
+ "lt",
+ "lv",
+ "ms",
+ "mt",
+ "nb",
+ "nl",
+ "pl",
+ "pt",
+ "pt-BR",
+ "ro",
+ "ru",
+ "sk",
+ "sl",
+ "sv",
+ "th",
+ "tr",
+ "vi",
+ "zh",
+ "zh-HK",
+ "zh-TW",
+ ]
+ ]
+ """
+ The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ mode: NotRequired[Literal["payment", "setup", "subscription"]]
+ """
+ The mode of the Checkout Session. Pass `subscription` if the Checkout Session includes at least one recurring item.
+ """
+ name_collection: NotRequired["SessionCreateParamsNameCollection"]
+ """
+ Controls name collection settings for the session.
+
+ You can configure Checkout to collect your customers' business names, individual names, or both. Each name field can be either required or optional.
+
+ If a [Customer](https://stripe.com/docs/api/customers) is created or provided, the names can be saved to the Customer object as well.
+ """
+ optional_items: NotRequired[List["SessionCreateParamsOptionalItem"]]
+ """
+ A list of optional items the customer can add to their order at checkout. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices).
+
+ There is a maximum of 10 optional items allowed on a Checkout Session, and the existing limits on the number of line items allowed on a Checkout Session apply to the combined number of line items and optional items.
+
+ For `payment` mode, there is a maximum of 100 combined line items and optional items, however it is recommended to consolidate items if there are more than a few dozen.
+
+ For `subscription` mode, there is a maximum of 20 line items and optional items with recurring Prices and 20 line items and optional items with one-time Prices.
+ """
+ origin_context: NotRequired[Literal["mobile_app", "web"]]
+ """
+ Where the user is coming from. This informs the optimizations that are applied to the session.
+ """
+ payment_intent_data: NotRequired["SessionCreateParamsPaymentIntentData"]
+ """
+ A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
+ """
+ payment_method_collection: NotRequired[Literal["always", "if_required"]]
+ """
+ Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.
+ This may occur if the Checkout Session includes a free trial or a discount.
+
+ Can only be set in `subscription` mode. Defaults to `always`.
+
+ 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_configuration: NotRequired[str]
+ """
+ The ID of the payment method configuration to use with this Checkout session.
+ """
+ payment_method_data: NotRequired["SessionCreateParamsPaymentMethodData"]
+ """
+ This parameter allows you to set some attributes on the payment method created during a Checkout session.
+ """
+ payment_method_options: NotRequired[
+ "SessionCreateParamsPaymentMethodOptions"
+ ]
+ """
+ Payment-method-specific configuration.
+ """
+ payment_method_types: NotRequired[
+ List[
+ Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "card",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "link",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ ]
+ ]
+ """
+ A list of the types of payment methods (e.g., `card`) this Checkout Session can accept.
+
+ You can omit this attribute to manage your payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
+ See [Dynamic Payment Methods](https://stripe.com/docs/payments/payment-methods/integration-options#using-dynamic-payment-methods) for more details.
+
+ Read more about the supported payment methods and their requirements in our [payment
+ method details guide](https://docs.stripe.com/docs/payments/checkout/payment-methods).
+
+ If multiple payment methods are passed, Checkout will dynamically reorder them to
+ prioritize the most relevant payment methods based on the customer's location and
+ other characteristics.
+ """
+ permissions: NotRequired["SessionCreateParamsPermissions"]
+ """
+ This property is used to set up permissions for various actions (e.g., update) on the CheckoutSession object. Can only be set when creating `embedded` or `custom` sessions.
+
+ For specific permissions, please refer to their dedicated subsections, such as `permissions.update_shipping_details`.
+ """
+ phone_number_collection: NotRequired[
+ "SessionCreateParamsPhoneNumberCollection"
+ ]
+ """
+ Controls phone number collection settings for the session.
+
+ We recommend that you review your privacy policy and check with your legal contacts
+ before using this feature. Learn more about [collecting phone numbers with Checkout](https://stripe.com/docs/payments/checkout/phone-numbers).
+ """
+ redirect_on_completion: NotRequired[
+ Literal["always", "if_required", "never"]
+ ]
+ """
+ This parameter applies to `ui_mode: embedded`. Learn more about the [redirect behavior](https://stripe.com/docs/payments/checkout/custom-success-page?payment-ui=embedded-form) of embedded sessions. Defaults to `always`.
+ """
+ return_url: NotRequired[str]
+ """
+ The URL to redirect your customer back to after they authenticate or cancel their payment on the
+ payment method's app or site. This parameter is required if `ui_mode` is `embedded` or `custom`
+ and redirect-based payment methods are enabled on the session.
+ """
+ saved_payment_method_options: NotRequired[
+ "SessionCreateParamsSavedPaymentMethodOptions"
+ ]
+ """
+ Controls saved payment method settings for the session. Only available in `payment` and `subscription` mode.
+ """
+ setup_intent_data: NotRequired["SessionCreateParamsSetupIntentData"]
+ """
+ A subset of parameters to be passed to SetupIntent creation for Checkout Sessions in `setup` mode.
+ """
+ shipping_address_collection: NotRequired[
+ "SessionCreateParamsShippingAddressCollection"
+ ]
+ """
+ When set, provides configuration for Checkout to collect a shipping address from a customer.
+ """
+ shipping_options: NotRequired[List["SessionCreateParamsShippingOption"]]
+ """
+ The shipping rate options to apply to this Session. Up to a maximum of 5.
+ """
+ submit_type: NotRequired[
+ Literal["auto", "book", "donate", "pay", "subscribe"]
+ ]
+ """
+ Describes the type of transaction being performed by Checkout in order
+ to customize relevant text on the page, such as the submit button.
+ `submit_type` can only be specified on Checkout Sessions in
+ `payment` or `subscription` mode. If blank or `auto`, `pay` is used.
+ """
+ subscription_data: NotRequired["SessionCreateParamsSubscriptionData"]
+ """
+ A subset of parameters to be passed to subscription creation for Checkout Sessions in `subscription` mode.
+ """
+ success_url: NotRequired[str]
+ """
+ The URL to which Stripe should send customers when payment or setup
+ is complete.
+ This parameter is not allowed if ui_mode is `embedded` or `custom`. If you'd like to use
+ information from the successful Checkout Session on your page, read the
+ guide on [customizing your success page](https://stripe.com/docs/payments/checkout/custom-success-page).
+ """
+ tax_id_collection: NotRequired["SessionCreateParamsTaxIdCollection"]
+ """
+ Controls tax ID collection during checkout.
+ """
+ ui_mode: NotRequired[Literal["custom", "embedded", "hosted"]]
+ """
+ The UI mode of the Session. Defaults to `hosted`.
+ """
+ wallet_options: NotRequired["SessionCreateParamsWalletOptions"]
+ """
+ Wallet-specific configuration.
+ """
+
+
+class SessionCreateParamsAdaptivePricing(TypedDict):
+ enabled: NotRequired[bool]
+ """
+ If set to `true`, Adaptive Pricing is available on [eligible sessions](https://docs.stripe.com/payments/currencies/localize-prices/adaptive-pricing?payment-ui=stripe-hosted#restrictions). Defaults to your [dashboard setting](https://dashboard.stripe.com/settings/adaptive-pricing).
+ """
+
+
+class SessionCreateParamsAfterExpiration(TypedDict):
+ recovery: NotRequired["SessionCreateParamsAfterExpirationRecovery"]
+ """
+ Configure a Checkout Session that can be used to recover an expired session.
+ """
+
+
+class SessionCreateParamsAfterExpirationRecovery(TypedDict):
+ allow_promotion_codes: NotRequired[bool]
+ """
+ Enables user redeemable promotion codes on the recovered Checkout Sessions. Defaults to `false`
+ """
+ enabled: bool
+ """
+ If `true`, a recovery URL will be generated to recover this Checkout Session if it
+ expires before a successful transaction is completed. It will be attached to the
+ Checkout Session object upon expiration.
+ """
+
+
+class SessionCreateParamsAutomaticTax(TypedDict):
+ enabled: bool
+ """
+ Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
+
+ Enabling this parameter causes Checkout to collect any billing address information necessary for tax calculation.
+ """
+ liability: NotRequired["SessionCreateParamsAutomaticTaxLiability"]
+ """
+ The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
+ """
+
+
+class SessionCreateParamsAutomaticTaxLiability(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SessionCreateParamsBrandingSettings(TypedDict):
+ background_color: NotRequired["Literal['']|str"]
+ """
+ A hex color value starting with `#` representing the background color for the Checkout Session.
+ """
+ border_style: NotRequired[
+ "Literal['']|Literal['pill', 'rectangular', 'rounded']"
+ ]
+ """
+ The border style for the Checkout Session.
+ """
+ button_color: NotRequired["Literal['']|str"]
+ """
+ A hex color value starting with `#` representing the button color for the Checkout Session.
+ """
+ display_name: NotRequired[str]
+ """
+ A string to override the business name shown on the Checkout Session.
+ """
+ font_family: NotRequired[
+ "Literal['']|Literal['be_vietnam_pro', 'bitter', 'chakra_petch', 'default', 'hahmlet', 'inconsolata', 'inter', 'lato', 'lora', 'm_plus_1_code', 'montserrat', 'noto_sans', 'noto_sans_jp', 'noto_serif', 'nunito', 'open_sans', 'pridi', 'pt_sans', 'pt_serif', 'raleway', 'roboto', 'roboto_slab', 'source_sans_pro', 'titillium_web', 'ubuntu_mono', 'zen_maru_gothic']"
+ ]
+ """
+ The font family for the Checkout Session corresponding to one of the [supported font families](https://docs.stripe.com/payments/checkout/customization/appearance?payment-ui=stripe-hosted#font-compatibility).
+ """
+ icon: NotRequired["SessionCreateParamsBrandingSettingsIcon"]
+ """
+ The icon for the Checkout Session. You cannot set both `logo` and `icon`.
+ """
+ logo: NotRequired["SessionCreateParamsBrandingSettingsLogo"]
+ """
+ The logo for the Checkout Session. You cannot set both `logo` and `icon`.
+ """
+
+
+class SessionCreateParamsBrandingSettingsIcon(TypedDict):
+ file: NotRequired[str]
+ """
+ The ID of a [File upload](https://stripe.com/docs/api/files) representing the icon. Purpose must be `business_icon`. Required if `type` is `file` and disallowed otherwise.
+ """
+ type: Literal["file", "url"]
+ """
+ The type of image for the icon. Must be one of `file` or `url`.
+ """
+ url: NotRequired[str]
+ """
+ The URL of the image. Required if `type` is `url` and disallowed otherwise.
+ """
+
+
+class SessionCreateParamsBrandingSettingsLogo(TypedDict):
+ file: NotRequired[str]
+ """
+ The ID of a [File upload](https://stripe.com/docs/api/files) representing the logo. Purpose must be `business_logo`. Required if `type` is `file` and disallowed otherwise.
+ """
+ type: Literal["file", "url"]
+ """
+ The type of image for the logo. Must be one of `file` or `url`.
+ """
+ url: NotRequired[str]
+ """
+ The URL of the image. Required if `type` is `url` and disallowed otherwise.
+ """
+
+
+class SessionCreateParamsConsentCollection(TypedDict):
+ payment_method_reuse_agreement: NotRequired[
+ "SessionCreateParamsConsentCollectionPaymentMethodReuseAgreement"
+ ]
+ """
+ Determines the display of payment method reuse agreement text in the UI. If set to `hidden`, it will hide legal text related to the reuse of a payment method.
+ """
+ promotions: NotRequired[Literal["auto", "none"]]
+ """
+ If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
+ Session will determine whether to display an option to opt into promotional communication
+ from the merchant depending on the customer's locale. Only available to US merchants.
+ """
+ terms_of_service: NotRequired[Literal["none", "required"]]
+ """
+ If set to `required`, it requires customers to check a terms of service checkbox before being able to pay.
+ There must be a valid terms of service URL set in your [Dashboard settings](https://dashboard.stripe.com/settings/public).
+ """
+
+
+class SessionCreateParamsConsentCollectionPaymentMethodReuseAgreement(
+ TypedDict,
+):
+ position: Literal["auto", "hidden"]
+ """
+ Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's
+ defaults will be used. When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
+ """
+
+
+class SessionCreateParamsCustomField(TypedDict):
+ dropdown: NotRequired["SessionCreateParamsCustomFieldDropdown"]
+ """
+ Configuration for `type=dropdown` fields.
+ """
+ key: str
+ """
+ String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
+ """
+ label: "SessionCreateParamsCustomFieldLabel"
+ """
+ The label for the field, displayed to the customer.
+ """
+ numeric: NotRequired["SessionCreateParamsCustomFieldNumeric"]
+ """
+ Configuration for `type=numeric` fields.
+ """
+ optional: NotRequired[bool]
+ """
+ Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
+ """
+ text: NotRequired["SessionCreateParamsCustomFieldText"]
+ """
+ Configuration for `type=text` fields.
+ """
+ type: Literal["dropdown", "numeric", "text"]
+ """
+ The type of the field.
+ """
+
+
+class SessionCreateParamsCustomFieldDropdown(TypedDict):
+ default_value: NotRequired[str]
+ """
+ The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
+ """
+ options: List["SessionCreateParamsCustomFieldDropdownOption"]
+ """
+ The options available for the customer to select. Up to 200 options allowed.
+ """
+
+
+class SessionCreateParamsCustomFieldDropdownOption(TypedDict):
+ label: str
+ """
+ The label for the option, displayed to the customer. Up to 100 characters.
+ """
+ value: str
+ """
+ The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
+ """
+
+
+class SessionCreateParamsCustomFieldLabel(TypedDict):
+ custom: str
+ """
+ Custom text for the label, displayed to the customer. Up to 50 characters.
+ """
+ type: Literal["custom"]
+ """
+ The type of the label.
+ """
+
+
+class SessionCreateParamsCustomFieldNumeric(TypedDict):
+ default_value: NotRequired[str]
+ """
+ The value that will pre-fill the field on the payment page.
+ """
+ maximum_length: NotRequired[int]
+ """
+ The maximum character length constraint for the customer's input.
+ """
+ minimum_length: NotRequired[int]
+ """
+ The minimum character length requirement for the customer's input.
+ """
+
+
+class SessionCreateParamsCustomFieldText(TypedDict):
+ default_value: NotRequired[str]
+ """
+ The value that will pre-fill the field on the payment page.
+ """
+ maximum_length: NotRequired[int]
+ """
+ The maximum character length constraint for the customer's input.
+ """
+ minimum_length: NotRequired[int]
+ """
+ The minimum character length requirement for the customer's input.
+ """
+
+
+class SessionCreateParamsCustomText(TypedDict):
+ after_submit: NotRequired[
+ "Literal['']|SessionCreateParamsCustomTextAfterSubmit"
+ ]
+ """
+ Custom text that should be displayed after the payment confirmation button.
+ """
+ shipping_address: NotRequired[
+ "Literal['']|SessionCreateParamsCustomTextShippingAddress"
+ ]
+ """
+ Custom text that should be displayed alongside shipping address collection.
+ """
+ submit: NotRequired["Literal['']|SessionCreateParamsCustomTextSubmit"]
+ """
+ Custom text that should be displayed alongside the payment confirmation button.
+ """
+ terms_of_service_acceptance: NotRequired[
+ "Literal['']|SessionCreateParamsCustomTextTermsOfServiceAcceptance"
+ ]
+ """
+ Custom text that should be displayed in place of the default terms of service agreement text.
+ """
+
+
+class SessionCreateParamsCustomTextAfterSubmit(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class SessionCreateParamsCustomTextShippingAddress(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class SessionCreateParamsCustomTextSubmit(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class SessionCreateParamsCustomTextTermsOfServiceAcceptance(TypedDict):
+ message: str
+ """
+ Text may be up to 1200 characters in length.
+ """
+
+
+class SessionCreateParamsCustomerUpdate(TypedDict):
+ address: NotRequired[Literal["auto", "never"]]
+ """
+ Describes whether Checkout saves the billing address onto `customer.address`.
+ To always collect a full billing address, use `billing_address_collection`. Defaults to `never`.
+ """
+ name: NotRequired[Literal["auto", "never"]]
+ """
+ Describes whether Checkout saves the name onto `customer.name`. Defaults to `never`.
+ """
+ shipping: NotRequired[Literal["auto", "never"]]
+ """
+ Describes whether Checkout saves shipping information onto `customer.shipping`.
+ To collect shipping information, use `shipping_address_collection`. Defaults to `never`.
+ """
+
+
+class SessionCreateParamsDiscount(TypedDict):
+ coupon: NotRequired[str]
+ """
+ The ID of the coupon to apply to this Session.
+ """
+ promotion_code: NotRequired[str]
+ """
+ The ID of a promotion code to apply to this Session.
+ """
+
+
+class SessionCreateParamsInvoiceCreation(TypedDict):
+ enabled: bool
+ """
+ Set to `true` to enable invoice creation.
+ """
+ invoice_data: NotRequired["SessionCreateParamsInvoiceCreationInvoiceData"]
+ """
+ Parameters passed when creating invoices for payment-mode Checkout Sessions.
+ """
+
+
+class SessionCreateParamsInvoiceCreationInvoiceData(TypedDict):
+ account_tax_ids: NotRequired["Literal['']|List[str]"]
+ """
+ The account tax IDs associated with the invoice.
+ """
+ custom_fields: NotRequired[
+ "Literal['']|List[SessionCreateParamsInvoiceCreationInvoiceDataCustomField]"
+ ]
+ """
+ Default custom fields to be displayed on invoices for this customer.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ footer: NotRequired[str]
+ """
+ Default footer to be displayed on invoices for this customer.
+ """
+ issuer: NotRequired["SessionCreateParamsInvoiceCreationInvoiceDataIssuer"]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ rendering_options: NotRequired[
+ "Literal['']|SessionCreateParamsInvoiceCreationInvoiceDataRenderingOptions"
+ ]
+ """
+ Default options for invoice PDF rendering for this customer.
+ """
+
+
+class SessionCreateParamsInvoiceCreationInvoiceDataCustomField(TypedDict):
+ name: str
+ """
+ The name of the custom field. This may be up to 40 characters.
+ """
+ value: str
+ """
+ The value of the custom field. This may be up to 140 characters.
+ """
+
+
+class SessionCreateParamsInvoiceCreationInvoiceDataIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SessionCreateParamsInvoiceCreationInvoiceDataRenderingOptions(TypedDict):
+ amount_tax_display: NotRequired[
+ "Literal['']|Literal['exclude_tax', 'include_inclusive_tax']"
+ ]
+ """
+ How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
+ """
+ template: NotRequired[str]
+ """
+ ID of the invoice rendering template to use for this invoice.
+ """
+
+
+class SessionCreateParamsLineItem(TypedDict):
+ adjustable_quantity: NotRequired[
+ "SessionCreateParamsLineItemAdjustableQuantity"
+ ]
+ """
+ When set, provides configuration for this item's quantity to be adjusted by the customer during Checkout.
+ """
+ dynamic_tax_rates: NotRequired[List[str]]
+ """
+ The [tax rates](https://stripe.com/docs/api/tax_rates) that will be applied to this line item depending on the customer's billing/shipping address. We currently support the following countries: US, GB, AU, and all countries in the EU.
+ """
+ price: NotRequired[str]
+ """
+ The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object. One of `price` or `price_data` is required.
+ """
+ price_data: NotRequired["SessionCreateParamsLineItemPriceData"]
+ """
+ Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
+ """
+ quantity: NotRequired[int]
+ """
+ The quantity of the line item being purchased. Quantity should not be defined when `recurring.usage_type=metered`.
+ """
+ tax_rates: NotRequired[List[str]]
+ """
+ The [tax rates](https://stripe.com/docs/api/tax_rates) which apply to this line item.
+ """
+
+
+class SessionCreateParamsLineItemAdjustableQuantity(TypedDict):
+ enabled: bool
+ """
+ Set to true if the quantity can be adjusted to any non-negative integer.
+ """
+ maximum: NotRequired[int]
+ """
+ The maximum quantity the customer can purchase for the Checkout Session. By default this value is 99. You can specify a value up to 999999.
+ """
+ minimum: NotRequired[int]
+ """
+ The minimum quantity the customer must purchase for the Checkout Session. By default this value is 0.
+ """
+
+
+class SessionCreateParamsLineItemPriceData(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ product: NotRequired[str]
+ """
+ The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
+ """
+ product_data: NotRequired[
+ "SessionCreateParamsLineItemPriceDataProductData"
+ ]
+ """
+ Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
+ """
+ recurring: NotRequired["SessionCreateParamsLineItemPriceDataRecurring"]
+ """
+ The recurring components of a price such as `interval` and `interval_count`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
+ """
+ unit_amount: NotRequired[int]
+ """
+ A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
+ """
+ unit_amount_decimal: NotRequired[str]
+ """
+ Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
+ """
+
+
+class SessionCreateParamsLineItemPriceDataProductData(TypedDict):
+ description: NotRequired[str]
+ """
+ The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
+ """
+ images: NotRequired[List[str]]
+ """
+ A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: str
+ """
+ The product's name, meant to be displayable to the customer.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+ unit_label: NotRequired[str]
+ """
+ A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
+ """
+
+
+class SessionCreateParamsLineItemPriceDataRecurring(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Specifies billing frequency. Either `day`, `week`, `month` or `year`.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
+ """
+
+
+class SessionCreateParamsNameCollection(TypedDict):
+ business: NotRequired["SessionCreateParamsNameCollectionBusiness"]
+ """
+ Controls settings applied for collecting the customer's business name on the session.
+ """
+ individual: NotRequired["SessionCreateParamsNameCollectionIndividual"]
+ """
+ Controls settings applied for collecting the customer's individual name on the session.
+ """
+
+
+class SessionCreateParamsNameCollectionBusiness(TypedDict):
+ enabled: bool
+ """
+ Enable business name collection on the Checkout Session. Defaults to `false`.
+ """
+ optional: NotRequired[bool]
+ """
+ Whether the customer is required to provide a business name before completing the Checkout Session. Defaults to `false`.
+ """
+
+
+class SessionCreateParamsNameCollectionIndividual(TypedDict):
+ enabled: bool
+ """
+ Enable individual name collection on the Checkout Session. Defaults to `false`.
+ """
+ optional: NotRequired[bool]
+ """
+ Whether the customer is required to provide their name before completing the Checkout Session. Defaults to `false`.
+ """
+
+
+class SessionCreateParamsOptionalItem(TypedDict):
+ adjustable_quantity: NotRequired[
+ "SessionCreateParamsOptionalItemAdjustableQuantity"
+ ]
+ """
+ When set, provides configuration for the customer to adjust the quantity of the line item created when a customer chooses to add this optional item to their order.
+ """
+ price: str
+ """
+ The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object.
+ """
+ quantity: int
+ """
+ The initial quantity of the line item created when a customer chooses to add this optional item to their order.
+ """
+
+
+class SessionCreateParamsOptionalItemAdjustableQuantity(TypedDict):
+ enabled: bool
+ """
+ Set to true if the quantity can be adjusted to any non-negative integer.
+ """
+ maximum: NotRequired[int]
+ """
+ The maximum quantity of this item the customer can purchase. By default this value is 99. You can specify a value up to 999999.
+ """
+ minimum: NotRequired[int]
+ """
+ The minimum quantity of this item the customer must purchase, if they choose to purchase it. Because this item is optional, the customer will always be able to remove it from their order, even if the `minimum` configured here is greater than 0. By default this value is 0.
+ """
+
+
+class SessionCreateParamsPaymentIntentData(TypedDict):
+ application_fee_amount: NotRequired[int]
+ """
+ The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+ capture_method: NotRequired[
+ Literal["automatic", "automatic_async", "manual"]
+ ]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ on_behalf_of: NotRequired[str]
+ """
+ The Stripe account ID for which these funds are intended. For details,
+ see the PaymentIntents [use case for connected
+ accounts](https://docs.stripe.com/docs/payments/connected-accounts).
+ """
+ receipt_email: NotRequired[str]
+ """
+ Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
+ """
+ setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
+ """
+ Indicates that you intend to [make future payments](https://stripe.com/docs/payments/payment-intents#future-usage) with the payment
+ method collected by this Checkout Session.
+
+ When setting this to `on_session`, Checkout will show a notice to the
+ customer that their payment details will be saved.
+
+ When setting this to `off_session`, Checkout will show a notice to the
+ customer that their payment details will be saved and used for future
+ payments.
+
+ If a Customer has been provided or Checkout creates a new Customer,
+ Checkout will attach the payment method to the Customer.
+
+ If Checkout does not create a Customer, the payment method is not attached
+ to a Customer. To reuse the payment method, you can retrieve it from the
+ Checkout Session's PaymentIntent.
+
+ When processing card payments, Checkout also uses `setup_future_usage`
+ to dynamically optimize your payment flow and comply with regional
+ legislation and network rules, such as SCA.
+ """
+ shipping: NotRequired["SessionCreateParamsPaymentIntentDataShipping"]
+ """
+ Shipping information for this payment.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
+
+ Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
+ """
+ statement_descriptor_suffix: NotRequired[str]
+ """
+ Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
+ """
+ transfer_data: NotRequired[
+ "SessionCreateParamsPaymentIntentDataTransferData"
+ ]
+ """
+ The parameters used to automatically create a Transfer when the payment succeeds.
+ For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
+ """
+ transfer_group: NotRequired[str]
+ """
+ A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
+ """
+
+
+class SessionCreateParamsPaymentIntentDataShipping(TypedDict):
+ address: "SessionCreateParamsPaymentIntentDataShippingAddress"
+ """
+ Shipping address.
+ """
+ carrier: NotRequired[str]
+ """
+ The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
+ """
+ name: str
+ """
+ Recipient name.
+ """
+ phone: NotRequired[str]
+ """
+ Recipient phone (including extension).
+ """
+ tracking_number: NotRequired[str]
+ """
+ The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
+ """
+
+
+class SessionCreateParamsPaymentIntentDataShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: str
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class SessionCreateParamsPaymentIntentDataTransferData(TypedDict):
+ amount: NotRequired[int]
+ """
+ The amount that will be transferred automatically when a charge succeeds.
+ """
+ destination: str
+ """
+ If specified, successful charges will be attributed to the destination
+ account for tax reporting, and the funds from charges will be transferred
+ to the destination account. The ID of the resulting transfer will be
+ returned on the successful charge's `transfer` field.
+ """
+
+
+class SessionCreateParamsPaymentMethodData(TypedDict):
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ Allow redisplay will be set on the payment method on confirmation and indicates whether this payment method can be shown again to the customer in a checkout flow. Only set this field if you wish to override the allow_redisplay value determined by Checkout.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptions(TypedDict):
+ acss_debit: NotRequired["SessionCreateParamsPaymentMethodOptionsAcssDebit"]
+ """
+ contains details about the ACSS Debit payment method options.
+ """
+ affirm: NotRequired["SessionCreateParamsPaymentMethodOptionsAffirm"]
+ """
+ contains details about the Affirm payment method options.
+ """
+ afterpay_clearpay: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsAfterpayClearpay"
+ ]
+ """
+ contains details about the Afterpay Clearpay payment method options.
+ """
+ alipay: NotRequired["SessionCreateParamsPaymentMethodOptionsAlipay"]
+ """
+ contains details about the Alipay payment method options.
+ """
+ alma: NotRequired["SessionCreateParamsPaymentMethodOptionsAlma"]
+ """
+ contains details about the Alma payment method options.
+ """
+ amazon_pay: NotRequired["SessionCreateParamsPaymentMethodOptionsAmazonPay"]
+ """
+ contains details about the AmazonPay payment method options.
+ """
+ au_becs_debit: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsAuBecsDebit"
+ ]
+ """
+ contains details about the AU Becs Debit payment method options.
+ """
+ bacs_debit: NotRequired["SessionCreateParamsPaymentMethodOptionsBacsDebit"]
+ """
+ contains details about the Bacs Debit payment method options.
+ """
+ bancontact: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsBancontact"
+ ]
+ """
+ contains details about the Bancontact payment method options.
+ """
+ billie: NotRequired["SessionCreateParamsPaymentMethodOptionsBillie"]
+ """
+ contains details about the Billie payment method options.
+ """
+ boleto: NotRequired["SessionCreateParamsPaymentMethodOptionsBoleto"]
+ """
+ contains details about the Boleto payment method options.
+ """
+ card: NotRequired["SessionCreateParamsPaymentMethodOptionsCard"]
+ """
+ contains details about the Card payment method options.
+ """
+ cashapp: NotRequired["SessionCreateParamsPaymentMethodOptionsCashapp"]
+ """
+ contains details about the Cashapp Pay payment method options.
+ """
+ customer_balance: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsCustomerBalance"
+ ]
+ """
+ contains details about the Customer Balance payment method options.
+ """
+ demo_pay: NotRequired["SessionCreateParamsPaymentMethodOptionsDemoPay"]
+ """
+ contains details about the DemoPay payment method options.
+ """
+ eps: NotRequired["SessionCreateParamsPaymentMethodOptionsEps"]
+ """
+ contains details about the EPS payment method options.
+ """
+ fpx: NotRequired["SessionCreateParamsPaymentMethodOptionsFpx"]
+ """
+ contains details about the FPX payment method options.
+ """
+ giropay: NotRequired["SessionCreateParamsPaymentMethodOptionsGiropay"]
+ """
+ contains details about the Giropay payment method options.
+ """
+ grabpay: NotRequired["SessionCreateParamsPaymentMethodOptionsGrabpay"]
+ """
+ contains details about the Grabpay payment method options.
+ """
+ ideal: NotRequired["SessionCreateParamsPaymentMethodOptionsIdeal"]
+ """
+ contains details about the Ideal payment method options.
+ """
+ kakao_pay: NotRequired["SessionCreateParamsPaymentMethodOptionsKakaoPay"]
+ """
+ contains details about the Kakao Pay payment method options.
+ """
+ klarna: NotRequired["SessionCreateParamsPaymentMethodOptionsKlarna"]
+ """
+ contains details about the Klarna payment method options.
+ """
+ konbini: NotRequired["SessionCreateParamsPaymentMethodOptionsKonbini"]
+ """
+ contains details about the Konbini payment method options.
+ """
+ kr_card: NotRequired["SessionCreateParamsPaymentMethodOptionsKrCard"]
+ """
+ contains details about the Korean card payment method options.
+ """
+ link: NotRequired["SessionCreateParamsPaymentMethodOptionsLink"]
+ """
+ contains details about the Link payment method options.
+ """
+ mobilepay: NotRequired["SessionCreateParamsPaymentMethodOptionsMobilepay"]
+ """
+ contains details about the Mobilepay payment method options.
+ """
+ multibanco: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsMultibanco"
+ ]
+ """
+ contains details about the Multibanco payment method options.
+ """
+ naver_pay: NotRequired["SessionCreateParamsPaymentMethodOptionsNaverPay"]
+ """
+ contains details about the Naver Pay payment method options.
+ """
+ oxxo: NotRequired["SessionCreateParamsPaymentMethodOptionsOxxo"]
+ """
+ contains details about the OXXO payment method options.
+ """
+ p24: NotRequired["SessionCreateParamsPaymentMethodOptionsP24"]
+ """
+ contains details about the P24 payment method options.
+ """
+ pay_by_bank: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsPayByBank"
+ ]
+ """
+ contains details about the Pay By Bank payment method options.
+ """
+ payco: NotRequired["SessionCreateParamsPaymentMethodOptionsPayco"]
+ """
+ contains details about the PAYCO payment method options.
+ """
+ paynow: NotRequired["SessionCreateParamsPaymentMethodOptionsPaynow"]
+ """
+ contains details about the PayNow payment method options.
+ """
+ paypal: NotRequired["SessionCreateParamsPaymentMethodOptionsPaypal"]
+ """
+ contains details about the PayPal payment method options.
+ """
+ pix: NotRequired["SessionCreateParamsPaymentMethodOptionsPix"]
+ """
+ contains details about the Pix payment method options.
+ """
+ revolut_pay: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsRevolutPay"
+ ]
+ """
+ contains details about the RevolutPay payment method options.
+ """
+ samsung_pay: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsSamsungPay"
+ ]
+ """
+ contains details about the Samsung Pay payment method options.
+ """
+ satispay: NotRequired["SessionCreateParamsPaymentMethodOptionsSatispay"]
+ """
+ contains details about the Satispay payment method options.
+ """
+ sepa_debit: NotRequired["SessionCreateParamsPaymentMethodOptionsSepaDebit"]
+ """
+ contains details about the Sepa Debit payment method options.
+ """
+ sofort: NotRequired["SessionCreateParamsPaymentMethodOptionsSofort"]
+ """
+ contains details about the Sofort payment method options.
+ """
+ swish: NotRequired["SessionCreateParamsPaymentMethodOptionsSwish"]
+ """
+ contains details about the Swish payment method options.
+ """
+ us_bank_account: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ contains details about the Us Bank Account payment method options.
+ """
+ wechat_pay: NotRequired["SessionCreateParamsPaymentMethodOptionsWechatPay"]
+ """
+ contains details about the WeChat Pay payment method options.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsAcssDebit(TypedDict):
+ currency: NotRequired[Literal["cad", "usd"]]
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). This is only accepted for Checkout Sessions in `setup` mode.
+ """
+ mandate_options: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsAcssDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ setup_future_usage: NotRequired[
+ Literal["none", "off_session", "on_session"]
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+ verification_method: NotRequired[
+ Literal["automatic", "instant", "microdeposits"]
+ ]
+ """
+ Verification method for the intent
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsAcssDebitMandateOptions(
+ TypedDict
+):
+ custom_mandate_url: NotRequired["Literal['']|str"]
+ """
+ A URL for custom mandate text to render during confirmation step.
+ The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
+ or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
+ """
+ default_for: NotRequired[List[Literal["invoice", "subscription"]]]
+ """
+ List of Stripe products where this mandate can be selected automatically. Only usable in `setup` mode.
+ """
+ interval_description: NotRequired[str]
+ """
+ Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
+ """
+ payment_schedule: NotRequired[Literal["combined", "interval", "sporadic"]]
+ """
+ Payment schedule for the mandate.
+ """
+ transaction_type: NotRequired[Literal["business", "personal"]]
+ """
+ Transaction type of the mandate.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsAffirm(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsAfterpayClearpay(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsAlipay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsAlma(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsAmazonPay(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ setup_future_usage: NotRequired[Literal["none", "off_session"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsAuBecsDebit(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsBacsDebit(TypedDict):
+ mandate_options: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsBacsDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ setup_future_usage: NotRequired[
+ Literal["none", "off_session", "on_session"]
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsBacsDebitMandateOptions(
+ TypedDict
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsBancontact(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsBillie(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsBoleto(TypedDict):
+ expires_after_days: NotRequired[int]
+ """
+ The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
+ """
+ setup_future_usage: NotRequired[
+ Literal["none", "off_session", "on_session"]
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsCard(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ installments: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsCardInstallments"
+ ]
+ """
+ Installment options for card payments
+ """
+ request_extended_authorization: NotRequired[
+ Literal["if_available", "never"]
+ ]
+ """
+ Request ability to [capture beyond the standard authorization validity window](https://docs.stripe.com/payments/extended-authorization) for this CheckoutSession.
+ """
+ request_incremental_authorization: NotRequired[
+ Literal["if_available", "never"]
+ ]
+ """
+ Request ability to [increment the authorization](https://docs.stripe.com/payments/incremental-authorization) for this CheckoutSession.
+ """
+ request_multicapture: NotRequired[Literal["if_available", "never"]]
+ """
+ Request ability to make [multiple captures](https://docs.stripe.com/payments/multicapture) for this CheckoutSession.
+ """
+ request_overcapture: NotRequired[Literal["if_available", "never"]]
+ """
+ Request ability to [overcapture](https://docs.stripe.com/payments/overcapture) for this CheckoutSession.
+ """
+ request_three_d_secure: NotRequired[
+ Literal["any", "automatic", "challenge"]
+ ]
+ """
+ We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
+ """
+ restrictions: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsCardRestrictions"
+ ]
+ """
+ Restrictions to apply to the card payment method. For example, you can block specific card brands.
+ """
+ setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+ statement_descriptor_suffix_kana: NotRequired[str]
+ """
+ Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that's set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
+ """
+ statement_descriptor_suffix_kanji: NotRequired[str]
+ """
+ Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that's set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsCardInstallments(TypedDict):
+ enabled: NotRequired[bool]
+ """
+ Setting to true enables installments for this Checkout Session.
+ Setting to false will prevent any installment plan from applying to a payment.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsCardRestrictions(TypedDict):
+ brands_blocked: NotRequired[
+ List[
+ Literal[
+ "american_express",
+ "discover_global_network",
+ "mastercard",
+ "visa",
+ ]
+ ]
+ ]
+ """
+ Specify the card brands to block in the Checkout Session. If a customer enters or selects a card belonging to a blocked brand, they can't complete the Session.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsCashapp(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ setup_future_usage: NotRequired[
+ Literal["none", "off_session", "on_session"]
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsCustomerBalance(TypedDict):
+ bank_transfer: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsCustomerBalanceBankTransfer"
+ ]
+ """
+ Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
+ """
+ funding_type: NotRequired[Literal["bank_transfer"]]
+ """
+ The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsCustomerBalanceBankTransfer(
+ TypedDict,
+):
+ eu_bank_transfer: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer"
+ ]
+ """
+ Configuration for eu_bank_transfer funding type.
+ """
+ requested_address_types: NotRequired[
+ List[
+ Literal[
+ "aba", "iban", "sepa", "sort_code", "spei", "swift", "zengin"
+ ]
+ ]
+ ]
+ """
+ List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
+
+ Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
+ """
+ type: Literal[
+ "eu_bank_transfer",
+ "gb_bank_transfer",
+ "jp_bank_transfer",
+ "mx_bank_transfer",
+ "us_bank_transfer",
+ ]
+ """
+ The list of bank transfer types that this PaymentIntent is allowed to use for funding.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsCustomerBalanceBankTransferEuBankTransfer(
+ TypedDict,
+):
+ country: str
+ """
+ The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsDemoPay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none", "off_session"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsEps(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsFpx(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsGiropay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsGrabpay(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsIdeal(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsKakaoPay(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ setup_future_usage: NotRequired[Literal["none", "off_session"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsKlarna(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+ subscriptions: NotRequired[
+ "Literal['']|List[SessionCreateParamsPaymentMethodOptionsKlarnaSubscription]"
+ ]
+ """
+ Subscription details if the Checkout Session sets up a future subscription.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsKlarnaSubscription(TypedDict):
+ interval: Literal["day", "month", "week", "year"]
+ """
+ Unit of time between subscription charges.
+ """
+ interval_count: NotRequired[int]
+ """
+ The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
+ """
+ name: NotRequired[str]
+ """
+ Name for subscription.
+ """
+ next_billing: (
+ "SessionCreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling"
+ )
+ """
+ Describes the upcoming charge for this subscription.
+ """
+ reference: str
+ """
+ A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsKlarnaSubscriptionNextBilling(
+ TypedDict,
+):
+ amount: int
+ """
+ The amount of the next charge for the subscription.
+ """
+ date: str
+ """
+ The date of the next charge for the subscription in YYYY-MM-DD format.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsKonbini(TypedDict):
+ expires_after_days: NotRequired[int]
+ """
+ The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsKrCard(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ setup_future_usage: NotRequired[Literal["none", "off_session"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsLink(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ setup_future_usage: NotRequired[Literal["none", "off_session"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsMobilepay(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsMultibanco(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsNaverPay(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ setup_future_usage: NotRequired[Literal["none", "off_session"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsOxxo(TypedDict):
+ expires_after_days: NotRequired[int]
+ """
+ The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsP24(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+ tos_shown_and_accepted: NotRequired[bool]
+ """
+ Confirm that the payer has accepted the P24 terms and conditions.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsPayByBank(TypedDict):
+ pass
+
+
+class SessionCreateParamsPaymentMethodOptionsPayco(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsPaynow(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsPaypal(TypedDict):
+ capture_method: NotRequired["Literal['']|Literal['manual']"]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ preferred_locale: NotRequired[
+ Literal[
+ "cs-CZ",
+ "da-DK",
+ "de-AT",
+ "de-DE",
+ "de-LU",
+ "el-GR",
+ "en-GB",
+ "en-US",
+ "es-ES",
+ "fi-FI",
+ "fr-BE",
+ "fr-FR",
+ "fr-LU",
+ "hu-HU",
+ "it-IT",
+ "nl-BE",
+ "nl-NL",
+ "pl-PL",
+ "pt-PT",
+ "sk-SK",
+ "sv-SE",
+ ]
+ ]
+ """
+ [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
+ """
+ reference: NotRequired[str]
+ """
+ A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
+ """
+ risk_correlation_id: NotRequired[str]
+ """
+ The risk correlation ID for an on-session payment using a saved PayPal payment method.
+ """
+ setup_future_usage: NotRequired[
+ "Literal['']|Literal['none', 'off_session']"
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+
+ If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsPix(TypedDict):
+ amount_includes_iof: NotRequired[Literal["always", "never"]]
+ """
+ Determines if the amount includes the IOF tax. Defaults to `never`.
+ """
+ expires_after_seconds: NotRequired[int]
+ """
+ The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsRevolutPay(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+ setup_future_usage: NotRequired[Literal["none", "off_session"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsSamsungPay(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsSatispay(TypedDict):
+ capture_method: NotRequired[Literal["manual"]]
+ """
+ Controls when the funds will be captured from the customer's account.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsSepaDebit(TypedDict):
+ mandate_options: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsSepaDebitMandateOptions"
+ ]
+ """
+ Additional fields for Mandate creation
+ """
+ setup_future_usage: NotRequired[
+ Literal["none", "off_session", "on_session"]
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsSepaDebitMandateOptions(
+ TypedDict
+):
+ reference_prefix: NotRequired["Literal['']|str"]
+ """
+ Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsSofort(TypedDict):
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsSwish(TypedDict):
+ reference: NotRequired[str]
+ """
+ The order reference that will be displayed to customers in the Swish application. Defaults to the `id` of the Payment Intent.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsUsBankAccount(TypedDict):
+ financial_connections: NotRequired[
+ "SessionCreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections"
+ ]
+ """
+ Additional fields for Financial Connections Session creation
+ """
+ setup_future_usage: NotRequired[
+ Literal["none", "off_session", "on_session"]
+ ]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+ target_date: NotRequired[str]
+ """
+ Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
+ """
+ verification_method: NotRequired[Literal["automatic", "instant"]]
+ """
+ Verification method for the intent
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsUsBankAccountFinancialConnections(
+ TypedDict,
+):
+ permissions: NotRequired[
+ List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ ]
+ """
+ The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+
+
+class SessionCreateParamsPaymentMethodOptionsWechatPay(TypedDict):
+ app_id: NotRequired[str]
+ """
+ The app ID registered with WeChat Pay. Only required when client is ios or android.
+ """
+ client: Literal["android", "ios", "web"]
+ """
+ The client type that the end customer will pay from
+ """
+ setup_future_usage: NotRequired[Literal["none"]]
+ """
+ Indicates that you intend to make future payments with this PaymentIntent's payment method.
+
+ If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](https://docs.stripe.com/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](https://docs.stripe.com/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
+
+ If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
+
+ When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](https://docs.stripe.com/strong-customer-authentication).
+ """
+
+
+class SessionCreateParamsPermissions(TypedDict):
+ update_shipping_details: NotRequired[Literal["client_only", "server_only"]]
+ """
+ Determines which entity is allowed to update the shipping details.
+
+ Default is `client_only`. Stripe Checkout client will automatically update the shipping details. If set to `server_only`, only your server is allowed to update the shipping details.
+
+ When set to `server_only`, you must add the onShippingDetailsChange event handler when initializing the Stripe Checkout client and manually update the shipping details from your server using the Stripe API.
+ """
+
+
+class SessionCreateParamsPhoneNumberCollection(TypedDict):
+ enabled: bool
+ """
+ Set to `true` to enable phone number collection.
+
+ Can only be set in `payment` and `subscription` mode.
+ """
+
+
+class SessionCreateParamsSavedPaymentMethodOptions(TypedDict):
+ allow_redisplay_filters: NotRequired[
+ List[Literal["always", "limited", "unspecified"]]
+ ]
+ """
+ Uses the `allow_redisplay` value of each saved payment method to filter the set presented to a returning customer. By default, only saved payment methods with 'allow_redisplay: ‘always' are shown in Checkout.
+ """
+ payment_method_remove: NotRequired[Literal["disabled", "enabled"]]
+ """
+ Enable customers to choose if they wish to remove their saved payment methods. Disabled by default.
+ """
+ payment_method_save: NotRequired[Literal["disabled", "enabled"]]
+ """
+ Enable customers to choose if they wish to save their payment method for future use. Disabled by default.
+ """
+
+
+class SessionCreateParamsSetupIntentData(TypedDict):
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ on_behalf_of: NotRequired[str]
+ """
+ The Stripe account for which the setup is intended.
+ """
+
+
+class SessionCreateParamsShippingAddressCollection(TypedDict):
+ allowed_countries: List[
+ Literal[
+ "AC",
+ "AD",
+ "AE",
+ "AF",
+ "AG",
+ "AI",
+ "AL",
+ "AM",
+ "AO",
+ "AQ",
+ "AR",
+ "AT",
+ "AU",
+ "AW",
+ "AX",
+ "AZ",
+ "BA",
+ "BB",
+ "BD",
+ "BE",
+ "BF",
+ "BG",
+ "BH",
+ "BI",
+ "BJ",
+ "BL",
+ "BM",
+ "BN",
+ "BO",
+ "BQ",
+ "BR",
+ "BS",
+ "BT",
+ "BV",
+ "BW",
+ "BY",
+ "BZ",
+ "CA",
+ "CD",
+ "CF",
+ "CG",
+ "CH",
+ "CI",
+ "CK",
+ "CL",
+ "CM",
+ "CN",
+ "CO",
+ "CR",
+ "CV",
+ "CW",
+ "CY",
+ "CZ",
+ "DE",
+ "DJ",
+ "DK",
+ "DM",
+ "DO",
+ "DZ",
+ "EC",
+ "EE",
+ "EG",
+ "EH",
+ "ER",
+ "ES",
+ "ET",
+ "FI",
+ "FJ",
+ "FK",
+ "FO",
+ "FR",
+ "GA",
+ "GB",
+ "GD",
+ "GE",
+ "GF",
+ "GG",
+ "GH",
+ "GI",
+ "GL",
+ "GM",
+ "GN",
+ "GP",
+ "GQ",
+ "GR",
+ "GS",
+ "GT",
+ "GU",
+ "GW",
+ "GY",
+ "HK",
+ "HN",
+ "HR",
+ "HT",
+ "HU",
+ "ID",
+ "IE",
+ "IL",
+ "IM",
+ "IN",
+ "IO",
+ "IQ",
+ "IS",
+ "IT",
+ "JE",
+ "JM",
+ "JO",
+ "JP",
+ "KE",
+ "KG",
+ "KH",
+ "KI",
+ "KM",
+ "KN",
+ "KR",
+ "KW",
+ "KY",
+ "KZ",
+ "LA",
+ "LB",
+ "LC",
+ "LI",
+ "LK",
+ "LR",
+ "LS",
+ "LT",
+ "LU",
+ "LV",
+ "LY",
+ "MA",
+ "MC",
+ "MD",
+ "ME",
+ "MF",
+ "MG",
+ "MK",
+ "ML",
+ "MM",
+ "MN",
+ "MO",
+ "MQ",
+ "MR",
+ "MS",
+ "MT",
+ "MU",
+ "MV",
+ "MW",
+ "MX",
+ "MY",
+ "MZ",
+ "NA",
+ "NC",
+ "NE",
+ "NG",
+ "NI",
+ "NL",
+ "NO",
+ "NP",
+ "NR",
+ "NU",
+ "NZ",
+ "OM",
+ "PA",
+ "PE",
+ "PF",
+ "PG",
+ "PH",
+ "PK",
+ "PL",
+ "PM",
+ "PN",
+ "PR",
+ "PS",
+ "PT",
+ "PY",
+ "QA",
+ "RE",
+ "RO",
+ "RS",
+ "RU",
+ "RW",
+ "SA",
+ "SB",
+ "SC",
+ "SD",
+ "SE",
+ "SG",
+ "SH",
+ "SI",
+ "SJ",
+ "SK",
+ "SL",
+ "SM",
+ "SN",
+ "SO",
+ "SR",
+ "SS",
+ "ST",
+ "SV",
+ "SX",
+ "SZ",
+ "TA",
+ "TC",
+ "TD",
+ "TF",
+ "TG",
+ "TH",
+ "TJ",
+ "TK",
+ "TL",
+ "TM",
+ "TN",
+ "TO",
+ "TR",
+ "TT",
+ "TV",
+ "TW",
+ "TZ",
+ "UA",
+ "UG",
+ "US",
+ "UY",
+ "UZ",
+ "VA",
+ "VC",
+ "VE",
+ "VG",
+ "VN",
+ "VU",
+ "WF",
+ "WS",
+ "XK",
+ "YE",
+ "YT",
+ "ZA",
+ "ZM",
+ "ZW",
+ "ZZ",
+ ]
+ ]
+ """
+ An array of two-letter ISO country codes representing which countries Checkout should provide as options for
+ shipping locations.
+ """
+
+
+class SessionCreateParamsShippingOption(TypedDict):
+ shipping_rate: NotRequired[str]
+ """
+ The ID of the Shipping Rate to use for this shipping option.
+ """
+ shipping_rate_data: NotRequired[
+ "SessionCreateParamsShippingOptionShippingRateData"
+ ]
+ """
+ Parameters to be passed to Shipping Rate creation for this shipping option.
+ """
+
+
+class SessionCreateParamsShippingOptionShippingRateData(TypedDict):
+ delivery_estimate: NotRequired[
+ "SessionCreateParamsShippingOptionShippingRateDataDeliveryEstimate"
+ ]
+ """
+ The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
+ """
+ display_name: str
+ """
+ The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
+ """
+ fixed_amount: NotRequired[
+ "SessionCreateParamsShippingOptionShippingRateDataFixedAmount"
+ ]
+ """
+ Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
+ """
+ type: NotRequired[Literal["fixed_amount"]]
+ """
+ The type of calculation to use on the shipping rate.
+ """
+
+
+class SessionCreateParamsShippingOptionShippingRateDataDeliveryEstimate(
+ TypedDict,
+):
+ maximum: NotRequired[
+ "SessionCreateParamsShippingOptionShippingRateDataDeliveryEstimateMaximum"
+ ]
+ """
+ The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
+ """
+ minimum: NotRequired[
+ "SessionCreateParamsShippingOptionShippingRateDataDeliveryEstimateMinimum"
+ ]
+ """
+ The lower bound of the estimated range. If empty, represents no lower bound.
+ """
+
+
+class SessionCreateParamsShippingOptionShippingRateDataDeliveryEstimateMaximum(
+ TypedDict,
+):
+ unit: Literal["business_day", "day", "hour", "month", "week"]
+ """
+ A unit of time.
+ """
+ value: int
+ """
+ Must be greater than 0.
+ """
+
+
+class SessionCreateParamsShippingOptionShippingRateDataDeliveryEstimateMinimum(
+ TypedDict,
+):
+ unit: Literal["business_day", "day", "hour", "month", "week"]
+ """
+ A unit of time.
+ """
+ value: int
+ """
+ Must be greater than 0.
+ """
+
+
+class SessionCreateParamsShippingOptionShippingRateDataFixedAmount(TypedDict):
+ amount: int
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ currency_options: NotRequired[
+ Dict[
+ str,
+ "SessionCreateParamsShippingOptionShippingRateDataFixedAmountCurrencyOptions",
+ ]
+ ]
+ """
+ Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+
+
+class SessionCreateParamsShippingOptionShippingRateDataFixedAmountCurrencyOptions(
+ TypedDict,
+):
+ amount: int
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
+
+
+class SessionCreateParamsSubscriptionData(TypedDict):
+ application_fee_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. To use an application fee percent, the request must be made on behalf of another account, using the `Stripe-Account` header or an OAuth key. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
+ """
+ billing_cycle_anchor: NotRequired[int]
+ """
+ A future timestamp to anchor the subscription's billing cycle for new subscriptions.
+ """
+ billing_mode: NotRequired["SessionCreateParamsSubscriptionDataBillingMode"]
+ """
+ Controls how prorations and invoices for subscriptions are calculated and orchestrated.
+ """
+ default_tax_rates: NotRequired[List[str]]
+ """
+ The tax rates that will apply to any subscription item that does not have
+ `tax_rates` set. Invoices created will have their `default_tax_rates` populated
+ from the subscription.
+ """
+ description: NotRequired[str]
+ """
+ The subscription's description, meant to be displayable to the customer.
+ Use this field to optionally store an explanation of the subscription
+ for rendering in the [customer portal](https://stripe.com/docs/customer-management).
+ """
+ invoice_settings: NotRequired[
+ "SessionCreateParamsSubscriptionDataInvoiceSettings"
+ ]
+ """
+ All invoices will be billed using the specified settings.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ on_behalf_of: NotRequired[str]
+ """
+ The account on behalf of which to charge, for each of the subscription's invoices.
+ """
+ proration_behavior: NotRequired[Literal["create_prorations", "none"]]
+ """
+ Determines how to handle prorations resulting from the `billing_cycle_anchor`. If no value is passed, the default is `create_prorations`.
+ """
+ transfer_data: NotRequired[
+ "SessionCreateParamsSubscriptionDataTransferData"
+ ]
+ """
+ If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges.
+ """
+ trial_end: NotRequired[int]
+ """
+ Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. Has to be at least 48 hours in the future.
+ """
+ trial_period_days: NotRequired[int]
+ """
+ Integer representing the number of trial period days before the customer is charged for the first time. Has to be at least 1.
+ """
+ trial_settings: NotRequired[
+ "SessionCreateParamsSubscriptionDataTrialSettings"
+ ]
+ """
+ Settings related to subscription trials.
+ """
+
+
+class SessionCreateParamsSubscriptionDataBillingMode(TypedDict):
+ flexible: NotRequired[
+ "SessionCreateParamsSubscriptionDataBillingModeFlexible"
+ ]
+ """
+ Configure behavior for flexible billing mode.
+ """
+ type: Literal["classic", "flexible"]
+ """
+ Controls the calculation and orchestration of prorations and invoices for subscriptions. If no value is passed, the default is `flexible`.
+ """
+
+
+class SessionCreateParamsSubscriptionDataBillingModeFlexible(TypedDict):
+ proration_discounts: NotRequired[Literal["included", "itemized"]]
+ """
+ Controls how invoices and invoice items display proration amounts and discount amounts.
+ """
+
+
+class SessionCreateParamsSubscriptionDataInvoiceSettings(TypedDict):
+ issuer: NotRequired[
+ "SessionCreateParamsSubscriptionDataInvoiceSettingsIssuer"
+ ]
+ """
+ The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
+ """
+
+
+class SessionCreateParamsSubscriptionDataInvoiceSettingsIssuer(TypedDict):
+ account: NotRequired[str]
+ """
+ The connected account being referenced when `type` is `account`.
+ """
+ type: Literal["account", "self"]
+ """
+ Type of the account referenced in the request.
+ """
+
+
+class SessionCreateParamsSubscriptionDataTransferData(TypedDict):
+ amount_percent: NotRequired[float]
+ """
+ A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
+ """
+ destination: str
+ """
+ ID of an existing, connected Stripe account.
+ """
+
+
+class SessionCreateParamsSubscriptionDataTrialSettings(TypedDict):
+ end_behavior: "SessionCreateParamsSubscriptionDataTrialSettingsEndBehavior"
+ """
+ Defines how the subscription should behave when the user's free trial ends.
+ """
+
+
+class SessionCreateParamsSubscriptionDataTrialSettingsEndBehavior(TypedDict):
+ missing_payment_method: Literal["cancel", "create_invoice", "pause"]
+ """
+ Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
+ """
+
+
+class SessionCreateParamsTaxIdCollection(TypedDict):
+ enabled: bool
+ """
+ Enable tax ID collection during checkout. Defaults to `false`.
+ """
+ required: NotRequired[Literal["if_supported", "never"]]
+ """
+ Describes whether a tax ID is required during checkout. Defaults to `never`.
+ """
+
+
+class SessionCreateParamsWalletOptions(TypedDict):
+ link: NotRequired["SessionCreateParamsWalletOptionsLink"]
+ """
+ contains details about the Link wallet options.
+ """
+
+
+class SessionCreateParamsWalletOptionsLink(TypedDict):
+ display: NotRequired[Literal["auto", "never"]]
+ """
+ Specifies whether Checkout should display Link as a payment option. By default, Checkout will display all the supported wallets that the Checkout Session was created with. This is the `auto` behavior, and it is the default choice.
+ """
diff --git a/stripe/params/checkout/_session_expire_params.py b/stripe/params/checkout/_session_expire_params.py
new file mode 100644
index 000000000..090460b1b
--- /dev/null
+++ b/stripe/params/checkout/_session_expire_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SessionExpireParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/checkout/_session_line_item_list_params.py b/stripe/params/checkout/_session_line_item_list_params.py
new file mode 100644
index 000000000..29666f0c4
--- /dev/null
+++ b/stripe/params/checkout/_session_line_item_list_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class SessionLineItemListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/checkout/_session_list_line_items_params.py b/stripe/params/checkout/_session_list_line_items_params.py
new file mode 100644
index 000000000..35895af27
--- /dev/null
+++ b/stripe/params/checkout/_session_list_line_items_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SessionListLineItemsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/checkout/_session_list_params.py b/stripe/params/checkout/_session_list_params.py
new file mode 100644
index 000000000..cf2a77104
--- /dev/null
+++ b/stripe/params/checkout/_session_list_params.py
@@ -0,0 +1,78 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SessionListParams(RequestOptions):
+ created: NotRequired["SessionListParamsCreated|int"]
+ """
+ Only return Checkout Sessions that were created during the given date interval.
+ """
+ customer: NotRequired[str]
+ """
+ Only return the Checkout Sessions for the Customer specified.
+ """
+ customer_details: NotRequired["SessionListParamsCustomerDetails"]
+ """
+ Only return the Checkout Sessions for the Customer details specified.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ payment_intent: NotRequired[str]
+ """
+ Only return the Checkout Session for the PaymentIntent specified.
+ """
+ payment_link: NotRequired[str]
+ """
+ Only return the Checkout Sessions for the Payment Link specified.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["complete", "expired", "open"]]
+ """
+ Only return the Checkout Sessions matching the given status.
+ """
+ subscription: NotRequired[str]
+ """
+ Only return the Checkout Session for the subscription specified.
+ """
+
+
+class SessionListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
+
+
+class SessionListParamsCustomerDetails(TypedDict):
+ email: str
+ """
+ Customer's email address.
+ """
diff --git a/stripe/params/checkout/_session_modify_params.py b/stripe/params/checkout/_session_modify_params.py
new file mode 100644
index 000000000..8a9fd9036
--- /dev/null
+++ b/stripe/params/checkout/_session_modify_params.py
@@ -0,0 +1,199 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SessionModifyParams(RequestOptions):
+ collected_information: NotRequired[
+ "SessionModifyParamsCollectedInformation"
+ ]
+ """
+ Information about the customer collected within the Checkout Session. Can only be set when updating `embedded` or `custom` sessions.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ shipping_options: NotRequired[
+ "Literal['']|List[SessionModifyParamsShippingOption]"
+ ]
+ """
+ The shipping rate options to apply to this Session. Up to a maximum of 5.
+ """
+
+
+class SessionModifyParamsCollectedInformation(TypedDict):
+ shipping_details: NotRequired[
+ "SessionModifyParamsCollectedInformationShippingDetails"
+ ]
+ """
+ The shipping details to apply to this Session.
+ """
+
+
+class SessionModifyParamsCollectedInformationShippingDetails(TypedDict):
+ address: "SessionModifyParamsCollectedInformationShippingDetailsAddress"
+ """
+ The address of the customer
+ """
+ name: str
+ """
+ The name of customer
+ """
+
+
+class SessionModifyParamsCollectedInformationShippingDetailsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: str
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: str
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class SessionModifyParamsShippingOption(TypedDict):
+ shipping_rate: NotRequired[str]
+ """
+ The ID of the Shipping Rate to use for this shipping option.
+ """
+ shipping_rate_data: NotRequired[
+ "SessionModifyParamsShippingOptionShippingRateData"
+ ]
+ """
+ Parameters to be passed to Shipping Rate creation for this shipping option.
+ """
+
+
+class SessionModifyParamsShippingOptionShippingRateData(TypedDict):
+ delivery_estimate: NotRequired[
+ "SessionModifyParamsShippingOptionShippingRateDataDeliveryEstimate"
+ ]
+ """
+ The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
+ """
+ display_name: str
+ """
+ The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
+ """
+ fixed_amount: NotRequired[
+ "SessionModifyParamsShippingOptionShippingRateDataFixedAmount"
+ ]
+ """
+ Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
+ """
+ type: NotRequired[Literal["fixed_amount"]]
+ """
+ The type of calculation to use on the shipping rate.
+ """
+
+
+class SessionModifyParamsShippingOptionShippingRateDataDeliveryEstimate(
+ TypedDict,
+):
+ maximum: NotRequired[
+ "SessionModifyParamsShippingOptionShippingRateDataDeliveryEstimateMaximum"
+ ]
+ """
+ The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
+ """
+ minimum: NotRequired[
+ "SessionModifyParamsShippingOptionShippingRateDataDeliveryEstimateMinimum"
+ ]
+ """
+ The lower bound of the estimated range. If empty, represents no lower bound.
+ """
+
+
+class SessionModifyParamsShippingOptionShippingRateDataDeliveryEstimateMaximum(
+ TypedDict,
+):
+ unit: Literal["business_day", "day", "hour", "month", "week"]
+ """
+ A unit of time.
+ """
+ value: int
+ """
+ Must be greater than 0.
+ """
+
+
+class SessionModifyParamsShippingOptionShippingRateDataDeliveryEstimateMinimum(
+ TypedDict,
+):
+ unit: Literal["business_day", "day", "hour", "month", "week"]
+ """
+ A unit of time.
+ """
+ value: int
+ """
+ Must be greater than 0.
+ """
+
+
+class SessionModifyParamsShippingOptionShippingRateDataFixedAmount(TypedDict):
+ amount: int
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ currency_options: NotRequired[
+ Dict[
+ str,
+ "SessionModifyParamsShippingOptionShippingRateDataFixedAmountCurrencyOptions",
+ ]
+ ]
+ """
+ Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+
+
+class SessionModifyParamsShippingOptionShippingRateDataFixedAmountCurrencyOptions(
+ TypedDict,
+):
+ amount: int
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
diff --git a/stripe/params/checkout/_session_retrieve_params.py b/stripe/params/checkout/_session_retrieve_params.py
new file mode 100644
index 000000000..fc641db91
--- /dev/null
+++ b/stripe/params/checkout/_session_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SessionRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/checkout/_session_update_params.py b/stripe/params/checkout/_session_update_params.py
new file mode 100644
index 000000000..2b7109590
--- /dev/null
+++ b/stripe/params/checkout/_session_update_params.py
@@ -0,0 +1,198 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SessionUpdateParams(TypedDict):
+ collected_information: NotRequired[
+ "SessionUpdateParamsCollectedInformation"
+ ]
+ """
+ Information about the customer collected within the Checkout Session. Can only be set when updating `embedded` or `custom` sessions.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ shipping_options: NotRequired[
+ "Literal['']|List[SessionUpdateParamsShippingOption]"
+ ]
+ """
+ The shipping rate options to apply to this Session. Up to a maximum of 5.
+ """
+
+
+class SessionUpdateParamsCollectedInformation(TypedDict):
+ shipping_details: NotRequired[
+ "SessionUpdateParamsCollectedInformationShippingDetails"
+ ]
+ """
+ The shipping details to apply to this Session.
+ """
+
+
+class SessionUpdateParamsCollectedInformationShippingDetails(TypedDict):
+ address: "SessionUpdateParamsCollectedInformationShippingDetailsAddress"
+ """
+ The address of the customer
+ """
+ name: str
+ """
+ The name of customer
+ """
+
+
+class SessionUpdateParamsCollectedInformationShippingDetailsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: str
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: str
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class SessionUpdateParamsShippingOption(TypedDict):
+ shipping_rate: NotRequired[str]
+ """
+ The ID of the Shipping Rate to use for this shipping option.
+ """
+ shipping_rate_data: NotRequired[
+ "SessionUpdateParamsShippingOptionShippingRateData"
+ ]
+ """
+ Parameters to be passed to Shipping Rate creation for this shipping option.
+ """
+
+
+class SessionUpdateParamsShippingOptionShippingRateData(TypedDict):
+ delivery_estimate: NotRequired[
+ "SessionUpdateParamsShippingOptionShippingRateDataDeliveryEstimate"
+ ]
+ """
+ The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
+ """
+ display_name: str
+ """
+ The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
+ """
+ fixed_amount: NotRequired[
+ "SessionUpdateParamsShippingOptionShippingRateDataFixedAmount"
+ ]
+ """
+ Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
+ """
+ type: NotRequired[Literal["fixed_amount"]]
+ """
+ The type of calculation to use on the shipping rate.
+ """
+
+
+class SessionUpdateParamsShippingOptionShippingRateDataDeliveryEstimate(
+ TypedDict,
+):
+ maximum: NotRequired[
+ "SessionUpdateParamsShippingOptionShippingRateDataDeliveryEstimateMaximum"
+ ]
+ """
+ The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
+ """
+ minimum: NotRequired[
+ "SessionUpdateParamsShippingOptionShippingRateDataDeliveryEstimateMinimum"
+ ]
+ """
+ The lower bound of the estimated range. If empty, represents no lower bound.
+ """
+
+
+class SessionUpdateParamsShippingOptionShippingRateDataDeliveryEstimateMaximum(
+ TypedDict,
+):
+ unit: Literal["business_day", "day", "hour", "month", "week"]
+ """
+ A unit of time.
+ """
+ value: int
+ """
+ Must be greater than 0.
+ """
+
+
+class SessionUpdateParamsShippingOptionShippingRateDataDeliveryEstimateMinimum(
+ TypedDict,
+):
+ unit: Literal["business_day", "day", "hour", "month", "week"]
+ """
+ A unit of time.
+ """
+ value: int
+ """
+ Must be greater than 0.
+ """
+
+
+class SessionUpdateParamsShippingOptionShippingRateDataFixedAmount(TypedDict):
+ amount: int
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ currency_options: NotRequired[
+ Dict[
+ str,
+ "SessionUpdateParamsShippingOptionShippingRateDataFixedAmountCurrencyOptions",
+ ]
+ ]
+ """
+ Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
+ """
+
+
+class SessionUpdateParamsShippingOptionShippingRateDataFixedAmountCurrencyOptions(
+ TypedDict,
+):
+ amount: int
+ """
+ A non-negative integer in cents representing how much to charge.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive", "unspecified"]]
+ """
+ Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
+ """
diff --git a/stripe/params/climate/__init__.py b/stripe/params/climate/__init__.py
new file mode 100644
index 000000000..fcdc03421
--- /dev/null
+++ b/stripe/params/climate/__init__.py
@@ -0,0 +1,32 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.climate._order_cancel_params import (
+ OrderCancelParams as OrderCancelParams,
+)
+from stripe.params.climate._order_create_params import (
+ OrderCreateParams as OrderCreateParams,
+)
+from stripe.params.climate._order_list_params import (
+ OrderListParams as OrderListParams,
+)
+from stripe.params.climate._order_modify_params import (
+ OrderModifyParams as OrderModifyParams,
+)
+from stripe.params.climate._order_retrieve_params import (
+ OrderRetrieveParams as OrderRetrieveParams,
+)
+from stripe.params.climate._order_update_params import (
+ OrderUpdateParams as OrderUpdateParams,
+)
+from stripe.params.climate._product_list_params import (
+ ProductListParams as ProductListParams,
+)
+from stripe.params.climate._product_retrieve_params import (
+ ProductRetrieveParams as ProductRetrieveParams,
+)
+from stripe.params.climate._supplier_list_params import (
+ SupplierListParams as SupplierListParams,
+)
+from stripe.params.climate._supplier_retrieve_params import (
+ SupplierRetrieveParams as SupplierRetrieveParams,
+)
diff --git a/stripe/params/climate/_order_cancel_params.py b/stripe/params/climate/_order_cancel_params.py
new file mode 100644
index 000000000..ba99988d5
--- /dev/null
+++ b/stripe/params/climate/_order_cancel_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class OrderCancelParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/climate/_order_create_params.py b/stripe/params/climate/_order_create_params.py
new file mode 100644
index 000000000..45ca42955
--- /dev/null
+++ b/stripe/params/climate/_order_create_params.py
@@ -0,0 +1,43 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import NotRequired, TypedDict
+
+
+class OrderCreateParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ Requested amount of carbon removal units. Either this or `metric_tons` must be specified.
+ """
+ beneficiary: NotRequired["OrderCreateParamsBeneficiary"]
+ """
+ Publicly sharable reference for the end beneficiary of carbon removal. Assumed to be the Stripe account if not set.
+ """
+ currency: NotRequired[str]
+ """
+ Request currency for the order as a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a supported [settlement currency for your account](https://stripe.com/docs/currencies). If omitted, the account's default currency will be used.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ metric_tons: NotRequired[str]
+ """
+ Requested number of tons for the order. Either this or `amount` must be specified.
+ """
+ product: str
+ """
+ Unique identifier of the Climate product.
+ """
+
+
+class OrderCreateParamsBeneficiary(TypedDict):
+ public_name: str
+ """
+ Publicly displayable name for the end beneficiary of carbon removal.
+ """
diff --git a/stripe/params/climate/_order_list_params.py b/stripe/params/climate/_order_list_params.py
new file mode 100644
index 000000000..c17bfa64f
--- /dev/null
+++ b/stripe/params/climate/_order_list_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class OrderListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/climate/_order_modify_params.py b/stripe/params/climate/_order_modify_params.py
new file mode 100644
index 000000000..af4371473
--- /dev/null
+++ b/stripe/params/climate/_order_modify_params.py
@@ -0,0 +1,27 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List, Union
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class OrderModifyParams(RequestOptions):
+ beneficiary: NotRequired["Literal['']|OrderModifyParamsBeneficiary"]
+ """
+ Publicly sharable reference for the end beneficiary of carbon removal. Assumed to be the Stripe account if not set.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+
+
+class OrderModifyParamsBeneficiary(TypedDict):
+ public_name: Union[Literal[""], str]
+ """
+ Publicly displayable name for the end beneficiary of carbon removal.
+ """
diff --git a/stripe/params/climate/_order_retrieve_params.py b/stripe/params/climate/_order_retrieve_params.py
new file mode 100644
index 000000000..9364635f9
--- /dev/null
+++ b/stripe/params/climate/_order_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class OrderRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/climate/_order_update_params.py b/stripe/params/climate/_order_update_params.py
new file mode 100644
index 000000000..05a947f03
--- /dev/null
+++ b/stripe/params/climate/_order_update_params.py
@@ -0,0 +1,26 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List, Union
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class OrderUpdateParams(TypedDict):
+ beneficiary: NotRequired["Literal['']|OrderUpdateParamsBeneficiary"]
+ """
+ Publicly sharable reference for the end beneficiary of carbon removal. Assumed to be the Stripe account if not set.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+
+
+class OrderUpdateParamsBeneficiary(TypedDict):
+ public_name: Union[Literal[""], str]
+ """
+ Publicly displayable name for the end beneficiary of carbon removal.
+ """
diff --git a/stripe/params/climate/_product_list_params.py b/stripe/params/climate/_product_list_params.py
new file mode 100644
index 000000000..504998abe
--- /dev/null
+++ b/stripe/params/climate/_product_list_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ProductListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/climate/_product_retrieve_params.py b/stripe/params/climate/_product_retrieve_params.py
new file mode 100644
index 000000000..c9cc1bd6b
--- /dev/null
+++ b/stripe/params/climate/_product_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ProductRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/climate/_supplier_list_params.py b/stripe/params/climate/_supplier_list_params.py
new file mode 100644
index 000000000..93e5b97aa
--- /dev/null
+++ b/stripe/params/climate/_supplier_list_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SupplierListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/climate/_supplier_retrieve_params.py b/stripe/params/climate/_supplier_retrieve_params.py
new file mode 100644
index 000000000..262e8b954
--- /dev/null
+++ b/stripe/params/climate/_supplier_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SupplierRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/entitlements/__init__.py b/stripe/params/entitlements/__init__.py
new file mode 100644
index 000000000..c6c7ad3c5
--- /dev/null
+++ b/stripe/params/entitlements/__init__.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.entitlements._active_entitlement_list_params import (
+ ActiveEntitlementListParams as ActiveEntitlementListParams,
+)
+from stripe.params.entitlements._active_entitlement_retrieve_params import (
+ ActiveEntitlementRetrieveParams as ActiveEntitlementRetrieveParams,
+)
+from stripe.params.entitlements._feature_create_params import (
+ FeatureCreateParams as FeatureCreateParams,
+)
+from stripe.params.entitlements._feature_list_params import (
+ FeatureListParams as FeatureListParams,
+)
+from stripe.params.entitlements._feature_modify_params import (
+ FeatureModifyParams as FeatureModifyParams,
+)
+from stripe.params.entitlements._feature_retrieve_params import (
+ FeatureRetrieveParams as FeatureRetrieveParams,
+)
+from stripe.params.entitlements._feature_update_params import (
+ FeatureUpdateParams as FeatureUpdateParams,
+)
diff --git a/stripe/params/entitlements/_active_entitlement_list_params.py b/stripe/params/entitlements/_active_entitlement_list_params.py
new file mode 100644
index 000000000..0964edb0a
--- /dev/null
+++ b/stripe/params/entitlements/_active_entitlement_list_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ActiveEntitlementListParams(RequestOptions):
+ customer: str
+ """
+ The ID of the customer.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/entitlements/_active_entitlement_retrieve_params.py b/stripe/params/entitlements/_active_entitlement_retrieve_params.py
new file mode 100644
index 000000000..c8d0020ed
--- /dev/null
+++ b/stripe/params/entitlements/_active_entitlement_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ActiveEntitlementRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/entitlements/_feature_create_params.py b/stripe/params/entitlements/_feature_create_params.py
new file mode 100644
index 000000000..58338e5f4
--- /dev/null
+++ b/stripe/params/entitlements/_feature_create_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import NotRequired
+
+
+class FeatureCreateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ lookup_key: str
+ """
+ A unique key you provide as your own system identifier. This may be up to 80 characters.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
+ """
+ name: str
+ """
+ The feature's name, for your own purpose, not meant to be displayable to the customer.
+ """
diff --git a/stripe/params/entitlements/_feature_list_params.py b/stripe/params/entitlements/_feature_list_params.py
new file mode 100644
index 000000000..d57a686c2
--- /dev/null
+++ b/stripe/params/entitlements/_feature_list_params.py
@@ -0,0 +1,32 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class FeatureListParams(RequestOptions):
+ archived: NotRequired[bool]
+ """
+ If set, filter results to only include features with the given archive status.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ lookup_key: NotRequired[str]
+ """
+ If set, filter results to only include features with the given lookup_key.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/entitlements/_feature_modify_params.py b/stripe/params/entitlements/_feature_modify_params.py
new file mode 100644
index 000000000..59158e75d
--- /dev/null
+++ b/stripe/params/entitlements/_feature_modify_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class FeatureModifyParams(RequestOptions):
+ active: NotRequired[bool]
+ """
+ Inactive features cannot be attached to new products and will not be returned from the features list endpoint.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
+ """
+ name: NotRequired[str]
+ """
+ The feature's name, for your own purpose, not meant to be displayable to the customer.
+ """
diff --git a/stripe/params/entitlements/_feature_retrieve_params.py b/stripe/params/entitlements/_feature_retrieve_params.py
new file mode 100644
index 000000000..5933235c2
--- /dev/null
+++ b/stripe/params/entitlements/_feature_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class FeatureRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/entitlements/_feature_update_params.py b/stripe/params/entitlements/_feature_update_params.py
new file mode 100644
index 000000000..cbc29b19a
--- /dev/null
+++ b/stripe/params/entitlements/_feature_update_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class FeatureUpdateParams(TypedDict):
+ active: NotRequired[bool]
+ """
+ Inactive features cannot be attached to new products and will not be returned from the features list endpoint.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
+ """
+ name: NotRequired[str]
+ """
+ The feature's name, for your own purpose, not meant to be displayable to the customer.
+ """
diff --git a/stripe/params/financial_connections/__init__.py b/stripe/params/financial_connections/__init__.py
new file mode 100644
index 000000000..dfc6f2c64
--- /dev/null
+++ b/stripe/params/financial_connections/__init__.py
@@ -0,0 +1,41 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.financial_connections._account_disconnect_params import (
+ AccountDisconnectParams as AccountDisconnectParams,
+)
+from stripe.params.financial_connections._account_list_owners_params import (
+ AccountListOwnersParams as AccountListOwnersParams,
+)
+from stripe.params.financial_connections._account_list_params import (
+ AccountListParams as AccountListParams,
+)
+from stripe.params.financial_connections._account_owner_list_params import (
+ AccountOwnerListParams as AccountOwnerListParams,
+)
+from stripe.params.financial_connections._account_refresh_account_params import (
+ AccountRefreshAccountParams as AccountRefreshAccountParams,
+)
+from stripe.params.financial_connections._account_refresh_params import (
+ AccountRefreshParams as AccountRefreshParams,
+)
+from stripe.params.financial_connections._account_retrieve_params import (
+ AccountRetrieveParams as AccountRetrieveParams,
+)
+from stripe.params.financial_connections._account_subscribe_params import (
+ AccountSubscribeParams as AccountSubscribeParams,
+)
+from stripe.params.financial_connections._account_unsubscribe_params import (
+ AccountUnsubscribeParams as AccountUnsubscribeParams,
+)
+from stripe.params.financial_connections._session_create_params import (
+ SessionCreateParams as SessionCreateParams,
+)
+from stripe.params.financial_connections._session_retrieve_params import (
+ SessionRetrieveParams as SessionRetrieveParams,
+)
+from stripe.params.financial_connections._transaction_list_params import (
+ TransactionListParams as TransactionListParams,
+)
+from stripe.params.financial_connections._transaction_retrieve_params import (
+ TransactionRetrieveParams as TransactionRetrieveParams,
+)
diff --git a/stripe/params/financial_connections/_account_disconnect_params.py b/stripe/params/financial_connections/_account_disconnect_params.py
new file mode 100644
index 000000000..45ca66ce0
--- /dev/null
+++ b/stripe/params/financial_connections/_account_disconnect_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AccountDisconnectParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/financial_connections/_account_list_owners_params.py b/stripe/params/financial_connections/_account_list_owners_params.py
new file mode 100644
index 000000000..a185d56c2
--- /dev/null
+++ b/stripe/params/financial_connections/_account_list_owners_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AccountListOwnersParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ ownership: str
+ """
+ The ID of the ownership object to fetch owners from.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/financial_connections/_account_list_params.py b/stripe/params/financial_connections/_account_list_params.py
new file mode 100644
index 000000000..d87f6b106
--- /dev/null
+++ b/stripe/params/financial_connections/_account_list_params.py
@@ -0,0 +1,43 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AccountListParams(RequestOptions):
+ account_holder: NotRequired["AccountListParamsAccountHolder"]
+ """
+ If present, only return accounts that belong to the specified account holder. `account_holder[customer]` and `account_holder[account]` are mutually exclusive.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ session: NotRequired[str]
+ """
+ If present, only return accounts that were collected as part of the given session.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class AccountListParamsAccountHolder(TypedDict):
+ account: NotRequired[str]
+ """
+ The ID of the Stripe account whose accounts will be retrieved.
+ """
+ customer: NotRequired[str]
+ """
+ The ID of the Stripe customer whose accounts will be retrieved.
+ """
diff --git a/stripe/params/financial_connections/_account_owner_list_params.py b/stripe/params/financial_connections/_account_owner_list_params.py
new file mode 100644
index 000000000..d2ea5e2f1
--- /dev/null
+++ b/stripe/params/financial_connections/_account_owner_list_params.py
@@ -0,0 +1,27 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AccountOwnerListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ ownership: str
+ """
+ The ID of the ownership object to fetch owners from.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/financial_connections/_account_refresh_account_params.py b/stripe/params/financial_connections/_account_refresh_account_params.py
new file mode 100644
index 000000000..578ef3c4b
--- /dev/null
+++ b/stripe/params/financial_connections/_account_refresh_account_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class AccountRefreshAccountParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ features: List[Literal["balance", "ownership", "transactions"]]
+ """
+ The list of account features that you would like to refresh.
+ """
diff --git a/stripe/params/financial_connections/_account_refresh_params.py b/stripe/params/financial_connections/_account_refresh_params.py
new file mode 100644
index 000000000..7ca98edde
--- /dev/null
+++ b/stripe/params/financial_connections/_account_refresh_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AccountRefreshParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ features: List[Literal["balance", "ownership", "transactions"]]
+ """
+ The list of account features that you would like to refresh.
+ """
diff --git a/stripe/params/financial_connections/_account_retrieve_params.py b/stripe/params/financial_connections/_account_retrieve_params.py
new file mode 100644
index 000000000..02d5a379c
--- /dev/null
+++ b/stripe/params/financial_connections/_account_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AccountRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/financial_connections/_account_subscribe_params.py b/stripe/params/financial_connections/_account_subscribe_params.py
new file mode 100644
index 000000000..b6ac1c02e
--- /dev/null
+++ b/stripe/params/financial_connections/_account_subscribe_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class AccountSubscribeParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ features: List[Literal["transactions"]]
+ """
+ The list of account features to which you would like to subscribe.
+ """
diff --git a/stripe/params/financial_connections/_account_unsubscribe_params.py b/stripe/params/financial_connections/_account_unsubscribe_params.py
new file mode 100644
index 000000000..98cc488d8
--- /dev/null
+++ b/stripe/params/financial_connections/_account_unsubscribe_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class AccountUnsubscribeParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ features: List[Literal["transactions"]]
+ """
+ The list of account features from which you would like to unsubscribe.
+ """
diff --git a/stripe/params/financial_connections/_session_create_params.py b/stripe/params/financial_connections/_session_create_params.py
new file mode 100644
index 000000000..e1dfd3660
--- /dev/null
+++ b/stripe/params/financial_connections/_session_create_params.py
@@ -0,0 +1,74 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SessionCreateParams(RequestOptions):
+ account_holder: "SessionCreateParamsAccountHolder"
+ """
+ The account holder to link accounts for.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ filters: NotRequired["SessionCreateParamsFilters"]
+ """
+ Filters to restrict the kinds of accounts to collect.
+ """
+ permissions: List[
+ Literal["balances", "ownership", "payment_method", "transactions"]
+ ]
+ """
+ List of data features that you would like to request access to.
+
+ Possible values are `balances`, `transactions`, `ownership`, and `payment_method`.
+ """
+ prefetch: NotRequired[
+ List[Literal["balances", "ownership", "transactions"]]
+ ]
+ """
+ List of data features that you would like to retrieve upon account creation.
+ """
+ return_url: NotRequired[str]
+ """
+ For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
+ """
+
+
+class SessionCreateParamsAccountHolder(TypedDict):
+ account: NotRequired[str]
+ """
+ The ID of the Stripe account whose accounts will be retrieved. Should only be present if `type` is `account`.
+ """
+ customer: NotRequired[str]
+ """
+ The ID of the Stripe customer whose accounts will be retrieved. Should only be present if `type` is `customer`.
+ """
+ type: Literal["account", "customer"]
+ """
+ Type of account holder to collect accounts for.
+ """
+
+
+class SessionCreateParamsFilters(TypedDict):
+ account_subcategories: NotRequired[
+ List[
+ Literal[
+ "checking",
+ "credit_card",
+ "line_of_credit",
+ "mortgage",
+ "savings",
+ ]
+ ]
+ ]
+ """
+ Restricts the Session to subcategories of accounts that can be linked. Valid subcategories are: `checking`, `savings`, `mortgage`, `line_of_credit`, `credit_card`.
+ """
+ countries: NotRequired[List[str]]
+ """
+ List of countries from which to collect accounts.
+ """
diff --git a/stripe/params/financial_connections/_session_retrieve_params.py b/stripe/params/financial_connections/_session_retrieve_params.py
new file mode 100644
index 000000000..fc641db91
--- /dev/null
+++ b/stripe/params/financial_connections/_session_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SessionRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/financial_connections/_transaction_list_params.py b/stripe/params/financial_connections/_transaction_list_params.py
new file mode 100644
index 000000000..3290ec94c
--- /dev/null
+++ b/stripe/params/financial_connections/_transaction_list_params.py
@@ -0,0 +1,62 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class TransactionListParams(RequestOptions):
+ account: str
+ """
+ The ID of the Financial Connections Account whose transactions will be retrieved.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ transacted_at: NotRequired["TransactionListParamsTransactedAt|int"]
+ """
+ A filter on the list based on the object `transacted_at` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with the following options:
+ """
+ transaction_refresh: NotRequired["TransactionListParamsTransactionRefresh"]
+ """
+ A filter on the list based on the object `transaction_refresh` field. The value can be a dictionary with the following options:
+ """
+
+
+class TransactionListParamsTransactedAt(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
+
+
+class TransactionListParamsTransactionRefresh(TypedDict):
+ after: str
+ """
+ Return results where the transactions were created or updated by a refresh that took place after this refresh (non-inclusive).
+ """
diff --git a/stripe/params/financial_connections/_transaction_retrieve_params.py b/stripe/params/financial_connections/_transaction_retrieve_params.py
new file mode 100644
index 000000000..07744dd96
--- /dev/null
+++ b/stripe/params/financial_connections/_transaction_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TransactionRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/forwarding/__init__.py b/stripe/params/forwarding/__init__.py
new file mode 100644
index 000000000..e12bd9cee
--- /dev/null
+++ b/stripe/params/forwarding/__init__.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.forwarding._request_create_params import (
+ RequestCreateParams as RequestCreateParams,
+)
+from stripe.params.forwarding._request_list_params import (
+ RequestListParams as RequestListParams,
+)
+from stripe.params.forwarding._request_retrieve_params import (
+ RequestRetrieveParams as RequestRetrieveParams,
+)
diff --git a/stripe/params/forwarding/_request_create_params.py b/stripe/params/forwarding/_request_create_params.py
new file mode 100644
index 000000000..e35ebfc51
--- /dev/null
+++ b/stripe/params/forwarding/_request_create_params.py
@@ -0,0 +1,62 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class RequestCreateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ payment_method: str
+ """
+ The PaymentMethod to insert into the forwarded request. Forwarding previously consumed PaymentMethods is allowed.
+ """
+ replacements: List[
+ Literal[
+ "card_cvc",
+ "card_expiry",
+ "card_number",
+ "cardholder_name",
+ "request_signature",
+ ]
+ ]
+ """
+ The field kinds to be replaced in the forwarded request.
+ """
+ request: "RequestCreateParamsRequest"
+ """
+ The request body and headers to be sent to the destination endpoint.
+ """
+ url: str
+ """
+ The destination URL for the forwarded request. Must be supported by the config.
+ """
+
+
+class RequestCreateParamsRequest(TypedDict):
+ body: NotRequired[str]
+ """
+ The body payload to send to the destination endpoint.
+ """
+ headers: NotRequired[List["RequestCreateParamsRequestHeader"]]
+ """
+ The headers to include in the forwarded request. Can be omitted if no additional headers (excluding Stripe-generated ones such as the Content-Type header) should be included.
+ """
+
+
+class RequestCreateParamsRequestHeader(TypedDict):
+ name: str
+ """
+ The header name.
+ """
+ value: str
+ """
+ The header value.
+ """
diff --git a/stripe/params/forwarding/_request_list_params.py b/stripe/params/forwarding/_request_list_params.py
new file mode 100644
index 000000000..6c79d6318
--- /dev/null
+++ b/stripe/params/forwarding/_request_list_params.py
@@ -0,0 +1,47 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class RequestListParams(RequestOptions):
+ created: NotRequired["RequestListParamsCreated"]
+ """
+ Similar to other List endpoints, filters results based on created timestamp. You can pass gt, gte, lt, and lte timestamp values.
+ """
+ ending_before: NotRequired[str]
+ """
+ A pagination cursor to fetch the previous page of the list. The value must be a ForwardingRequest ID.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A pagination cursor to fetch the next page of the list. The value must be a ForwardingRequest ID.
+ """
+
+
+class RequestListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Return results where the `created` field is greater than this value.
+ """
+ gte: NotRequired[int]
+ """
+ Return results where the `created` field is greater than or equal to this value.
+ """
+ lt: NotRequired[int]
+ """
+ Return results where the `created` field is less than this value.
+ """
+ lte: NotRequired[int]
+ """
+ Return results where the `created` field is less than or equal to this value.
+ """
diff --git a/stripe/params/forwarding/_request_retrieve_params.py b/stripe/params/forwarding/_request_retrieve_params.py
new file mode 100644
index 000000000..988b7d6a4
--- /dev/null
+++ b/stripe/params/forwarding/_request_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class RequestRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/identity/__init__.py b/stripe/params/identity/__init__.py
new file mode 100644
index 000000000..2ba55f00f
--- /dev/null
+++ b/stripe/params/identity/__init__.py
@@ -0,0 +1,29 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.identity._verification_report_list_params import (
+ VerificationReportListParams as VerificationReportListParams,
+)
+from stripe.params.identity._verification_report_retrieve_params import (
+ VerificationReportRetrieveParams as VerificationReportRetrieveParams,
+)
+from stripe.params.identity._verification_session_cancel_params import (
+ VerificationSessionCancelParams as VerificationSessionCancelParams,
+)
+from stripe.params.identity._verification_session_create_params import (
+ VerificationSessionCreateParams as VerificationSessionCreateParams,
+)
+from stripe.params.identity._verification_session_list_params import (
+ VerificationSessionListParams as VerificationSessionListParams,
+)
+from stripe.params.identity._verification_session_modify_params import (
+ VerificationSessionModifyParams as VerificationSessionModifyParams,
+)
+from stripe.params.identity._verification_session_redact_params import (
+ VerificationSessionRedactParams as VerificationSessionRedactParams,
+)
+from stripe.params.identity._verification_session_retrieve_params import (
+ VerificationSessionRetrieveParams as VerificationSessionRetrieveParams,
+)
+from stripe.params.identity._verification_session_update_params import (
+ VerificationSessionUpdateParams as VerificationSessionUpdateParams,
+)
diff --git a/stripe/params/identity/_verification_report_list_params.py b/stripe/params/identity/_verification_report_list_params.py
new file mode 100644
index 000000000..e02d3b364
--- /dev/null
+++ b/stripe/params/identity/_verification_report_list_params.py
@@ -0,0 +1,59 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class VerificationReportListParams(RequestOptions):
+ client_reference_id: NotRequired[str]
+ """
+ A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
+ """
+ created: NotRequired["VerificationReportListParamsCreated|int"]
+ """
+ Only return VerificationReports that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ type: NotRequired[Literal["document", "id_number"]]
+ """
+ Only return VerificationReports of this type
+ """
+ verification_session: NotRequired[str]
+ """
+ Only return VerificationReports created by this VerificationSession ID. It is allowed to provide a VerificationIntent ID.
+ """
+
+
+class VerificationReportListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/identity/_verification_report_retrieve_params.py b/stripe/params/identity/_verification_report_retrieve_params.py
new file mode 100644
index 000000000..a289cedde
--- /dev/null
+++ b/stripe/params/identity/_verification_report_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class VerificationReportRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/identity/_verification_session_cancel_params.py b/stripe/params/identity/_verification_session_cancel_params.py
new file mode 100644
index 000000000..3c43c7a9f
--- /dev/null
+++ b/stripe/params/identity/_verification_session_cancel_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class VerificationSessionCancelParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/identity/_verification_session_create_params.py b/stripe/params/identity/_verification_session_create_params.py
new file mode 100644
index 000000000..2c7cc20af
--- /dev/null
+++ b/stripe/params/identity/_verification_session_create_params.py
@@ -0,0 +1,102 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class VerificationSessionCreateParams(RequestOptions):
+ client_reference_id: NotRequired[str]
+ """
+ A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ options: NotRequired["VerificationSessionCreateParamsOptions"]
+ """
+ A set of options for the session's verification checks.
+ """
+ provided_details: NotRequired[
+ "VerificationSessionCreateParamsProvidedDetails"
+ ]
+ """
+ Details provided about the user being verified. These details may be shown to the user.
+ """
+ related_customer: NotRequired[str]
+ """
+ Customer ID
+ """
+ related_person: NotRequired["VerificationSessionCreateParamsRelatedPerson"]
+ """
+ Tokens referencing a Person resource and it's associated account.
+ """
+ return_url: NotRequired[str]
+ """
+ The URL that the user will be redirected to upon completing the verification flow.
+ """
+ type: NotRequired[Literal["document", "id_number"]]
+ """
+ The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed. You must provide a `type` if not passing `verification_flow`.
+ """
+ verification_flow: NotRequired[str]
+ """
+ The ID of a verification flow from the Dashboard. See https://docs.stripe.com/identity/verification-flows.
+ """
+
+
+class VerificationSessionCreateParamsOptions(TypedDict):
+ document: NotRequired[
+ "Literal['']|VerificationSessionCreateParamsOptionsDocument"
+ ]
+ """
+ Options that apply to the [document check](https://stripe.com/docs/identity/verification-checks?type=document).
+ """
+
+
+class VerificationSessionCreateParamsOptionsDocument(TypedDict):
+ allowed_types: NotRequired[
+ List[Literal["driving_license", "id_card", "passport"]]
+ ]
+ """
+ Array of strings of allowed identity document types. If the provided identity document isn't one of the allowed types, the verification check will fail with a document_type_not_allowed error code.
+ """
+ require_id_number: NotRequired[bool]
+ """
+ Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document's extracted name and date of birth.
+ """
+ require_live_capture: NotRequired[bool]
+ """
+ Disable image uploads, identity document images have to be captured using the device's camera.
+ """
+ require_matching_selfie: NotRequired[bool]
+ """
+ Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user's face. [Learn more](https://stripe.com/docs/identity/selfie).
+ """
+
+
+class VerificationSessionCreateParamsProvidedDetails(TypedDict):
+ email: NotRequired[str]
+ """
+ Email of user being verified
+ """
+ phone: NotRequired[str]
+ """
+ Phone number of user being verified
+ """
+
+
+class VerificationSessionCreateParamsRelatedPerson(TypedDict):
+ account: str
+ """
+ A token representing a connected account. If provided, the person parameter is also required and must be associated with the account.
+ """
+ person: str
+ """
+ A token referencing a Person resource that this verification is being used to verify.
+ """
diff --git a/stripe/params/identity/_verification_session_list_params.py b/stripe/params/identity/_verification_session_list_params.py
new file mode 100644
index 000000000..6bd462214
--- /dev/null
+++ b/stripe/params/identity/_verification_session_list_params.py
@@ -0,0 +1,58 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class VerificationSessionListParams(RequestOptions):
+ client_reference_id: NotRequired[str]
+ """
+ A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
+ """
+ created: NotRequired["VerificationSessionListParamsCreated|int"]
+ """
+ Only return VerificationSessions that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ related_customer: NotRequired[str]
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[
+ Literal["canceled", "processing", "requires_input", "verified"]
+ ]
+ """
+ Only return VerificationSessions with this status. [Learn more about the lifecycle of sessions](https://stripe.com/docs/identity/how-sessions-work).
+ """
+
+
+class VerificationSessionListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/identity/_verification_session_modify_params.py b/stripe/params/identity/_verification_session_modify_params.py
new file mode 100644
index 000000000..ec4fb2c11
--- /dev/null
+++ b/stripe/params/identity/_verification_session_modify_params.py
@@ -0,0 +1,71 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class VerificationSessionModifyParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ options: NotRequired["VerificationSessionModifyParamsOptions"]
+ """
+ A set of options for the session's verification checks.
+ """
+ provided_details: NotRequired[
+ "VerificationSessionModifyParamsProvidedDetails"
+ ]
+ """
+ Details provided about the user being verified. These details may be shown to the user.
+ """
+ type: NotRequired[Literal["document", "id_number"]]
+ """
+ The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed.
+ """
+
+
+class VerificationSessionModifyParamsOptions(TypedDict):
+ document: NotRequired[
+ "Literal['']|VerificationSessionModifyParamsOptionsDocument"
+ ]
+ """
+ Options that apply to the [document check](https://stripe.com/docs/identity/verification-checks?type=document).
+ """
+
+
+class VerificationSessionModifyParamsOptionsDocument(TypedDict):
+ allowed_types: NotRequired[
+ List[Literal["driving_license", "id_card", "passport"]]
+ ]
+ """
+ Array of strings of allowed identity document types. If the provided identity document isn't one of the allowed types, the verification check will fail with a document_type_not_allowed error code.
+ """
+ require_id_number: NotRequired[bool]
+ """
+ Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document's extracted name and date of birth.
+ """
+ require_live_capture: NotRequired[bool]
+ """
+ Disable image uploads, identity document images have to be captured using the device's camera.
+ """
+ require_matching_selfie: NotRequired[bool]
+ """
+ Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user's face. [Learn more](https://stripe.com/docs/identity/selfie).
+ """
+
+
+class VerificationSessionModifyParamsProvidedDetails(TypedDict):
+ email: NotRequired[str]
+ """
+ Email of user being verified
+ """
+ phone: NotRequired[str]
+ """
+ Phone number of user being verified
+ """
diff --git a/stripe/params/identity/_verification_session_redact_params.py b/stripe/params/identity/_verification_session_redact_params.py
new file mode 100644
index 000000000..a624950ff
--- /dev/null
+++ b/stripe/params/identity/_verification_session_redact_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class VerificationSessionRedactParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/identity/_verification_session_retrieve_params.py b/stripe/params/identity/_verification_session_retrieve_params.py
new file mode 100644
index 000000000..f696500f6
--- /dev/null
+++ b/stripe/params/identity/_verification_session_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class VerificationSessionRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/identity/_verification_session_update_params.py b/stripe/params/identity/_verification_session_update_params.py
new file mode 100644
index 000000000..6fe2b7271
--- /dev/null
+++ b/stripe/params/identity/_verification_session_update_params.py
@@ -0,0 +1,70 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class VerificationSessionUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ options: NotRequired["VerificationSessionUpdateParamsOptions"]
+ """
+ A set of options for the session's verification checks.
+ """
+ provided_details: NotRequired[
+ "VerificationSessionUpdateParamsProvidedDetails"
+ ]
+ """
+ Details provided about the user being verified. These details may be shown to the user.
+ """
+ type: NotRequired[Literal["document", "id_number"]]
+ """
+ The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed.
+ """
+
+
+class VerificationSessionUpdateParamsOptions(TypedDict):
+ document: NotRequired[
+ "Literal['']|VerificationSessionUpdateParamsOptionsDocument"
+ ]
+ """
+ Options that apply to the [document check](https://stripe.com/docs/identity/verification-checks?type=document).
+ """
+
+
+class VerificationSessionUpdateParamsOptionsDocument(TypedDict):
+ allowed_types: NotRequired[
+ List[Literal["driving_license", "id_card", "passport"]]
+ ]
+ """
+ Array of strings of allowed identity document types. If the provided identity document isn't one of the allowed types, the verification check will fail with a document_type_not_allowed error code.
+ """
+ require_id_number: NotRequired[bool]
+ """
+ Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document's extracted name and date of birth.
+ """
+ require_live_capture: NotRequired[bool]
+ """
+ Disable image uploads, identity document images have to be captured using the device's camera.
+ """
+ require_matching_selfie: NotRequired[bool]
+ """
+ Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user's face. [Learn more](https://stripe.com/docs/identity/selfie).
+ """
+
+
+class VerificationSessionUpdateParamsProvidedDetails(TypedDict):
+ email: NotRequired[str]
+ """
+ Email of user being verified
+ """
+ phone: NotRequired[str]
+ """
+ Phone number of user being verified
+ """
diff --git a/stripe/params/issuing/__init__.py b/stripe/params/issuing/__init__.py
new file mode 100644
index 000000000..2bb64e3b2
--- /dev/null
+++ b/stripe/params/issuing/__init__.py
@@ -0,0 +1,167 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.issuing._authorization_approve_params import (
+ AuthorizationApproveParams as AuthorizationApproveParams,
+)
+from stripe.params.issuing._authorization_capture_params import (
+ AuthorizationCaptureParams as AuthorizationCaptureParams,
+)
+from stripe.params.issuing._authorization_create_params import (
+ AuthorizationCreateParams as AuthorizationCreateParams,
+)
+from stripe.params.issuing._authorization_decline_params import (
+ AuthorizationDeclineParams as AuthorizationDeclineParams,
+)
+from stripe.params.issuing._authorization_expire_params import (
+ AuthorizationExpireParams as AuthorizationExpireParams,
+)
+from stripe.params.issuing._authorization_finalize_amount_params import (
+ AuthorizationFinalizeAmountParams as AuthorizationFinalizeAmountParams,
+)
+from stripe.params.issuing._authorization_increment_params import (
+ AuthorizationIncrementParams as AuthorizationIncrementParams,
+)
+from stripe.params.issuing._authorization_list_params import (
+ AuthorizationListParams as AuthorizationListParams,
+)
+from stripe.params.issuing._authorization_modify_params import (
+ AuthorizationModifyParams as AuthorizationModifyParams,
+)
+from stripe.params.issuing._authorization_respond_params import (
+ AuthorizationRespondParams as AuthorizationRespondParams,
+)
+from stripe.params.issuing._authorization_retrieve_params import (
+ AuthorizationRetrieveParams as AuthorizationRetrieveParams,
+)
+from stripe.params.issuing._authorization_reverse_params import (
+ AuthorizationReverseParams as AuthorizationReverseParams,
+)
+from stripe.params.issuing._authorization_update_params import (
+ AuthorizationUpdateParams as AuthorizationUpdateParams,
+)
+from stripe.params.issuing._card_create_params import (
+ CardCreateParams as CardCreateParams,
+)
+from stripe.params.issuing._card_deliver_card_params import (
+ CardDeliverCardParams as CardDeliverCardParams,
+)
+from stripe.params.issuing._card_fail_card_params import (
+ CardFailCardParams as CardFailCardParams,
+)
+from stripe.params.issuing._card_list_params import (
+ CardListParams as CardListParams,
+)
+from stripe.params.issuing._card_modify_params import (
+ CardModifyParams as CardModifyParams,
+)
+from stripe.params.issuing._card_retrieve_params import (
+ CardRetrieveParams as CardRetrieveParams,
+)
+from stripe.params.issuing._card_return_card_params import (
+ CardReturnCardParams as CardReturnCardParams,
+)
+from stripe.params.issuing._card_ship_card_params import (
+ CardShipCardParams as CardShipCardParams,
+)
+from stripe.params.issuing._card_submit_card_params import (
+ CardSubmitCardParams as CardSubmitCardParams,
+)
+from stripe.params.issuing._card_update_params import (
+ CardUpdateParams as CardUpdateParams,
+)
+from stripe.params.issuing._cardholder_create_params import (
+ CardholderCreateParams as CardholderCreateParams,
+)
+from stripe.params.issuing._cardholder_list_params import (
+ CardholderListParams as CardholderListParams,
+)
+from stripe.params.issuing._cardholder_modify_params import (
+ CardholderModifyParams as CardholderModifyParams,
+)
+from stripe.params.issuing._cardholder_retrieve_params import (
+ CardholderRetrieveParams as CardholderRetrieveParams,
+)
+from stripe.params.issuing._cardholder_update_params import (
+ CardholderUpdateParams as CardholderUpdateParams,
+)
+from stripe.params.issuing._dispute_create_params import (
+ DisputeCreateParams as DisputeCreateParams,
+)
+from stripe.params.issuing._dispute_list_params import (
+ DisputeListParams as DisputeListParams,
+)
+from stripe.params.issuing._dispute_modify_params import (
+ DisputeModifyParams as DisputeModifyParams,
+)
+from stripe.params.issuing._dispute_retrieve_params import (
+ DisputeRetrieveParams as DisputeRetrieveParams,
+)
+from stripe.params.issuing._dispute_submit_params import (
+ DisputeSubmitParams as DisputeSubmitParams,
+)
+from stripe.params.issuing._dispute_update_params import (
+ DisputeUpdateParams as DisputeUpdateParams,
+)
+from stripe.params.issuing._personalization_design_activate_params import (
+ PersonalizationDesignActivateParams as PersonalizationDesignActivateParams,
+)
+from stripe.params.issuing._personalization_design_create_params import (
+ PersonalizationDesignCreateParams as PersonalizationDesignCreateParams,
+)
+from stripe.params.issuing._personalization_design_deactivate_params import (
+ PersonalizationDesignDeactivateParams as PersonalizationDesignDeactivateParams,
+)
+from stripe.params.issuing._personalization_design_list_params import (
+ PersonalizationDesignListParams as PersonalizationDesignListParams,
+)
+from stripe.params.issuing._personalization_design_modify_params import (
+ PersonalizationDesignModifyParams as PersonalizationDesignModifyParams,
+)
+from stripe.params.issuing._personalization_design_reject_params import (
+ PersonalizationDesignRejectParams as PersonalizationDesignRejectParams,
+)
+from stripe.params.issuing._personalization_design_retrieve_params import (
+ PersonalizationDesignRetrieveParams as PersonalizationDesignRetrieveParams,
+)
+from stripe.params.issuing._personalization_design_update_params import (
+ PersonalizationDesignUpdateParams as PersonalizationDesignUpdateParams,
+)
+from stripe.params.issuing._physical_bundle_list_params import (
+ PhysicalBundleListParams as PhysicalBundleListParams,
+)
+from stripe.params.issuing._physical_bundle_retrieve_params import (
+ PhysicalBundleRetrieveParams as PhysicalBundleRetrieveParams,
+)
+from stripe.params.issuing._token_list_params import (
+ TokenListParams as TokenListParams,
+)
+from stripe.params.issuing._token_modify_params import (
+ TokenModifyParams as TokenModifyParams,
+)
+from stripe.params.issuing._token_retrieve_params import (
+ TokenRetrieveParams as TokenRetrieveParams,
+)
+from stripe.params.issuing._token_update_params import (
+ TokenUpdateParams as TokenUpdateParams,
+)
+from stripe.params.issuing._transaction_create_force_capture_params import (
+ TransactionCreateForceCaptureParams as TransactionCreateForceCaptureParams,
+)
+from stripe.params.issuing._transaction_create_unlinked_refund_params import (
+ TransactionCreateUnlinkedRefundParams as TransactionCreateUnlinkedRefundParams,
+)
+from stripe.params.issuing._transaction_list_params import (
+ TransactionListParams as TransactionListParams,
+)
+from stripe.params.issuing._transaction_modify_params import (
+ TransactionModifyParams as TransactionModifyParams,
+)
+from stripe.params.issuing._transaction_refund_params import (
+ TransactionRefundParams as TransactionRefundParams,
+)
+from stripe.params.issuing._transaction_retrieve_params import (
+ TransactionRetrieveParams as TransactionRetrieveParams,
+)
+from stripe.params.issuing._transaction_update_params import (
+ TransactionUpdateParams as TransactionUpdateParams,
+)
diff --git a/stripe/params/issuing/_authorization_approve_params.py b/stripe/params/issuing/_authorization_approve_params.py
new file mode 100644
index 000000000..f21d353f1
--- /dev/null
+++ b/stripe/params/issuing/_authorization_approve_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class AuthorizationApproveParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ If the authorization's `pending_request.is_amount_controllable` property is `true`, you may provide this value to control how much to hold for the authorization. Must be positive (use [`decline`](https://stripe.com/docs/api/issuing/authorizations/decline) to decline an authorization request).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/issuing/_authorization_capture_params.py b/stripe/params/issuing/_authorization_capture_params.py
new file mode 100644
index 000000000..79049f779
--- /dev/null
+++ b/stripe/params/issuing/_authorization_capture_params.py
@@ -0,0 +1,273 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AuthorizationCaptureParams(RequestOptions):
+ capture_amount: NotRequired[int]
+ """
+ The amount to capture from the authorization. If not provided, the full amount of the authorization will be captured. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ close_authorization: NotRequired[bool]
+ """
+ Whether to close the authorization after capture. Defaults to true. Set to false to enable multi-capture flows.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ purchase_details: NotRequired["AuthorizationCaptureParamsPurchaseDetails"]
+ """
+ Additional purchase information that is optionally provided by the merchant.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetails(TypedDict):
+ fleet: NotRequired["AuthorizationCaptureParamsPurchaseDetailsFleet"]
+ """
+ Fleet-specific information for transactions using Fleet cards.
+ """
+ flight: NotRequired["AuthorizationCaptureParamsPurchaseDetailsFlight"]
+ """
+ Information about the flight that was purchased with this transaction.
+ """
+ fuel: NotRequired["AuthorizationCaptureParamsPurchaseDetailsFuel"]
+ """
+ Information about fuel that was purchased with this transaction.
+ """
+ lodging: NotRequired["AuthorizationCaptureParamsPurchaseDetailsLodging"]
+ """
+ Information about lodging that was purchased with this transaction.
+ """
+ receipt: NotRequired[
+ List["AuthorizationCaptureParamsPurchaseDetailsReceipt"]
+ ]
+ """
+ The line items in the purchase.
+ """
+ reference: NotRequired[str]
+ """
+ A merchant-specific order number.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFleet(TypedDict):
+ cardholder_prompt_data: NotRequired[
+ "AuthorizationCaptureParamsPurchaseDetailsFleetCardholderPromptData"
+ ]
+ """
+ Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
+ """
+ purchase_type: NotRequired[
+ Literal[
+ "fuel_and_non_fuel_purchase", "fuel_purchase", "non_fuel_purchase"
+ ]
+ ]
+ """
+ The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
+ """
+ reported_breakdown: NotRequired[
+ "AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdown"
+ ]
+ """
+ More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
+ """
+ service_type: NotRequired[
+ Literal["full_service", "non_fuel_transaction", "self_service"]
+ ]
+ """
+ The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFleetCardholderPromptData(
+ TypedDict,
+):
+ driver_id: NotRequired[str]
+ """
+ Driver ID.
+ """
+ odometer: NotRequired[int]
+ """
+ Odometer reading.
+ """
+ unspecified_id: NotRequired[str]
+ """
+ An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
+ """
+ user_id: NotRequired[str]
+ """
+ User ID.
+ """
+ vehicle_number: NotRequired[str]
+ """
+ Vehicle number.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdown(
+ TypedDict,
+):
+ fuel: NotRequired[
+ "AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdownFuel"
+ ]
+ """
+ Breakdown of fuel portion of the purchase.
+ """
+ non_fuel: NotRequired[
+ "AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel"
+ ]
+ """
+ Breakdown of non-fuel portion of the purchase.
+ """
+ tax: NotRequired[
+ "AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdownTax"
+ ]
+ """
+ Information about tax included in this transaction.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdownFuel(
+ TypedDict,
+):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel(
+ TypedDict,
+):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdownTax(
+ TypedDict,
+):
+ local_amount_decimal: NotRequired[str]
+ """
+ Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+ national_amount_decimal: NotRequired[str]
+ """
+ Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFlight(TypedDict):
+ departure_at: NotRequired[int]
+ """
+ The time that the flight departed.
+ """
+ passenger_name: NotRequired[str]
+ """
+ The name of the passenger.
+ """
+ refundable: NotRequired[bool]
+ """
+ Whether the ticket is refundable.
+ """
+ segments: NotRequired[
+ List["AuthorizationCaptureParamsPurchaseDetailsFlightSegment"]
+ ]
+ """
+ The legs of the trip.
+ """
+ travel_agency: NotRequired[str]
+ """
+ The travel agency that issued the ticket.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFlightSegment(TypedDict):
+ arrival_airport_code: NotRequired[str]
+ """
+ The three-letter IATA airport code of the flight's destination.
+ """
+ carrier: NotRequired[str]
+ """
+ The airline carrier code.
+ """
+ departure_airport_code: NotRequired[str]
+ """
+ The three-letter IATA airport code that the flight departed from.
+ """
+ flight_number: NotRequired[str]
+ """
+ The flight number.
+ """
+ service_class: NotRequired[str]
+ """
+ The flight's service class.
+ """
+ stopover_allowed: NotRequired[bool]
+ """
+ Whether a stopover is allowed on this flight.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFuel(TypedDict):
+ industry_product_code: NotRequired[str]
+ """
+ [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
+ """
+ quantity_decimal: NotRequired[str]
+ """
+ The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
+ """
+ type: NotRequired[
+ Literal[
+ "diesel",
+ "other",
+ "unleaded_plus",
+ "unleaded_regular",
+ "unleaded_super",
+ ]
+ ]
+ """
+ The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
+ """
+ unit: NotRequired[
+ Literal[
+ "charging_minute",
+ "imperial_gallon",
+ "kilogram",
+ "kilowatt_hour",
+ "liter",
+ "other",
+ "pound",
+ "us_gallon",
+ ]
+ ]
+ """
+ The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
+ """
+ unit_cost_decimal: NotRequired[str]
+ """
+ The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsLodging(TypedDict):
+ check_in_at: NotRequired[int]
+ """
+ The time of checking into the lodging.
+ """
+ nights: NotRequired[int]
+ """
+ The number of nights stayed at the lodging.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsReceipt(TypedDict):
+ description: NotRequired[str]
+ quantity: NotRequired[str]
+ total: NotRequired[int]
+ unit_cost: NotRequired[int]
diff --git a/stripe/params/issuing/_authorization_create_params.py b/stripe/params/issuing/_authorization_create_params.py
new file mode 100644
index 000000000..c5831f78c
--- /dev/null
+++ b/stripe/params/issuing/_authorization_create_params.py
@@ -0,0 +1,674 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AuthorizationCreateParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ The total amount to attempt to authorize. This amount is in the provided currency, or defaults to the card's currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ amount_details: NotRequired["AuthorizationCreateParamsAmountDetails"]
+ """
+ Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ authorization_method: NotRequired[
+ Literal["chip", "contactless", "keyed_in", "online", "swipe"]
+ ]
+ """
+ How the card details were provided. Defaults to online.
+ """
+ card: str
+ """
+ Card associated with this authorization.
+ """
+ currency: NotRequired[str]
+ """
+ The currency of the authorization. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ fleet: NotRequired["AuthorizationCreateParamsFleet"]
+ """
+ Fleet-specific information for authorizations using Fleet cards.
+ """
+ fraud_disputability_likelihood: NotRequired[
+ Literal["neutral", "unknown", "very_likely", "very_unlikely"]
+ ]
+ """
+ Probability that this transaction can be disputed in the event of fraud. Assessed by comparing the characteristics of the authorization to card network rules.
+ """
+ fuel: NotRequired["AuthorizationCreateParamsFuel"]
+ """
+ Information about fuel that was purchased with this transaction.
+ """
+ is_amount_controllable: NotRequired[bool]
+ """
+ If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.
+ """
+ merchant_amount: NotRequired[int]
+ """
+ The total amount to attempt to authorize. This amount is in the provided merchant currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ merchant_currency: NotRequired[str]
+ """
+ The currency of the authorization. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ merchant_data: NotRequired["AuthorizationCreateParamsMerchantData"]
+ """
+ Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
+ """
+ network_data: NotRequired["AuthorizationCreateParamsNetworkData"]
+ """
+ Details about the authorization, such as identifiers, set by the card network.
+ """
+ risk_assessment: NotRequired["AuthorizationCreateParamsRiskAssessment"]
+ """
+ Stripe's assessment of the fraud risk for this authorization.
+ """
+ verification_data: NotRequired["AuthorizationCreateParamsVerificationData"]
+ """
+ Verifications that Stripe performed on information that the cardholder provided to the merchant.
+ """
+ wallet: NotRequired[Literal["apple_pay", "google_pay", "samsung_pay"]]
+ """
+ The digital wallet used for this transaction. One of `apple_pay`, `google_pay`, or `samsung_pay`. Will populate as `null` when no digital wallet was utilized.
+ """
+
+
+class AuthorizationCreateParamsAmountDetails(TypedDict):
+ atm_fee: NotRequired[int]
+ """
+ The ATM withdrawal fee.
+ """
+ cashback_amount: NotRequired[int]
+ """
+ The amount of cash requested by the cardholder.
+ """
+
+
+class AuthorizationCreateParamsFleet(TypedDict):
+ cardholder_prompt_data: NotRequired[
+ "AuthorizationCreateParamsFleetCardholderPromptData"
+ ]
+ """
+ Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
+ """
+ purchase_type: NotRequired[
+ Literal[
+ "fuel_and_non_fuel_purchase", "fuel_purchase", "non_fuel_purchase"
+ ]
+ ]
+ """
+ The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
+ """
+ reported_breakdown: NotRequired[
+ "AuthorizationCreateParamsFleetReportedBreakdown"
+ ]
+ """
+ More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
+ """
+ service_type: NotRequired[
+ Literal["full_service", "non_fuel_transaction", "self_service"]
+ ]
+ """
+ The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
+ """
+
+
+class AuthorizationCreateParamsFleetCardholderPromptData(TypedDict):
+ driver_id: NotRequired[str]
+ """
+ Driver ID.
+ """
+ odometer: NotRequired[int]
+ """
+ Odometer reading.
+ """
+ unspecified_id: NotRequired[str]
+ """
+ An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
+ """
+ user_id: NotRequired[str]
+ """
+ User ID.
+ """
+ vehicle_number: NotRequired[str]
+ """
+ Vehicle number.
+ """
+
+
+class AuthorizationCreateParamsFleetReportedBreakdown(TypedDict):
+ fuel: NotRequired["AuthorizationCreateParamsFleetReportedBreakdownFuel"]
+ """
+ Breakdown of fuel portion of the purchase.
+ """
+ non_fuel: NotRequired[
+ "AuthorizationCreateParamsFleetReportedBreakdownNonFuel"
+ ]
+ """
+ Breakdown of non-fuel portion of the purchase.
+ """
+ tax: NotRequired["AuthorizationCreateParamsFleetReportedBreakdownTax"]
+ """
+ Information about tax included in this transaction.
+ """
+
+
+class AuthorizationCreateParamsFleetReportedBreakdownFuel(TypedDict):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
+ """
+
+
+class AuthorizationCreateParamsFleetReportedBreakdownNonFuel(TypedDict):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
+ """
+
+
+class AuthorizationCreateParamsFleetReportedBreakdownTax(TypedDict):
+ local_amount_decimal: NotRequired[str]
+ """
+ Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+ national_amount_decimal: NotRequired[str]
+ """
+ Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+
+
+class AuthorizationCreateParamsFuel(TypedDict):
+ industry_product_code: NotRequired[str]
+ """
+ [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
+ """
+ quantity_decimal: NotRequired[str]
+ """
+ The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
+ """
+ type: NotRequired[
+ Literal[
+ "diesel",
+ "other",
+ "unleaded_plus",
+ "unleaded_regular",
+ "unleaded_super",
+ ]
+ ]
+ """
+ The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
+ """
+ unit: NotRequired[
+ Literal[
+ "charging_minute",
+ "imperial_gallon",
+ "kilogram",
+ "kilowatt_hour",
+ "liter",
+ "other",
+ "pound",
+ "us_gallon",
+ ]
+ ]
+ """
+ The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
+ """
+ unit_cost_decimal: NotRequired[str]
+ """
+ The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
+ """
+
+
+class AuthorizationCreateParamsMerchantData(TypedDict):
+ category: NotRequired[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ """
+ A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
+ """
+ city: NotRequired[str]
+ """
+ City where the seller is located
+ """
+ country: NotRequired[str]
+ """
+ Country where the seller is located
+ """
+ name: NotRequired[str]
+ """
+ Name of the seller
+ """
+ network_id: NotRequired[str]
+ """
+ Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code where the seller is located
+ """
+ state: NotRequired[str]
+ """
+ State where the seller is located
+ """
+ terminal_id: NotRequired[str]
+ """
+ An ID assigned by the seller to the location of the sale.
+ """
+ url: NotRequired[str]
+ """
+ URL provided by the merchant on a 3DS request
+ """
+
+
+class AuthorizationCreateParamsNetworkData(TypedDict):
+ acquiring_institution_id: NotRequired[str]
+ """
+ Identifier assigned to the acquirer by the card network.
+ """
+
+
+class AuthorizationCreateParamsRiskAssessment(TypedDict):
+ card_testing_risk: NotRequired[
+ "AuthorizationCreateParamsRiskAssessmentCardTestingRisk"
+ ]
+ """
+ Stripe's assessment of this authorization's likelihood of being card testing activity.
+ """
+ merchant_dispute_risk: NotRequired[
+ "AuthorizationCreateParamsRiskAssessmentMerchantDisputeRisk"
+ ]
+ """
+ The dispute risk of the merchant (the seller on a purchase) on an authorization based on all Stripe Issuing activity.
+ """
+
+
+class AuthorizationCreateParamsRiskAssessmentCardTestingRisk(TypedDict):
+ invalid_account_number_decline_rate_past_hour: NotRequired[int]
+ """
+ The % of declines due to a card number not existing in the past hour, taking place at the same merchant. Higher rates correspond to a greater probability of card testing activity, meaning bad actors may be attempting different card number combinations to guess a correct one. Takes on values between 0 and 100.
+ """
+ invalid_credentials_decline_rate_past_hour: NotRequired[int]
+ """
+ The % of declines due to incorrect verification data (like CVV or expiry) in the past hour, taking place at the same merchant. Higher rates correspond to a greater probability of bad actors attempting to utilize valid card credentials at merchants with verification requirements. Takes on values between 0 and 100.
+ """
+ risk_level: Literal[
+ "elevated", "highest", "low", "normal", "not_assessed", "unknown"
+ ]
+ """
+ The likelihood that this authorization is associated with card testing activity. This is assessed by evaluating decline activity over the last hour.
+ """
+
+
+class AuthorizationCreateParamsRiskAssessmentMerchantDisputeRisk(TypedDict):
+ dispute_rate: NotRequired[int]
+ """
+ The dispute rate observed across all Stripe Issuing authorizations for this merchant. For example, a value of 50 means 50% of authorizations from this merchant on Stripe Issuing have resulted in a dispute. Higher values mean a higher likelihood the authorization is disputed. Takes on values between 0 and 100.
+ """
+ risk_level: Literal[
+ "elevated", "highest", "low", "normal", "not_assessed", "unknown"
+ ]
+ """
+ The likelihood that authorizations from this merchant will result in a dispute based on their history on Stripe Issuing.
+ """
+
+
+class AuthorizationCreateParamsVerificationData(TypedDict):
+ address_line1_check: NotRequired[
+ Literal["match", "mismatch", "not_provided"]
+ ]
+ """
+ Whether the cardholder provided an address first line and if it matched the cardholder's `billing.address.line1`.
+ """
+ address_postal_code_check: NotRequired[
+ Literal["match", "mismatch", "not_provided"]
+ ]
+ """
+ Whether the cardholder provided a postal code and if it matched the cardholder's `billing.address.postal_code`.
+ """
+ authentication_exemption: NotRequired[
+ "AuthorizationCreateParamsVerificationDataAuthenticationExemption"
+ ]
+ """
+ The exemption applied to this authorization.
+ """
+ cvc_check: NotRequired[Literal["match", "mismatch", "not_provided"]]
+ """
+ Whether the cardholder provided a CVC and if it matched Stripe's record.
+ """
+ expiry_check: NotRequired[Literal["match", "mismatch", "not_provided"]]
+ """
+ Whether the cardholder provided an expiry date and if it matched Stripe's record.
+ """
+ three_d_secure: NotRequired[
+ "AuthorizationCreateParamsVerificationDataThreeDSecure"
+ ]
+ """
+ 3D Secure details.
+ """
+
+
+class AuthorizationCreateParamsVerificationDataAuthenticationExemption(
+ TypedDict,
+):
+ claimed_by: Literal["acquirer", "issuer"]
+ """
+ The entity that requested the exemption, either the acquiring merchant or the Issuing user.
+ """
+ type: Literal[
+ "low_value_transaction", "transaction_risk_analysis", "unknown"
+ ]
+ """
+ The specific exemption claimed for this authorization.
+ """
+
+
+class AuthorizationCreateParamsVerificationDataThreeDSecure(TypedDict):
+ result: Literal[
+ "attempt_acknowledged", "authenticated", "failed", "required"
+ ]
+ """
+ The outcome of the 3D Secure authentication request.
+ """
diff --git a/stripe/params/issuing/_authorization_decline_params.py b/stripe/params/issuing/_authorization_decline_params.py
new file mode 100644
index 000000000..d746a8a1c
--- /dev/null
+++ b/stripe/params/issuing/_authorization_decline_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class AuthorizationDeclineParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/issuing/_authorization_expire_params.py b/stripe/params/issuing/_authorization_expire_params.py
new file mode 100644
index 000000000..46a5aa04c
--- /dev/null
+++ b/stripe/params/issuing/_authorization_expire_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AuthorizationExpireParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_authorization_finalize_amount_params.py b/stripe/params/issuing/_authorization_finalize_amount_params.py
new file mode 100644
index 000000000..a15604fa9
--- /dev/null
+++ b/stripe/params/issuing/_authorization_finalize_amount_params.py
@@ -0,0 +1,166 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AuthorizationFinalizeAmountParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ final_amount: int
+ """
+ The final authorization amount that will be captured by the merchant. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ fleet: NotRequired["AuthorizationFinalizeAmountParamsFleet"]
+ """
+ Fleet-specific information for authorizations using Fleet cards.
+ """
+ fuel: NotRequired["AuthorizationFinalizeAmountParamsFuel"]
+ """
+ Information about fuel that was purchased with this transaction.
+ """
+
+
+class AuthorizationFinalizeAmountParamsFleet(TypedDict):
+ cardholder_prompt_data: NotRequired[
+ "AuthorizationFinalizeAmountParamsFleetCardholderPromptData"
+ ]
+ """
+ Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
+ """
+ purchase_type: NotRequired[
+ Literal[
+ "fuel_and_non_fuel_purchase", "fuel_purchase", "non_fuel_purchase"
+ ]
+ ]
+ """
+ The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
+ """
+ reported_breakdown: NotRequired[
+ "AuthorizationFinalizeAmountParamsFleetReportedBreakdown"
+ ]
+ """
+ More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
+ """
+ service_type: NotRequired[
+ Literal["full_service", "non_fuel_transaction", "self_service"]
+ ]
+ """
+ The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
+ """
+
+
+class AuthorizationFinalizeAmountParamsFleetCardholderPromptData(TypedDict):
+ driver_id: NotRequired[str]
+ """
+ Driver ID.
+ """
+ odometer: NotRequired[int]
+ """
+ Odometer reading.
+ """
+ unspecified_id: NotRequired[str]
+ """
+ An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
+ """
+ user_id: NotRequired[str]
+ """
+ User ID.
+ """
+ vehicle_number: NotRequired[str]
+ """
+ Vehicle number.
+ """
+
+
+class AuthorizationFinalizeAmountParamsFleetReportedBreakdown(TypedDict):
+ fuel: NotRequired[
+ "AuthorizationFinalizeAmountParamsFleetReportedBreakdownFuel"
+ ]
+ """
+ Breakdown of fuel portion of the purchase.
+ """
+ non_fuel: NotRequired[
+ "AuthorizationFinalizeAmountParamsFleetReportedBreakdownNonFuel"
+ ]
+ """
+ Breakdown of non-fuel portion of the purchase.
+ """
+ tax: NotRequired[
+ "AuthorizationFinalizeAmountParamsFleetReportedBreakdownTax"
+ ]
+ """
+ Information about tax included in this transaction.
+ """
+
+
+class AuthorizationFinalizeAmountParamsFleetReportedBreakdownFuel(TypedDict):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
+ """
+
+
+class AuthorizationFinalizeAmountParamsFleetReportedBreakdownNonFuel(
+ TypedDict
+):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
+ """
+
+
+class AuthorizationFinalizeAmountParamsFleetReportedBreakdownTax(TypedDict):
+ local_amount_decimal: NotRequired[str]
+ """
+ Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+ national_amount_decimal: NotRequired[str]
+ """
+ Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+
+
+class AuthorizationFinalizeAmountParamsFuel(TypedDict):
+ industry_product_code: NotRequired[str]
+ """
+ [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
+ """
+ quantity_decimal: NotRequired[str]
+ """
+ The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
+ """
+ type: NotRequired[
+ Literal[
+ "diesel",
+ "other",
+ "unleaded_plus",
+ "unleaded_regular",
+ "unleaded_super",
+ ]
+ ]
+ """
+ The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
+ """
+ unit: NotRequired[
+ Literal[
+ "charging_minute",
+ "imperial_gallon",
+ "kilogram",
+ "kilowatt_hour",
+ "liter",
+ "other",
+ "pound",
+ "us_gallon",
+ ]
+ ]
+ """
+ The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
+ """
+ unit_cost_decimal: NotRequired[str]
+ """
+ The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
+ """
diff --git a/stripe/params/issuing/_authorization_increment_params.py b/stripe/params/issuing/_authorization_increment_params.py
new file mode 100644
index 000000000..30fe7ede7
--- /dev/null
+++ b/stripe/params/issuing/_authorization_increment_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AuthorizationIncrementParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ increment_amount: int
+ """
+ The amount to increment the authorization by. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ is_amount_controllable: NotRequired[bool]
+ """
+ If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.
+ """
diff --git a/stripe/params/issuing/_authorization_list_params.py b/stripe/params/issuing/_authorization_list_params.py
new file mode 100644
index 000000000..ccea33632
--- /dev/null
+++ b/stripe/params/issuing/_authorization_list_params.py
@@ -0,0 +1,59 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AuthorizationListParams(RequestOptions):
+ card: NotRequired[str]
+ """
+ Only return authorizations that belong to the given card.
+ """
+ cardholder: NotRequired[str]
+ """
+ Only return authorizations that belong to the given cardholder.
+ """
+ created: NotRequired["AuthorizationListParamsCreated|int"]
+ """
+ Only return authorizations that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["closed", "expired", "pending", "reversed"]]
+ """
+ Only return authorizations with the given status. One of `pending`, `closed`, or `reversed`.
+ """
+
+
+class AuthorizationListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/issuing/_authorization_modify_params.py b/stripe/params/issuing/_authorization_modify_params.py
new file mode 100644
index 000000000..af0629823
--- /dev/null
+++ b/stripe/params/issuing/_authorization_modify_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class AuthorizationModifyParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/issuing/_authorization_respond_params.py b/stripe/params/issuing/_authorization_respond_params.py
new file mode 100644
index 000000000..885fdda9f
--- /dev/null
+++ b/stripe/params/issuing/_authorization_respond_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AuthorizationRespondParams(RequestOptions):
+ confirmed: bool
+ """
+ Whether to simulate the user confirming that the transaction was legitimate (true) or telling Stripe that it was fraudulent (false).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_authorization_retrieve_params.py b/stripe/params/issuing/_authorization_retrieve_params.py
new file mode 100644
index 000000000..58e557b8e
--- /dev/null
+++ b/stripe/params/issuing/_authorization_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AuthorizationRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_authorization_reverse_params.py b/stripe/params/issuing/_authorization_reverse_params.py
new file mode 100644
index 000000000..5788d84fd
--- /dev/null
+++ b/stripe/params/issuing/_authorization_reverse_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class AuthorizationReverseParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ reverse_amount: NotRequired[int]
+ """
+ The amount to reverse from the authorization. If not provided, the full amount of the authorization will be reversed. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
diff --git a/stripe/params/issuing/_authorization_update_params.py b/stripe/params/issuing/_authorization_update_params.py
new file mode 100644
index 000000000..6734372bf
--- /dev/null
+++ b/stripe/params/issuing/_authorization_update_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AuthorizationUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/issuing/_card_create_params.py b/stripe/params/issuing/_card_create_params.py
new file mode 100644
index 000000000..6b5059c9a
--- /dev/null
+++ b/stripe/params/issuing/_card_create_params.py
@@ -0,0 +1,1103 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CardCreateParams(RequestOptions):
+ cardholder: NotRequired[str]
+ """
+ The [Cardholder](https://stripe.com/docs/api#issuing_cardholder_object) object with which the card will be associated.
+ """
+ currency: str
+ """
+ The currency for the card.
+ """
+ exp_month: NotRequired[int]
+ """
+ The desired expiration month (1-12) for this card if [specifying a custom expiration date](https://docs.stripe.com/issuing/cards/virtual/issue-cards?testing-method=with-code#exp-dates).
+ """
+ exp_year: NotRequired[int]
+ """
+ The desired 4-digit expiration year for this card if [specifying a custom expiration date](https://docs.stripe.com/issuing/cards/virtual/issue-cards?testing-method=with-code#exp-dates).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: NotRequired[str]
+ """
+ The new financial account ID the card will be associated with. This field allows a card to be reassigned to a different financial account.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ personalization_design: NotRequired[str]
+ """
+ The personalization design object belonging to this card.
+ """
+ pin: NotRequired["CardCreateParamsPin"]
+ """
+ The desired PIN for this card.
+ """
+ replacement_for: NotRequired[str]
+ """
+ The card this is meant to be a replacement for (if any).
+ """
+ replacement_reason: NotRequired[
+ Literal["damaged", "expired", "lost", "stolen"]
+ ]
+ """
+ If `replacement_for` is specified, this should indicate why that card is being replaced.
+ """
+ second_line: NotRequired["Literal['']|str"]
+ """
+ The second line to print on the card. Max length: 24 characters.
+ """
+ shipping: NotRequired["CardCreateParamsShipping"]
+ """
+ The address where the card will be shipped.
+ """
+ spending_controls: NotRequired["CardCreateParamsSpendingControls"]
+ """
+ Rules that control spending for this card. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
+ """
+ status: NotRequired[Literal["active", "inactive"]]
+ """
+ Whether authorizations can be approved on this card. May be blocked from activating cards depending on past-due Cardholder requirements. Defaults to `inactive`.
+ """
+ type: Literal["physical", "virtual"]
+ """
+ The type of card to issue. Possible values are `physical` or `virtual`.
+ """
+
+
+class CardCreateParamsPin(TypedDict):
+ encrypted_number: NotRequired[str]
+ """
+ The card's desired new PIN, encrypted under Stripe's public key.
+ """
+
+
+class CardCreateParamsShipping(TypedDict):
+ address: "CardCreateParamsShippingAddress"
+ """
+ The address that the card is shipped to.
+ """
+ address_validation: NotRequired[
+ "CardCreateParamsShippingAddressValidation"
+ ]
+ """
+ Address validation settings.
+ """
+ customs: NotRequired["CardCreateParamsShippingCustoms"]
+ """
+ Customs information for the shipment.
+ """
+ name: str
+ """
+ The name printed on the shipping label when shipping the card.
+ """
+ phone_number: NotRequired[str]
+ """
+ Phone number of the recipient of the shipment.
+ """
+ require_signature: NotRequired[bool]
+ """
+ Whether a signature is required for card delivery.
+ """
+ service: NotRequired[Literal["express", "priority", "standard"]]
+ """
+ Shipment service.
+ """
+ type: NotRequired[Literal["bulk", "individual"]]
+ """
+ Packaging options.
+ """
+
+
+class CardCreateParamsShippingAddress(TypedDict):
+ city: str
+ """
+ City, district, suburb, town, or village.
+ """
+ country: str
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: str
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: str
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class CardCreateParamsShippingAddressValidation(TypedDict):
+ mode: Literal[
+ "disabled", "normalization_only", "validation_and_normalization"
+ ]
+ """
+ The address validation capabilities to use.
+ """
+
+
+class CardCreateParamsShippingCustoms(TypedDict):
+ eori_number: NotRequired[str]
+ """
+ The Economic Operators Registration and Identification (EORI) number to use for Customs. Required for bulk shipments to Europe.
+ """
+
+
+class CardCreateParamsSpendingControls(TypedDict):
+ allowed_categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
+ """
+ allowed_merchant_countries: NotRequired[List[str]]
+ """
+ Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
+ """
+ blocked_categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
+ """
+ blocked_merchant_countries: NotRequired[List[str]]
+ """
+ Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
+ """
+ spending_limits: NotRequired[
+ List["CardCreateParamsSpendingControlsSpendingLimit"]
+ ]
+ """
+ Limit spending with amount-based rules that apply across any cards this card replaced (i.e., its `replacement_for` card and _that_ card's `replacement_for` card, up the chain).
+ """
+
+
+class CardCreateParamsSpendingControlsSpendingLimit(TypedDict):
+ amount: int
+ """
+ Maximum amount allowed to spend per interval.
+ """
+ categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
+ """
+ interval: Literal[
+ "all_time", "daily", "monthly", "per_authorization", "weekly", "yearly"
+ ]
+ """
+ Interval (or event) to which the amount applies.
+ """
diff --git a/stripe/params/issuing/_card_deliver_card_params.py b/stripe/params/issuing/_card_deliver_card_params.py
new file mode 100644
index 000000000..4c5883138
--- /dev/null
+++ b/stripe/params/issuing/_card_deliver_card_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CardDeliverCardParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_card_fail_card_params.py b/stripe/params/issuing/_card_fail_card_params.py
new file mode 100644
index 000000000..5ef9da9a0
--- /dev/null
+++ b/stripe/params/issuing/_card_fail_card_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CardFailCardParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_card_list_params.py b/stripe/params/issuing/_card_list_params.py
new file mode 100644
index 000000000..ebc0d470c
--- /dev/null
+++ b/stripe/params/issuing/_card_list_params.py
@@ -0,0 +1,72 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CardListParams(RequestOptions):
+ cardholder: NotRequired[str]
+ """
+ Only return cards belonging to the Cardholder with the provided ID.
+ """
+ created: NotRequired["CardListParamsCreated|int"]
+ """
+ Only return cards that were issued during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ exp_month: NotRequired[int]
+ """
+ Only return cards that have the given expiration month.
+ """
+ exp_year: NotRequired[int]
+ """
+ Only return cards that have the given expiration year.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ last4: NotRequired[str]
+ """
+ Only return cards that have the given last four digits.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ personalization_design: NotRequired[str]
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["active", "canceled", "inactive"]]
+ """
+ Only return cards that have the given status. One of `active`, `inactive`, or `canceled`.
+ """
+ type: NotRequired[Literal["physical", "virtual"]]
+ """
+ Only return cards that have the given type. One of `virtual` or `physical`.
+ """
+
+
+class CardListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/issuing/_card_modify_params.py b/stripe/params/issuing/_card_modify_params.py
new file mode 100644
index 000000000..f635f349d
--- /dev/null
+++ b/stripe/params/issuing/_card_modify_params.py
@@ -0,0 +1,1066 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CardModifyParams(RequestOptions):
+ cancellation_reason: NotRequired[Literal["lost", "stolen"]]
+ """
+ Reason why the `status` of this card is `canceled`.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ personalization_design: NotRequired[str]
+ pin: NotRequired["CardModifyParamsPin"]
+ """
+ The desired new PIN for this card.
+ """
+ shipping: NotRequired["CardModifyParamsShipping"]
+ """
+ Updated shipping information for the card.
+ """
+ spending_controls: NotRequired["CardModifyParamsSpendingControls"]
+ """
+ Rules that control spending for this card. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
+ """
+ status: NotRequired[Literal["active", "canceled", "inactive"]]
+ """
+ Dictates whether authorizations can be approved on this card. May be blocked from activating cards depending on past-due Cardholder requirements. Defaults to `inactive`. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`.
+ """
+
+
+class CardModifyParamsPin(TypedDict):
+ encrypted_number: NotRequired[str]
+ """
+ The card's desired new PIN, encrypted under Stripe's public key.
+ """
+
+
+class CardModifyParamsShipping(TypedDict):
+ address: "CardModifyParamsShippingAddress"
+ """
+ The address that the card is shipped to.
+ """
+ address_validation: NotRequired[
+ "CardModifyParamsShippingAddressValidation"
+ ]
+ """
+ Address validation settings.
+ """
+ customs: NotRequired["CardModifyParamsShippingCustoms"]
+ """
+ Customs information for the shipment.
+ """
+ name: str
+ """
+ The name printed on the shipping label when shipping the card.
+ """
+ phone_number: NotRequired[str]
+ """
+ Phone number of the recipient of the shipment.
+ """
+ require_signature: NotRequired[bool]
+ """
+ Whether a signature is required for card delivery.
+ """
+ service: NotRequired[Literal["express", "priority", "standard"]]
+ """
+ Shipment service.
+ """
+ type: NotRequired[Literal["bulk", "individual"]]
+ """
+ Packaging options.
+ """
+
+
+class CardModifyParamsShippingAddress(TypedDict):
+ city: str
+ """
+ City, district, suburb, town, or village.
+ """
+ country: str
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: str
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: str
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class CardModifyParamsShippingAddressValidation(TypedDict):
+ mode: Literal[
+ "disabled", "normalization_only", "validation_and_normalization"
+ ]
+ """
+ The address validation capabilities to use.
+ """
+
+
+class CardModifyParamsShippingCustoms(TypedDict):
+ eori_number: NotRequired[str]
+ """
+ The Economic Operators Registration and Identification (EORI) number to use for Customs. Required for bulk shipments to Europe.
+ """
+
+
+class CardModifyParamsSpendingControls(TypedDict):
+ allowed_categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
+ """
+ allowed_merchant_countries: NotRequired[List[str]]
+ """
+ Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
+ """
+ blocked_categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
+ """
+ blocked_merchant_countries: NotRequired[List[str]]
+ """
+ Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
+ """
+ spending_limits: NotRequired[
+ List["CardModifyParamsSpendingControlsSpendingLimit"]
+ ]
+ """
+ Limit spending with amount-based rules that apply across any cards this card replaced (i.e., its `replacement_for` card and _that_ card's `replacement_for` card, up the chain).
+ """
+
+
+class CardModifyParamsSpendingControlsSpendingLimit(TypedDict):
+ amount: int
+ """
+ Maximum amount allowed to spend per interval.
+ """
+ categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
+ """
+ interval: Literal[
+ "all_time", "daily", "monthly", "per_authorization", "weekly", "yearly"
+ ]
+ """
+ Interval (or event) to which the amount applies.
+ """
diff --git a/stripe/params/issuing/_card_retrieve_params.py b/stripe/params/issuing/_card_retrieve_params.py
new file mode 100644
index 000000000..4c3afad9a
--- /dev/null
+++ b/stripe/params/issuing/_card_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CardRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_card_return_card_params.py b/stripe/params/issuing/_card_return_card_params.py
new file mode 100644
index 000000000..1f18e8e18
--- /dev/null
+++ b/stripe/params/issuing/_card_return_card_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CardReturnCardParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_card_ship_card_params.py b/stripe/params/issuing/_card_ship_card_params.py
new file mode 100644
index 000000000..6071008df
--- /dev/null
+++ b/stripe/params/issuing/_card_ship_card_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CardShipCardParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_card_submit_card_params.py b/stripe/params/issuing/_card_submit_card_params.py
new file mode 100644
index 000000000..d31646696
--- /dev/null
+++ b/stripe/params/issuing/_card_submit_card_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CardSubmitCardParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_card_update_params.py b/stripe/params/issuing/_card_update_params.py
new file mode 100644
index 000000000..74a6a9d98
--- /dev/null
+++ b/stripe/params/issuing/_card_update_params.py
@@ -0,0 +1,1065 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CardUpdateParams(TypedDict):
+ cancellation_reason: NotRequired[Literal["lost", "stolen"]]
+ """
+ Reason why the `status` of this card is `canceled`.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ personalization_design: NotRequired[str]
+ pin: NotRequired["CardUpdateParamsPin"]
+ """
+ The desired new PIN for this card.
+ """
+ shipping: NotRequired["CardUpdateParamsShipping"]
+ """
+ Updated shipping information for the card.
+ """
+ spending_controls: NotRequired["CardUpdateParamsSpendingControls"]
+ """
+ Rules that control spending for this card. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
+ """
+ status: NotRequired[Literal["active", "canceled", "inactive"]]
+ """
+ Dictates whether authorizations can be approved on this card. May be blocked from activating cards depending on past-due Cardholder requirements. Defaults to `inactive`. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`.
+ """
+
+
+class CardUpdateParamsPin(TypedDict):
+ encrypted_number: NotRequired[str]
+ """
+ The card's desired new PIN, encrypted under Stripe's public key.
+ """
+
+
+class CardUpdateParamsShipping(TypedDict):
+ address: "CardUpdateParamsShippingAddress"
+ """
+ The address that the card is shipped to.
+ """
+ address_validation: NotRequired[
+ "CardUpdateParamsShippingAddressValidation"
+ ]
+ """
+ Address validation settings.
+ """
+ customs: NotRequired["CardUpdateParamsShippingCustoms"]
+ """
+ Customs information for the shipment.
+ """
+ name: str
+ """
+ The name printed on the shipping label when shipping the card.
+ """
+ phone_number: NotRequired[str]
+ """
+ Phone number of the recipient of the shipment.
+ """
+ require_signature: NotRequired[bool]
+ """
+ Whether a signature is required for card delivery.
+ """
+ service: NotRequired[Literal["express", "priority", "standard"]]
+ """
+ Shipment service.
+ """
+ type: NotRequired[Literal["bulk", "individual"]]
+ """
+ Packaging options.
+ """
+
+
+class CardUpdateParamsShippingAddress(TypedDict):
+ city: str
+ """
+ City, district, suburb, town, or village.
+ """
+ country: str
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: str
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: str
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class CardUpdateParamsShippingAddressValidation(TypedDict):
+ mode: Literal[
+ "disabled", "normalization_only", "validation_and_normalization"
+ ]
+ """
+ The address validation capabilities to use.
+ """
+
+
+class CardUpdateParamsShippingCustoms(TypedDict):
+ eori_number: NotRequired[str]
+ """
+ The Economic Operators Registration and Identification (EORI) number to use for Customs. Required for bulk shipments to Europe.
+ """
+
+
+class CardUpdateParamsSpendingControls(TypedDict):
+ allowed_categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
+ """
+ allowed_merchant_countries: NotRequired[List[str]]
+ """
+ Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
+ """
+ blocked_categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
+ """
+ blocked_merchant_countries: NotRequired[List[str]]
+ """
+ Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
+ """
+ spending_limits: NotRequired[
+ List["CardUpdateParamsSpendingControlsSpendingLimit"]
+ ]
+ """
+ Limit spending with amount-based rules that apply across any cards this card replaced (i.e., its `replacement_for` card and _that_ card's `replacement_for` card, up the chain).
+ """
+
+
+class CardUpdateParamsSpendingControlsSpendingLimit(TypedDict):
+ amount: int
+ """
+ Maximum amount allowed to spend per interval.
+ """
+ categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
+ """
+ interval: Literal[
+ "all_time", "daily", "monthly", "per_authorization", "weekly", "yearly"
+ ]
+ """
+ Interval (or event) to which the amount applies.
+ """
diff --git a/stripe/params/issuing/_cardholder_create_params.py b/stripe/params/issuing/_cardholder_create_params.py
new file mode 100644
index 000000000..a5caa9e09
--- /dev/null
+++ b/stripe/params/issuing/_cardholder_create_params.py
@@ -0,0 +1,1128 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CardholderCreateParams(RequestOptions):
+ billing: "CardholderCreateParamsBilling"
+ """
+ The cardholder's billing address.
+ """
+ company: NotRequired["CardholderCreateParamsCompany"]
+ """
+ Additional information about a `company` cardholder.
+ """
+ email: NotRequired[str]
+ """
+ The cardholder's email address.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ individual: NotRequired["CardholderCreateParamsIndividual"]
+ """
+ Additional information about an `individual` cardholder.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: str
+ """
+ The cardholder's name. This will be printed on cards issued to them. The maximum length of this field is 24 characters. This field cannot contain any special characters or numbers.
+ """
+ phone_number: NotRequired[str]
+ """
+ The cardholder's phone number. This will be transformed to [E.164](https://en.wikipedia.org/wiki/E.164) if it is not provided in that format already. This is required for all cardholders who will be creating EU cards. See the [3D Secure documentation](https://stripe.com/docs/issuing/3d-secure#when-is-3d-secure-applied) for more details.
+ """
+ preferred_locales: NotRequired[List[Literal["de", "en", "es", "fr", "it"]]]
+ """
+ The cardholder's preferred locales (languages), ordered by preference. Locales can be `de`, `en`, `es`, `fr`, or `it`.
+ This changes the language of the [3D Secure flow](https://stripe.com/docs/issuing/3d-secure) and one-time password messages sent to the cardholder.
+ """
+ spending_controls: NotRequired["CardholderCreateParamsSpendingControls"]
+ """
+ Rules that control spending across this cardholder's cards. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
+ """
+ status: NotRequired[Literal["active", "inactive"]]
+ """
+ Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`.
+ """
+ type: NotRequired[Literal["company", "individual"]]
+ """
+ One of `individual` or `company`. See [Choose a cardholder type](https://stripe.com/docs/issuing/other/choose-cardholder) for more details.
+ """
+
+
+class CardholderCreateParamsBilling(TypedDict):
+ address: "CardholderCreateParamsBillingAddress"
+ """
+ The cardholder's billing address.
+ """
+
+
+class CardholderCreateParamsBillingAddress(TypedDict):
+ city: str
+ """
+ City, district, suburb, town, or village.
+ """
+ country: str
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: str
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: str
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class CardholderCreateParamsCompany(TypedDict):
+ tax_id: NotRequired[str]
+ """
+ The entity's business ID number.
+ """
+
+
+class CardholderCreateParamsIndividual(TypedDict):
+ card_issuing: NotRequired["CardholderCreateParamsIndividualCardIssuing"]
+ """
+ Information related to the card_issuing program for this cardholder.
+ """
+ dob: NotRequired["CardholderCreateParamsIndividualDob"]
+ """
+ The date of birth of this cardholder. Cardholders must be older than 13 years old.
+ """
+ first_name: NotRequired[str]
+ """
+ The first name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
+ """
+ last_name: NotRequired[str]
+ """
+ The last name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
+ """
+ verification: NotRequired["CardholderCreateParamsIndividualVerification"]
+ """
+ Government-issued ID document for this cardholder.
+ """
+
+
+class CardholderCreateParamsIndividualCardIssuing(TypedDict):
+ user_terms_acceptance: NotRequired[
+ "CardholderCreateParamsIndividualCardIssuingUserTermsAcceptance"
+ ]
+ """
+ Information about cardholder acceptance of Celtic [Authorized User Terms](https://stripe.com/docs/issuing/cards#accept-authorized-user-terms). Required for cards backed by a Celtic program.
+ """
+
+
+class CardholderCreateParamsIndividualCardIssuingUserTermsAcceptance(
+ TypedDict
+):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
+ """
+ user_agent: NotRequired["Literal['']|str"]
+ """
+ The user agent of the browser from which the cardholder accepted the Authorized User Terms.
+ """
+
+
+class CardholderCreateParamsIndividualDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class CardholderCreateParamsIndividualVerification(TypedDict):
+ document: NotRequired[
+ "CardholderCreateParamsIndividualVerificationDocument"
+ ]
+ """
+ An identifying document, either a passport or local ID card.
+ """
+
+
+class CardholderCreateParamsIndividualVerificationDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
+ """
+
+
+class CardholderCreateParamsSpendingControls(TypedDict):
+ allowed_categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
+ """
+ allowed_merchant_countries: NotRequired[List[str]]
+ """
+ Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
+ """
+ blocked_categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
+ """
+ blocked_merchant_countries: NotRequired[List[str]]
+ """
+ Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
+ """
+ spending_limits: NotRequired[
+ List["CardholderCreateParamsSpendingControlsSpendingLimit"]
+ ]
+ """
+ Limit spending with amount-based rules that apply across this cardholder's cards.
+ """
+ spending_limits_currency: NotRequired[str]
+ """
+ Currency of amounts within `spending_limits`. Defaults to your merchant country's currency.
+ """
+
+
+class CardholderCreateParamsSpendingControlsSpendingLimit(TypedDict):
+ amount: int
+ """
+ Maximum amount allowed to spend per interval.
+ """
+ categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
+ """
+ interval: Literal[
+ "all_time", "daily", "monthly", "per_authorization", "weekly", "yearly"
+ ]
+ """
+ Interval (or event) to which the amount applies.
+ """
diff --git a/stripe/params/issuing/_cardholder_list_params.py b/stripe/params/issuing/_cardholder_list_params.py
new file mode 100644
index 000000000..00fc05d23
--- /dev/null
+++ b/stripe/params/issuing/_cardholder_list_params.py
@@ -0,0 +1,63 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CardholderListParams(RequestOptions):
+ created: NotRequired["CardholderListParamsCreated|int"]
+ """
+ Only return cardholders that were created during the given date interval.
+ """
+ email: NotRequired[str]
+ """
+ Only return cardholders that have the given email address.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ phone_number: NotRequired[str]
+ """
+ Only return cardholders that have the given phone number.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["active", "blocked", "inactive"]]
+ """
+ Only return cardholders that have the given status. One of `active`, `inactive`, or `blocked`.
+ """
+ type: NotRequired[Literal["company", "individual"]]
+ """
+ Only return cardholders that have the given type. One of `individual` or `company`.
+ """
+
+
+class CardholderListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/issuing/_cardholder_modify_params.py b/stripe/params/issuing/_cardholder_modify_params.py
new file mode 100644
index 000000000..74bfc8406
--- /dev/null
+++ b/stripe/params/issuing/_cardholder_modify_params.py
@@ -0,0 +1,1120 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CardholderModifyParams(RequestOptions):
+ billing: NotRequired["CardholderModifyParamsBilling"]
+ """
+ The cardholder's billing address.
+ """
+ company: NotRequired["CardholderModifyParamsCompany"]
+ """
+ Additional information about a `company` cardholder.
+ """
+ email: NotRequired[str]
+ """
+ The cardholder's email address.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ individual: NotRequired["CardholderModifyParamsIndividual"]
+ """
+ Additional information about an `individual` cardholder.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ phone_number: NotRequired[str]
+ """
+ The cardholder's phone number. This is required for all cardholders who will be creating EU cards. See the [3D Secure documentation](https://stripe.com/docs/issuing/3d-secure) for more details.
+ """
+ preferred_locales: NotRequired[List[Literal["de", "en", "es", "fr", "it"]]]
+ """
+ The cardholder's preferred locales (languages), ordered by preference. Locales can be `de`, `en`, `es`, `fr`, or `it`.
+ This changes the language of the [3D Secure flow](https://stripe.com/docs/issuing/3d-secure) and one-time password messages sent to the cardholder.
+ """
+ spending_controls: NotRequired["CardholderModifyParamsSpendingControls"]
+ """
+ Rules that control spending across this cardholder's cards. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
+ """
+ status: NotRequired[Literal["active", "inactive"]]
+ """
+ Specifies whether to permit authorizations on this cardholder's cards.
+ """
+
+
+class CardholderModifyParamsBilling(TypedDict):
+ address: "CardholderModifyParamsBillingAddress"
+ """
+ The cardholder's billing address.
+ """
+
+
+class CardholderModifyParamsBillingAddress(TypedDict):
+ city: str
+ """
+ City, district, suburb, town, or village.
+ """
+ country: str
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: str
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: str
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class CardholderModifyParamsCompany(TypedDict):
+ tax_id: NotRequired[str]
+ """
+ The entity's business ID number.
+ """
+
+
+class CardholderModifyParamsIndividual(TypedDict):
+ card_issuing: NotRequired["CardholderModifyParamsIndividualCardIssuing"]
+ """
+ Information related to the card_issuing program for this cardholder.
+ """
+ dob: NotRequired["CardholderModifyParamsIndividualDob"]
+ """
+ The date of birth of this cardholder. Cardholders must be older than 13 years old.
+ """
+ first_name: NotRequired[str]
+ """
+ The first name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
+ """
+ last_name: NotRequired[str]
+ """
+ The last name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
+ """
+ verification: NotRequired["CardholderModifyParamsIndividualVerification"]
+ """
+ Government-issued ID document for this cardholder.
+ """
+
+
+class CardholderModifyParamsIndividualCardIssuing(TypedDict):
+ user_terms_acceptance: NotRequired[
+ "CardholderModifyParamsIndividualCardIssuingUserTermsAcceptance"
+ ]
+ """
+ Information about cardholder acceptance of Celtic [Authorized User Terms](https://stripe.com/docs/issuing/cards#accept-authorized-user-terms). Required for cards backed by a Celtic program.
+ """
+
+
+class CardholderModifyParamsIndividualCardIssuingUserTermsAcceptance(
+ TypedDict
+):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
+ """
+ user_agent: NotRequired["Literal['']|str"]
+ """
+ The user agent of the browser from which the cardholder accepted the Authorized User Terms.
+ """
+
+
+class CardholderModifyParamsIndividualDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class CardholderModifyParamsIndividualVerification(TypedDict):
+ document: NotRequired[
+ "CardholderModifyParamsIndividualVerificationDocument"
+ ]
+ """
+ An identifying document, either a passport or local ID card.
+ """
+
+
+class CardholderModifyParamsIndividualVerificationDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
+ """
+
+
+class CardholderModifyParamsSpendingControls(TypedDict):
+ allowed_categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
+ """
+ allowed_merchant_countries: NotRequired[List[str]]
+ """
+ Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
+ """
+ blocked_categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
+ """
+ blocked_merchant_countries: NotRequired[List[str]]
+ """
+ Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
+ """
+ spending_limits: NotRequired[
+ List["CardholderModifyParamsSpendingControlsSpendingLimit"]
+ ]
+ """
+ Limit spending with amount-based rules that apply across this cardholder's cards.
+ """
+ spending_limits_currency: NotRequired[str]
+ """
+ Currency of amounts within `spending_limits`. Defaults to your merchant country's currency.
+ """
+
+
+class CardholderModifyParamsSpendingControlsSpendingLimit(TypedDict):
+ amount: int
+ """
+ Maximum amount allowed to spend per interval.
+ """
+ categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
+ """
+ interval: Literal[
+ "all_time", "daily", "monthly", "per_authorization", "weekly", "yearly"
+ ]
+ """
+ Interval (or event) to which the amount applies.
+ """
diff --git a/stripe/params/issuing/_cardholder_retrieve_params.py b/stripe/params/issuing/_cardholder_retrieve_params.py
new file mode 100644
index 000000000..43bdef06d
--- /dev/null
+++ b/stripe/params/issuing/_cardholder_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CardholderRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_cardholder_update_params.py b/stripe/params/issuing/_cardholder_update_params.py
new file mode 100644
index 000000000..ffc9c2898
--- /dev/null
+++ b/stripe/params/issuing/_cardholder_update_params.py
@@ -0,0 +1,1119 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CardholderUpdateParams(TypedDict):
+ billing: NotRequired["CardholderUpdateParamsBilling"]
+ """
+ The cardholder's billing address.
+ """
+ company: NotRequired["CardholderUpdateParamsCompany"]
+ """
+ Additional information about a `company` cardholder.
+ """
+ email: NotRequired[str]
+ """
+ The cardholder's email address.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ individual: NotRequired["CardholderUpdateParamsIndividual"]
+ """
+ Additional information about an `individual` cardholder.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ phone_number: NotRequired[str]
+ """
+ The cardholder's phone number. This is required for all cardholders who will be creating EU cards. See the [3D Secure documentation](https://stripe.com/docs/issuing/3d-secure) for more details.
+ """
+ preferred_locales: NotRequired[List[Literal["de", "en", "es", "fr", "it"]]]
+ """
+ The cardholder's preferred locales (languages), ordered by preference. Locales can be `de`, `en`, `es`, `fr`, or `it`.
+ This changes the language of the [3D Secure flow](https://stripe.com/docs/issuing/3d-secure) and one-time password messages sent to the cardholder.
+ """
+ spending_controls: NotRequired["CardholderUpdateParamsSpendingControls"]
+ """
+ Rules that control spending across this cardholder's cards. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
+ """
+ status: NotRequired[Literal["active", "inactive"]]
+ """
+ Specifies whether to permit authorizations on this cardholder's cards.
+ """
+
+
+class CardholderUpdateParamsBilling(TypedDict):
+ address: "CardholderUpdateParamsBillingAddress"
+ """
+ The cardholder's billing address.
+ """
+
+
+class CardholderUpdateParamsBillingAddress(TypedDict):
+ city: str
+ """
+ City, district, suburb, town, or village.
+ """
+ country: str
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: str
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: str
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class CardholderUpdateParamsCompany(TypedDict):
+ tax_id: NotRequired[str]
+ """
+ The entity's business ID number.
+ """
+
+
+class CardholderUpdateParamsIndividual(TypedDict):
+ card_issuing: NotRequired["CardholderUpdateParamsIndividualCardIssuing"]
+ """
+ Information related to the card_issuing program for this cardholder.
+ """
+ dob: NotRequired["CardholderUpdateParamsIndividualDob"]
+ """
+ The date of birth of this cardholder. Cardholders must be older than 13 years old.
+ """
+ first_name: NotRequired[str]
+ """
+ The first name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
+ """
+ last_name: NotRequired[str]
+ """
+ The last name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
+ """
+ verification: NotRequired["CardholderUpdateParamsIndividualVerification"]
+ """
+ Government-issued ID document for this cardholder.
+ """
+
+
+class CardholderUpdateParamsIndividualCardIssuing(TypedDict):
+ user_terms_acceptance: NotRequired[
+ "CardholderUpdateParamsIndividualCardIssuingUserTermsAcceptance"
+ ]
+ """
+ Information about cardholder acceptance of Celtic [Authorized User Terms](https://stripe.com/docs/issuing/cards#accept-authorized-user-terms). Required for cards backed by a Celtic program.
+ """
+
+
+class CardholderUpdateParamsIndividualCardIssuingUserTermsAcceptance(
+ TypedDict
+):
+ date: NotRequired[int]
+ """
+ The Unix timestamp marking when the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
+ """
+ ip: NotRequired[str]
+ """
+ The IP address from which the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
+ """
+ user_agent: NotRequired["Literal['']|str"]
+ """
+ The user agent of the browser from which the cardholder accepted the Authorized User Terms.
+ """
+
+
+class CardholderUpdateParamsIndividualDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class CardholderUpdateParamsIndividualVerification(TypedDict):
+ document: NotRequired[
+ "CardholderUpdateParamsIndividualVerificationDocument"
+ ]
+ """
+ An identifying document, either a passport or local ID card.
+ """
+
+
+class CardholderUpdateParamsIndividualVerificationDocument(TypedDict):
+ back: NotRequired[str]
+ """
+ The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
+ """
+ front: NotRequired[str]
+ """
+ The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
+ """
+
+
+class CardholderUpdateParamsSpendingControls(TypedDict):
+ allowed_categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
+ """
+ allowed_merchant_countries: NotRequired[List[str]]
+ """
+ Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
+ """
+ blocked_categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
+ """
+ blocked_merchant_countries: NotRequired[List[str]]
+ """
+ Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
+ """
+ spending_limits: NotRequired[
+ List["CardholderUpdateParamsSpendingControlsSpendingLimit"]
+ ]
+ """
+ Limit spending with amount-based rules that apply across this cardholder's cards.
+ """
+ spending_limits_currency: NotRequired[str]
+ """
+ Currency of amounts within `spending_limits`. Defaults to your merchant country's currency.
+ """
+
+
+class CardholderUpdateParamsSpendingControlsSpendingLimit(TypedDict):
+ amount: int
+ """
+ Maximum amount allowed to spend per interval.
+ """
+ categories: NotRequired[
+ List[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ ]
+ """
+ Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
+ """
+ interval: Literal[
+ "all_time", "daily", "monthly", "per_authorization", "weekly", "yearly"
+ ]
+ """
+ Interval (or event) to which the amount applies.
+ """
diff --git a/stripe/params/issuing/_dispute_create_params.py b/stripe/params/issuing/_dispute_create_params.py
new file mode 100644
index 000000000..4fdc92093
--- /dev/null
+++ b/stripe/params/issuing/_dispute_create_params.py
@@ -0,0 +1,287 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class DisputeCreateParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ The dispute amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). If not set, defaults to the full transaction amount.
+ """
+ evidence: NotRequired["DisputeCreateParamsEvidence"]
+ """
+ Evidence provided for the dispute.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ transaction: NotRequired[str]
+ """
+ The ID of the issuing transaction to create a dispute for. For transaction on Treasury FinancialAccounts, use `treasury.received_debit`.
+ """
+ treasury: NotRequired["DisputeCreateParamsTreasury"]
+ """
+ Params for disputes related to Treasury FinancialAccounts
+ """
+
+
+class DisputeCreateParamsEvidence(TypedDict):
+ canceled: NotRequired["Literal['']|DisputeCreateParamsEvidenceCanceled"]
+ """
+ Evidence provided when `reason` is 'canceled'.
+ """
+ duplicate: NotRequired["Literal['']|DisputeCreateParamsEvidenceDuplicate"]
+ """
+ Evidence provided when `reason` is 'duplicate'.
+ """
+ fraudulent: NotRequired[
+ "Literal['']|DisputeCreateParamsEvidenceFraudulent"
+ ]
+ """
+ Evidence provided when `reason` is 'fraudulent'.
+ """
+ merchandise_not_as_described: NotRequired[
+ "Literal['']|DisputeCreateParamsEvidenceMerchandiseNotAsDescribed"
+ ]
+ """
+ Evidence provided when `reason` is 'merchandise_not_as_described'.
+ """
+ no_valid_authorization: NotRequired[
+ "Literal['']|DisputeCreateParamsEvidenceNoValidAuthorization"
+ ]
+ """
+ Evidence provided when `reason` is 'no_valid_authorization'.
+ """
+ not_received: NotRequired[
+ "Literal['']|DisputeCreateParamsEvidenceNotReceived"
+ ]
+ """
+ Evidence provided when `reason` is 'not_received'.
+ """
+ other: NotRequired["Literal['']|DisputeCreateParamsEvidenceOther"]
+ """
+ Evidence provided when `reason` is 'other'.
+ """
+ reason: NotRequired[
+ Literal[
+ "canceled",
+ "duplicate",
+ "fraudulent",
+ "merchandise_not_as_described",
+ "no_valid_authorization",
+ "not_received",
+ "other",
+ "service_not_as_described",
+ ]
+ ]
+ """
+ The reason for filing the dispute. The evidence should be submitted in the field of the same name.
+ """
+ service_not_as_described: NotRequired[
+ "Literal['']|DisputeCreateParamsEvidenceServiceNotAsDescribed"
+ ]
+ """
+ Evidence provided when `reason` is 'service_not_as_described'.
+ """
+
+
+class DisputeCreateParamsEvidenceCanceled(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ canceled_at: NotRequired["Literal['']|int"]
+ """
+ Date when order was canceled.
+ """
+ cancellation_policy_provided: NotRequired["Literal['']|bool"]
+ """
+ Whether the cardholder was provided with a cancellation policy.
+ """
+ cancellation_reason: NotRequired["Literal['']|str"]
+ """
+ Reason for canceling the order.
+ """
+ expected_at: NotRequired["Literal['']|int"]
+ """
+ Date when the cardholder expected to receive the product.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ Description of the merchandise or service that was purchased.
+ """
+ product_type: NotRequired["Literal['']|Literal['merchandise', 'service']"]
+ """
+ Whether the product was a merchandise or service.
+ """
+ return_status: NotRequired[
+ "Literal['']|Literal['merchant_rejected', 'successful']"
+ ]
+ """
+ Result of cardholder's attempt to return the product.
+ """
+ returned_at: NotRequired["Literal['']|int"]
+ """
+ Date when the product was returned or attempted to be returned.
+ """
+
+
+class DisputeCreateParamsEvidenceDuplicate(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ card_statement: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the card statement showing that the product had already been paid for.
+ """
+ cash_receipt: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the receipt showing that the product had been paid for in cash.
+ """
+ check_image: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Image of the front and back of the check that was used to pay for the product.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ original_transaction: NotRequired[str]
+ """
+ Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one.
+ """
+
+
+class DisputeCreateParamsEvidenceFraudulent(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+
+
+class DisputeCreateParamsEvidenceMerchandiseNotAsDescribed(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ received_at: NotRequired["Literal['']|int"]
+ """
+ Date when the product was received.
+ """
+ return_description: NotRequired["Literal['']|str"]
+ """
+ Description of the cardholder's attempt to return the product.
+ """
+ return_status: NotRequired[
+ "Literal['']|Literal['merchant_rejected', 'successful']"
+ ]
+ """
+ Result of cardholder's attempt to return the product.
+ """
+ returned_at: NotRequired["Literal['']|int"]
+ """
+ Date when the product was returned or attempted to be returned.
+ """
+
+
+class DisputeCreateParamsEvidenceNoValidAuthorization(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+
+
+class DisputeCreateParamsEvidenceNotReceived(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ expected_at: NotRequired["Literal['']|int"]
+ """
+ Date when the cardholder expected to receive the product.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ Description of the merchandise or service that was purchased.
+ """
+ product_type: NotRequired["Literal['']|Literal['merchandise', 'service']"]
+ """
+ Whether the product was a merchandise or service.
+ """
+
+
+class DisputeCreateParamsEvidenceOther(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ Description of the merchandise or service that was purchased.
+ """
+ product_type: NotRequired["Literal['']|Literal['merchandise', 'service']"]
+ """
+ Whether the product was a merchandise or service.
+ """
+
+
+class DisputeCreateParamsEvidenceServiceNotAsDescribed(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ canceled_at: NotRequired["Literal['']|int"]
+ """
+ Date when order was canceled.
+ """
+ cancellation_reason: NotRequired["Literal['']|str"]
+ """
+ Reason for canceling the order.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ received_at: NotRequired["Literal['']|int"]
+ """
+ Date when the product was received.
+ """
+
+
+class DisputeCreateParamsTreasury(TypedDict):
+ received_debit: str
+ """
+ The ID of the ReceivedDebit to initiate an Issuings dispute for.
+ """
diff --git a/stripe/params/issuing/_dispute_list_params.py b/stripe/params/issuing/_dispute_list_params.py
new file mode 100644
index 000000000..f613beba0
--- /dev/null
+++ b/stripe/params/issuing/_dispute_list_params.py
@@ -0,0 +1,57 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class DisputeListParams(RequestOptions):
+ created: NotRequired["DisputeListParamsCreated|int"]
+ """
+ Only return Issuing disputes that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[
+ Literal["expired", "lost", "submitted", "unsubmitted", "won"]
+ ]
+ """
+ Select Issuing disputes with the given status.
+ """
+ transaction: NotRequired[str]
+ """
+ Select the Issuing dispute for the given transaction.
+ """
+
+
+class DisputeListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/issuing/_dispute_modify_params.py b/stripe/params/issuing/_dispute_modify_params.py
new file mode 100644
index 000000000..2843be9cd
--- /dev/null
+++ b/stripe/params/issuing/_dispute_modify_params.py
@@ -0,0 +1,272 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class DisputeModifyParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ The dispute amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ evidence: NotRequired["DisputeModifyParamsEvidence"]
+ """
+ Evidence provided for the dispute.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+
+
+class DisputeModifyParamsEvidence(TypedDict):
+ canceled: NotRequired["Literal['']|DisputeModifyParamsEvidenceCanceled"]
+ """
+ Evidence provided when `reason` is 'canceled'.
+ """
+ duplicate: NotRequired["Literal['']|DisputeModifyParamsEvidenceDuplicate"]
+ """
+ Evidence provided when `reason` is 'duplicate'.
+ """
+ fraudulent: NotRequired[
+ "Literal['']|DisputeModifyParamsEvidenceFraudulent"
+ ]
+ """
+ Evidence provided when `reason` is 'fraudulent'.
+ """
+ merchandise_not_as_described: NotRequired[
+ "Literal['']|DisputeModifyParamsEvidenceMerchandiseNotAsDescribed"
+ ]
+ """
+ Evidence provided when `reason` is 'merchandise_not_as_described'.
+ """
+ no_valid_authorization: NotRequired[
+ "Literal['']|DisputeModifyParamsEvidenceNoValidAuthorization"
+ ]
+ """
+ Evidence provided when `reason` is 'no_valid_authorization'.
+ """
+ not_received: NotRequired[
+ "Literal['']|DisputeModifyParamsEvidenceNotReceived"
+ ]
+ """
+ Evidence provided when `reason` is 'not_received'.
+ """
+ other: NotRequired["Literal['']|DisputeModifyParamsEvidenceOther"]
+ """
+ Evidence provided when `reason` is 'other'.
+ """
+ reason: NotRequired[
+ Literal[
+ "canceled",
+ "duplicate",
+ "fraudulent",
+ "merchandise_not_as_described",
+ "no_valid_authorization",
+ "not_received",
+ "other",
+ "service_not_as_described",
+ ]
+ ]
+ """
+ The reason for filing the dispute. The evidence should be submitted in the field of the same name.
+ """
+ service_not_as_described: NotRequired[
+ "Literal['']|DisputeModifyParamsEvidenceServiceNotAsDescribed"
+ ]
+ """
+ Evidence provided when `reason` is 'service_not_as_described'.
+ """
+
+
+class DisputeModifyParamsEvidenceCanceled(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ canceled_at: NotRequired["Literal['']|int"]
+ """
+ Date when order was canceled.
+ """
+ cancellation_policy_provided: NotRequired["Literal['']|bool"]
+ """
+ Whether the cardholder was provided with a cancellation policy.
+ """
+ cancellation_reason: NotRequired["Literal['']|str"]
+ """
+ Reason for canceling the order.
+ """
+ expected_at: NotRequired["Literal['']|int"]
+ """
+ Date when the cardholder expected to receive the product.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ Description of the merchandise or service that was purchased.
+ """
+ product_type: NotRequired["Literal['']|Literal['merchandise', 'service']"]
+ """
+ Whether the product was a merchandise or service.
+ """
+ return_status: NotRequired[
+ "Literal['']|Literal['merchant_rejected', 'successful']"
+ ]
+ """
+ Result of cardholder's attempt to return the product.
+ """
+ returned_at: NotRequired["Literal['']|int"]
+ """
+ Date when the product was returned or attempted to be returned.
+ """
+
+
+class DisputeModifyParamsEvidenceDuplicate(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ card_statement: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the card statement showing that the product had already been paid for.
+ """
+ cash_receipt: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the receipt showing that the product had been paid for in cash.
+ """
+ check_image: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Image of the front and back of the check that was used to pay for the product.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ original_transaction: NotRequired[str]
+ """
+ Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one.
+ """
+
+
+class DisputeModifyParamsEvidenceFraudulent(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+
+
+class DisputeModifyParamsEvidenceMerchandiseNotAsDescribed(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ received_at: NotRequired["Literal['']|int"]
+ """
+ Date when the product was received.
+ """
+ return_description: NotRequired["Literal['']|str"]
+ """
+ Description of the cardholder's attempt to return the product.
+ """
+ return_status: NotRequired[
+ "Literal['']|Literal['merchant_rejected', 'successful']"
+ ]
+ """
+ Result of cardholder's attempt to return the product.
+ """
+ returned_at: NotRequired["Literal['']|int"]
+ """
+ Date when the product was returned or attempted to be returned.
+ """
+
+
+class DisputeModifyParamsEvidenceNoValidAuthorization(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+
+
+class DisputeModifyParamsEvidenceNotReceived(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ expected_at: NotRequired["Literal['']|int"]
+ """
+ Date when the cardholder expected to receive the product.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ Description of the merchandise or service that was purchased.
+ """
+ product_type: NotRequired["Literal['']|Literal['merchandise', 'service']"]
+ """
+ Whether the product was a merchandise or service.
+ """
+
+
+class DisputeModifyParamsEvidenceOther(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ Description of the merchandise or service that was purchased.
+ """
+ product_type: NotRequired["Literal['']|Literal['merchandise', 'service']"]
+ """
+ Whether the product was a merchandise or service.
+ """
+
+
+class DisputeModifyParamsEvidenceServiceNotAsDescribed(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ canceled_at: NotRequired["Literal['']|int"]
+ """
+ Date when order was canceled.
+ """
+ cancellation_reason: NotRequired["Literal['']|str"]
+ """
+ Reason for canceling the order.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ received_at: NotRequired["Literal['']|int"]
+ """
+ Date when the product was received.
+ """
diff --git a/stripe/params/issuing/_dispute_retrieve_params.py b/stripe/params/issuing/_dispute_retrieve_params.py
new file mode 100644
index 000000000..5d350dc83
--- /dev/null
+++ b/stripe/params/issuing/_dispute_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class DisputeRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_dispute_submit_params.py b/stripe/params/issuing/_dispute_submit_params.py
new file mode 100644
index 000000000..3f504f2dc
--- /dev/null
+++ b/stripe/params/issuing/_dispute_submit_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class DisputeSubmitParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/issuing/_dispute_update_params.py b/stripe/params/issuing/_dispute_update_params.py
new file mode 100644
index 000000000..3a7d33188
--- /dev/null
+++ b/stripe/params/issuing/_dispute_update_params.py
@@ -0,0 +1,271 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class DisputeUpdateParams(TypedDict):
+ amount: NotRequired[int]
+ """
+ The dispute amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ evidence: NotRequired["DisputeUpdateParamsEvidence"]
+ """
+ Evidence provided for the dispute.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+
+
+class DisputeUpdateParamsEvidence(TypedDict):
+ canceled: NotRequired["Literal['']|DisputeUpdateParamsEvidenceCanceled"]
+ """
+ Evidence provided when `reason` is 'canceled'.
+ """
+ duplicate: NotRequired["Literal['']|DisputeUpdateParamsEvidenceDuplicate"]
+ """
+ Evidence provided when `reason` is 'duplicate'.
+ """
+ fraudulent: NotRequired[
+ "Literal['']|DisputeUpdateParamsEvidenceFraudulent"
+ ]
+ """
+ Evidence provided when `reason` is 'fraudulent'.
+ """
+ merchandise_not_as_described: NotRequired[
+ "Literal['']|DisputeUpdateParamsEvidenceMerchandiseNotAsDescribed"
+ ]
+ """
+ Evidence provided when `reason` is 'merchandise_not_as_described'.
+ """
+ no_valid_authorization: NotRequired[
+ "Literal['']|DisputeUpdateParamsEvidenceNoValidAuthorization"
+ ]
+ """
+ Evidence provided when `reason` is 'no_valid_authorization'.
+ """
+ not_received: NotRequired[
+ "Literal['']|DisputeUpdateParamsEvidenceNotReceived"
+ ]
+ """
+ Evidence provided when `reason` is 'not_received'.
+ """
+ other: NotRequired["Literal['']|DisputeUpdateParamsEvidenceOther"]
+ """
+ Evidence provided when `reason` is 'other'.
+ """
+ reason: NotRequired[
+ Literal[
+ "canceled",
+ "duplicate",
+ "fraudulent",
+ "merchandise_not_as_described",
+ "no_valid_authorization",
+ "not_received",
+ "other",
+ "service_not_as_described",
+ ]
+ ]
+ """
+ The reason for filing the dispute. The evidence should be submitted in the field of the same name.
+ """
+ service_not_as_described: NotRequired[
+ "Literal['']|DisputeUpdateParamsEvidenceServiceNotAsDescribed"
+ ]
+ """
+ Evidence provided when `reason` is 'service_not_as_described'.
+ """
+
+
+class DisputeUpdateParamsEvidenceCanceled(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ canceled_at: NotRequired["Literal['']|int"]
+ """
+ Date when order was canceled.
+ """
+ cancellation_policy_provided: NotRequired["Literal['']|bool"]
+ """
+ Whether the cardholder was provided with a cancellation policy.
+ """
+ cancellation_reason: NotRequired["Literal['']|str"]
+ """
+ Reason for canceling the order.
+ """
+ expected_at: NotRequired["Literal['']|int"]
+ """
+ Date when the cardholder expected to receive the product.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ Description of the merchandise or service that was purchased.
+ """
+ product_type: NotRequired["Literal['']|Literal['merchandise', 'service']"]
+ """
+ Whether the product was a merchandise or service.
+ """
+ return_status: NotRequired[
+ "Literal['']|Literal['merchant_rejected', 'successful']"
+ ]
+ """
+ Result of cardholder's attempt to return the product.
+ """
+ returned_at: NotRequired["Literal['']|int"]
+ """
+ Date when the product was returned or attempted to be returned.
+ """
+
+
+class DisputeUpdateParamsEvidenceDuplicate(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ card_statement: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the card statement showing that the product had already been paid for.
+ """
+ cash_receipt: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the receipt showing that the product had been paid for in cash.
+ """
+ check_image: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Image of the front and back of the check that was used to pay for the product.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ original_transaction: NotRequired[str]
+ """
+ Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one.
+ """
+
+
+class DisputeUpdateParamsEvidenceFraudulent(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+
+
+class DisputeUpdateParamsEvidenceMerchandiseNotAsDescribed(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ received_at: NotRequired["Literal['']|int"]
+ """
+ Date when the product was received.
+ """
+ return_description: NotRequired["Literal['']|str"]
+ """
+ Description of the cardholder's attempt to return the product.
+ """
+ return_status: NotRequired[
+ "Literal['']|Literal['merchant_rejected', 'successful']"
+ ]
+ """
+ Result of cardholder's attempt to return the product.
+ """
+ returned_at: NotRequired["Literal['']|int"]
+ """
+ Date when the product was returned or attempted to be returned.
+ """
+
+
+class DisputeUpdateParamsEvidenceNoValidAuthorization(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+
+
+class DisputeUpdateParamsEvidenceNotReceived(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ expected_at: NotRequired["Literal['']|int"]
+ """
+ Date when the cardholder expected to receive the product.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ Description of the merchandise or service that was purchased.
+ """
+ product_type: NotRequired["Literal['']|Literal['merchandise', 'service']"]
+ """
+ Whether the product was a merchandise or service.
+ """
+
+
+class DisputeUpdateParamsEvidenceOther(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ product_description: NotRequired["Literal['']|str"]
+ """
+ Description of the merchandise or service that was purchased.
+ """
+ product_type: NotRequired["Literal['']|Literal['merchandise', 'service']"]
+ """
+ Whether the product was a merchandise or service.
+ """
+
+
+class DisputeUpdateParamsEvidenceServiceNotAsDescribed(TypedDict):
+ additional_documentation: NotRequired["Literal['']|str"]
+ """
+ (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
+ """
+ canceled_at: NotRequired["Literal['']|int"]
+ """
+ Date when order was canceled.
+ """
+ cancellation_reason: NotRequired["Literal['']|str"]
+ """
+ Reason for canceling the order.
+ """
+ explanation: NotRequired["Literal['']|str"]
+ """
+ Explanation of why the cardholder is disputing this transaction.
+ """
+ received_at: NotRequired["Literal['']|int"]
+ """
+ Date when the product was received.
+ """
diff --git a/stripe/params/issuing/_personalization_design_activate_params.py b/stripe/params/issuing/_personalization_design_activate_params.py
new file mode 100644
index 000000000..90467a013
--- /dev/null
+++ b/stripe/params/issuing/_personalization_design_activate_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PersonalizationDesignActivateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_personalization_design_create_params.py b/stripe/params/issuing/_personalization_design_create_params.py
new file mode 100644
index 000000000..39fd71913
--- /dev/null
+++ b/stripe/params/issuing/_personalization_design_create_params.py
@@ -0,0 +1,70 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PersonalizationDesignCreateParams(RequestOptions):
+ card_logo: NotRequired[str]
+ """
+ The file for the card logo, for use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`.
+ """
+ carrier_text: NotRequired["PersonalizationDesignCreateParamsCarrierText"]
+ """
+ Hash containing carrier text, for use with physical bundles that support carrier text.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ lookup_key: NotRequired[str]
+ """
+ A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired[str]
+ """
+ Friendly display name.
+ """
+ physical_bundle: str
+ """
+ The physical bundle object belonging to this personalization design.
+ """
+ preferences: NotRequired["PersonalizationDesignCreateParamsPreferences"]
+ """
+ Information on whether this personalization design is used to create cards when one is not specified.
+ """
+ transfer_lookup_key: NotRequired[bool]
+ """
+ If set to true, will atomically remove the lookup key from the existing personalization design, and assign it to this personalization design.
+ """
+
+
+class PersonalizationDesignCreateParamsCarrierText(TypedDict):
+ footer_body: NotRequired["Literal['']|str"]
+ """
+ The footer body text of the carrier letter.
+ """
+ footer_title: NotRequired["Literal['']|str"]
+ """
+ The footer title text of the carrier letter.
+ """
+ header_body: NotRequired["Literal['']|str"]
+ """
+ The header body text of the carrier letter.
+ """
+ header_title: NotRequired["Literal['']|str"]
+ """
+ The header title text of the carrier letter.
+ """
+
+
+class PersonalizationDesignCreateParamsPreferences(TypedDict):
+ is_default: bool
+ """
+ Whether we use this personalization design to create cards when one isn't specified. A connected account uses the Connect platform's default design if no personalization design is set as the default design.
+ """
diff --git a/stripe/params/issuing/_personalization_design_deactivate_params.py b/stripe/params/issuing/_personalization_design_deactivate_params.py
new file mode 100644
index 000000000..8871eb27a
--- /dev/null
+++ b/stripe/params/issuing/_personalization_design_deactivate_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PersonalizationDesignDeactivateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_personalization_design_list_params.py b/stripe/params/issuing/_personalization_design_list_params.py
new file mode 100644
index 000000000..a212083f6
--- /dev/null
+++ b/stripe/params/issuing/_personalization_design_list_params.py
@@ -0,0 +1,47 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PersonalizationDesignListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ lookup_keys: NotRequired[List[str]]
+ """
+ Only return personalization designs with the given lookup keys.
+ """
+ preferences: NotRequired["PersonalizationDesignListParamsPreferences"]
+ """
+ Only return personalization designs with the given preferences.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["active", "inactive", "rejected", "review"]]
+ """
+ Only return personalization designs with the given status.
+ """
+
+
+class PersonalizationDesignListParamsPreferences(TypedDict):
+ is_default: NotRequired[bool]
+ """
+ Only return the personalization design that's set as the default. A connected account uses the Connect platform's default design if no personalization design is set as the default.
+ """
+ is_platform_default: NotRequired[bool]
+ """
+ Only return the personalization design that is set as the Connect platform's default. This parameter is only applicable to connected accounts.
+ """
diff --git a/stripe/params/issuing/_personalization_design_modify_params.py b/stripe/params/issuing/_personalization_design_modify_params.py
new file mode 100644
index 000000000..1c57a9dfc
--- /dev/null
+++ b/stripe/params/issuing/_personalization_design_modify_params.py
@@ -0,0 +1,72 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PersonalizationDesignModifyParams(RequestOptions):
+ card_logo: NotRequired["Literal['']|str"]
+ """
+ The file for the card logo, for use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`.
+ """
+ carrier_text: NotRequired[
+ "Literal['']|PersonalizationDesignModifyParamsCarrierText"
+ ]
+ """
+ Hash containing carrier text, for use with physical bundles that support carrier text.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ lookup_key: NotRequired["Literal['']|str"]
+ """
+ A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Friendly display name. Providing an empty string will set the field to null.
+ """
+ physical_bundle: NotRequired[str]
+ """
+ The physical bundle object belonging to this personalization design.
+ """
+ preferences: NotRequired["PersonalizationDesignModifyParamsPreferences"]
+ """
+ Information on whether this personalization design is used to create cards when one is not specified.
+ """
+ transfer_lookup_key: NotRequired[bool]
+ """
+ If set to true, will atomically remove the lookup key from the existing personalization design, and assign it to this personalization design.
+ """
+
+
+class PersonalizationDesignModifyParamsCarrierText(TypedDict):
+ footer_body: NotRequired["Literal['']|str"]
+ """
+ The footer body text of the carrier letter.
+ """
+ footer_title: NotRequired["Literal['']|str"]
+ """
+ The footer title text of the carrier letter.
+ """
+ header_body: NotRequired["Literal['']|str"]
+ """
+ The header body text of the carrier letter.
+ """
+ header_title: NotRequired["Literal['']|str"]
+ """
+ The header title text of the carrier letter.
+ """
+
+
+class PersonalizationDesignModifyParamsPreferences(TypedDict):
+ is_default: bool
+ """
+ Whether we use this personalization design to create cards when one isn't specified. A connected account uses the Connect platform's default design if no personalization design is set as the default design.
+ """
diff --git a/stripe/params/issuing/_personalization_design_reject_params.py b/stripe/params/issuing/_personalization_design_reject_params.py
new file mode 100644
index 000000000..ced5adae7
--- /dev/null
+++ b/stripe/params/issuing/_personalization_design_reject_params.py
@@ -0,0 +1,52 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PersonalizationDesignRejectParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ rejection_reasons: "PersonalizationDesignRejectParamsRejectionReasons"
+ """
+ The reason(s) the personalization design was rejected.
+ """
+
+
+class PersonalizationDesignRejectParamsRejectionReasons(TypedDict):
+ card_logo: NotRequired[
+ List[
+ Literal[
+ "geographic_location",
+ "inappropriate",
+ "network_name",
+ "non_binary_image",
+ "non_fiat_currency",
+ "other",
+ "other_entity",
+ "promotional_material",
+ ]
+ ]
+ ]
+ """
+ The reason(s) the card logo was rejected.
+ """
+ carrier_text: NotRequired[
+ List[
+ Literal[
+ "geographic_location",
+ "inappropriate",
+ "network_name",
+ "non_fiat_currency",
+ "other",
+ "other_entity",
+ "promotional_material",
+ ]
+ ]
+ ]
+ """
+ The reason(s) the carrier text was rejected.
+ """
diff --git a/stripe/params/issuing/_personalization_design_retrieve_params.py b/stripe/params/issuing/_personalization_design_retrieve_params.py
new file mode 100644
index 000000000..02e8577f0
--- /dev/null
+++ b/stripe/params/issuing/_personalization_design_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PersonalizationDesignRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_personalization_design_update_params.py b/stripe/params/issuing/_personalization_design_update_params.py
new file mode 100644
index 000000000..d5f3f57b5
--- /dev/null
+++ b/stripe/params/issuing/_personalization_design_update_params.py
@@ -0,0 +1,71 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PersonalizationDesignUpdateParams(TypedDict):
+ card_logo: NotRequired["Literal['']|str"]
+ """
+ The file for the card logo, for use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`.
+ """
+ carrier_text: NotRequired[
+ "Literal['']|PersonalizationDesignUpdateParamsCarrierText"
+ ]
+ """
+ Hash containing carrier text, for use with physical bundles that support carrier text.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ lookup_key: NotRequired["Literal['']|str"]
+ """
+ A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Friendly display name. Providing an empty string will set the field to null.
+ """
+ physical_bundle: NotRequired[str]
+ """
+ The physical bundle object belonging to this personalization design.
+ """
+ preferences: NotRequired["PersonalizationDesignUpdateParamsPreferences"]
+ """
+ Information on whether this personalization design is used to create cards when one is not specified.
+ """
+ transfer_lookup_key: NotRequired[bool]
+ """
+ If set to true, will atomically remove the lookup key from the existing personalization design, and assign it to this personalization design.
+ """
+
+
+class PersonalizationDesignUpdateParamsCarrierText(TypedDict):
+ footer_body: NotRequired["Literal['']|str"]
+ """
+ The footer body text of the carrier letter.
+ """
+ footer_title: NotRequired["Literal['']|str"]
+ """
+ The footer title text of the carrier letter.
+ """
+ header_body: NotRequired["Literal['']|str"]
+ """
+ The header body text of the carrier letter.
+ """
+ header_title: NotRequired["Literal['']|str"]
+ """
+ The header title text of the carrier letter.
+ """
+
+
+class PersonalizationDesignUpdateParamsPreferences(TypedDict):
+ is_default: bool
+ """
+ Whether we use this personalization design to create cards when one isn't specified. A connected account uses the Connect platform's default design if no personalization design is set as the default design.
+ """
diff --git a/stripe/params/issuing/_physical_bundle_list_params.py b/stripe/params/issuing/_physical_bundle_list_params.py
new file mode 100644
index 000000000..5193d4872
--- /dev/null
+++ b/stripe/params/issuing/_physical_bundle_list_params.py
@@ -0,0 +1,32 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class PhysicalBundleListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["active", "inactive", "review"]]
+ """
+ Only return physical bundles with the given status.
+ """
+ type: NotRequired[Literal["custom", "standard"]]
+ """
+ Only return physical bundles with the given type.
+ """
diff --git a/stripe/params/issuing/_physical_bundle_retrieve_params.py b/stripe/params/issuing/_physical_bundle_retrieve_params.py
new file mode 100644
index 000000000..9a21a41d9
--- /dev/null
+++ b/stripe/params/issuing/_physical_bundle_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class PhysicalBundleRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_token_list_params.py b/stripe/params/issuing/_token_list_params.py
new file mode 100644
index 000000000..fa43b1dd0
--- /dev/null
+++ b/stripe/params/issuing/_token_list_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TokenListParams(RequestOptions):
+ card: str
+ """
+ The Issuing card identifier to list tokens for.
+ """
+ created: NotRequired["TokenListParamsCreated|int"]
+ """
+ Only return Issuing tokens that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["active", "deleted", "requested", "suspended"]]
+ """
+ Select Issuing tokens with the given status.
+ """
+
+
+class TokenListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/issuing/_token_modify_params.py b/stripe/params/issuing/_token_modify_params.py
new file mode 100644
index 000000000..d8cbd4b20
--- /dev/null
+++ b/stripe/params/issuing/_token_modify_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class TokenModifyParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ status: Literal["active", "deleted", "suspended"]
+ """
+ Specifies which status the token should be updated to.
+ """
diff --git a/stripe/params/issuing/_token_retrieve_params.py b/stripe/params/issuing/_token_retrieve_params.py
new file mode 100644
index 000000000..a8e659fc6
--- /dev/null
+++ b/stripe/params/issuing/_token_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TokenRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_token_update_params.py b/stripe/params/issuing/_token_update_params.py
new file mode 100644
index 000000000..3b78cc084
--- /dev/null
+++ b/stripe/params/issuing/_token_update_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TokenUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ status: Literal["active", "deleted", "suspended"]
+ """
+ Specifies which status the token should be updated to.
+ """
diff --git a/stripe/params/issuing/_transaction_create_force_capture_params.py b/stripe/params/issuing/_transaction_create_force_capture_params.py
new file mode 100644
index 000000000..d9f6709a9
--- /dev/null
+++ b/stripe/params/issuing/_transaction_create_force_capture_params.py
@@ -0,0 +1,629 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TransactionCreateForceCaptureParams(RequestOptions):
+ amount: int
+ """
+ The total amount to attempt to capture. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ card: str
+ """
+ Card associated with this transaction.
+ """
+ currency: NotRequired[str]
+ """
+ The currency of the capture. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ merchant_data: NotRequired[
+ "TransactionCreateForceCaptureParamsMerchantData"
+ ]
+ """
+ Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
+ """
+ purchase_details: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetails"
+ ]
+ """
+ Additional purchase information that is optionally provided by the merchant.
+ """
+
+
+class TransactionCreateForceCaptureParamsMerchantData(TypedDict):
+ category: NotRequired[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ """
+ A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
+ """
+ city: NotRequired[str]
+ """
+ City where the seller is located
+ """
+ country: NotRequired[str]
+ """
+ Country where the seller is located
+ """
+ name: NotRequired[str]
+ """
+ Name of the seller
+ """
+ network_id: NotRequired[str]
+ """
+ Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code where the seller is located
+ """
+ state: NotRequired[str]
+ """
+ State where the seller is located
+ """
+ terminal_id: NotRequired[str]
+ """
+ An ID assigned by the seller to the location of the sale.
+ """
+ url: NotRequired[str]
+ """
+ URL provided by the merchant on a 3DS request
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetails(TypedDict):
+ fleet: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsFleet"
+ ]
+ """
+ Fleet-specific information for transactions using Fleet cards.
+ """
+ flight: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsFlight"
+ ]
+ """
+ Information about the flight that was purchased with this transaction.
+ """
+ fuel: NotRequired["TransactionCreateForceCaptureParamsPurchaseDetailsFuel"]
+ """
+ Information about fuel that was purchased with this transaction.
+ """
+ lodging: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsLodging"
+ ]
+ """
+ Information about lodging that was purchased with this transaction.
+ """
+ receipt: NotRequired[
+ List["TransactionCreateForceCaptureParamsPurchaseDetailsReceipt"]
+ ]
+ """
+ The line items in the purchase.
+ """
+ reference: NotRequired[str]
+ """
+ A merchant-specific order number.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFleet(TypedDict):
+ cardholder_prompt_data: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsFleetCardholderPromptData"
+ ]
+ """
+ Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
+ """
+ purchase_type: NotRequired[
+ Literal[
+ "fuel_and_non_fuel_purchase", "fuel_purchase", "non_fuel_purchase"
+ ]
+ ]
+ """
+ The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
+ """
+ reported_breakdown: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdown"
+ ]
+ """
+ More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
+ """
+ service_type: NotRequired[
+ Literal["full_service", "non_fuel_transaction", "self_service"]
+ ]
+ """
+ The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFleetCardholderPromptData(
+ TypedDict,
+):
+ driver_id: NotRequired[str]
+ """
+ Driver ID.
+ """
+ odometer: NotRequired[int]
+ """
+ Odometer reading.
+ """
+ unspecified_id: NotRequired[str]
+ """
+ An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
+ """
+ user_id: NotRequired[str]
+ """
+ User ID.
+ """
+ vehicle_number: NotRequired[str]
+ """
+ Vehicle number.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdown(
+ TypedDict,
+):
+ fuel: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownFuel"
+ ]
+ """
+ Breakdown of fuel portion of the purchase.
+ """
+ non_fuel: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel"
+ ]
+ """
+ Breakdown of non-fuel portion of the purchase.
+ """
+ tax: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownTax"
+ ]
+ """
+ Information about tax included in this transaction.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownFuel(
+ TypedDict,
+):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel(
+ TypedDict,
+):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownTax(
+ TypedDict,
+):
+ local_amount_decimal: NotRequired[str]
+ """
+ Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+ national_amount_decimal: NotRequired[str]
+ """
+ Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFlight(TypedDict):
+ departure_at: NotRequired[int]
+ """
+ The time that the flight departed.
+ """
+ passenger_name: NotRequired[str]
+ """
+ The name of the passenger.
+ """
+ refundable: NotRequired[bool]
+ """
+ Whether the ticket is refundable.
+ """
+ segments: NotRequired[
+ List["TransactionCreateForceCaptureParamsPurchaseDetailsFlightSegment"]
+ ]
+ """
+ The legs of the trip.
+ """
+ travel_agency: NotRequired[str]
+ """
+ The travel agency that issued the ticket.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFlightSegment(
+ TypedDict,
+):
+ arrival_airport_code: NotRequired[str]
+ """
+ The three-letter IATA airport code of the flight's destination.
+ """
+ carrier: NotRequired[str]
+ """
+ The airline carrier code.
+ """
+ departure_airport_code: NotRequired[str]
+ """
+ The three-letter IATA airport code that the flight departed from.
+ """
+ flight_number: NotRequired[str]
+ """
+ The flight number.
+ """
+ service_class: NotRequired[str]
+ """
+ The flight's service class.
+ """
+ stopover_allowed: NotRequired[bool]
+ """
+ Whether a stopover is allowed on this flight.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFuel(TypedDict):
+ industry_product_code: NotRequired[str]
+ """
+ [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
+ """
+ quantity_decimal: NotRequired[str]
+ """
+ The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
+ """
+ type: NotRequired[
+ Literal[
+ "diesel",
+ "other",
+ "unleaded_plus",
+ "unleaded_regular",
+ "unleaded_super",
+ ]
+ ]
+ """
+ The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
+ """
+ unit: NotRequired[
+ Literal[
+ "charging_minute",
+ "imperial_gallon",
+ "kilogram",
+ "kilowatt_hour",
+ "liter",
+ "other",
+ "pound",
+ "us_gallon",
+ ]
+ ]
+ """
+ The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
+ """
+ unit_cost_decimal: NotRequired[str]
+ """
+ The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsLodging(TypedDict):
+ check_in_at: NotRequired[int]
+ """
+ The time of checking into the lodging.
+ """
+ nights: NotRequired[int]
+ """
+ The number of nights stayed at the lodging.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsReceipt(TypedDict):
+ description: NotRequired[str]
+ quantity: NotRequired[str]
+ total: NotRequired[int]
+ unit_cost: NotRequired[int]
diff --git a/stripe/params/issuing/_transaction_create_unlinked_refund_params.py b/stripe/params/issuing/_transaction_create_unlinked_refund_params.py
new file mode 100644
index 000000000..8a0d378f9
--- /dev/null
+++ b/stripe/params/issuing/_transaction_create_unlinked_refund_params.py
@@ -0,0 +1,633 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TransactionCreateUnlinkedRefundParams(RequestOptions):
+ amount: int
+ """
+ The total amount to attempt to refund. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ card: str
+ """
+ Card associated with this unlinked refund transaction.
+ """
+ currency: NotRequired[str]
+ """
+ The currency of the unlinked refund. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ merchant_data: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsMerchantData"
+ ]
+ """
+ Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
+ """
+ purchase_details: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetails"
+ ]
+ """
+ Additional purchase information that is optionally provided by the merchant.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsMerchantData(TypedDict):
+ category: NotRequired[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ """
+ A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
+ """
+ city: NotRequired[str]
+ """
+ City where the seller is located
+ """
+ country: NotRequired[str]
+ """
+ Country where the seller is located
+ """
+ name: NotRequired[str]
+ """
+ Name of the seller
+ """
+ network_id: NotRequired[str]
+ """
+ Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code where the seller is located
+ """
+ state: NotRequired[str]
+ """
+ State where the seller is located
+ """
+ terminal_id: NotRequired[str]
+ """
+ An ID assigned by the seller to the location of the sale.
+ """
+ url: NotRequired[str]
+ """
+ URL provided by the merchant on a 3DS request
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetails(TypedDict):
+ fleet: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleet"
+ ]
+ """
+ Fleet-specific information for transactions using Fleet cards.
+ """
+ flight: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFlight"
+ ]
+ """
+ Information about the flight that was purchased with this transaction.
+ """
+ fuel: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFuel"
+ ]
+ """
+ Information about fuel that was purchased with this transaction.
+ """
+ lodging: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsLodging"
+ ]
+ """
+ Information about lodging that was purchased with this transaction.
+ """
+ receipt: NotRequired[
+ List["TransactionCreateUnlinkedRefundParamsPurchaseDetailsReceipt"]
+ ]
+ """
+ The line items in the purchase.
+ """
+ reference: NotRequired[str]
+ """
+ A merchant-specific order number.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleet(TypedDict):
+ cardholder_prompt_data: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetCardholderPromptData"
+ ]
+ """
+ Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
+ """
+ purchase_type: NotRequired[
+ Literal[
+ "fuel_and_non_fuel_purchase", "fuel_purchase", "non_fuel_purchase"
+ ]
+ ]
+ """
+ The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
+ """
+ reported_breakdown: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdown"
+ ]
+ """
+ More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
+ """
+ service_type: NotRequired[
+ Literal["full_service", "non_fuel_transaction", "self_service"]
+ ]
+ """
+ The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetCardholderPromptData(
+ TypedDict,
+):
+ driver_id: NotRequired[str]
+ """
+ Driver ID.
+ """
+ odometer: NotRequired[int]
+ """
+ Odometer reading.
+ """
+ unspecified_id: NotRequired[str]
+ """
+ An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
+ """
+ user_id: NotRequired[str]
+ """
+ User ID.
+ """
+ vehicle_number: NotRequired[str]
+ """
+ Vehicle number.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdown(
+ TypedDict,
+):
+ fuel: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownFuel"
+ ]
+ """
+ Breakdown of fuel portion of the purchase.
+ """
+ non_fuel: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownNonFuel"
+ ]
+ """
+ Breakdown of non-fuel portion of the purchase.
+ """
+ tax: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownTax"
+ ]
+ """
+ Information about tax included in this transaction.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownFuel(
+ TypedDict,
+):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownNonFuel(
+ TypedDict,
+):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownTax(
+ TypedDict,
+):
+ local_amount_decimal: NotRequired[str]
+ """
+ Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+ national_amount_decimal: NotRequired[str]
+ """
+ Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFlight(TypedDict):
+ departure_at: NotRequired[int]
+ """
+ The time that the flight departed.
+ """
+ passenger_name: NotRequired[str]
+ """
+ The name of the passenger.
+ """
+ refundable: NotRequired[bool]
+ """
+ Whether the ticket is refundable.
+ """
+ segments: NotRequired[
+ List[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFlightSegment"
+ ]
+ ]
+ """
+ The legs of the trip.
+ """
+ travel_agency: NotRequired[str]
+ """
+ The travel agency that issued the ticket.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFlightSegment(
+ TypedDict,
+):
+ arrival_airport_code: NotRequired[str]
+ """
+ The three-letter IATA airport code of the flight's destination.
+ """
+ carrier: NotRequired[str]
+ """
+ The airline carrier code.
+ """
+ departure_airport_code: NotRequired[str]
+ """
+ The three-letter IATA airport code that the flight departed from.
+ """
+ flight_number: NotRequired[str]
+ """
+ The flight number.
+ """
+ service_class: NotRequired[str]
+ """
+ The flight's service class.
+ """
+ stopover_allowed: NotRequired[bool]
+ """
+ Whether a stopover is allowed on this flight.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFuel(TypedDict):
+ industry_product_code: NotRequired[str]
+ """
+ [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
+ """
+ quantity_decimal: NotRequired[str]
+ """
+ The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
+ """
+ type: NotRequired[
+ Literal[
+ "diesel",
+ "other",
+ "unleaded_plus",
+ "unleaded_regular",
+ "unleaded_super",
+ ]
+ ]
+ """
+ The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
+ """
+ unit: NotRequired[
+ Literal[
+ "charging_minute",
+ "imperial_gallon",
+ "kilogram",
+ "kilowatt_hour",
+ "liter",
+ "other",
+ "pound",
+ "us_gallon",
+ ]
+ ]
+ """
+ The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
+ """
+ unit_cost_decimal: NotRequired[str]
+ """
+ The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsLodging(TypedDict):
+ check_in_at: NotRequired[int]
+ """
+ The time of checking into the lodging.
+ """
+ nights: NotRequired[int]
+ """
+ The number of nights stayed at the lodging.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsReceipt(TypedDict):
+ description: NotRequired[str]
+ quantity: NotRequired[str]
+ total: NotRequired[int]
+ unit_cost: NotRequired[int]
diff --git a/stripe/params/issuing/_transaction_list_params.py b/stripe/params/issuing/_transaction_list_params.py
new file mode 100644
index 000000000..41595dd53
--- /dev/null
+++ b/stripe/params/issuing/_transaction_list_params.py
@@ -0,0 +1,59 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TransactionListParams(RequestOptions):
+ card: NotRequired[str]
+ """
+ Only return transactions that belong to the given card.
+ """
+ cardholder: NotRequired[str]
+ """
+ Only return transactions that belong to the given cardholder.
+ """
+ created: NotRequired["TransactionListParamsCreated|int"]
+ """
+ Only return transactions that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ type: NotRequired[Literal["capture", "refund"]]
+ """
+ Only return transactions that have the given type. One of `capture` or `refund`.
+ """
+
+
+class TransactionListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/issuing/_transaction_modify_params.py b/stripe/params/issuing/_transaction_modify_params.py
new file mode 100644
index 000000000..ba255b790
--- /dev/null
+++ b/stripe/params/issuing/_transaction_modify_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class TransactionModifyParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/issuing/_transaction_refund_params.py b/stripe/params/issuing/_transaction_refund_params.py
new file mode 100644
index 000000000..0953e1baa
--- /dev/null
+++ b/stripe/params/issuing/_transaction_refund_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TransactionRefundParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ refund_amount: NotRequired[int]
+ """
+ The total amount to attempt to refund. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
diff --git a/stripe/params/issuing/_transaction_retrieve_params.py b/stripe/params/issuing/_transaction_retrieve_params.py
new file mode 100644
index 000000000..07744dd96
--- /dev/null
+++ b/stripe/params/issuing/_transaction_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TransactionRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/issuing/_transaction_update_params.py b/stripe/params/issuing/_transaction_update_params.py
new file mode 100644
index 000000000..8cb955c53
--- /dev/null
+++ b/stripe/params/issuing/_transaction_update_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TransactionUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/radar/__init__.py b/stripe/params/radar/__init__.py
new file mode 100644
index 000000000..3b4c1e795
--- /dev/null
+++ b/stripe/params/radar/__init__.py
@@ -0,0 +1,38 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.radar._early_fraud_warning_list_params import (
+ EarlyFraudWarningListParams as EarlyFraudWarningListParams,
+)
+from stripe.params.radar._early_fraud_warning_retrieve_params import (
+ EarlyFraudWarningRetrieveParams as EarlyFraudWarningRetrieveParams,
+)
+from stripe.params.radar._value_list_create_params import (
+ ValueListCreateParams as ValueListCreateParams,
+)
+from stripe.params.radar._value_list_delete_params import (
+ ValueListDeleteParams as ValueListDeleteParams,
+)
+from stripe.params.radar._value_list_item_create_params import (
+ ValueListItemCreateParams as ValueListItemCreateParams,
+)
+from stripe.params.radar._value_list_item_delete_params import (
+ ValueListItemDeleteParams as ValueListItemDeleteParams,
+)
+from stripe.params.radar._value_list_item_list_params import (
+ ValueListItemListParams as ValueListItemListParams,
+)
+from stripe.params.radar._value_list_item_retrieve_params import (
+ ValueListItemRetrieveParams as ValueListItemRetrieveParams,
+)
+from stripe.params.radar._value_list_list_params import (
+ ValueListListParams as ValueListListParams,
+)
+from stripe.params.radar._value_list_modify_params import (
+ ValueListModifyParams as ValueListModifyParams,
+)
+from stripe.params.radar._value_list_retrieve_params import (
+ ValueListRetrieveParams as ValueListRetrieveParams,
+)
+from stripe.params.radar._value_list_update_params import (
+ ValueListUpdateParams as ValueListUpdateParams,
+)
diff --git a/stripe/params/radar/_early_fraud_warning_list_params.py b/stripe/params/radar/_early_fraud_warning_list_params.py
new file mode 100644
index 000000000..9a16bf6c0
--- /dev/null
+++ b/stripe/params/radar/_early_fraud_warning_list_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class EarlyFraudWarningListParams(RequestOptions):
+ charge: NotRequired[str]
+ """
+ Only return early fraud warnings for the charge specified by this charge ID.
+ """
+ created: NotRequired["EarlyFraudWarningListParamsCreated|int"]
+ """
+ Only return early fraud warnings that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ payment_intent: NotRequired[str]
+ """
+ Only return early fraud warnings for charges that were created by the PaymentIntent specified by this PaymentIntent ID.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class EarlyFraudWarningListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/radar/_early_fraud_warning_retrieve_params.py b/stripe/params/radar/_early_fraud_warning_retrieve_params.py
new file mode 100644
index 000000000..b218981ed
--- /dev/null
+++ b/stripe/params/radar/_early_fraud_warning_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class EarlyFraudWarningRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/radar/_value_list_create_params.py b/stripe/params/radar/_value_list_create_params.py
new file mode 100644
index 000000000..1299e35db
--- /dev/null
+++ b/stripe/params/radar/_value_list_create_params.py
@@ -0,0 +1,41 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class ValueListCreateParams(RequestOptions):
+ alias: str
+ """
+ The name of the value list for use in rules.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ item_type: NotRequired[
+ Literal[
+ "card_bin",
+ "card_fingerprint",
+ "case_sensitive_string",
+ "country",
+ "customer_id",
+ "email",
+ "ip_address",
+ "sepa_debit_fingerprint",
+ "string",
+ "us_bank_account_fingerprint",
+ ]
+ ]
+ """
+ Type of the items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, `case_sensitive_string`, `customer_id`, `sepa_debit_fingerprint`, or `us_bank_account_fingerprint`. Use `string` if the item type is unknown or mixed.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: str
+ """
+ The human-readable name of the value list.
+ """
diff --git a/stripe/params/radar/_value_list_delete_params.py b/stripe/params/radar/_value_list_delete_params.py
new file mode 100644
index 000000000..448eeaa3c
--- /dev/null
+++ b/stripe/params/radar/_value_list_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class ValueListDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/radar/_value_list_item_create_params.py b/stripe/params/radar/_value_list_item_create_params.py
new file mode 100644
index 000000000..d9be1d858
--- /dev/null
+++ b/stripe/params/radar/_value_list_item_create_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ValueListItemCreateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ value: str
+ """
+ The value of the item (whose type must match the type of the parent value list).
+ """
+ value_list: str
+ """
+ The identifier of the value list which the created item will be added to.
+ """
diff --git a/stripe/params/radar/_value_list_item_delete_params.py b/stripe/params/radar/_value_list_item_delete_params.py
new file mode 100644
index 000000000..6f7b8a6b7
--- /dev/null
+++ b/stripe/params/radar/_value_list_item_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class ValueListItemDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/radar/_value_list_item_list_params.py b/stripe/params/radar/_value_list_item_list_params.py
new file mode 100644
index 000000000..5a76612db
--- /dev/null
+++ b/stripe/params/radar/_value_list_item_list_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ValueListItemListParams(RequestOptions):
+ created: NotRequired["ValueListItemListParamsCreated|int"]
+ """
+ Only return items that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ value: NotRequired[str]
+ """
+ Return items belonging to the parent list whose value matches the specified value (using an "is like" match).
+ """
+ value_list: str
+ """
+ Identifier for the parent value list this item belongs to.
+ """
+
+
+class ValueListItemListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/radar/_value_list_item_retrieve_params.py b/stripe/params/radar/_value_list_item_retrieve_params.py
new file mode 100644
index 000000000..746958c63
--- /dev/null
+++ b/stripe/params/radar/_value_list_item_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ValueListItemRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/radar/_value_list_list_params.py b/stripe/params/radar/_value_list_list_params.py
new file mode 100644
index 000000000..911490ef8
--- /dev/null
+++ b/stripe/params/radar/_value_list_list_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ValueListListParams(RequestOptions):
+ alias: NotRequired[str]
+ """
+ The alias used to reference the value list when writing rules.
+ """
+ contains: NotRequired[str]
+ """
+ A value contained within a value list - returns all value lists containing this value.
+ """
+ created: NotRequired["ValueListListParamsCreated|int"]
+ """
+ Only return value lists that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class ValueListListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/radar/_value_list_modify_params.py b/stripe/params/radar/_value_list_modify_params.py
new file mode 100644
index 000000000..31a60cbc3
--- /dev/null
+++ b/stripe/params/radar/_value_list_modify_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import NotRequired
+
+
+class ValueListModifyParams(RequestOptions):
+ alias: NotRequired[str]
+ """
+ The name of the value list for use in rules.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired[str]
+ """
+ The human-readable name of the value list.
+ """
diff --git a/stripe/params/radar/_value_list_retrieve_params.py b/stripe/params/radar/_value_list_retrieve_params.py
new file mode 100644
index 000000000..f7b2434f2
--- /dev/null
+++ b/stripe/params/radar/_value_list_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ValueListRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/radar/_value_list_update_params.py b/stripe/params/radar/_value_list_update_params.py
new file mode 100644
index 000000000..e8cbd9f18
--- /dev/null
+++ b/stripe/params/radar/_value_list_update_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ValueListUpdateParams(TypedDict):
+ alias: NotRequired[str]
+ """
+ The name of the value list for use in rules.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ name: NotRequired[str]
+ """
+ The human-readable name of the value list.
+ """
diff --git a/stripe/params/reporting/__init__.py b/stripe/params/reporting/__init__.py
new file mode 100644
index 000000000..90d29b148
--- /dev/null
+++ b/stripe/params/reporting/__init__.py
@@ -0,0 +1,17 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.reporting._report_run_create_params import (
+ ReportRunCreateParams as ReportRunCreateParams,
+)
+from stripe.params.reporting._report_run_list_params import (
+ ReportRunListParams as ReportRunListParams,
+)
+from stripe.params.reporting._report_run_retrieve_params import (
+ ReportRunRetrieveParams as ReportRunRetrieveParams,
+)
+from stripe.params.reporting._report_type_list_params import (
+ ReportTypeListParams as ReportTypeListParams,
+)
+from stripe.params.reporting._report_type_retrieve_params import (
+ ReportTypeRetrieveParams as ReportTypeRetrieveParams,
+)
diff --git a/stripe/params/reporting/_report_run_create_params.py b/stripe/params/reporting/_report_run_create_params.py
new file mode 100644
index 000000000..d3f0dabb3
--- /dev/null
+++ b/stripe/params/reporting/_report_run_create_params.py
@@ -0,0 +1,697 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ReportRunCreateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ parameters: NotRequired["ReportRunCreateParamsParameters"]
+ """
+ Parameters specifying how the report should be run. Different Report Types have different required and optional parameters, listed in the [API Access to Reports](https://stripe.com/docs/reporting/statements/api) documentation.
+ """
+ report_type: str
+ """
+ The ID of the [report type](https://stripe.com/docs/reporting/statements/api#report-types) to run, such as `"balance.summary.1"`.
+ """
+
+
+class ReportRunCreateParamsParameters(TypedDict):
+ columns: NotRequired[List[str]]
+ """
+ The set of report columns to include in the report output. If omitted, the Report Type is run with its default column set.
+ """
+ connected_account: NotRequired[str]
+ """
+ Connected account ID to filter for in the report run.
+ """
+ currency: NotRequired[str]
+ """
+ Currency of objects to be included in the report run.
+ """
+ interval_end: NotRequired[int]
+ """
+ Ending timestamp of data to be included in the report run (exclusive).
+ """
+ interval_start: NotRequired[int]
+ """
+ Starting timestamp of data to be included in the report run.
+ """
+ payout: NotRequired[str]
+ """
+ Payout ID by which to filter the report run.
+ """
+ reporting_category: NotRequired[
+ Literal[
+ "advance",
+ "advance_funding",
+ "anticipation_repayment",
+ "charge",
+ "charge_failure",
+ "climate_order_purchase",
+ "climate_order_refund",
+ "connect_collection_transfer",
+ "connect_reserved_funds",
+ "contribution",
+ "dispute",
+ "dispute_reversal",
+ "fee",
+ "financing_paydown",
+ "financing_paydown_reversal",
+ "financing_payout",
+ "financing_payout_reversal",
+ "issuing_authorization_hold",
+ "issuing_authorization_release",
+ "issuing_dispute",
+ "issuing_transaction",
+ "network_cost",
+ "other_adjustment",
+ "partial_capture_reversal",
+ "payout",
+ "payout_reversal",
+ "platform_earning",
+ "platform_earning_refund",
+ "refund",
+ "refund_failure",
+ "risk_reserved_funds",
+ "tax",
+ "topup",
+ "topup_reversal",
+ "transfer",
+ "transfer_reversal",
+ "unreconciled_customer_funds",
+ ]
+ ]
+ """
+ Category of balance transactions to be included in the report run.
+ """
+ timezone: NotRequired[
+ Literal[
+ "Africa/Abidjan",
+ "Africa/Accra",
+ "Africa/Addis_Ababa",
+ "Africa/Algiers",
+ "Africa/Asmara",
+ "Africa/Asmera",
+ "Africa/Bamako",
+ "Africa/Bangui",
+ "Africa/Banjul",
+ "Africa/Bissau",
+ "Africa/Blantyre",
+ "Africa/Brazzaville",
+ "Africa/Bujumbura",
+ "Africa/Cairo",
+ "Africa/Casablanca",
+ "Africa/Ceuta",
+ "Africa/Conakry",
+ "Africa/Dakar",
+ "Africa/Dar_es_Salaam",
+ "Africa/Djibouti",
+ "Africa/Douala",
+ "Africa/El_Aaiun",
+ "Africa/Freetown",
+ "Africa/Gaborone",
+ "Africa/Harare",
+ "Africa/Johannesburg",
+ "Africa/Juba",
+ "Africa/Kampala",
+ "Africa/Khartoum",
+ "Africa/Kigali",
+ "Africa/Kinshasa",
+ "Africa/Lagos",
+ "Africa/Libreville",
+ "Africa/Lome",
+ "Africa/Luanda",
+ "Africa/Lubumbashi",
+ "Africa/Lusaka",
+ "Africa/Malabo",
+ "Africa/Maputo",
+ "Africa/Maseru",
+ "Africa/Mbabane",
+ "Africa/Mogadishu",
+ "Africa/Monrovia",
+ "Africa/Nairobi",
+ "Africa/Ndjamena",
+ "Africa/Niamey",
+ "Africa/Nouakchott",
+ "Africa/Ouagadougou",
+ "Africa/Porto-Novo",
+ "Africa/Sao_Tome",
+ "Africa/Timbuktu",
+ "Africa/Tripoli",
+ "Africa/Tunis",
+ "Africa/Windhoek",
+ "America/Adak",
+ "America/Anchorage",
+ "America/Anguilla",
+ "America/Antigua",
+ "America/Araguaina",
+ "America/Argentina/Buenos_Aires",
+ "America/Argentina/Catamarca",
+ "America/Argentina/ComodRivadavia",
+ "America/Argentina/Cordoba",
+ "America/Argentina/Jujuy",
+ "America/Argentina/La_Rioja",
+ "America/Argentina/Mendoza",
+ "America/Argentina/Rio_Gallegos",
+ "America/Argentina/Salta",
+ "America/Argentina/San_Juan",
+ "America/Argentina/San_Luis",
+ "America/Argentina/Tucuman",
+ "America/Argentina/Ushuaia",
+ "America/Aruba",
+ "America/Asuncion",
+ "America/Atikokan",
+ "America/Atka",
+ "America/Bahia",
+ "America/Bahia_Banderas",
+ "America/Barbados",
+ "America/Belem",
+ "America/Belize",
+ "America/Blanc-Sablon",
+ "America/Boa_Vista",
+ "America/Bogota",
+ "America/Boise",
+ "America/Buenos_Aires",
+ "America/Cambridge_Bay",
+ "America/Campo_Grande",
+ "America/Cancun",
+ "America/Caracas",
+ "America/Catamarca",
+ "America/Cayenne",
+ "America/Cayman",
+ "America/Chicago",
+ "America/Chihuahua",
+ "America/Ciudad_Juarez",
+ "America/Coral_Harbour",
+ "America/Cordoba",
+ "America/Costa_Rica",
+ "America/Coyhaique",
+ "America/Creston",
+ "America/Cuiaba",
+ "America/Curacao",
+ "America/Danmarkshavn",
+ "America/Dawson",
+ "America/Dawson_Creek",
+ "America/Denver",
+ "America/Detroit",
+ "America/Dominica",
+ "America/Edmonton",
+ "America/Eirunepe",
+ "America/El_Salvador",
+ "America/Ensenada",
+ "America/Fort_Nelson",
+ "America/Fort_Wayne",
+ "America/Fortaleza",
+ "America/Glace_Bay",
+ "America/Godthab",
+ "America/Goose_Bay",
+ "America/Grand_Turk",
+ "America/Grenada",
+ "America/Guadeloupe",
+ "America/Guatemala",
+ "America/Guayaquil",
+ "America/Guyana",
+ "America/Halifax",
+ "America/Havana",
+ "America/Hermosillo",
+ "America/Indiana/Indianapolis",
+ "America/Indiana/Knox",
+ "America/Indiana/Marengo",
+ "America/Indiana/Petersburg",
+ "America/Indiana/Tell_City",
+ "America/Indiana/Vevay",
+ "America/Indiana/Vincennes",
+ "America/Indiana/Winamac",
+ "America/Indianapolis",
+ "America/Inuvik",
+ "America/Iqaluit",
+ "America/Jamaica",
+ "America/Jujuy",
+ "America/Juneau",
+ "America/Kentucky/Louisville",
+ "America/Kentucky/Monticello",
+ "America/Knox_IN",
+ "America/Kralendijk",
+ "America/La_Paz",
+ "America/Lima",
+ "America/Los_Angeles",
+ "America/Louisville",
+ "America/Lower_Princes",
+ "America/Maceio",
+ "America/Managua",
+ "America/Manaus",
+ "America/Marigot",
+ "America/Martinique",
+ "America/Matamoros",
+ "America/Mazatlan",
+ "America/Mendoza",
+ "America/Menominee",
+ "America/Merida",
+ "America/Metlakatla",
+ "America/Mexico_City",
+ "America/Miquelon",
+ "America/Moncton",
+ "America/Monterrey",
+ "America/Montevideo",
+ "America/Montreal",
+ "America/Montserrat",
+ "America/Nassau",
+ "America/New_York",
+ "America/Nipigon",
+ "America/Nome",
+ "America/Noronha",
+ "America/North_Dakota/Beulah",
+ "America/North_Dakota/Center",
+ "America/North_Dakota/New_Salem",
+ "America/Nuuk",
+ "America/Ojinaga",
+ "America/Panama",
+ "America/Pangnirtung",
+ "America/Paramaribo",
+ "America/Phoenix",
+ "America/Port-au-Prince",
+ "America/Port_of_Spain",
+ "America/Porto_Acre",
+ "America/Porto_Velho",
+ "America/Puerto_Rico",
+ "America/Punta_Arenas",
+ "America/Rainy_River",
+ "America/Rankin_Inlet",
+ "America/Recife",
+ "America/Regina",
+ "America/Resolute",
+ "America/Rio_Branco",
+ "America/Rosario",
+ "America/Santa_Isabel",
+ "America/Santarem",
+ "America/Santiago",
+ "America/Santo_Domingo",
+ "America/Sao_Paulo",
+ "America/Scoresbysund",
+ "America/Shiprock",
+ "America/Sitka",
+ "America/St_Barthelemy",
+ "America/St_Johns",
+ "America/St_Kitts",
+ "America/St_Lucia",
+ "America/St_Thomas",
+ "America/St_Vincent",
+ "America/Swift_Current",
+ "America/Tegucigalpa",
+ "America/Thule",
+ "America/Thunder_Bay",
+ "America/Tijuana",
+ "America/Toronto",
+ "America/Tortola",
+ "America/Vancouver",
+ "America/Virgin",
+ "America/Whitehorse",
+ "America/Winnipeg",
+ "America/Yakutat",
+ "America/Yellowknife",
+ "Antarctica/Casey",
+ "Antarctica/Davis",
+ "Antarctica/DumontDUrville",
+ "Antarctica/Macquarie",
+ "Antarctica/Mawson",
+ "Antarctica/McMurdo",
+ "Antarctica/Palmer",
+ "Antarctica/Rothera",
+ "Antarctica/South_Pole",
+ "Antarctica/Syowa",
+ "Antarctica/Troll",
+ "Antarctica/Vostok",
+ "Arctic/Longyearbyen",
+ "Asia/Aden",
+ "Asia/Almaty",
+ "Asia/Amman",
+ "Asia/Anadyr",
+ "Asia/Aqtau",
+ "Asia/Aqtobe",
+ "Asia/Ashgabat",
+ "Asia/Ashkhabad",
+ "Asia/Atyrau",
+ "Asia/Baghdad",
+ "Asia/Bahrain",
+ "Asia/Baku",
+ "Asia/Bangkok",
+ "Asia/Barnaul",
+ "Asia/Beirut",
+ "Asia/Bishkek",
+ "Asia/Brunei",
+ "Asia/Calcutta",
+ "Asia/Chita",
+ "Asia/Choibalsan",
+ "Asia/Chongqing",
+ "Asia/Chungking",
+ "Asia/Colombo",
+ "Asia/Dacca",
+ "Asia/Damascus",
+ "Asia/Dhaka",
+ "Asia/Dili",
+ "Asia/Dubai",
+ "Asia/Dushanbe",
+ "Asia/Famagusta",
+ "Asia/Gaza",
+ "Asia/Harbin",
+ "Asia/Hebron",
+ "Asia/Ho_Chi_Minh",
+ "Asia/Hong_Kong",
+ "Asia/Hovd",
+ "Asia/Irkutsk",
+ "Asia/Istanbul",
+ "Asia/Jakarta",
+ "Asia/Jayapura",
+ "Asia/Jerusalem",
+ "Asia/Kabul",
+ "Asia/Kamchatka",
+ "Asia/Karachi",
+ "Asia/Kashgar",
+ "Asia/Kathmandu",
+ "Asia/Katmandu",
+ "Asia/Khandyga",
+ "Asia/Kolkata",
+ "Asia/Krasnoyarsk",
+ "Asia/Kuala_Lumpur",
+ "Asia/Kuching",
+ "Asia/Kuwait",
+ "Asia/Macao",
+ "Asia/Macau",
+ "Asia/Magadan",
+ "Asia/Makassar",
+ "Asia/Manila",
+ "Asia/Muscat",
+ "Asia/Nicosia",
+ "Asia/Novokuznetsk",
+ "Asia/Novosibirsk",
+ "Asia/Omsk",
+ "Asia/Oral",
+ "Asia/Phnom_Penh",
+ "Asia/Pontianak",
+ "Asia/Pyongyang",
+ "Asia/Qatar",
+ "Asia/Qostanay",
+ "Asia/Qyzylorda",
+ "Asia/Rangoon",
+ "Asia/Riyadh",
+ "Asia/Saigon",
+ "Asia/Sakhalin",
+ "Asia/Samarkand",
+ "Asia/Seoul",
+ "Asia/Shanghai",
+ "Asia/Singapore",
+ "Asia/Srednekolymsk",
+ "Asia/Taipei",
+ "Asia/Tashkent",
+ "Asia/Tbilisi",
+ "Asia/Tehran",
+ "Asia/Tel_Aviv",
+ "Asia/Thimbu",
+ "Asia/Thimphu",
+ "Asia/Tokyo",
+ "Asia/Tomsk",
+ "Asia/Ujung_Pandang",
+ "Asia/Ulaanbaatar",
+ "Asia/Ulan_Bator",
+ "Asia/Urumqi",
+ "Asia/Ust-Nera",
+ "Asia/Vientiane",
+ "Asia/Vladivostok",
+ "Asia/Yakutsk",
+ "Asia/Yangon",
+ "Asia/Yekaterinburg",
+ "Asia/Yerevan",
+ "Atlantic/Azores",
+ "Atlantic/Bermuda",
+ "Atlantic/Canary",
+ "Atlantic/Cape_Verde",
+ "Atlantic/Faeroe",
+ "Atlantic/Faroe",
+ "Atlantic/Jan_Mayen",
+ "Atlantic/Madeira",
+ "Atlantic/Reykjavik",
+ "Atlantic/South_Georgia",
+ "Atlantic/St_Helena",
+ "Atlantic/Stanley",
+ "Australia/ACT",
+ "Australia/Adelaide",
+ "Australia/Brisbane",
+ "Australia/Broken_Hill",
+ "Australia/Canberra",
+ "Australia/Currie",
+ "Australia/Darwin",
+ "Australia/Eucla",
+ "Australia/Hobart",
+ "Australia/LHI",
+ "Australia/Lindeman",
+ "Australia/Lord_Howe",
+ "Australia/Melbourne",
+ "Australia/NSW",
+ "Australia/North",
+ "Australia/Perth",
+ "Australia/Queensland",
+ "Australia/South",
+ "Australia/Sydney",
+ "Australia/Tasmania",
+ "Australia/Victoria",
+ "Australia/West",
+ "Australia/Yancowinna",
+ "Brazil/Acre",
+ "Brazil/DeNoronha",
+ "Brazil/East",
+ "Brazil/West",
+ "CET",
+ "CST6CDT",
+ "Canada/Atlantic",
+ "Canada/Central",
+ "Canada/Eastern",
+ "Canada/Mountain",
+ "Canada/Newfoundland",
+ "Canada/Pacific",
+ "Canada/Saskatchewan",
+ "Canada/Yukon",
+ "Chile/Continental",
+ "Chile/EasterIsland",
+ "Cuba",
+ "EET",
+ "EST",
+ "EST5EDT",
+ "Egypt",
+ "Eire",
+ "Etc/GMT",
+ "Etc/GMT+0",
+ "Etc/GMT+1",
+ "Etc/GMT+10",
+ "Etc/GMT+11",
+ "Etc/GMT+12",
+ "Etc/GMT+2",
+ "Etc/GMT+3",
+ "Etc/GMT+4",
+ "Etc/GMT+5",
+ "Etc/GMT+6",
+ "Etc/GMT+7",
+ "Etc/GMT+8",
+ "Etc/GMT+9",
+ "Etc/GMT-0",
+ "Etc/GMT-1",
+ "Etc/GMT-10",
+ "Etc/GMT-11",
+ "Etc/GMT-12",
+ "Etc/GMT-13",
+ "Etc/GMT-14",
+ "Etc/GMT-2",
+ "Etc/GMT-3",
+ "Etc/GMT-4",
+ "Etc/GMT-5",
+ "Etc/GMT-6",
+ "Etc/GMT-7",
+ "Etc/GMT-8",
+ "Etc/GMT-9",
+ "Etc/GMT0",
+ "Etc/Greenwich",
+ "Etc/UCT",
+ "Etc/UTC",
+ "Etc/Universal",
+ "Etc/Zulu",
+ "Europe/Amsterdam",
+ "Europe/Andorra",
+ "Europe/Astrakhan",
+ "Europe/Athens",
+ "Europe/Belfast",
+ "Europe/Belgrade",
+ "Europe/Berlin",
+ "Europe/Bratislava",
+ "Europe/Brussels",
+ "Europe/Bucharest",
+ "Europe/Budapest",
+ "Europe/Busingen",
+ "Europe/Chisinau",
+ "Europe/Copenhagen",
+ "Europe/Dublin",
+ "Europe/Gibraltar",
+ "Europe/Guernsey",
+ "Europe/Helsinki",
+ "Europe/Isle_of_Man",
+ "Europe/Istanbul",
+ "Europe/Jersey",
+ "Europe/Kaliningrad",
+ "Europe/Kiev",
+ "Europe/Kirov",
+ "Europe/Kyiv",
+ "Europe/Lisbon",
+ "Europe/Ljubljana",
+ "Europe/London",
+ "Europe/Luxembourg",
+ "Europe/Madrid",
+ "Europe/Malta",
+ "Europe/Mariehamn",
+ "Europe/Minsk",
+ "Europe/Monaco",
+ "Europe/Moscow",
+ "Europe/Nicosia",
+ "Europe/Oslo",
+ "Europe/Paris",
+ "Europe/Podgorica",
+ "Europe/Prague",
+ "Europe/Riga",
+ "Europe/Rome",
+ "Europe/Samara",
+ "Europe/San_Marino",
+ "Europe/Sarajevo",
+ "Europe/Saratov",
+ "Europe/Simferopol",
+ "Europe/Skopje",
+ "Europe/Sofia",
+ "Europe/Stockholm",
+ "Europe/Tallinn",
+ "Europe/Tirane",
+ "Europe/Tiraspol",
+ "Europe/Ulyanovsk",
+ "Europe/Uzhgorod",
+ "Europe/Vaduz",
+ "Europe/Vatican",
+ "Europe/Vienna",
+ "Europe/Vilnius",
+ "Europe/Volgograd",
+ "Europe/Warsaw",
+ "Europe/Zagreb",
+ "Europe/Zaporozhye",
+ "Europe/Zurich",
+ "Factory",
+ "GB",
+ "GB-Eire",
+ "GMT",
+ "GMT+0",
+ "GMT-0",
+ "GMT0",
+ "Greenwich",
+ "HST",
+ "Hongkong",
+ "Iceland",
+ "Indian/Antananarivo",
+ "Indian/Chagos",
+ "Indian/Christmas",
+ "Indian/Cocos",
+ "Indian/Comoro",
+ "Indian/Kerguelen",
+ "Indian/Mahe",
+ "Indian/Maldives",
+ "Indian/Mauritius",
+ "Indian/Mayotte",
+ "Indian/Reunion",
+ "Iran",
+ "Israel",
+ "Jamaica",
+ "Japan",
+ "Kwajalein",
+ "Libya",
+ "MET",
+ "MST",
+ "MST7MDT",
+ "Mexico/BajaNorte",
+ "Mexico/BajaSur",
+ "Mexico/General",
+ "NZ",
+ "NZ-CHAT",
+ "Navajo",
+ "PRC",
+ "PST8PDT",
+ "Pacific/Apia",
+ "Pacific/Auckland",
+ "Pacific/Bougainville",
+ "Pacific/Chatham",
+ "Pacific/Chuuk",
+ "Pacific/Easter",
+ "Pacific/Efate",
+ "Pacific/Enderbury",
+ "Pacific/Fakaofo",
+ "Pacific/Fiji",
+ "Pacific/Funafuti",
+ "Pacific/Galapagos",
+ "Pacific/Gambier",
+ "Pacific/Guadalcanal",
+ "Pacific/Guam",
+ "Pacific/Honolulu",
+ "Pacific/Johnston",
+ "Pacific/Kanton",
+ "Pacific/Kiritimati",
+ "Pacific/Kosrae",
+ "Pacific/Kwajalein",
+ "Pacific/Majuro",
+ "Pacific/Marquesas",
+ "Pacific/Midway",
+ "Pacific/Nauru",
+ "Pacific/Niue",
+ "Pacific/Norfolk",
+ "Pacific/Noumea",
+ "Pacific/Pago_Pago",
+ "Pacific/Palau",
+ "Pacific/Pitcairn",
+ "Pacific/Pohnpei",
+ "Pacific/Ponape",
+ "Pacific/Port_Moresby",
+ "Pacific/Rarotonga",
+ "Pacific/Saipan",
+ "Pacific/Samoa",
+ "Pacific/Tahiti",
+ "Pacific/Tarawa",
+ "Pacific/Tongatapu",
+ "Pacific/Truk",
+ "Pacific/Wake",
+ "Pacific/Wallis",
+ "Pacific/Yap",
+ "Poland",
+ "Portugal",
+ "ROC",
+ "ROK",
+ "Singapore",
+ "Turkey",
+ "UCT",
+ "US/Alaska",
+ "US/Aleutian",
+ "US/Arizona",
+ "US/Central",
+ "US/East-Indiana",
+ "US/Eastern",
+ "US/Hawaii",
+ "US/Indiana-Starke",
+ "US/Michigan",
+ "US/Mountain",
+ "US/Pacific",
+ "US/Pacific-New",
+ "US/Samoa",
+ "UTC",
+ "Universal",
+ "W-SU",
+ "WET",
+ "Zulu",
+ ]
+ ]
+ """
+ Defaults to `Etc/UTC`. The output timezone for all timestamps in the report. A list of possible time zone values is maintained at the [IANA Time Zone Database](http://www.iana.org/time-zones). Has no effect on `interval_start` or `interval_end`.
+ """
diff --git a/stripe/params/reporting/_report_run_list_params.py b/stripe/params/reporting/_report_run_list_params.py
new file mode 100644
index 000000000..befc905ef
--- /dev/null
+++ b/stripe/params/reporting/_report_run_list_params.py
@@ -0,0 +1,47 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ReportRunListParams(RequestOptions):
+ created: NotRequired["ReportRunListParamsCreated|int"]
+ """
+ Only return Report Runs that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+
+
+class ReportRunListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/reporting/_report_run_retrieve_params.py b/stripe/params/reporting/_report_run_retrieve_params.py
new file mode 100644
index 000000000..f17591ac4
--- /dev/null
+++ b/stripe/params/reporting/_report_run_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ReportRunRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/reporting/_report_type_list_params.py b/stripe/params/reporting/_report_type_list_params.py
new file mode 100644
index 000000000..ebfb226fc
--- /dev/null
+++ b/stripe/params/reporting/_report_type_list_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ReportTypeListParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/reporting/_report_type_retrieve_params.py b/stripe/params/reporting/_report_type_retrieve_params.py
new file mode 100644
index 000000000..e35a36bae
--- /dev/null
+++ b/stripe/params/reporting/_report_type_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ReportTypeRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/sigma/__init__.py b/stripe/params/sigma/__init__.py
new file mode 100644
index 000000000..4ff3eb3d4
--- /dev/null
+++ b/stripe/params/sigma/__init__.py
@@ -0,0 +1,8 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.sigma._scheduled_query_run_list_params import (
+ ScheduledQueryRunListParams as ScheduledQueryRunListParams,
+)
+from stripe.params.sigma._scheduled_query_run_retrieve_params import (
+ ScheduledQueryRunRetrieveParams as ScheduledQueryRunRetrieveParams,
+)
diff --git a/stripe/params/sigma/_scheduled_query_run_list_params.py b/stripe/params/sigma/_scheduled_query_run_list_params.py
new file mode 100644
index 000000000..22dc4fc20
--- /dev/null
+++ b/stripe/params/sigma/_scheduled_query_run_list_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ScheduledQueryRunListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/sigma/_scheduled_query_run_retrieve_params.py b/stripe/params/sigma/_scheduled_query_run_retrieve_params.py
new file mode 100644
index 000000000..439adc13b
--- /dev/null
+++ b/stripe/params/sigma/_scheduled_query_run_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ScheduledQueryRunRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/tax/__init__.py b/stripe/params/tax/__init__.py
new file mode 100644
index 000000000..e66421663
--- /dev/null
+++ b/stripe/params/tax/__init__.py
@@ -0,0 +1,53 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.tax._calculation_create_params import (
+ CalculationCreateParams as CalculationCreateParams,
+)
+from stripe.params.tax._calculation_line_item_list_params import (
+ CalculationLineItemListParams as CalculationLineItemListParams,
+)
+from stripe.params.tax._calculation_list_line_items_params import (
+ CalculationListLineItemsParams as CalculationListLineItemsParams,
+)
+from stripe.params.tax._calculation_retrieve_params import (
+ CalculationRetrieveParams as CalculationRetrieveParams,
+)
+from stripe.params.tax._registration_create_params import (
+ RegistrationCreateParams as RegistrationCreateParams,
+)
+from stripe.params.tax._registration_list_params import (
+ RegistrationListParams as RegistrationListParams,
+)
+from stripe.params.tax._registration_modify_params import (
+ RegistrationModifyParams as RegistrationModifyParams,
+)
+from stripe.params.tax._registration_retrieve_params import (
+ RegistrationRetrieveParams as RegistrationRetrieveParams,
+)
+from stripe.params.tax._registration_update_params import (
+ RegistrationUpdateParams as RegistrationUpdateParams,
+)
+from stripe.params.tax._settings_modify_params import (
+ SettingsModifyParams as SettingsModifyParams,
+)
+from stripe.params.tax._settings_retrieve_params import (
+ SettingsRetrieveParams as SettingsRetrieveParams,
+)
+from stripe.params.tax._settings_update_params import (
+ SettingsUpdateParams as SettingsUpdateParams,
+)
+from stripe.params.tax._transaction_create_from_calculation_params import (
+ TransactionCreateFromCalculationParams as TransactionCreateFromCalculationParams,
+)
+from stripe.params.tax._transaction_create_reversal_params import (
+ TransactionCreateReversalParams as TransactionCreateReversalParams,
+)
+from stripe.params.tax._transaction_line_item_list_params import (
+ TransactionLineItemListParams as TransactionLineItemListParams,
+)
+from stripe.params.tax._transaction_list_line_items_params import (
+ TransactionListLineItemsParams as TransactionListLineItemsParams,
+)
+from stripe.params.tax._transaction_retrieve_params import (
+ TransactionRetrieveParams as TransactionRetrieveParams,
+)
diff --git a/stripe/params/tax/_calculation_create_params.py b/stripe/params/tax/_calculation_create_params.py
new file mode 100644
index 000000000..f1815268a
--- /dev/null
+++ b/stripe/params/tax/_calculation_create_params.py
@@ -0,0 +1,299 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class CalculationCreateParams(RequestOptions):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ customer: NotRequired[str]
+ """
+ The ID of an existing customer to use for this calculation. If provided, the customer's address and tax IDs are copied to `customer_details`.
+ """
+ customer_details: NotRequired["CalculationCreateParamsCustomerDetails"]
+ """
+ Details about the customer, including address and tax IDs.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ line_items: List["CalculationCreateParamsLineItem"]
+ """
+ A list of items the customer is purchasing.
+ """
+ ship_from_details: NotRequired["CalculationCreateParamsShipFromDetails"]
+ """
+ Details about the address from which the goods are being shipped.
+ """
+ shipping_cost: NotRequired["CalculationCreateParamsShippingCost"]
+ """
+ Shipping cost details to be used for the calculation.
+ """
+ tax_date: NotRequired[int]
+ """
+ Timestamp of date at which the tax rules and rates in effect applies for the calculation. Measured in seconds since the Unix epoch. Can be up to 48 hours in the past, and up to 48 hours in the future.
+ """
+
+
+class CalculationCreateParamsCustomerDetails(TypedDict):
+ address: NotRequired["CalculationCreateParamsCustomerDetailsAddress"]
+ """
+ The customer's postal address (for example, home or business location).
+ """
+ address_source: NotRequired[Literal["billing", "shipping"]]
+ """
+ The type of customer address provided.
+ """
+ ip_address: NotRequired[str]
+ """
+ The customer's IP address (IPv4 or IPv6).
+ """
+ tax_ids: NotRequired[List["CalculationCreateParamsCustomerDetailsTaxId"]]
+ """
+ The customer's tax IDs. Stripe Tax might consider a transaction with applicable tax IDs to be B2B, which might affect the tax calculation result. Stripe Tax doesn't validate tax IDs for correctness.
+ """
+ taxability_override: NotRequired[
+ Literal["customer_exempt", "none", "reverse_charge"]
+ ]
+ """
+ Overrides the tax calculation result to allow you to not collect tax from your customer. Use this if you've manually checked your customer's tax exemptions. Prefer providing the customer's `tax_ids` where possible, which automatically determines whether `reverse_charge` applies.
+ """
+
+
+class CalculationCreateParamsCustomerDetailsAddress(TypedDict):
+ city: NotRequired["Literal['']|str"]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: str
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired["Literal['']|str"]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired["Literal['']|str"]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired["Literal['']|str"]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired["Literal['']|str"]
+ """
+ State, county, province, or region. We recommend sending [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code value when possible.
+ """
+
+
+class CalculationCreateParamsCustomerDetailsTaxId(TypedDict):
+ type: Literal[
+ "ad_nrt",
+ "ae_trn",
+ "al_tin",
+ "am_tin",
+ "ao_tin",
+ "ar_cuit",
+ "au_abn",
+ "au_arn",
+ "aw_tin",
+ "az_tin",
+ "ba_tin",
+ "bb_tin",
+ "bd_bin",
+ "bf_ifu",
+ "bg_uic",
+ "bh_vat",
+ "bj_ifu",
+ "bo_tin",
+ "br_cnpj",
+ "br_cpf",
+ "bs_tin",
+ "by_tin",
+ "ca_bn",
+ "ca_gst_hst",
+ "ca_pst_bc",
+ "ca_pst_mb",
+ "ca_pst_sk",
+ "ca_qst",
+ "cd_nif",
+ "ch_uid",
+ "ch_vat",
+ "cl_tin",
+ "cm_niu",
+ "cn_tin",
+ "co_nit",
+ "cr_tin",
+ "cv_nif",
+ "de_stn",
+ "do_rcn",
+ "ec_ruc",
+ "eg_tin",
+ "es_cif",
+ "et_tin",
+ "eu_oss_vat",
+ "eu_vat",
+ "gb_vat",
+ "ge_vat",
+ "gn_nif",
+ "hk_br",
+ "hr_oib",
+ "hu_tin",
+ "id_npwp",
+ "il_vat",
+ "in_gst",
+ "is_vat",
+ "jp_cn",
+ "jp_rn",
+ "jp_trn",
+ "ke_pin",
+ "kg_tin",
+ "kh_tin",
+ "kr_brn",
+ "kz_bin",
+ "la_tin",
+ "li_uid",
+ "li_vat",
+ "ma_vat",
+ "md_vat",
+ "me_pib",
+ "mk_vat",
+ "mr_nif",
+ "mx_rfc",
+ "my_frp",
+ "my_itn",
+ "my_sst",
+ "ng_tin",
+ "no_vat",
+ "no_voec",
+ "np_pan",
+ "nz_gst",
+ "om_vat",
+ "pe_ruc",
+ "ph_tin",
+ "ro_tin",
+ "rs_pib",
+ "ru_inn",
+ "ru_kpp",
+ "sa_vat",
+ "sg_gst",
+ "sg_uen",
+ "si_tin",
+ "sn_ninea",
+ "sr_fin",
+ "sv_nit",
+ "th_vat",
+ "tj_tin",
+ "tr_tin",
+ "tw_vat",
+ "tz_vat",
+ "ua_vat",
+ "ug_tin",
+ "us_ein",
+ "uy_ruc",
+ "uz_tin",
+ "uz_vat",
+ "ve_rif",
+ "vn_tin",
+ "za_vat",
+ "zm_tin",
+ "zw_tin",
+ ]
+ """
+ Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
+ """
+ value: str
+ """
+ Value of the tax ID.
+ """
+
+
+class CalculationCreateParamsLineItem(TypedDict):
+ amount: int
+ """
+ A positive integer representing the line item's total price in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes are calculated on top of this amount.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
+ """
+ product: NotRequired[str]
+ """
+ If provided, the product's `tax_code` will be used as the line item's `tax_code`.
+ """
+ quantity: NotRequired[int]
+ """
+ The number of units of the item being purchased. Used to calculate the per-unit price from the total `amount` for the line. For example, if `amount=100` and `quantity=4`, the calculated unit price is 25.
+ """
+ reference: NotRequired[str]
+ """
+ A custom identifier for this line item, which must be unique across the line items in the calculation. The reference helps identify each line item in exported [tax reports](https://stripe.com/docs/tax/reports).
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive"]]
+ """
+ Specifies whether the `amount` includes taxes. Defaults to `exclusive`.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID to use for this line item. If not provided, we will use the tax code from the provided `product` param. If neither `tax_code` nor `product` is provided, we will use the default tax code from your Tax Settings.
+ """
+
+
+class CalculationCreateParamsShipFromDetails(TypedDict):
+ address: "CalculationCreateParamsShipFromDetailsAddress"
+ """
+ The address from which the goods are being shipped from.
+ """
+
+
+class CalculationCreateParamsShipFromDetailsAddress(TypedDict):
+ city: NotRequired["Literal['']|str"]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: str
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired["Literal['']|str"]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired["Literal['']|str"]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired["Literal['']|str"]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired["Literal['']|str"]
+ """
+ State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix, such as "NY" or "TX".
+ """
+
+
+class CalculationCreateParamsShippingCost(TypedDict):
+ amount: NotRequired[int]
+ """
+ A positive integer in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) representing the shipping charge. If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes are calculated on top of this amount.
+ """
+ shipping_rate: NotRequired[str]
+ """
+ If provided, the [shipping rate](https://stripe.com/docs/api/shipping_rates/object)'s `amount`, `tax_code` and `tax_behavior` are used. If you provide a shipping rate, then you cannot pass the `amount`, `tax_code`, or `tax_behavior` parameters.
+ """
+ tax_behavior: NotRequired[Literal["exclusive", "inclusive"]]
+ """
+ Specifies whether the `amount` includes taxes. If `tax_behavior=inclusive`, then the amount includes taxes. Defaults to `exclusive`.
+ """
+ tax_code: NotRequired[str]
+ """
+ The [tax code](https://stripe.com/docs/tax/tax-categories) used to calculate tax on shipping. If not provided, the default shipping tax code from your [Tax Settings](https://dashboard.stripe.com/settings/tax) is used.
+ """
diff --git a/stripe/params/tax/_calculation_line_item_list_params.py b/stripe/params/tax/_calculation_line_item_list_params.py
new file mode 100644
index 000000000..8c988d49a
--- /dev/null
+++ b/stripe/params/tax/_calculation_line_item_list_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CalculationLineItemListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/tax/_calculation_list_line_items_params.py b/stripe/params/tax/_calculation_list_line_items_params.py
new file mode 100644
index 000000000..f2f7ea58a
--- /dev/null
+++ b/stripe/params/tax/_calculation_list_line_items_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CalculationListLineItemsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/tax/_calculation_retrieve_params.py b/stripe/params/tax/_calculation_retrieve_params.py
new file mode 100644
index 000000000..ac247ea4d
--- /dev/null
+++ b/stripe/params/tax/_calculation_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CalculationRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/tax/_registration_create_params.py b/stripe/params/tax/_registration_create_params.py
new file mode 100644
index 000000000..2ea18e073
--- /dev/null
+++ b/stripe/params/tax/_registration_create_params.py
@@ -0,0 +1,1881 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List, Union
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class RegistrationCreateParams(RequestOptions):
+ active_from: Union[Literal["now"], int]
+ """
+ Time at which the Tax Registration becomes active. It can be either `now` to indicate the current time, or a future timestamp measured in seconds since the Unix epoch.
+ """
+ country: str
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ country_options: "RegistrationCreateParamsCountryOptions"
+ """
+ Specific options for a registration in the specified `country`.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired[int]
+ """
+ If set, the Tax Registration stops being active at this time. If not set, the Tax Registration will be active indefinitely. Timestamp measured in seconds since the Unix epoch.
+ """
+
+
+_RegistrationCreateParamsCountryOptionsBase = TypedDict(
+ "RegistrationCreateParamsCountryOptions",
+ {
+ "in": NotRequired["RegistrationCreateParamsCountryOptionsIn"],
+ "is": NotRequired["RegistrationCreateParamsCountryOptionsIs"],
+ },
+)
+
+
+class RegistrationCreateParamsCountryOptions(
+ _RegistrationCreateParamsCountryOptionsBase,
+):
+ ae: NotRequired["RegistrationCreateParamsCountryOptionsAe"]
+ """
+ Options for the registration in AE.
+ """
+ al: NotRequired["RegistrationCreateParamsCountryOptionsAl"]
+ """
+ Options for the registration in AL.
+ """
+ am: NotRequired["RegistrationCreateParamsCountryOptionsAm"]
+ """
+ Options for the registration in AM.
+ """
+ ao: NotRequired["RegistrationCreateParamsCountryOptionsAo"]
+ """
+ Options for the registration in AO.
+ """
+ at: NotRequired["RegistrationCreateParamsCountryOptionsAt"]
+ """
+ Options for the registration in AT.
+ """
+ au: NotRequired["RegistrationCreateParamsCountryOptionsAu"]
+ """
+ Options for the registration in AU.
+ """
+ aw: NotRequired["RegistrationCreateParamsCountryOptionsAw"]
+ """
+ Options for the registration in AW.
+ """
+ az: NotRequired["RegistrationCreateParamsCountryOptionsAz"]
+ """
+ Options for the registration in AZ.
+ """
+ ba: NotRequired["RegistrationCreateParamsCountryOptionsBa"]
+ """
+ Options for the registration in BA.
+ """
+ bb: NotRequired["RegistrationCreateParamsCountryOptionsBb"]
+ """
+ Options for the registration in BB.
+ """
+ bd: NotRequired["RegistrationCreateParamsCountryOptionsBd"]
+ """
+ Options for the registration in BD.
+ """
+ be: NotRequired["RegistrationCreateParamsCountryOptionsBe"]
+ """
+ Options for the registration in BE.
+ """
+ bf: NotRequired["RegistrationCreateParamsCountryOptionsBf"]
+ """
+ Options for the registration in BF.
+ """
+ bg: NotRequired["RegistrationCreateParamsCountryOptionsBg"]
+ """
+ Options for the registration in BG.
+ """
+ bh: NotRequired["RegistrationCreateParamsCountryOptionsBh"]
+ """
+ Options for the registration in BH.
+ """
+ bj: NotRequired["RegistrationCreateParamsCountryOptionsBj"]
+ """
+ Options for the registration in BJ.
+ """
+ bs: NotRequired["RegistrationCreateParamsCountryOptionsBs"]
+ """
+ Options for the registration in BS.
+ """
+ by: NotRequired["RegistrationCreateParamsCountryOptionsBy"]
+ """
+ Options for the registration in BY.
+ """
+ ca: NotRequired["RegistrationCreateParamsCountryOptionsCa"]
+ """
+ Options for the registration in CA.
+ """
+ cd: NotRequired["RegistrationCreateParamsCountryOptionsCd"]
+ """
+ Options for the registration in CD.
+ """
+ ch: NotRequired["RegistrationCreateParamsCountryOptionsCh"]
+ """
+ Options for the registration in CH.
+ """
+ cl: NotRequired["RegistrationCreateParamsCountryOptionsCl"]
+ """
+ Options for the registration in CL.
+ """
+ cm: NotRequired["RegistrationCreateParamsCountryOptionsCm"]
+ """
+ Options for the registration in CM.
+ """
+ co: NotRequired["RegistrationCreateParamsCountryOptionsCo"]
+ """
+ Options for the registration in CO.
+ """
+ cr: NotRequired["RegistrationCreateParamsCountryOptionsCr"]
+ """
+ Options for the registration in CR.
+ """
+ cv: NotRequired["RegistrationCreateParamsCountryOptionsCv"]
+ """
+ Options for the registration in CV.
+ """
+ cy: NotRequired["RegistrationCreateParamsCountryOptionsCy"]
+ """
+ Options for the registration in CY.
+ """
+ cz: NotRequired["RegistrationCreateParamsCountryOptionsCz"]
+ """
+ Options for the registration in CZ.
+ """
+ de: NotRequired["RegistrationCreateParamsCountryOptionsDe"]
+ """
+ Options for the registration in DE.
+ """
+ dk: NotRequired["RegistrationCreateParamsCountryOptionsDk"]
+ """
+ Options for the registration in DK.
+ """
+ ec: NotRequired["RegistrationCreateParamsCountryOptionsEc"]
+ """
+ Options for the registration in EC.
+ """
+ ee: NotRequired["RegistrationCreateParamsCountryOptionsEe"]
+ """
+ Options for the registration in EE.
+ """
+ eg: NotRequired["RegistrationCreateParamsCountryOptionsEg"]
+ """
+ Options for the registration in EG.
+ """
+ es: NotRequired["RegistrationCreateParamsCountryOptionsEs"]
+ """
+ Options for the registration in ES.
+ """
+ et: NotRequired["RegistrationCreateParamsCountryOptionsEt"]
+ """
+ Options for the registration in ET.
+ """
+ fi: NotRequired["RegistrationCreateParamsCountryOptionsFi"]
+ """
+ Options for the registration in FI.
+ """
+ fr: NotRequired["RegistrationCreateParamsCountryOptionsFr"]
+ """
+ Options for the registration in FR.
+ """
+ gb: NotRequired["RegistrationCreateParamsCountryOptionsGb"]
+ """
+ Options for the registration in GB.
+ """
+ ge: NotRequired["RegistrationCreateParamsCountryOptionsGe"]
+ """
+ Options for the registration in GE.
+ """
+ gn: NotRequired["RegistrationCreateParamsCountryOptionsGn"]
+ """
+ Options for the registration in GN.
+ """
+ gr: NotRequired["RegistrationCreateParamsCountryOptionsGr"]
+ """
+ Options for the registration in GR.
+ """
+ hr: NotRequired["RegistrationCreateParamsCountryOptionsHr"]
+ """
+ Options for the registration in HR.
+ """
+ hu: NotRequired["RegistrationCreateParamsCountryOptionsHu"]
+ """
+ Options for the registration in HU.
+ """
+ id: NotRequired["RegistrationCreateParamsCountryOptionsId"]
+ """
+ Options for the registration in ID.
+ """
+ ie: NotRequired["RegistrationCreateParamsCountryOptionsIe"]
+ """
+ Options for the registration in IE.
+ """
+ it: NotRequired["RegistrationCreateParamsCountryOptionsIt"]
+ """
+ Options for the registration in IT.
+ """
+ jp: NotRequired["RegistrationCreateParamsCountryOptionsJp"]
+ """
+ Options for the registration in JP.
+ """
+ ke: NotRequired["RegistrationCreateParamsCountryOptionsKe"]
+ """
+ Options for the registration in KE.
+ """
+ kg: NotRequired["RegistrationCreateParamsCountryOptionsKg"]
+ """
+ Options for the registration in KG.
+ """
+ kh: NotRequired["RegistrationCreateParamsCountryOptionsKh"]
+ """
+ Options for the registration in KH.
+ """
+ kr: NotRequired["RegistrationCreateParamsCountryOptionsKr"]
+ """
+ Options for the registration in KR.
+ """
+ kz: NotRequired["RegistrationCreateParamsCountryOptionsKz"]
+ """
+ Options for the registration in KZ.
+ """
+ la: NotRequired["RegistrationCreateParamsCountryOptionsLa"]
+ """
+ Options for the registration in LA.
+ """
+ lt: NotRequired["RegistrationCreateParamsCountryOptionsLt"]
+ """
+ Options for the registration in LT.
+ """
+ lu: NotRequired["RegistrationCreateParamsCountryOptionsLu"]
+ """
+ Options for the registration in LU.
+ """
+ lv: NotRequired["RegistrationCreateParamsCountryOptionsLv"]
+ """
+ Options for the registration in LV.
+ """
+ ma: NotRequired["RegistrationCreateParamsCountryOptionsMa"]
+ """
+ Options for the registration in MA.
+ """
+ md: NotRequired["RegistrationCreateParamsCountryOptionsMd"]
+ """
+ Options for the registration in MD.
+ """
+ me: NotRequired["RegistrationCreateParamsCountryOptionsMe"]
+ """
+ Options for the registration in ME.
+ """
+ mk: NotRequired["RegistrationCreateParamsCountryOptionsMk"]
+ """
+ Options for the registration in MK.
+ """
+ mr: NotRequired["RegistrationCreateParamsCountryOptionsMr"]
+ """
+ Options for the registration in MR.
+ """
+ mt: NotRequired["RegistrationCreateParamsCountryOptionsMt"]
+ """
+ Options for the registration in MT.
+ """
+ mx: NotRequired["RegistrationCreateParamsCountryOptionsMx"]
+ """
+ Options for the registration in MX.
+ """
+ my: NotRequired["RegistrationCreateParamsCountryOptionsMy"]
+ """
+ Options for the registration in MY.
+ """
+ ng: NotRequired["RegistrationCreateParamsCountryOptionsNg"]
+ """
+ Options for the registration in NG.
+ """
+ nl: NotRequired["RegistrationCreateParamsCountryOptionsNl"]
+ """
+ Options for the registration in NL.
+ """
+ no: NotRequired["RegistrationCreateParamsCountryOptionsNo"]
+ """
+ Options for the registration in NO.
+ """
+ np: NotRequired["RegistrationCreateParamsCountryOptionsNp"]
+ """
+ Options for the registration in NP.
+ """
+ nz: NotRequired["RegistrationCreateParamsCountryOptionsNz"]
+ """
+ Options for the registration in NZ.
+ """
+ om: NotRequired["RegistrationCreateParamsCountryOptionsOm"]
+ """
+ Options for the registration in OM.
+ """
+ pe: NotRequired["RegistrationCreateParamsCountryOptionsPe"]
+ """
+ Options for the registration in PE.
+ """
+ ph: NotRequired["RegistrationCreateParamsCountryOptionsPh"]
+ """
+ Options for the registration in PH.
+ """
+ pl: NotRequired["RegistrationCreateParamsCountryOptionsPl"]
+ """
+ Options for the registration in PL.
+ """
+ pt: NotRequired["RegistrationCreateParamsCountryOptionsPt"]
+ """
+ Options for the registration in PT.
+ """
+ ro: NotRequired["RegistrationCreateParamsCountryOptionsRo"]
+ """
+ Options for the registration in RO.
+ """
+ rs: NotRequired["RegistrationCreateParamsCountryOptionsRs"]
+ """
+ Options for the registration in RS.
+ """
+ ru: NotRequired["RegistrationCreateParamsCountryOptionsRu"]
+ """
+ Options for the registration in RU.
+ """
+ sa: NotRequired["RegistrationCreateParamsCountryOptionsSa"]
+ """
+ Options for the registration in SA.
+ """
+ se: NotRequired["RegistrationCreateParamsCountryOptionsSe"]
+ """
+ Options for the registration in SE.
+ """
+ sg: NotRequired["RegistrationCreateParamsCountryOptionsSg"]
+ """
+ Options for the registration in SG.
+ """
+ si: NotRequired["RegistrationCreateParamsCountryOptionsSi"]
+ """
+ Options for the registration in SI.
+ """
+ sk: NotRequired["RegistrationCreateParamsCountryOptionsSk"]
+ """
+ Options for the registration in SK.
+ """
+ sn: NotRequired["RegistrationCreateParamsCountryOptionsSn"]
+ """
+ Options for the registration in SN.
+ """
+ sr: NotRequired["RegistrationCreateParamsCountryOptionsSr"]
+ """
+ Options for the registration in SR.
+ """
+ th: NotRequired["RegistrationCreateParamsCountryOptionsTh"]
+ """
+ Options for the registration in TH.
+ """
+ tj: NotRequired["RegistrationCreateParamsCountryOptionsTj"]
+ """
+ Options for the registration in TJ.
+ """
+ tr: NotRequired["RegistrationCreateParamsCountryOptionsTr"]
+ """
+ Options for the registration in TR.
+ """
+ tz: NotRequired["RegistrationCreateParamsCountryOptionsTz"]
+ """
+ Options for the registration in TZ.
+ """
+ ua: NotRequired["RegistrationCreateParamsCountryOptionsUa"]
+ """
+ Options for the registration in UA.
+ """
+ ug: NotRequired["RegistrationCreateParamsCountryOptionsUg"]
+ """
+ Options for the registration in UG.
+ """
+ us: NotRequired["RegistrationCreateParamsCountryOptionsUs"]
+ """
+ Options for the registration in US.
+ """
+ uy: NotRequired["RegistrationCreateParamsCountryOptionsUy"]
+ """
+ Options for the registration in UY.
+ """
+ uz: NotRequired["RegistrationCreateParamsCountryOptionsUz"]
+ """
+ Options for the registration in UZ.
+ """
+ vn: NotRequired["RegistrationCreateParamsCountryOptionsVn"]
+ """
+ Options for the registration in VN.
+ """
+ za: NotRequired["RegistrationCreateParamsCountryOptionsZa"]
+ """
+ Options for the registration in ZA.
+ """
+ zm: NotRequired["RegistrationCreateParamsCountryOptionsZm"]
+ """
+ Options for the registration in ZM.
+ """
+ zw: NotRequired["RegistrationCreateParamsCountryOptionsZw"]
+ """
+ Options for the registration in ZW.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsAe(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsAeStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsAeStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsAl(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsAlStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsAlStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsAm(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsAo(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsAoStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsAoStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsAt(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsAtStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsAtStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsAu(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsAuStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsAuStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsAw(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsAwStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsAwStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsAz(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBa(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsBaStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBaStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBb(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsBbStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBbStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBd(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsBdStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBdStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBe(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsBeStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBeStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBf(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsBfStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBfStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBg(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsBgStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBgStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBh(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsBhStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBhStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBj(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBs(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsBsStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBsStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsBy(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsCa(TypedDict):
+ province_standard: NotRequired[
+ "RegistrationCreateParamsCountryOptionsCaProvinceStandard"
+ ]
+ """
+ Options for the provincial tax registration.
+ """
+ type: Literal["province_standard", "simplified", "standard"]
+ """
+ Type of registration to be created in Canada.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsCaProvinceStandard(TypedDict):
+ province: str
+ """
+ Two-letter CA province code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)).
+ """
+
+
+class RegistrationCreateParamsCountryOptionsCd(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsCdStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsCdStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsCh(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsChStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsChStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsCl(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsCm(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsCo(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsCr(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsCv(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsCy(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsCyStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsCyStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsCz(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsCzStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsCzStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsDe(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsDeStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsDeStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsDk(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsDkStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsDkStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsEc(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsEe(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsEeStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsEeStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsEg(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsEs(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsEsStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsEsStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsEt(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsEtStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsEtStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsFi(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsFiStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsFiStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsFr(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsFrStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsFrStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsGb(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsGbStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsGbStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsGe(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsGn(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsGnStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsGnStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsGr(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsGrStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsGrStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsHr(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsHrStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsHrStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsHu(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsHuStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsHuStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsId(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsIe(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsIeStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsIeStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsIn(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsIs(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsIsStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsIsStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsIt(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsItStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsItStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsJp(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsJpStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsJpStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsKe(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsKg(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsKh(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsKr(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsKz(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsLa(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsLt(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsLtStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsLtStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsLu(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsLuStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsLuStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsLv(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsLvStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsLvStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsMa(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsMd(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsMe(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsMeStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsMeStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsMk(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsMkStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsMkStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsMr(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsMrStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsMrStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsMt(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsMtStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsMtStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsMx(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsMy(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsNg(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsNl(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsNlStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsNlStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsNo(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsNoStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsNoStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsNp(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsNz(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsNzStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsNzStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsOm(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsOmStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsOmStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsPe(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsPh(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsPl(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsPlStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsPlStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsPt(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsPtStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsPtStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsRo(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsRoStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsRoStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsRs(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsRsStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsRsStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsRu(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsSa(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsSe(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsSeStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsSeStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsSg(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsSgStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsSgStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsSi(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsSiStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsSiStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsSk(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsSkStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
+ """
+ Type of registration to be created in an EU country.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsSkStandard(TypedDict):
+ place_of_supply_scheme: Literal[
+ "inbound_goods", "small_seller", "standard"
+ ]
+ """
+ Place of supply scheme used in an EU standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsSn(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsSr(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsSrStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsSrStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsTh(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsTj(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsTr(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsTz(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsUa(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsUg(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsUs(TypedDict):
+ local_amusement_tax: NotRequired[
+ "RegistrationCreateParamsCountryOptionsUsLocalAmusementTax"
+ ]
+ """
+ Options for the local amusement tax registration.
+ """
+ local_lease_tax: NotRequired[
+ "RegistrationCreateParamsCountryOptionsUsLocalLeaseTax"
+ ]
+ """
+ Options for the local lease tax registration.
+ """
+ state: str
+ """
+ Two-letter US state code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)).
+ """
+ state_sales_tax: NotRequired[
+ "RegistrationCreateParamsCountryOptionsUsStateSalesTax"
+ ]
+ """
+ Options for the state sales tax registration.
+ """
+ type: Literal[
+ "local_amusement_tax",
+ "local_lease_tax",
+ "state_communications_tax",
+ "state_retail_delivery_fee",
+ "state_sales_tax",
+ ]
+ """
+ Type of registration to be created in the US.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsUsLocalAmusementTax(TypedDict):
+ jurisdiction: str
+ """
+ A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. Supported FIPS codes are: `14000` (Chicago), `06613` (Bloomington), `21696` (East Dundee), `24582` (Evanston), `45421` (Lynwood), `48892` (Midlothian), `64343` (River Grove), and `68081` (Schiller Park).
+ """
+
+
+class RegistrationCreateParamsCountryOptionsUsLocalLeaseTax(TypedDict):
+ jurisdiction: str
+ """
+ A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. Supported FIPS codes are: `14000` (Chicago).
+ """
+
+
+class RegistrationCreateParamsCountryOptionsUsStateSalesTax(TypedDict):
+ elections: List[
+ "RegistrationCreateParamsCountryOptionsUsStateSalesTaxElection"
+ ]
+ """
+ Elections for the state sales tax registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsUsStateSalesTaxElection(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 RegistrationCreateParamsCountryOptionsUy(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsUyStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsUyStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsUz(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsVn(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsZa(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsZaStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsZaStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsZm(TypedDict):
+ type: Literal["simplified"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsZw(TypedDict):
+ standard: NotRequired["RegistrationCreateParamsCountryOptionsZwStandard"]
+ """
+ Options for the standard registration.
+ """
+ type: Literal["standard"]
+ """
+ Type of registration to be created in `country`.
+ """
+
+
+class RegistrationCreateParamsCountryOptionsZwStandard(TypedDict):
+ place_of_supply_scheme: NotRequired[Literal["inbound_goods", "standard"]]
+ """
+ Place of supply scheme used in an standard registration.
+ """
diff --git a/stripe/params/tax/_registration_list_params.py b/stripe/params/tax/_registration_list_params.py
new file mode 100644
index 000000000..7573e1e6b
--- /dev/null
+++ b/stripe/params/tax/_registration_list_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class RegistrationListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["active", "all", "expired", "scheduled"]]
+ """
+ The status of the Tax Registration.
+ """
diff --git a/stripe/params/tax/_registration_modify_params.py b/stripe/params/tax/_registration_modify_params.py
new file mode 100644
index 000000000..30bbc04ff
--- /dev/null
+++ b/stripe/params/tax/_registration_modify_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class RegistrationModifyParams(RequestOptions):
+ active_from: NotRequired["Literal['now']|int"]
+ """
+ Time at which the registration becomes active. It can be either `now` to indicate the current time, or a timestamp measured in seconds since the Unix epoch.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired["Literal['']|Literal['now']|int"]
+ """
+ If set, the registration stops being active at this time. If not set, the registration will be active indefinitely. It can be either `now` to indicate the current time, or a timestamp measured in seconds since the Unix epoch.
+ """
diff --git a/stripe/params/tax/_registration_retrieve_params.py b/stripe/params/tax/_registration_retrieve_params.py
new file mode 100644
index 000000000..63ce76072
--- /dev/null
+++ b/stripe/params/tax/_registration_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class RegistrationRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/tax/_registration_update_params.py b/stripe/params/tax/_registration_update_params.py
new file mode 100644
index 000000000..4d8240076
--- /dev/null
+++ b/stripe/params/tax/_registration_update_params.py
@@ -0,0 +1,19 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class RegistrationUpdateParams(TypedDict):
+ active_from: NotRequired["Literal['now']|int"]
+ """
+ Time at which the registration becomes active. It can be either `now` to indicate the current time, or a timestamp measured in seconds since the Unix epoch.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ expires_at: NotRequired["Literal['']|Literal['now']|int"]
+ """
+ If set, the registration stops being active at this time. If not set, the registration will be active indefinitely. It can be either `now` to indicate the current time, or a timestamp measured in seconds since the Unix epoch.
+ """
diff --git a/stripe/params/tax/_settings_modify_params.py b/stripe/params/tax/_settings_modify_params.py
new file mode 100644
index 000000000..52f9780f1
--- /dev/null
+++ b/stripe/params/tax/_settings_modify_params.py
@@ -0,0 +1,67 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SettingsModifyParams(RequestOptions):
+ defaults: NotRequired["SettingsModifyParamsDefaults"]
+ """
+ Default configuration to be used on Stripe Tax calculations.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ head_office: NotRequired["SettingsModifyParamsHeadOffice"]
+ """
+ The place where your business is located.
+ """
+
+
+class SettingsModifyParamsDefaults(TypedDict):
+ tax_behavior: NotRequired[
+ Literal["exclusive", "inclusive", "inferred_by_currency"]
+ ]
+ """
+ Specifies the default [tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#tax-behavior) to be used when the item's price has unspecified tax behavior. One of inclusive, exclusive, or inferred_by_currency. Once specified, it cannot be changed back to null.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+
+
+class SettingsModifyParamsHeadOffice(TypedDict):
+ address: "SettingsModifyParamsHeadOfficeAddress"
+ """
+ The location of the business for tax purposes.
+ """
+
+
+class SettingsModifyParamsHeadOfficeAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix, such as "NY" or "TX".
+ """
diff --git a/stripe/params/tax/_settings_retrieve_params.py b/stripe/params/tax/_settings_retrieve_params.py
new file mode 100644
index 000000000..2d136233d
--- /dev/null
+++ b/stripe/params/tax/_settings_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class SettingsRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/tax/_settings_update_params.py b/stripe/params/tax/_settings_update_params.py
new file mode 100644
index 000000000..1d0bb94a1
--- /dev/null
+++ b/stripe/params/tax/_settings_update_params.py
@@ -0,0 +1,66 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class SettingsUpdateParams(TypedDict):
+ defaults: NotRequired["SettingsUpdateParamsDefaults"]
+ """
+ Default configuration to be used on Stripe Tax calculations.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ head_office: NotRequired["SettingsUpdateParamsHeadOffice"]
+ """
+ The place where your business is located.
+ """
+
+
+class SettingsUpdateParamsDefaults(TypedDict):
+ tax_behavior: NotRequired[
+ Literal["exclusive", "inclusive", "inferred_by_currency"]
+ ]
+ """
+ Specifies the default [tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#tax-behavior) to be used when the item's price has unspecified tax behavior. One of inclusive, exclusive, or inferred_by_currency. Once specified, it cannot be changed back to null.
+ """
+ tax_code: NotRequired[str]
+ """
+ A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
+ """
+
+
+class SettingsUpdateParamsHeadOffice(TypedDict):
+ address: "SettingsUpdateParamsHeadOfficeAddress"
+ """
+ The location of the business for tax purposes.
+ """
+
+
+class SettingsUpdateParamsHeadOfficeAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix, such as "NY" or "TX".
+ """
diff --git a/stripe/params/tax/_transaction_create_from_calculation_params.py b/stripe/params/tax/_transaction_create_from_calculation_params.py
new file mode 100644
index 000000000..233bb0f08
--- /dev/null
+++ b/stripe/params/tax/_transaction_create_from_calculation_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import NotRequired
+
+
+class TransactionCreateFromCalculationParams(RequestOptions):
+ calculation: str
+ """
+ Tax Calculation ID to be used as input when creating the transaction.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ posted_at: NotRequired[int]
+ """
+ The Unix timestamp representing when the tax liability is assumed or reduced, which determines the liability posting period and handling in tax liability reports. The timestamp must fall within the `tax_date` and the current time, unless the `tax_date` is scheduled in advance. Defaults to the current time.
+ """
+ reference: str
+ """
+ A custom order or sale identifier, such as 'myOrder_123'. Must be unique across all transactions, including reversals.
+ """
diff --git a/stripe/params/tax/_transaction_create_reversal_params.py b/stripe/params/tax/_transaction_create_reversal_params.py
new file mode 100644
index 000000000..a86a4b2cd
--- /dev/null
+++ b/stripe/params/tax/_transaction_create_reversal_params.py
@@ -0,0 +1,78 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TransactionCreateReversalParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ flat_amount: NotRequired[int]
+ """
+ A flat amount to reverse across the entire transaction, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative. This value represents the total amount to refund from the transaction, including taxes.
+ """
+ line_items: NotRequired[List["TransactionCreateReversalParamsLineItem"]]
+ """
+ The line item amounts to reverse.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ mode: Literal["full", "partial"]
+ """
+ If `partial`, the provided line item or shipping cost amounts are reversed. If `full`, the original transaction is fully reversed.
+ """
+ original_transaction: str
+ """
+ The ID of the Transaction to partially or fully reverse.
+ """
+ reference: str
+ """
+ A custom identifier for this reversal, such as `myOrder_123-refund_1`, which must be unique across all transactions. The reference helps identify this reversal transaction in exported [tax reports](https://stripe.com/docs/tax/reports).
+ """
+ shipping_cost: NotRequired["TransactionCreateReversalParamsShippingCost"]
+ """
+ The shipping cost to reverse.
+ """
+
+
+class TransactionCreateReversalParamsLineItem(TypedDict):
+ amount: int
+ """
+ The amount to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
+ """
+ amount_tax: int
+ """
+ The amount of tax to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
+ """
+ original_line_item: str
+ """
+ The `id` of the line item to reverse in the original transaction.
+ """
+ quantity: NotRequired[int]
+ """
+ The quantity reversed. Appears in [tax exports](https://stripe.com/docs/tax/reports), but does not affect the amount of tax reversed.
+ """
+ reference: str
+ """
+ A custom identifier for this line item in the reversal transaction, such as 'L1-refund'.
+ """
+
+
+class TransactionCreateReversalParamsShippingCost(TypedDict):
+ amount: int
+ """
+ The amount to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
+ """
+ amount_tax: int
+ """
+ The amount of tax to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
+ """
diff --git a/stripe/params/tax/_transaction_line_item_list_params.py b/stripe/params/tax/_transaction_line_item_list_params.py
new file mode 100644
index 000000000..03900a6e5
--- /dev/null
+++ b/stripe/params/tax/_transaction_line_item_list_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class TransactionLineItemListParams(TypedDict):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/tax/_transaction_list_line_items_params.py b/stripe/params/tax/_transaction_list_line_items_params.py
new file mode 100644
index 000000000..bd1d9ab6f
--- /dev/null
+++ b/stripe/params/tax/_transaction_list_line_items_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TransactionListLineItemsParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/tax/_transaction_retrieve_params.py b/stripe/params/tax/_transaction_retrieve_params.py
new file mode 100644
index 000000000..07744dd96
--- /dev/null
+++ b/stripe/params/tax/_transaction_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TransactionRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/terminal/__init__.py b/stripe/params/terminal/__init__.py
new file mode 100644
index 000000000..c2680ef2f
--- /dev/null
+++ b/stripe/params/terminal/__init__.py
@@ -0,0 +1,92 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.terminal._configuration_create_params import (
+ ConfigurationCreateParams as ConfigurationCreateParams,
+)
+from stripe.params.terminal._configuration_delete_params import (
+ ConfigurationDeleteParams as ConfigurationDeleteParams,
+)
+from stripe.params.terminal._configuration_list_params import (
+ ConfigurationListParams as ConfigurationListParams,
+)
+from stripe.params.terminal._configuration_modify_params import (
+ ConfigurationModifyParams as ConfigurationModifyParams,
+)
+from stripe.params.terminal._configuration_retrieve_params import (
+ ConfigurationRetrieveParams as ConfigurationRetrieveParams,
+)
+from stripe.params.terminal._configuration_update_params import (
+ ConfigurationUpdateParams as ConfigurationUpdateParams,
+)
+from stripe.params.terminal._connection_token_create_params import (
+ ConnectionTokenCreateParams as ConnectionTokenCreateParams,
+)
+from stripe.params.terminal._location_create_params import (
+ LocationCreateParams as LocationCreateParams,
+)
+from stripe.params.terminal._location_delete_params import (
+ LocationDeleteParams as LocationDeleteParams,
+)
+from stripe.params.terminal._location_list_params import (
+ LocationListParams as LocationListParams,
+)
+from stripe.params.terminal._location_modify_params import (
+ LocationModifyParams as LocationModifyParams,
+)
+from stripe.params.terminal._location_retrieve_params import (
+ LocationRetrieveParams as LocationRetrieveParams,
+)
+from stripe.params.terminal._location_update_params import (
+ LocationUpdateParams as LocationUpdateParams,
+)
+from stripe.params.terminal._reader_cancel_action_params import (
+ ReaderCancelActionParams as ReaderCancelActionParams,
+)
+from stripe.params.terminal._reader_collect_inputs_params import (
+ ReaderCollectInputsParams as ReaderCollectInputsParams,
+)
+from stripe.params.terminal._reader_collect_payment_method_params import (
+ ReaderCollectPaymentMethodParams as ReaderCollectPaymentMethodParams,
+)
+from stripe.params.terminal._reader_confirm_payment_intent_params import (
+ ReaderConfirmPaymentIntentParams as ReaderConfirmPaymentIntentParams,
+)
+from stripe.params.terminal._reader_create_params import (
+ ReaderCreateParams as ReaderCreateParams,
+)
+from stripe.params.terminal._reader_delete_params import (
+ ReaderDeleteParams as ReaderDeleteParams,
+)
+from stripe.params.terminal._reader_list_params import (
+ ReaderListParams as ReaderListParams,
+)
+from stripe.params.terminal._reader_modify_params import (
+ ReaderModifyParams as ReaderModifyParams,
+)
+from stripe.params.terminal._reader_present_payment_method_params import (
+ ReaderPresentPaymentMethodParams as ReaderPresentPaymentMethodParams,
+)
+from stripe.params.terminal._reader_process_payment_intent_params import (
+ ReaderProcessPaymentIntentParams as ReaderProcessPaymentIntentParams,
+)
+from stripe.params.terminal._reader_process_setup_intent_params import (
+ ReaderProcessSetupIntentParams as ReaderProcessSetupIntentParams,
+)
+from stripe.params.terminal._reader_refund_payment_params import (
+ ReaderRefundPaymentParams as ReaderRefundPaymentParams,
+)
+from stripe.params.terminal._reader_retrieve_params import (
+ ReaderRetrieveParams as ReaderRetrieveParams,
+)
+from stripe.params.terminal._reader_set_reader_display_params import (
+ ReaderSetReaderDisplayParams as ReaderSetReaderDisplayParams,
+)
+from stripe.params.terminal._reader_succeed_input_collection_params import (
+ ReaderSucceedInputCollectionParams as ReaderSucceedInputCollectionParams,
+)
+from stripe.params.terminal._reader_timeout_input_collection_params import (
+ ReaderTimeoutInputCollectionParams as ReaderTimeoutInputCollectionParams,
+)
+from stripe.params.terminal._reader_update_params import (
+ ReaderUpdateParams as ReaderUpdateParams,
+)
diff --git a/stripe/params/terminal/_configuration_create_params.py b/stripe/params/terminal/_configuration_create_params.py
new file mode 100644
index 000000000..a9e9fe3c5
--- /dev/null
+++ b/stripe/params/terminal/_configuration_create_params.py
@@ -0,0 +1,572 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ConfigurationCreateParams(RequestOptions):
+ bbpos_wisepad3: NotRequired["ConfigurationCreateParamsBbposWisepad3"]
+ """
+ An object containing device type specific settings for BBPOS WisePad 3 readers
+ """
+ bbpos_wisepos_e: NotRequired["ConfigurationCreateParamsBbposWiseposE"]
+ """
+ An object containing device type specific settings for BBPOS WisePOS E readers
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ name: NotRequired[str]
+ """
+ Name of the configuration
+ """
+ offline: NotRequired["Literal['']|ConfigurationCreateParamsOffline"]
+ """
+ Configurations for collecting transactions offline.
+ """
+ reboot_window: NotRequired["ConfigurationCreateParamsRebootWindow"]
+ """
+ Reboot time settings for readers that support customized reboot time configuration.
+ """
+ stripe_s700: NotRequired["ConfigurationCreateParamsStripeS700"]
+ """
+ An object containing device type specific settings for Stripe S700 readers
+ """
+ tipping: NotRequired["Literal['']|ConfigurationCreateParamsTipping"]
+ """
+ Tipping configurations for readers supporting on-reader tips
+ """
+ verifone_p400: NotRequired["ConfigurationCreateParamsVerifoneP400"]
+ """
+ An object containing device type specific settings for Verifone P400 readers
+ """
+ wifi: NotRequired["Literal['']|ConfigurationCreateParamsWifi"]
+ """
+ Configurations for connecting to a WiFi network.
+ """
+
+
+class ConfigurationCreateParamsBbposWisepad3(TypedDict):
+ splashscreen: NotRequired["Literal['']|str"]
+ """
+ A File ID representing an image you would like displayed on the reader.
+ """
+
+
+class ConfigurationCreateParamsBbposWiseposE(TypedDict):
+ splashscreen: NotRequired["Literal['']|str"]
+ """
+ A File ID representing an image to display on the reader
+ """
+
+
+class ConfigurationCreateParamsOffline(TypedDict):
+ enabled: bool
+ """
+ Determines whether to allow transactions to be collected while reader is offline. Defaults to false.
+ """
+
+
+class ConfigurationCreateParamsRebootWindow(TypedDict):
+ end_hour: int
+ """
+ Integer between 0 to 23 that represents the end hour of the reboot time window. The value must be different than the start_hour.
+ """
+ start_hour: int
+ """
+ Integer between 0 to 23 that represents the start hour of the reboot time window.
+ """
+
+
+class ConfigurationCreateParamsStripeS700(TypedDict):
+ splashscreen: NotRequired["Literal['']|str"]
+ """
+ A File ID representing an image you would like displayed on the reader.
+ """
+
+
+class ConfigurationCreateParamsTipping(TypedDict):
+ aed: NotRequired["ConfigurationCreateParamsTippingAed"]
+ """
+ Tipping configuration for AED
+ """
+ aud: NotRequired["ConfigurationCreateParamsTippingAud"]
+ """
+ Tipping configuration for AUD
+ """
+ bgn: NotRequired["ConfigurationCreateParamsTippingBgn"]
+ """
+ Tipping configuration for BGN
+ """
+ cad: NotRequired["ConfigurationCreateParamsTippingCad"]
+ """
+ Tipping configuration for CAD
+ """
+ chf: NotRequired["ConfigurationCreateParamsTippingChf"]
+ """
+ Tipping configuration for CHF
+ """
+ czk: NotRequired["ConfigurationCreateParamsTippingCzk"]
+ """
+ Tipping configuration for CZK
+ """
+ dkk: NotRequired["ConfigurationCreateParamsTippingDkk"]
+ """
+ Tipping configuration for DKK
+ """
+ eur: NotRequired["ConfigurationCreateParamsTippingEur"]
+ """
+ Tipping configuration for EUR
+ """
+ gbp: NotRequired["ConfigurationCreateParamsTippingGbp"]
+ """
+ Tipping configuration for GBP
+ """
+ hkd: NotRequired["ConfigurationCreateParamsTippingHkd"]
+ """
+ Tipping configuration for HKD
+ """
+ huf: NotRequired["ConfigurationCreateParamsTippingHuf"]
+ """
+ Tipping configuration for HUF
+ """
+ jpy: NotRequired["ConfigurationCreateParamsTippingJpy"]
+ """
+ Tipping configuration for JPY
+ """
+ mxn: NotRequired["ConfigurationCreateParamsTippingMxn"]
+ """
+ Tipping configuration for MXN
+ """
+ myr: NotRequired["ConfigurationCreateParamsTippingMyr"]
+ """
+ Tipping configuration for MYR
+ """
+ nok: NotRequired["ConfigurationCreateParamsTippingNok"]
+ """
+ Tipping configuration for NOK
+ """
+ nzd: NotRequired["ConfigurationCreateParamsTippingNzd"]
+ """
+ Tipping configuration for NZD
+ """
+ pln: NotRequired["ConfigurationCreateParamsTippingPln"]
+ """
+ Tipping configuration for PLN
+ """
+ ron: NotRequired["ConfigurationCreateParamsTippingRon"]
+ """
+ Tipping configuration for RON
+ """
+ sek: NotRequired["ConfigurationCreateParamsTippingSek"]
+ """
+ Tipping configuration for SEK
+ """
+ sgd: NotRequired["ConfigurationCreateParamsTippingSgd"]
+ """
+ Tipping configuration for SGD
+ """
+ usd: NotRequired["ConfigurationCreateParamsTippingUsd"]
+ """
+ Tipping configuration for USD
+ """
+
+
+class ConfigurationCreateParamsTippingAed(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingAud(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingBgn(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingCad(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingChf(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingCzk(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingDkk(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingEur(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingGbp(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingHkd(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingHuf(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingJpy(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingMxn(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingMyr(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingNok(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingNzd(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingPln(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingRon(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingSek(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingSgd(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsTippingUsd(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationCreateParamsVerifoneP400(TypedDict):
+ splashscreen: NotRequired["Literal['']|str"]
+ """
+ A File ID representing an image you would like displayed on the reader.
+ """
+
+
+class ConfigurationCreateParamsWifi(TypedDict):
+ enterprise_eap_peap: NotRequired[
+ "ConfigurationCreateParamsWifiEnterpriseEapPeap"
+ ]
+ """
+ Credentials for a WPA-Enterprise WiFi network using the EAP-PEAP authentication method.
+ """
+ enterprise_eap_tls: NotRequired[
+ "ConfigurationCreateParamsWifiEnterpriseEapTls"
+ ]
+ """
+ Credentials for a WPA-Enterprise WiFi network using the EAP-TLS authentication method.
+ """
+ personal_psk: NotRequired["ConfigurationCreateParamsWifiPersonalPsk"]
+ """
+ Credentials for a WPA-Personal WiFi network.
+ """
+ type: Literal["enterprise_eap_peap", "enterprise_eap_tls", "personal_psk"]
+ """
+ Security type of the WiFi network. Fill out the hash with the corresponding name to provide the set of credentials for this security type.
+ """
+
+
+class ConfigurationCreateParamsWifiEnterpriseEapPeap(TypedDict):
+ ca_certificate_file: NotRequired[str]
+ """
+ A File ID representing a PEM file containing the server certificate
+ """
+ password: str
+ """
+ Password for connecting to the WiFi network
+ """
+ ssid: str
+ """
+ Name of the WiFi network
+ """
+ username: str
+ """
+ Username for connecting to the WiFi network
+ """
+
+
+class ConfigurationCreateParamsWifiEnterpriseEapTls(TypedDict):
+ ca_certificate_file: NotRequired[str]
+ """
+ A File ID representing a PEM file containing the server certificate
+ """
+ client_certificate_file: str
+ """
+ A File ID representing a PEM file containing the client certificate
+ """
+ private_key_file: str
+ """
+ A File ID representing a PEM file containing the client RSA private key
+ """
+ private_key_file_password: NotRequired[str]
+ """
+ Password for the private key file
+ """
+ ssid: str
+ """
+ Name of the WiFi network
+ """
+
+
+class ConfigurationCreateParamsWifiPersonalPsk(TypedDict):
+ password: str
+ """
+ Password for connecting to the WiFi network
+ """
+ ssid: str
+ """
+ Name of the WiFi network
+ """
diff --git a/stripe/params/terminal/_configuration_delete_params.py b/stripe/params/terminal/_configuration_delete_params.py
new file mode 100644
index 000000000..e9d95e0b0
--- /dev/null
+++ b/stripe/params/terminal/_configuration_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class ConfigurationDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/terminal/_configuration_list_params.py b/stripe/params/terminal/_configuration_list_params.py
new file mode 100644
index 000000000..c9e68efcf
--- /dev/null
+++ b/stripe/params/terminal/_configuration_list_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ConfigurationListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ is_account_default: NotRequired[bool]
+ """
+ if present, only return the account default or non-default configurations.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/terminal/_configuration_modify_params.py b/stripe/params/terminal/_configuration_modify_params.py
new file mode 100644
index 000000000..34db732f4
--- /dev/null
+++ b/stripe/params/terminal/_configuration_modify_params.py
@@ -0,0 +1,580 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ConfigurationModifyParams(RequestOptions):
+ bbpos_wisepad3: NotRequired[
+ "Literal['']|ConfigurationModifyParamsBbposWisepad3"
+ ]
+ """
+ An object containing device type specific settings for BBPOS WisePad 3 readers
+ """
+ bbpos_wisepos_e: NotRequired[
+ "Literal['']|ConfigurationModifyParamsBbposWiseposE"
+ ]
+ """
+ An object containing device type specific settings for BBPOS WisePOS E readers
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ name: NotRequired[str]
+ """
+ Name of the configuration
+ """
+ offline: NotRequired["Literal['']|ConfigurationModifyParamsOffline"]
+ """
+ Configurations for collecting transactions offline.
+ """
+ reboot_window: NotRequired[
+ "Literal['']|ConfigurationModifyParamsRebootWindow"
+ ]
+ """
+ Reboot time settings for readers that support customized reboot time configuration.
+ """
+ stripe_s700: NotRequired["Literal['']|ConfigurationModifyParamsStripeS700"]
+ """
+ An object containing device type specific settings for Stripe S700 readers
+ """
+ tipping: NotRequired["Literal['']|ConfigurationModifyParamsTipping"]
+ """
+ Tipping configurations for readers supporting on-reader tips
+ """
+ verifone_p400: NotRequired[
+ "Literal['']|ConfigurationModifyParamsVerifoneP400"
+ ]
+ """
+ An object containing device type specific settings for Verifone P400 readers
+ """
+ wifi: NotRequired["Literal['']|ConfigurationModifyParamsWifi"]
+ """
+ Configurations for connecting to a WiFi network.
+ """
+
+
+class ConfigurationModifyParamsBbposWisepad3(TypedDict):
+ splashscreen: NotRequired["Literal['']|str"]
+ """
+ A File ID representing an image you would like displayed on the reader.
+ """
+
+
+class ConfigurationModifyParamsBbposWiseposE(TypedDict):
+ splashscreen: NotRequired["Literal['']|str"]
+ """
+ A File ID representing an image to display on the reader
+ """
+
+
+class ConfigurationModifyParamsOffline(TypedDict):
+ enabled: bool
+ """
+ Determines whether to allow transactions to be collected while reader is offline. Defaults to false.
+ """
+
+
+class ConfigurationModifyParamsRebootWindow(TypedDict):
+ end_hour: int
+ """
+ Integer between 0 to 23 that represents the end hour of the reboot time window. The value must be different than the start_hour.
+ """
+ start_hour: int
+ """
+ Integer between 0 to 23 that represents the start hour of the reboot time window.
+ """
+
+
+class ConfigurationModifyParamsStripeS700(TypedDict):
+ splashscreen: NotRequired["Literal['']|str"]
+ """
+ A File ID representing an image you would like displayed on the reader.
+ """
+
+
+class ConfigurationModifyParamsTipping(TypedDict):
+ aed: NotRequired["ConfigurationModifyParamsTippingAed"]
+ """
+ Tipping configuration for AED
+ """
+ aud: NotRequired["ConfigurationModifyParamsTippingAud"]
+ """
+ Tipping configuration for AUD
+ """
+ bgn: NotRequired["ConfigurationModifyParamsTippingBgn"]
+ """
+ Tipping configuration for BGN
+ """
+ cad: NotRequired["ConfigurationModifyParamsTippingCad"]
+ """
+ Tipping configuration for CAD
+ """
+ chf: NotRequired["ConfigurationModifyParamsTippingChf"]
+ """
+ Tipping configuration for CHF
+ """
+ czk: NotRequired["ConfigurationModifyParamsTippingCzk"]
+ """
+ Tipping configuration for CZK
+ """
+ dkk: NotRequired["ConfigurationModifyParamsTippingDkk"]
+ """
+ Tipping configuration for DKK
+ """
+ eur: NotRequired["ConfigurationModifyParamsTippingEur"]
+ """
+ Tipping configuration for EUR
+ """
+ gbp: NotRequired["ConfigurationModifyParamsTippingGbp"]
+ """
+ Tipping configuration for GBP
+ """
+ hkd: NotRequired["ConfigurationModifyParamsTippingHkd"]
+ """
+ Tipping configuration for HKD
+ """
+ huf: NotRequired["ConfigurationModifyParamsTippingHuf"]
+ """
+ Tipping configuration for HUF
+ """
+ jpy: NotRequired["ConfigurationModifyParamsTippingJpy"]
+ """
+ Tipping configuration for JPY
+ """
+ mxn: NotRequired["ConfigurationModifyParamsTippingMxn"]
+ """
+ Tipping configuration for MXN
+ """
+ myr: NotRequired["ConfigurationModifyParamsTippingMyr"]
+ """
+ Tipping configuration for MYR
+ """
+ nok: NotRequired["ConfigurationModifyParamsTippingNok"]
+ """
+ Tipping configuration for NOK
+ """
+ nzd: NotRequired["ConfigurationModifyParamsTippingNzd"]
+ """
+ Tipping configuration for NZD
+ """
+ pln: NotRequired["ConfigurationModifyParamsTippingPln"]
+ """
+ Tipping configuration for PLN
+ """
+ ron: NotRequired["ConfigurationModifyParamsTippingRon"]
+ """
+ Tipping configuration for RON
+ """
+ sek: NotRequired["ConfigurationModifyParamsTippingSek"]
+ """
+ Tipping configuration for SEK
+ """
+ sgd: NotRequired["ConfigurationModifyParamsTippingSgd"]
+ """
+ Tipping configuration for SGD
+ """
+ usd: NotRequired["ConfigurationModifyParamsTippingUsd"]
+ """
+ Tipping configuration for USD
+ """
+
+
+class ConfigurationModifyParamsTippingAed(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingAud(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingBgn(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingCad(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingChf(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingCzk(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingDkk(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingEur(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingGbp(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingHkd(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingHuf(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingJpy(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingMxn(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingMyr(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingNok(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingNzd(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingPln(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingRon(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingSek(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingSgd(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsTippingUsd(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationModifyParamsVerifoneP400(TypedDict):
+ splashscreen: NotRequired["Literal['']|str"]
+ """
+ A File ID representing an image you would like displayed on the reader.
+ """
+
+
+class ConfigurationModifyParamsWifi(TypedDict):
+ enterprise_eap_peap: NotRequired[
+ "ConfigurationModifyParamsWifiEnterpriseEapPeap"
+ ]
+ """
+ Credentials for a WPA-Enterprise WiFi network using the EAP-PEAP authentication method.
+ """
+ enterprise_eap_tls: NotRequired[
+ "ConfigurationModifyParamsWifiEnterpriseEapTls"
+ ]
+ """
+ Credentials for a WPA-Enterprise WiFi network using the EAP-TLS authentication method.
+ """
+ personal_psk: NotRequired["ConfigurationModifyParamsWifiPersonalPsk"]
+ """
+ Credentials for a WPA-Personal WiFi network.
+ """
+ type: Literal["enterprise_eap_peap", "enterprise_eap_tls", "personal_psk"]
+ """
+ Security type of the WiFi network. Fill out the hash with the corresponding name to provide the set of credentials for this security type.
+ """
+
+
+class ConfigurationModifyParamsWifiEnterpriseEapPeap(TypedDict):
+ ca_certificate_file: NotRequired[str]
+ """
+ A File ID representing a PEM file containing the server certificate
+ """
+ password: str
+ """
+ Password for connecting to the WiFi network
+ """
+ ssid: str
+ """
+ Name of the WiFi network
+ """
+ username: str
+ """
+ Username for connecting to the WiFi network
+ """
+
+
+class ConfigurationModifyParamsWifiEnterpriseEapTls(TypedDict):
+ ca_certificate_file: NotRequired[str]
+ """
+ A File ID representing a PEM file containing the server certificate
+ """
+ client_certificate_file: str
+ """
+ A File ID representing a PEM file containing the client certificate
+ """
+ private_key_file: str
+ """
+ A File ID representing a PEM file containing the client RSA private key
+ """
+ private_key_file_password: NotRequired[str]
+ """
+ Password for the private key file
+ """
+ ssid: str
+ """
+ Name of the WiFi network
+ """
+
+
+class ConfigurationModifyParamsWifiPersonalPsk(TypedDict):
+ password: str
+ """
+ Password for connecting to the WiFi network
+ """
+ ssid: str
+ """
+ Name of the WiFi network
+ """
diff --git a/stripe/params/terminal/_configuration_retrieve_params.py b/stripe/params/terminal/_configuration_retrieve_params.py
new file mode 100644
index 000000000..95f024ac8
--- /dev/null
+++ b/stripe/params/terminal/_configuration_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ConfigurationRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/terminal/_configuration_update_params.py b/stripe/params/terminal/_configuration_update_params.py
new file mode 100644
index 000000000..b6707407a
--- /dev/null
+++ b/stripe/params/terminal/_configuration_update_params.py
@@ -0,0 +1,579 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ConfigurationUpdateParams(TypedDict):
+ bbpos_wisepad3: NotRequired[
+ "Literal['']|ConfigurationUpdateParamsBbposWisepad3"
+ ]
+ """
+ An object containing device type specific settings for BBPOS WisePad 3 readers
+ """
+ bbpos_wisepos_e: NotRequired[
+ "Literal['']|ConfigurationUpdateParamsBbposWiseposE"
+ ]
+ """
+ An object containing device type specific settings for BBPOS WisePOS E readers
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ name: NotRequired[str]
+ """
+ Name of the configuration
+ """
+ offline: NotRequired["Literal['']|ConfigurationUpdateParamsOffline"]
+ """
+ Configurations for collecting transactions offline.
+ """
+ reboot_window: NotRequired[
+ "Literal['']|ConfigurationUpdateParamsRebootWindow"
+ ]
+ """
+ Reboot time settings for readers that support customized reboot time configuration.
+ """
+ stripe_s700: NotRequired["Literal['']|ConfigurationUpdateParamsStripeS700"]
+ """
+ An object containing device type specific settings for Stripe S700 readers
+ """
+ tipping: NotRequired["Literal['']|ConfigurationUpdateParamsTipping"]
+ """
+ Tipping configurations for readers supporting on-reader tips
+ """
+ verifone_p400: NotRequired[
+ "Literal['']|ConfigurationUpdateParamsVerifoneP400"
+ ]
+ """
+ An object containing device type specific settings for Verifone P400 readers
+ """
+ wifi: NotRequired["Literal['']|ConfigurationUpdateParamsWifi"]
+ """
+ Configurations for connecting to a WiFi network.
+ """
+
+
+class ConfigurationUpdateParamsBbposWisepad3(TypedDict):
+ splashscreen: NotRequired["Literal['']|str"]
+ """
+ A File ID representing an image you would like displayed on the reader.
+ """
+
+
+class ConfigurationUpdateParamsBbposWiseposE(TypedDict):
+ splashscreen: NotRequired["Literal['']|str"]
+ """
+ A File ID representing an image to display on the reader
+ """
+
+
+class ConfigurationUpdateParamsOffline(TypedDict):
+ enabled: bool
+ """
+ Determines whether to allow transactions to be collected while reader is offline. Defaults to false.
+ """
+
+
+class ConfigurationUpdateParamsRebootWindow(TypedDict):
+ end_hour: int
+ """
+ Integer between 0 to 23 that represents the end hour of the reboot time window. The value must be different than the start_hour.
+ """
+ start_hour: int
+ """
+ Integer between 0 to 23 that represents the start hour of the reboot time window.
+ """
+
+
+class ConfigurationUpdateParamsStripeS700(TypedDict):
+ splashscreen: NotRequired["Literal['']|str"]
+ """
+ A File ID representing an image you would like displayed on the reader.
+ """
+
+
+class ConfigurationUpdateParamsTipping(TypedDict):
+ aed: NotRequired["ConfigurationUpdateParamsTippingAed"]
+ """
+ Tipping configuration for AED
+ """
+ aud: NotRequired["ConfigurationUpdateParamsTippingAud"]
+ """
+ Tipping configuration for AUD
+ """
+ bgn: NotRequired["ConfigurationUpdateParamsTippingBgn"]
+ """
+ Tipping configuration for BGN
+ """
+ cad: NotRequired["ConfigurationUpdateParamsTippingCad"]
+ """
+ Tipping configuration for CAD
+ """
+ chf: NotRequired["ConfigurationUpdateParamsTippingChf"]
+ """
+ Tipping configuration for CHF
+ """
+ czk: NotRequired["ConfigurationUpdateParamsTippingCzk"]
+ """
+ Tipping configuration for CZK
+ """
+ dkk: NotRequired["ConfigurationUpdateParamsTippingDkk"]
+ """
+ Tipping configuration for DKK
+ """
+ eur: NotRequired["ConfigurationUpdateParamsTippingEur"]
+ """
+ Tipping configuration for EUR
+ """
+ gbp: NotRequired["ConfigurationUpdateParamsTippingGbp"]
+ """
+ Tipping configuration for GBP
+ """
+ hkd: NotRequired["ConfigurationUpdateParamsTippingHkd"]
+ """
+ Tipping configuration for HKD
+ """
+ huf: NotRequired["ConfigurationUpdateParamsTippingHuf"]
+ """
+ Tipping configuration for HUF
+ """
+ jpy: NotRequired["ConfigurationUpdateParamsTippingJpy"]
+ """
+ Tipping configuration for JPY
+ """
+ mxn: NotRequired["ConfigurationUpdateParamsTippingMxn"]
+ """
+ Tipping configuration for MXN
+ """
+ myr: NotRequired["ConfigurationUpdateParamsTippingMyr"]
+ """
+ Tipping configuration for MYR
+ """
+ nok: NotRequired["ConfigurationUpdateParamsTippingNok"]
+ """
+ Tipping configuration for NOK
+ """
+ nzd: NotRequired["ConfigurationUpdateParamsTippingNzd"]
+ """
+ Tipping configuration for NZD
+ """
+ pln: NotRequired["ConfigurationUpdateParamsTippingPln"]
+ """
+ Tipping configuration for PLN
+ """
+ ron: NotRequired["ConfigurationUpdateParamsTippingRon"]
+ """
+ Tipping configuration for RON
+ """
+ sek: NotRequired["ConfigurationUpdateParamsTippingSek"]
+ """
+ Tipping configuration for SEK
+ """
+ sgd: NotRequired["ConfigurationUpdateParamsTippingSgd"]
+ """
+ Tipping configuration for SGD
+ """
+ usd: NotRequired["ConfigurationUpdateParamsTippingUsd"]
+ """
+ Tipping configuration for USD
+ """
+
+
+class ConfigurationUpdateParamsTippingAed(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingAud(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingBgn(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingCad(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingChf(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingCzk(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingDkk(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingEur(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingGbp(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingHkd(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingHuf(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingJpy(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingMxn(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingMyr(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingNok(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingNzd(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingPln(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingRon(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingSek(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingSgd(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsTippingUsd(TypedDict):
+ fixed_amounts: NotRequired[List[int]]
+ """
+ Fixed amounts displayed when collecting a tip
+ """
+ percentages: NotRequired[List[int]]
+ """
+ Percentages displayed when collecting a tip
+ """
+ smart_tip_threshold: NotRequired[int]
+ """
+ Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
+ """
+
+
+class ConfigurationUpdateParamsVerifoneP400(TypedDict):
+ splashscreen: NotRequired["Literal['']|str"]
+ """
+ A File ID representing an image you would like displayed on the reader.
+ """
+
+
+class ConfigurationUpdateParamsWifi(TypedDict):
+ enterprise_eap_peap: NotRequired[
+ "ConfigurationUpdateParamsWifiEnterpriseEapPeap"
+ ]
+ """
+ Credentials for a WPA-Enterprise WiFi network using the EAP-PEAP authentication method.
+ """
+ enterprise_eap_tls: NotRequired[
+ "ConfigurationUpdateParamsWifiEnterpriseEapTls"
+ ]
+ """
+ Credentials for a WPA-Enterprise WiFi network using the EAP-TLS authentication method.
+ """
+ personal_psk: NotRequired["ConfigurationUpdateParamsWifiPersonalPsk"]
+ """
+ Credentials for a WPA-Personal WiFi network.
+ """
+ type: Literal["enterprise_eap_peap", "enterprise_eap_tls", "personal_psk"]
+ """
+ Security type of the WiFi network. Fill out the hash with the corresponding name to provide the set of credentials for this security type.
+ """
+
+
+class ConfigurationUpdateParamsWifiEnterpriseEapPeap(TypedDict):
+ ca_certificate_file: NotRequired[str]
+ """
+ A File ID representing a PEM file containing the server certificate
+ """
+ password: str
+ """
+ Password for connecting to the WiFi network
+ """
+ ssid: str
+ """
+ Name of the WiFi network
+ """
+ username: str
+ """
+ Username for connecting to the WiFi network
+ """
+
+
+class ConfigurationUpdateParamsWifiEnterpriseEapTls(TypedDict):
+ ca_certificate_file: NotRequired[str]
+ """
+ A File ID representing a PEM file containing the server certificate
+ """
+ client_certificate_file: str
+ """
+ A File ID representing a PEM file containing the client certificate
+ """
+ private_key_file: str
+ """
+ A File ID representing a PEM file containing the client RSA private key
+ """
+ private_key_file_password: NotRequired[str]
+ """
+ Password for the private key file
+ """
+ ssid: str
+ """
+ Name of the WiFi network
+ """
+
+
+class ConfigurationUpdateParamsWifiPersonalPsk(TypedDict):
+ password: str
+ """
+ Password for connecting to the WiFi network
+ """
+ ssid: str
+ """
+ Name of the WiFi network
+ """
diff --git a/stripe/params/terminal/_connection_token_create_params.py b/stripe/params/terminal/_connection_token_create_params.py
new file mode 100644
index 000000000..5035f7e4b
--- /dev/null
+++ b/stripe/params/terminal/_connection_token_create_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ConnectionTokenCreateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ 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://docs.stripe.com/terminal/fleet/locations-and-zones?dashboard-or-api=api#connection-tokens).
+ """
diff --git a/stripe/params/terminal/_location_create_params.py b/stripe/params/terminal/_location_create_params.py
new file mode 100644
index 000000000..72a484005
--- /dev/null
+++ b/stripe/params/terminal/_location_create_params.py
@@ -0,0 +1,137 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class LocationCreateParams(RequestOptions):
+ address: NotRequired["LocationCreateParamsAddress"]
+ """
+ The full address of the location.
+ """
+ address_kana: NotRequired["LocationCreateParamsAddressKana"]
+ """
+ The Kana variation of the full address of the location (Japan only).
+ """
+ address_kanji: NotRequired["LocationCreateParamsAddressKanji"]
+ """
+ The Kanji variation of the full address of the location (Japan only).
+ """
+ configuration_overrides: NotRequired[str]
+ """
+ The ID of a configuration that will be used to customize all readers in this location.
+ """
+ display_name: NotRequired[str]
+ """
+ A name for the location. Maximum length is 1000 characters.
+ """
+ display_name_kana: NotRequired[str]
+ """
+ The Kana variation of the name for the location (Japan only). Maximum length is 1000 characters.
+ """
+ display_name_kanji: NotRequired[str]
+ """
+ The Kanji variation of the name for the location (Japan only). Maximum length is 1000 characters.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ phone: NotRequired[str]
+ """
+ The phone number for the location.
+ """
+
+
+class LocationCreateParamsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: str
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class LocationCreateParamsAddressKana(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class LocationCreateParamsAddressKanji(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
diff --git a/stripe/params/terminal/_location_delete_params.py b/stripe/params/terminal/_location_delete_params.py
new file mode 100644
index 000000000..d7f8582ca
--- /dev/null
+++ b/stripe/params/terminal/_location_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class LocationDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/terminal/_location_list_params.py b/stripe/params/terminal/_location_list_params.py
new file mode 100644
index 000000000..44de1fd82
--- /dev/null
+++ b/stripe/params/terminal/_location_list_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class LocationListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/terminal/_location_modify_params.py b/stripe/params/terminal/_location_modify_params.py
new file mode 100644
index 000000000..f4c76e275
--- /dev/null
+++ b/stripe/params/terminal/_location_modify_params.py
@@ -0,0 +1,137 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class LocationModifyParams(RequestOptions):
+ address: NotRequired["LocationModifyParamsAddress"]
+ """
+ The full address of the location. You can't change the location's `country`. If you need to modify the `country` field, create a new `Location` object and re-register any existing readers to that location.
+ """
+ address_kana: NotRequired["LocationModifyParamsAddressKana"]
+ """
+ The Kana variation of the full address of the location (Japan only).
+ """
+ address_kanji: NotRequired["LocationModifyParamsAddressKanji"]
+ """
+ The Kanji variation of the full address of the location (Japan only).
+ """
+ configuration_overrides: NotRequired["Literal['']|str"]
+ """
+ The ID of a configuration that will be used to customize all readers in this location.
+ """
+ display_name: NotRequired["Literal['']|str"]
+ """
+ A name for the location.
+ """
+ display_name_kana: NotRequired["Literal['']|str"]
+ """
+ The Kana variation of the name for the location (Japan only).
+ """
+ display_name_kanji: NotRequired["Literal['']|str"]
+ """
+ The Kanji variation of the name for the location (Japan only).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ The phone number for the location.
+ """
+
+
+class LocationModifyParamsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class LocationModifyParamsAddressKana(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class LocationModifyParamsAddressKanji(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
diff --git a/stripe/params/terminal/_location_retrieve_params.py b/stripe/params/terminal/_location_retrieve_params.py
new file mode 100644
index 000000000..107563bb5
--- /dev/null
+++ b/stripe/params/terminal/_location_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class LocationRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/terminal/_location_update_params.py b/stripe/params/terminal/_location_update_params.py
new file mode 100644
index 000000000..bd0083cbb
--- /dev/null
+++ b/stripe/params/terminal/_location_update_params.py
@@ -0,0 +1,136 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class LocationUpdateParams(TypedDict):
+ address: NotRequired["LocationUpdateParamsAddress"]
+ """
+ The full address of the location. You can't change the location's `country`. If you need to modify the `country` field, create a new `Location` object and re-register any existing readers to that location.
+ """
+ address_kana: NotRequired["LocationUpdateParamsAddressKana"]
+ """
+ The Kana variation of the full address of the location (Japan only).
+ """
+ address_kanji: NotRequired["LocationUpdateParamsAddressKanji"]
+ """
+ The Kanji variation of the full address of the location (Japan only).
+ """
+ configuration_overrides: NotRequired["Literal['']|str"]
+ """
+ The ID of a configuration that will be used to customize all readers in this location.
+ """
+ display_name: NotRequired["Literal['']|str"]
+ """
+ A name for the location.
+ """
+ display_name_kana: NotRequired["Literal['']|str"]
+ """
+ The Kana variation of the name for the location (Japan only).
+ """
+ display_name_kanji: NotRequired["Literal['']|str"]
+ """
+ The Kanji variation of the name for the location (Japan only).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ The phone number for the location.
+ """
+
+
+class LocationUpdateParamsAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class LocationUpdateParamsAddressKana(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
+
+
+class LocationUpdateParamsAddressKanji(TypedDict):
+ city: NotRequired[str]
+ """
+ City or ward.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Block or building number.
+ """
+ line2: NotRequired[str]
+ """
+ Building details.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code.
+ """
+ state: NotRequired[str]
+ """
+ Prefecture.
+ """
+ town: NotRequired[str]
+ """
+ Town or cho-me.
+ """
diff --git a/stripe/params/terminal/_reader_cancel_action_params.py b/stripe/params/terminal/_reader_cancel_action_params.py
new file mode 100644
index 000000000..13541d52a
--- /dev/null
+++ b/stripe/params/terminal/_reader_cancel_action_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ReaderCancelActionParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/terminal/_reader_collect_inputs_params.py b/stripe/params/terminal/_reader_collect_inputs_params.py
new file mode 100644
index 000000000..90ca68798
--- /dev/null
+++ b/stripe/params/terminal/_reader_collect_inputs_params.py
@@ -0,0 +1,101 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ReaderCollectInputsParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ inputs: List["ReaderCollectInputsParamsInput"]
+ """
+ List of inputs to be collected using the Reader
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+
+
+class ReaderCollectInputsParamsInput(TypedDict):
+ custom_text: "ReaderCollectInputsParamsInputCustomText"
+ """
+ Customize the text which will be displayed while collecting this input
+ """
+ required: NotRequired[bool]
+ """
+ Indicate that this input is required, disabling the skip button
+ """
+ selection: NotRequired["ReaderCollectInputsParamsInputSelection"]
+ """
+ Options for the `selection` input
+ """
+ toggles: NotRequired[List["ReaderCollectInputsParamsInputToggle"]]
+ """
+ List of toggles to be displayed and customization for the toggles
+ """
+ type: Literal[
+ "email", "numeric", "phone", "selection", "signature", "text"
+ ]
+ """
+ The type of input to collect
+ """
+
+
+class ReaderCollectInputsParamsInputCustomText(TypedDict):
+ description: NotRequired[str]
+ """
+ The description which will be displayed when collecting this input
+ """
+ skip_button: NotRequired[str]
+ """
+ The skip button text
+ """
+ submit_button: NotRequired[str]
+ """
+ The submit button text
+ """
+ title: str
+ """
+ The title which will be displayed when collecting this input
+ """
+
+
+class ReaderCollectInputsParamsInputSelection(TypedDict):
+ choices: List["ReaderCollectInputsParamsInputSelectionChoice"]
+ """
+ List of choices for the `selection` input
+ """
+
+
+class ReaderCollectInputsParamsInputSelectionChoice(TypedDict):
+ id: str
+ """
+ The unique identifier for this choice
+ """
+ style: NotRequired[Literal["primary", "secondary"]]
+ """
+ The style of the button which will be shown for this choice
+ """
+ text: str
+ """
+ The text which will be shown on the button for this choice
+ """
+
+
+class ReaderCollectInputsParamsInputToggle(TypedDict):
+ default_value: NotRequired[Literal["disabled", "enabled"]]
+ """
+ The default value of the toggle
+ """
+ description: NotRequired[str]
+ """
+ The description which will be displayed for the toggle
+ """
+ title: NotRequired[str]
+ """
+ The title which will be displayed for the toggle
+ """
diff --git a/stripe/params/terminal/_reader_collect_payment_method_params.py b/stripe/params/terminal/_reader_collect_payment_method_params.py
new file mode 100644
index 000000000..f6572c95e
--- /dev/null
+++ b/stripe/params/terminal/_reader_collect_payment_method_params.py
@@ -0,0 +1,50 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ReaderCollectPaymentMethodParams(RequestOptions):
+ collect_config: NotRequired[
+ "ReaderCollectPaymentMethodParamsCollectConfig"
+ ]
+ """
+ Configuration overrides.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ payment_intent: str
+ """
+ PaymentIntent ID.
+ """
+
+
+class ReaderCollectPaymentMethodParamsCollectConfig(TypedDict):
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
+ """
+ enable_customer_cancellation: NotRequired[bool]
+ """
+ Enables cancel button on transaction screens.
+ """
+ skip_tipping: NotRequired[bool]
+ """
+ Override showing a tipping selection screen on this transaction.
+ """
+ tipping: NotRequired[
+ "ReaderCollectPaymentMethodParamsCollectConfigTipping"
+ ]
+ """
+ Tipping configuration for this transaction.
+ """
+
+
+class ReaderCollectPaymentMethodParamsCollectConfigTipping(TypedDict):
+ amount_eligible: NotRequired[int]
+ """
+ Amount used to calculate tip suggestions on tipping selection screen for this transaction. Must be a positive integer in the smallest currency unit (e.g., 100 cents to represent $1.00 or 100 to represent ¥100, a zero-decimal currency).
+ """
diff --git a/stripe/params/terminal/_reader_confirm_payment_intent_params.py b/stripe/params/terminal/_reader_confirm_payment_intent_params.py
new file mode 100644
index 000000000..47785c3fa
--- /dev/null
+++ b/stripe/params/terminal/_reader_confirm_payment_intent_params.py
@@ -0,0 +1,29 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ReaderConfirmPaymentIntentParams(RequestOptions):
+ confirm_config: NotRequired[
+ "ReaderConfirmPaymentIntentParamsConfirmConfig"
+ ]
+ """
+ Configuration overrides.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ payment_intent: str
+ """
+ PaymentIntent ID.
+ """
+
+
+class ReaderConfirmPaymentIntentParamsConfirmConfig(TypedDict):
+ return_url: NotRequired[str]
+ """
+ The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
+ """
diff --git a/stripe/params/terminal/_reader_create_params.py b/stripe/params/terminal/_reader_create_params.py
new file mode 100644
index 000000000..6e6d550d7
--- /dev/null
+++ b/stripe/params/terminal/_reader_create_params.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class ReaderCreateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ label: NotRequired[str]
+ """
+ Custom label given to the reader for easier identification. If no label is specified, the registration code will be used.
+ """
+ location: NotRequired[str]
+ """
+ The location to assign the reader to.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ registration_code: str
+ """
+ A code generated by the reader used for registering to an account.
+ """
diff --git a/stripe/params/terminal/_reader_delete_params.py b/stripe/params/terminal/_reader_delete_params.py
new file mode 100644
index 000000000..a9ac7242c
--- /dev/null
+++ b/stripe/params/terminal/_reader_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class ReaderDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/terminal/_reader_list_params.py b/stripe/params/terminal/_reader_list_params.py
new file mode 100644
index 000000000..6f77b07ab
--- /dev/null
+++ b/stripe/params/terminal/_reader_list_params.py
@@ -0,0 +1,52 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class ReaderListParams(RequestOptions):
+ device_type: NotRequired[
+ Literal[
+ "bbpos_chipper2x",
+ "bbpos_wisepad3",
+ "bbpos_wisepos_e",
+ "mobile_phone_reader",
+ "simulated_stripe_s700",
+ "simulated_wisepos_e",
+ "stripe_m2",
+ "stripe_s700",
+ "verifone_P400",
+ ]
+ ]
+ """
+ Filters readers by device type
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ location: NotRequired[str]
+ """
+ A location ID to filter the response list to only readers at the specific location
+ """
+ serial_number: NotRequired[str]
+ """
+ Filters readers by serial number
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["offline", "online"]]
+ """
+ A status filter to filter readers to only offline or online readers
+ """
diff --git a/stripe/params/terminal/_reader_modify_params.py b/stripe/params/terminal/_reader_modify_params.py
new file mode 100644
index 000000000..da2d79c97
--- /dev/null
+++ b/stripe/params/terminal/_reader_modify_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired
+
+
+class ReaderModifyParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ label: NotRequired["Literal['']|str"]
+ """
+ The new label of the reader.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/terminal/_reader_present_payment_method_params.py b/stripe/params/terminal/_reader_present_payment_method_params.py
new file mode 100644
index 000000000..c73ce6ea1
--- /dev/null
+++ b/stripe/params/terminal/_reader_present_payment_method_params.py
@@ -0,0 +1,67 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ReaderPresentPaymentMethodParams(RequestOptions):
+ amount_tip: NotRequired[int]
+ """
+ Simulated on-reader tip amount.
+ """
+ card: NotRequired["ReaderPresentPaymentMethodParamsCard"]
+ """
+ Simulated data for the card payment method.
+ """
+ card_present: NotRequired["ReaderPresentPaymentMethodParamsCardPresent"]
+ """
+ Simulated data for the card_present payment method.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ interac_present: NotRequired[
+ "ReaderPresentPaymentMethodParamsInteracPresent"
+ ]
+ """
+ Simulated data for the interac_present payment method.
+ """
+ type: NotRequired[Literal["card", "card_present", "interac_present"]]
+ """
+ Simulated payment type.
+ """
+
+
+class ReaderPresentPaymentMethodParamsCard(TypedDict):
+ cvc: NotRequired[str]
+ """
+ Card security code.
+ """
+ exp_month: int
+ """
+ Two-digit number representing the card's expiration month.
+ """
+ exp_year: int
+ """
+ Two- or four-digit number representing the card's expiration year.
+ """
+ number: str
+ """
+ The card number, as a string without any separators.
+ """
+
+
+class ReaderPresentPaymentMethodParamsCardPresent(TypedDict):
+ number: NotRequired[str]
+ """
+ The card number, as a string without any separators.
+ """
+
+
+class ReaderPresentPaymentMethodParamsInteracPresent(TypedDict):
+ number: NotRequired[str]
+ """
+ Card Number
+ """
diff --git a/stripe/params/terminal/_reader_process_payment_intent_params.py b/stripe/params/terminal/_reader_process_payment_intent_params.py
new file mode 100644
index 000000000..e1207d8ae
--- /dev/null
+++ b/stripe/params/terminal/_reader_process_payment_intent_params.py
@@ -0,0 +1,54 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ReaderProcessPaymentIntentParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ payment_intent: str
+ """
+ PaymentIntent ID
+ """
+ process_config: NotRequired[
+ "ReaderProcessPaymentIntentParamsProcessConfig"
+ ]
+ """
+ Configuration overrides
+ """
+
+
+class ReaderProcessPaymentIntentParamsProcessConfig(TypedDict):
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
+ """
+ enable_customer_cancellation: NotRequired[bool]
+ """
+ Enables cancel button on transaction screens.
+ """
+ return_url: NotRequired[str]
+ """
+ The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
+ """
+ skip_tipping: NotRequired[bool]
+ """
+ Override showing a tipping selection screen on this transaction.
+ """
+ tipping: NotRequired[
+ "ReaderProcessPaymentIntentParamsProcessConfigTipping"
+ ]
+ """
+ Tipping configuration for this transaction.
+ """
+
+
+class ReaderProcessPaymentIntentParamsProcessConfigTipping(TypedDict):
+ amount_eligible: NotRequired[int]
+ """
+ Amount used to calculate tip suggestions on tipping selection screen for this transaction. Must be a positive integer in the smallest currency unit (e.g., 100 cents to represent $1.00 or 100 to represent ¥100, a zero-decimal currency).
+ """
diff --git a/stripe/params/terminal/_reader_process_setup_intent_params.py b/stripe/params/terminal/_reader_process_setup_intent_params.py
new file mode 100644
index 000000000..0f98f8bb1
--- /dev/null
+++ b/stripe/params/terminal/_reader_process_setup_intent_params.py
@@ -0,0 +1,31 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ReaderProcessSetupIntentParams(RequestOptions):
+ allow_redisplay: Literal["always", "limited", "unspecified"]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ process_config: NotRequired["ReaderProcessSetupIntentParamsProcessConfig"]
+ """
+ Configuration overrides
+ """
+ setup_intent: str
+ """
+ SetupIntent ID
+ """
+
+
+class ReaderProcessSetupIntentParamsProcessConfig(TypedDict):
+ enable_customer_cancellation: NotRequired[bool]
+ """
+ Enables cancel button on transaction screens.
+ """
diff --git a/stripe/params/terminal/_reader_refund_payment_params.py b/stripe/params/terminal/_reader_refund_payment_params.py
new file mode 100644
index 000000000..2cb33c244
--- /dev/null
+++ b/stripe/params/terminal/_reader_refund_payment_params.py
@@ -0,0 +1,49 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ReaderRefundPaymentParams(RequestOptions):
+ amount: NotRequired[int]
+ """
+ A positive integer in __cents__ representing how much of this charge to refund.
+ """
+ charge: NotRequired[str]
+ """
+ ID of the Charge to refund.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ payment_intent: NotRequired[str]
+ """
+ ID of the PaymentIntent to refund.
+ """
+ refund_application_fee: NotRequired[bool]
+ """
+ Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.
+ """
+ refund_payment_config: NotRequired[
+ "ReaderRefundPaymentParamsRefundPaymentConfig"
+ ]
+ """
+ Configuration overrides
+ """
+ reverse_transfer: NotRequired[bool]
+ """
+ Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount). A transfer can be reversed only by the application that created the charge.
+ """
+
+
+class ReaderRefundPaymentParamsRefundPaymentConfig(TypedDict):
+ enable_customer_cancellation: NotRequired[bool]
+ """
+ Enables cancel button on transaction screens.
+ """
diff --git a/stripe/params/terminal/_reader_retrieve_params.py b/stripe/params/terminal/_reader_retrieve_params.py
new file mode 100644
index 000000000..172fa8d8e
--- /dev/null
+++ b/stripe/params/terminal/_reader_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ReaderRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/terminal/_reader_set_reader_display_params.py b/stripe/params/terminal/_reader_set_reader_display_params.py
new file mode 100644
index 000000000..bc4b3f77c
--- /dev/null
+++ b/stripe/params/terminal/_reader_set_reader_display_params.py
@@ -0,0 +1,54 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ReaderSetReaderDisplayParams(RequestOptions):
+ cart: NotRequired["ReaderSetReaderDisplayParamsCart"]
+ """
+ Cart
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ type: Literal["cart"]
+ """
+ Type
+ """
+
+
+class ReaderSetReaderDisplayParamsCart(TypedDict):
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ line_items: List["ReaderSetReaderDisplayParamsCartLineItem"]
+ """
+ Array of line items that were purchased.
+ """
+ tax: NotRequired[int]
+ """
+ The amount of tax in cents.
+ """
+ total: int
+ """
+ Total balance of cart due in cents.
+ """
+
+
+class ReaderSetReaderDisplayParamsCartLineItem(TypedDict):
+ amount: int
+ """
+ The price of the item in cents.
+ """
+ description: str
+ """
+ The description or name of the item.
+ """
+ quantity: int
+ """
+ The quantity of the line item being purchased.
+ """
diff --git a/stripe/params/terminal/_reader_succeed_input_collection_params.py b/stripe/params/terminal/_reader_succeed_input_collection_params.py
new file mode 100644
index 000000000..0872d72aa
--- /dev/null
+++ b/stripe/params/terminal/_reader_succeed_input_collection_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class ReaderSucceedInputCollectionParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ skip_non_required_inputs: NotRequired[Literal["all", "none"]]
+ """
+ This parameter defines the skip behavior for input collection.
+ """
diff --git a/stripe/params/terminal/_reader_timeout_input_collection_params.py b/stripe/params/terminal/_reader_timeout_input_collection_params.py
new file mode 100644
index 000000000..4a25a66bd
--- /dev/null
+++ b/stripe/params/terminal/_reader_timeout_input_collection_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ReaderTimeoutInputCollectionParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/terminal/_reader_update_params.py b/stripe/params/terminal/_reader_update_params.py
new file mode 100644
index 000000000..25b94dc25
--- /dev/null
+++ b/stripe/params/terminal/_reader_update_params.py
@@ -0,0 +1,19 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ReaderUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ label: NotRequired["Literal['']|str"]
+ """
+ The new label of the reader.
+ """
+ metadata: NotRequired["Literal['']|Dict[str, str]"]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
diff --git a/stripe/params/test_helpers/__init__.py b/stripe/params/test_helpers/__init__.py
new file mode 100644
index 000000000..614d61c29
--- /dev/null
+++ b/stripe/params/test_helpers/__init__.py
@@ -0,0 +1,31 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.test_helpers import (
+ issuing as issuing,
+ terminal as terminal,
+ treasury as treasury,
+)
+from stripe.params.test_helpers._confirmation_token_create_params import (
+ ConfirmationTokenCreateParams as ConfirmationTokenCreateParams,
+)
+from stripe.params.test_helpers._customer_fund_cash_balance_params import (
+ CustomerFundCashBalanceParams as CustomerFundCashBalanceParams,
+)
+from stripe.params.test_helpers._refund_expire_params import (
+ RefundExpireParams as RefundExpireParams,
+)
+from stripe.params.test_helpers._test_clock_advance_params import (
+ TestClockAdvanceParams as TestClockAdvanceParams,
+)
+from stripe.params.test_helpers._test_clock_create_params import (
+ TestClockCreateParams as TestClockCreateParams,
+)
+from stripe.params.test_helpers._test_clock_delete_params import (
+ TestClockDeleteParams as TestClockDeleteParams,
+)
+from stripe.params.test_helpers._test_clock_list_params import (
+ TestClockListParams as TestClockListParams,
+)
+from stripe.params.test_helpers._test_clock_retrieve_params import (
+ TestClockRetrieveParams as TestClockRetrieveParams,
+)
diff --git a/stripe/params/test_helpers/_confirmation_token_create_params.py b/stripe/params/test_helpers/_confirmation_token_create_params.py
new file mode 100644
index 000000000..b3069075c
--- /dev/null
+++ b/stripe/params/test_helpers/_confirmation_token_create_params.py
@@ -0,0 +1,925 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ConfirmationTokenCreateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ payment_method: NotRequired[str]
+ """
+ ID of an existing PaymentMethod.
+ """
+ payment_method_data: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodData"
+ ]
+ """
+ If provided, this hash will be used to create a PaymentMethod.
+ """
+ payment_method_options: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodOptions"
+ ]
+ """
+ Payment-method-specific configuration for this ConfirmationToken.
+ """
+ return_url: NotRequired[str]
+ """
+ Return URL used to confirm the Intent.
+ """
+ setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
+ """
+ Indicates that you intend to make future payments with this ConfirmationToken's payment method.
+
+ The presence of this property will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete.
+ """
+ shipping: NotRequired["ConfirmationTokenCreateParamsShipping"]
+ """
+ Shipping information for this ConfirmationToken.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodData(TypedDict):
+ acss_debit: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataAcssDebit"
+ ]
+ """
+ If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
+ """
+ affirm: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataAffirm"]
+ """
+ If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
+ """
+ afterpay_clearpay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataAfterpayClearpay"
+ ]
+ """
+ If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
+ """
+ alipay: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataAlipay"]
+ """
+ If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
+ """
+ allow_redisplay: NotRequired[Literal["always", "limited", "unspecified"]]
+ """
+ This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
+ """
+ alma: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataAlma"]
+ """
+ If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
+ """
+ amazon_pay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataAmazonPay"
+ ]
+ """
+ If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
+ """
+ au_becs_debit: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataAuBecsDebit"
+ ]
+ """
+ If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
+ """
+ bacs_debit: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataBacsDebit"
+ ]
+ """
+ If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
+ """
+ bancontact: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataBancontact"
+ ]
+ """
+ If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
+ """
+ billie: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataBillie"]
+ """
+ If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
+ """
+ billing_details: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataBillingDetails"
+ ]
+ """
+ Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+ """
+ blik: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataBlik"]
+ """
+ If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
+ """
+ boleto: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataBoleto"]
+ """
+ If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
+ """
+ cashapp: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataCashapp"
+ ]
+ """
+ If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
+ """
+ crypto: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataCrypto"]
+ """
+ If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
+ """
+ customer_balance: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataCustomerBalance"
+ ]
+ """
+ If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
+ """
+ eps: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataEps"]
+ """
+ If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
+ """
+ fpx: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataFpx"]
+ """
+ If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
+ """
+ giropay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataGiropay"
+ ]
+ """
+ If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
+ """
+ grabpay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataGrabpay"
+ ]
+ """
+ If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
+ """
+ ideal: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataIdeal"]
+ """
+ If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
+ """
+ interac_present: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataInteracPresent"
+ ]
+ """
+ If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
+ """
+ kakao_pay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataKakaoPay"
+ ]
+ """
+ If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
+ """
+ klarna: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataKlarna"]
+ """
+ If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
+ """
+ konbini: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataKonbini"
+ ]
+ """
+ If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
+ """
+ kr_card: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataKrCard"
+ ]
+ """
+ If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
+ """
+ link: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataLink"]
+ """
+ If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
+ """
+ mb_way: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataMbWay"]
+ """
+ If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ mobilepay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataMobilepay"
+ ]
+ """
+ If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
+ """
+ multibanco: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataMultibanco"
+ ]
+ """
+ If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
+ """
+ naver_pay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataNaverPay"
+ ]
+ """
+ If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
+ """
+ nz_bank_account: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataNzBankAccount"
+ ]
+ """
+ If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
+ """
+ oxxo: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataOxxo"]
+ """
+ If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
+ """
+ p24: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataP24"]
+ """
+ If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
+ """
+ pay_by_bank: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataPayByBank"
+ ]
+ """
+ If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
+ """
+ payco: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataPayco"]
+ """
+ If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
+ """
+ paynow: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataPaynow"]
+ """
+ If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
+ """
+ paypal: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataPaypal"]
+ """
+ If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
+ """
+ pix: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataPix"]
+ """
+ If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
+ """
+ promptpay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataPromptpay"
+ ]
+ """
+ If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
+ """
+ radar_options: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataRadarOptions"
+ ]
+ """
+ Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
+ """
+ revolut_pay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataRevolutPay"
+ ]
+ """
+ If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
+ """
+ samsung_pay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataSamsungPay"
+ ]
+ """
+ If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
+ """
+ satispay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataSatispay"
+ ]
+ """
+ If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
+ """
+ sepa_debit: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataSepaDebit"
+ ]
+ """
+ If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
+ """
+ sofort: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataSofort"]
+ """
+ If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
+ """
+ swish: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataSwish"]
+ """
+ If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
+ """
+ twint: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataTwint"]
+ """
+ If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
+ """
+ type: Literal[
+ "acss_debit",
+ "affirm",
+ "afterpay_clearpay",
+ "alipay",
+ "alma",
+ "amazon_pay",
+ "au_becs_debit",
+ "bacs_debit",
+ "bancontact",
+ "billie",
+ "blik",
+ "boleto",
+ "cashapp",
+ "crypto",
+ "customer_balance",
+ "eps",
+ "fpx",
+ "giropay",
+ "grabpay",
+ "ideal",
+ "kakao_pay",
+ "klarna",
+ "konbini",
+ "kr_card",
+ "link",
+ "mb_way",
+ "mobilepay",
+ "multibanco",
+ "naver_pay",
+ "nz_bank_account",
+ "oxxo",
+ "p24",
+ "pay_by_bank",
+ "payco",
+ "paynow",
+ "paypal",
+ "pix",
+ "promptpay",
+ "revolut_pay",
+ "samsung_pay",
+ "satispay",
+ "sepa_debit",
+ "sofort",
+ "swish",
+ "twint",
+ "us_bank_account",
+ "wechat_pay",
+ "zip",
+ ]
+ """
+ The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
+ """
+ us_bank_account: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataUsBankAccount"
+ ]
+ """
+ If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
+ """
+ wechat_pay: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodDataWechatPay"
+ ]
+ """
+ If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
+ """
+ zip: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataZip"]
+ """
+ If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataAcssDebit(TypedDict):
+ account_number: str
+ """
+ Customer's bank account number.
+ """
+ institution_number: str
+ """
+ Institution number of the customer's bank.
+ """
+ transit_number: str
+ """
+ Transit number of the customer's bank.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataAffirm(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataAfterpayClearpay(
+ TypedDict
+):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataAlipay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataAlma(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataAmazonPay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataAuBecsDebit(TypedDict):
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bsb_number: str
+ """
+ Bank-State-Branch number of the bank account.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataBacsDebit(TypedDict):
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account that the funds will be debited from.
+ """
+ sort_code: NotRequired[str]
+ """
+ Sort code of the bank account. (e.g., `10-20-30`)
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataBancontact(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataBillie(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataBillingDetails(TypedDict):
+ address: NotRequired[
+ "Literal['']|ConfirmationTokenCreateParamsPaymentMethodDataBillingDetailsAddress"
+ ]
+ """
+ Billing address.
+ """
+ email: NotRequired["Literal['']|str"]
+ """
+ Email address.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Full name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Billing phone number (including extension).
+ """
+ tax_id: NotRequired[str]
+ """
+ Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataBillingDetailsAddress(
+ TypedDict,
+):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataBlik(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataBoleto(TypedDict):
+ tax_id: str
+ """
+ The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataCashapp(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataCrypto(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataCustomerBalance(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataEps(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "arzte_und_apotheker_bank",
+ "austrian_anadi_bank_ag",
+ "bank_austria",
+ "bankhaus_carl_spangler",
+ "bankhaus_schelhammer_und_schattera_ag",
+ "bawag_psk_ag",
+ "bks_bank_ag",
+ "brull_kallmus_bank_ag",
+ "btv_vier_lander_bank",
+ "capital_bank_grawe_gruppe_ag",
+ "deutsche_bank_ag",
+ "dolomitenbank",
+ "easybank_ag",
+ "erste_bank_und_sparkassen",
+ "hypo_alpeadriabank_international_ag",
+ "hypo_bank_burgenland_aktiengesellschaft",
+ "hypo_noe_lb_fur_niederosterreich_u_wien",
+ "hypo_oberosterreich_salzburg_steiermark",
+ "hypo_tirol_bank_ag",
+ "hypo_vorarlberg_bank_ag",
+ "marchfelder_bank",
+ "oberbank_ag",
+ "raiffeisen_bankengruppe_osterreich",
+ "schoellerbank_ag",
+ "sparda_bank_wien",
+ "volksbank_gruppe",
+ "volkskreditbank_ag",
+ "vr_bank_braunau",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataFpx(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type for FPX transaction
+ """
+ bank: Literal[
+ "affin_bank",
+ "agrobank",
+ "alliance_bank",
+ "ambank",
+ "bank_islam",
+ "bank_muamalat",
+ "bank_of_china",
+ "bank_rakyat",
+ "bsn",
+ "cimb",
+ "deutsche_bank",
+ "hong_leong_bank",
+ "hsbc",
+ "kfh",
+ "maybank2e",
+ "maybank2u",
+ "ocbc",
+ "pb_enterprise",
+ "public_bank",
+ "rhb",
+ "standard_chartered",
+ "uob",
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataGiropay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataGrabpay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataIdeal(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "abn_amro",
+ "asn_bank",
+ "bunq",
+ "buut",
+ "handelsbanken",
+ "ing",
+ "knab",
+ "moneyou",
+ "n26",
+ "nn",
+ "rabobank",
+ "regiobank",
+ "revolut",
+ "sns_bank",
+ "triodos_bank",
+ "van_lanschot",
+ "yoursafe",
+ ]
+ ]
+ """
+ The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataInteracPresent(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataKakaoPay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataKlarna(TypedDict):
+ dob: NotRequired["ConfirmationTokenCreateParamsPaymentMethodDataKlarnaDob"]
+ """
+ Customer's date of birth
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataKlarnaDob(TypedDict):
+ day: int
+ """
+ The day of birth, between 1 and 31.
+ """
+ month: int
+ """
+ The month of birth, between 1 and 12.
+ """
+ year: int
+ """
+ The four-digit year of birth.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataKonbini(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataKrCard(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataLink(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataMbWay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataMobilepay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataMultibanco(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataNaverPay(TypedDict):
+ funding: NotRequired[Literal["card", "points"]]
+ """
+ Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataNzBankAccount(TypedDict):
+ account_holder_name: NotRequired[str]
+ """
+ The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
+ """
+ account_number: str
+ """
+ The account number for the bank account.
+ """
+ bank_code: str
+ """
+ The numeric code for the bank account's bank.
+ """
+ branch_code: str
+ """
+ The numeric code for the bank account's bank branch.
+ """
+ reference: NotRequired[str]
+ suffix: str
+ """
+ The suffix of the bank account number.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataOxxo(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataP24(TypedDict):
+ bank: NotRequired[
+ Literal[
+ "alior_bank",
+ "bank_millennium",
+ "bank_nowy_bfg_sa",
+ "bank_pekao_sa",
+ "banki_spbdzielcze",
+ "blik",
+ "bnp_paribas",
+ "boz",
+ "citi_handlowy",
+ "credit_agricole",
+ "envelobank",
+ "etransfer_pocztowy24",
+ "getin_bank",
+ "ideabank",
+ "ing",
+ "inteligo",
+ "mbank_mtransfer",
+ "nest_przelew",
+ "noble_pay",
+ "pbac_z_ipko",
+ "plus_bank",
+ "santander_przelew24",
+ "tmobile_usbugi_bankowe",
+ "toyota_bank",
+ "velobank",
+ "volkswagen_bank",
+ ]
+ ]
+ """
+ The customer's bank.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataPayByBank(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataPayco(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataPaynow(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataPaypal(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataPix(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataPromptpay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataRadarOptions(TypedDict):
+ session: NotRequired[str]
+ """
+ A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataRevolutPay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataSamsungPay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataSatispay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataSepaDebit(TypedDict):
+ iban: str
+ """
+ IBAN of the bank account.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataSofort(TypedDict):
+ country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
+ """
+ Two-letter ISO code representing the country the bank account is located in.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataSwish(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataTwint(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataUsBankAccount(TypedDict):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type: individual or company.
+ """
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account.
+ """
+ account_type: NotRequired[Literal["checking", "savings"]]
+ """
+ Account type: checkings or savings. Defaults to checking if omitted.
+ """
+ financial_connections_account: NotRequired[str]
+ """
+ The ID of a Financial Connections Account to use as a payment method.
+ """
+ routing_number: NotRequired[str]
+ """
+ Routing number of the bank account.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataWechatPay(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodDataZip(TypedDict):
+ pass
+
+
+class ConfirmationTokenCreateParamsPaymentMethodOptions(TypedDict):
+ card: NotRequired["ConfirmationTokenCreateParamsPaymentMethodOptionsCard"]
+ """
+ Configuration for any card payments confirmed using this ConfirmationToken.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodOptionsCard(TypedDict):
+ installments: NotRequired[
+ "ConfirmationTokenCreateParamsPaymentMethodOptionsCardInstallments"
+ ]
+ """
+ Installment configuration for payments confirmed using this ConfirmationToken.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodOptionsCardInstallments(
+ TypedDict,
+):
+ plan: (
+ "ConfirmationTokenCreateParamsPaymentMethodOptionsCardInstallmentsPlan"
+ )
+ """
+ The selected installment plan to use for this payment attempt.
+ This parameter can only be provided during confirmation.
+ """
+
+
+class ConfirmationTokenCreateParamsPaymentMethodOptionsCardInstallmentsPlan(
+ TypedDict,
+):
+ count: NotRequired[int]
+ """
+ For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
+ """
+ interval: NotRequired[Literal["month"]]
+ """
+ For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
+ One of `month`.
+ """
+ type: Literal["bonus", "fixed_count", "revolving"]
+ """
+ Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
+ """
+
+
+class ConfirmationTokenCreateParamsShipping(TypedDict):
+ address: "ConfirmationTokenCreateParamsShippingAddress"
+ """
+ Shipping address
+ """
+ name: str
+ """
+ Recipient name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Recipient phone (including extension)
+ """
+
+
+class ConfirmationTokenCreateParamsShippingAddress(TypedDict):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
diff --git a/stripe/params/test_helpers/_customer_fund_cash_balance_params.py b/stripe/params/test_helpers/_customer_fund_cash_balance_params.py
new file mode 100644
index 000000000..dde8f3e4a
--- /dev/null
+++ b/stripe/params/test_helpers/_customer_fund_cash_balance_params.py
@@ -0,0 +1,23 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CustomerFundCashBalanceParams(TypedDict):
+ amount: int
+ """
+ Amount to be used for this test cash balance transaction. A positive integer representing how much to fund in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to fund $1.00 or 100 to fund ¥100, a zero-decimal currency).
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ reference: NotRequired[str]
+ """
+ A description of the test funding. This simulates free-text references supplied by customers when making bank transfers to their cash balance. You can use this to test how Stripe's [reconciliation algorithm](https://stripe.com/docs/payments/customer-balance/reconciliation) applies to different user inputs.
+ """
diff --git a/stripe/params/test_helpers/_refund_expire_params.py b/stripe/params/test_helpers/_refund_expire_params.py
new file mode 100644
index 000000000..4aa861465
--- /dev/null
+++ b/stripe/params/test_helpers/_refund_expire_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class RefundExpireParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/_test_clock_advance_params.py b/stripe/params/test_helpers/_test_clock_advance_params.py
new file mode 100644
index 000000000..94bf0dc10
--- /dev/null
+++ b/stripe/params/test_helpers/_test_clock_advance_params.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TestClockAdvanceParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ frozen_time: int
+ """
+ The time to advance the test clock. Must be after the test clock's current frozen time. Cannot be more than two intervals in the future from the shortest subscription in this test clock. If there are no subscriptions in this test clock, it cannot be more than two years in the future.
+ """
diff --git a/stripe/params/test_helpers/_test_clock_create_params.py b/stripe/params/test_helpers/_test_clock_create_params.py
new file mode 100644
index 000000000..9375ca502
--- /dev/null
+++ b/stripe/params/test_helpers/_test_clock_create_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TestClockCreateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ frozen_time: int
+ """
+ The initial frozen time for this test clock.
+ """
+ name: NotRequired[str]
+ """
+ The name for this test clock.
+ """
diff --git a/stripe/params/test_helpers/_test_clock_delete_params.py b/stripe/params/test_helpers/_test_clock_delete_params.py
new file mode 100644
index 000000000..f8e96c11f
--- /dev/null
+++ b/stripe/params/test_helpers/_test_clock_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+
+
+class TestClockDeleteParams(RequestOptions):
+ pass
diff --git a/stripe/params/test_helpers/_test_clock_list_params.py b/stripe/params/test_helpers/_test_clock_list_params.py
new file mode 100644
index 000000000..666d2be2c
--- /dev/null
+++ b/stripe/params/test_helpers/_test_clock_list_params.py
@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TestClockListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
diff --git a/stripe/params/test_helpers/_test_clock_retrieve_params.py b/stripe/params/test_helpers/_test_clock_retrieve_params.py
new file mode 100644
index 000000000..d87ea3cec
--- /dev/null
+++ b/stripe/params/test_helpers/_test_clock_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TestClockRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/issuing/__init__.py b/stripe/params/test_helpers/issuing/__init__.py
new file mode 100644
index 000000000..bceef1870
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/__init__.py
@@ -0,0 +1,56 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.test_helpers.issuing._authorization_capture_params import (
+ AuthorizationCaptureParams as AuthorizationCaptureParams,
+)
+from stripe.params.test_helpers.issuing._authorization_create_params import (
+ AuthorizationCreateParams as AuthorizationCreateParams,
+)
+from stripe.params.test_helpers.issuing._authorization_expire_params import (
+ AuthorizationExpireParams as AuthorizationExpireParams,
+)
+from stripe.params.test_helpers.issuing._authorization_finalize_amount_params import (
+ AuthorizationFinalizeAmountParams as AuthorizationFinalizeAmountParams,
+)
+from stripe.params.test_helpers.issuing._authorization_increment_params import (
+ AuthorizationIncrementParams as AuthorizationIncrementParams,
+)
+from stripe.params.test_helpers.issuing._authorization_respond_params import (
+ AuthorizationRespondParams as AuthorizationRespondParams,
+)
+from stripe.params.test_helpers.issuing._authorization_reverse_params import (
+ AuthorizationReverseParams as AuthorizationReverseParams,
+)
+from stripe.params.test_helpers.issuing._card_deliver_card_params import (
+ CardDeliverCardParams as CardDeliverCardParams,
+)
+from stripe.params.test_helpers.issuing._card_fail_card_params import (
+ CardFailCardParams as CardFailCardParams,
+)
+from stripe.params.test_helpers.issuing._card_return_card_params import (
+ CardReturnCardParams as CardReturnCardParams,
+)
+from stripe.params.test_helpers.issuing._card_ship_card_params import (
+ CardShipCardParams as CardShipCardParams,
+)
+from stripe.params.test_helpers.issuing._card_submit_card_params import (
+ CardSubmitCardParams as CardSubmitCardParams,
+)
+from stripe.params.test_helpers.issuing._personalization_design_activate_params import (
+ PersonalizationDesignActivateParams as PersonalizationDesignActivateParams,
+)
+from stripe.params.test_helpers.issuing._personalization_design_deactivate_params import (
+ PersonalizationDesignDeactivateParams as PersonalizationDesignDeactivateParams,
+)
+from stripe.params.test_helpers.issuing._personalization_design_reject_params import (
+ PersonalizationDesignRejectParams as PersonalizationDesignRejectParams,
+)
+from stripe.params.test_helpers.issuing._transaction_create_force_capture_params import (
+ TransactionCreateForceCaptureParams as TransactionCreateForceCaptureParams,
+)
+from stripe.params.test_helpers.issuing._transaction_create_unlinked_refund_params import (
+ TransactionCreateUnlinkedRefundParams as TransactionCreateUnlinkedRefundParams,
+)
+from stripe.params.test_helpers.issuing._transaction_refund_params import (
+ TransactionRefundParams as TransactionRefundParams,
+)
diff --git a/stripe/params/test_helpers/issuing/_authorization_capture_params.py b/stripe/params/test_helpers/issuing/_authorization_capture_params.py
new file mode 100644
index 000000000..a18365064
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_authorization_capture_params.py
@@ -0,0 +1,272 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AuthorizationCaptureParams(TypedDict):
+ capture_amount: NotRequired[int]
+ """
+ The amount to capture from the authorization. If not provided, the full amount of the authorization will be captured. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ close_authorization: NotRequired[bool]
+ """
+ Whether to close the authorization after capture. Defaults to true. Set to false to enable multi-capture flows.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ purchase_details: NotRequired["AuthorizationCaptureParamsPurchaseDetails"]
+ """
+ Additional purchase information that is optionally provided by the merchant.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetails(TypedDict):
+ fleet: NotRequired["AuthorizationCaptureParamsPurchaseDetailsFleet"]
+ """
+ Fleet-specific information for transactions using Fleet cards.
+ """
+ flight: NotRequired["AuthorizationCaptureParamsPurchaseDetailsFlight"]
+ """
+ Information about the flight that was purchased with this transaction.
+ """
+ fuel: NotRequired["AuthorizationCaptureParamsPurchaseDetailsFuel"]
+ """
+ Information about fuel that was purchased with this transaction.
+ """
+ lodging: NotRequired["AuthorizationCaptureParamsPurchaseDetailsLodging"]
+ """
+ Information about lodging that was purchased with this transaction.
+ """
+ receipt: NotRequired[
+ List["AuthorizationCaptureParamsPurchaseDetailsReceipt"]
+ ]
+ """
+ The line items in the purchase.
+ """
+ reference: NotRequired[str]
+ """
+ A merchant-specific order number.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFleet(TypedDict):
+ cardholder_prompt_data: NotRequired[
+ "AuthorizationCaptureParamsPurchaseDetailsFleetCardholderPromptData"
+ ]
+ """
+ Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
+ """
+ purchase_type: NotRequired[
+ Literal[
+ "fuel_and_non_fuel_purchase", "fuel_purchase", "non_fuel_purchase"
+ ]
+ ]
+ """
+ The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
+ """
+ reported_breakdown: NotRequired[
+ "AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdown"
+ ]
+ """
+ More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
+ """
+ service_type: NotRequired[
+ Literal["full_service", "non_fuel_transaction", "self_service"]
+ ]
+ """
+ The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFleetCardholderPromptData(
+ TypedDict,
+):
+ driver_id: NotRequired[str]
+ """
+ Driver ID.
+ """
+ odometer: NotRequired[int]
+ """
+ Odometer reading.
+ """
+ unspecified_id: NotRequired[str]
+ """
+ An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
+ """
+ user_id: NotRequired[str]
+ """
+ User ID.
+ """
+ vehicle_number: NotRequired[str]
+ """
+ Vehicle number.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdown(
+ TypedDict,
+):
+ fuel: NotRequired[
+ "AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdownFuel"
+ ]
+ """
+ Breakdown of fuel portion of the purchase.
+ """
+ non_fuel: NotRequired[
+ "AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel"
+ ]
+ """
+ Breakdown of non-fuel portion of the purchase.
+ """
+ tax: NotRequired[
+ "AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdownTax"
+ ]
+ """
+ Information about tax included in this transaction.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdownFuel(
+ TypedDict,
+):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel(
+ TypedDict,
+):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFleetReportedBreakdownTax(
+ TypedDict,
+):
+ local_amount_decimal: NotRequired[str]
+ """
+ Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+ national_amount_decimal: NotRequired[str]
+ """
+ Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFlight(TypedDict):
+ departure_at: NotRequired[int]
+ """
+ The time that the flight departed.
+ """
+ passenger_name: NotRequired[str]
+ """
+ The name of the passenger.
+ """
+ refundable: NotRequired[bool]
+ """
+ Whether the ticket is refundable.
+ """
+ segments: NotRequired[
+ List["AuthorizationCaptureParamsPurchaseDetailsFlightSegment"]
+ ]
+ """
+ The legs of the trip.
+ """
+ travel_agency: NotRequired[str]
+ """
+ The travel agency that issued the ticket.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFlightSegment(TypedDict):
+ arrival_airport_code: NotRequired[str]
+ """
+ The three-letter IATA airport code of the flight's destination.
+ """
+ carrier: NotRequired[str]
+ """
+ The airline carrier code.
+ """
+ departure_airport_code: NotRequired[str]
+ """
+ The three-letter IATA airport code that the flight departed from.
+ """
+ flight_number: NotRequired[str]
+ """
+ The flight number.
+ """
+ service_class: NotRequired[str]
+ """
+ The flight's service class.
+ """
+ stopover_allowed: NotRequired[bool]
+ """
+ Whether a stopover is allowed on this flight.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsFuel(TypedDict):
+ industry_product_code: NotRequired[str]
+ """
+ [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
+ """
+ quantity_decimal: NotRequired[str]
+ """
+ The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
+ """
+ type: NotRequired[
+ Literal[
+ "diesel",
+ "other",
+ "unleaded_plus",
+ "unleaded_regular",
+ "unleaded_super",
+ ]
+ ]
+ """
+ The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
+ """
+ unit: NotRequired[
+ Literal[
+ "charging_minute",
+ "imperial_gallon",
+ "kilogram",
+ "kilowatt_hour",
+ "liter",
+ "other",
+ "pound",
+ "us_gallon",
+ ]
+ ]
+ """
+ The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
+ """
+ unit_cost_decimal: NotRequired[str]
+ """
+ The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsLodging(TypedDict):
+ check_in_at: NotRequired[int]
+ """
+ The time of checking into the lodging.
+ """
+ nights: NotRequired[int]
+ """
+ The number of nights stayed at the lodging.
+ """
+
+
+class AuthorizationCaptureParamsPurchaseDetailsReceipt(TypedDict):
+ description: NotRequired[str]
+ quantity: NotRequired[str]
+ total: NotRequired[int]
+ unit_cost: NotRequired[int]
diff --git a/stripe/params/test_helpers/issuing/_authorization_create_params.py b/stripe/params/test_helpers/issuing/_authorization_create_params.py
new file mode 100644
index 000000000..42e6321a2
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_authorization_create_params.py
@@ -0,0 +1,673 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AuthorizationCreateParams(TypedDict):
+ amount: NotRequired[int]
+ """
+ The total amount to attempt to authorize. This amount is in the provided currency, or defaults to the card's currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ amount_details: NotRequired["AuthorizationCreateParamsAmountDetails"]
+ """
+ Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ authorization_method: NotRequired[
+ Literal["chip", "contactless", "keyed_in", "online", "swipe"]
+ ]
+ """
+ How the card details were provided. Defaults to online.
+ """
+ card: str
+ """
+ Card associated with this authorization.
+ """
+ currency: NotRequired[str]
+ """
+ The currency of the authorization. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ fleet: NotRequired["AuthorizationCreateParamsFleet"]
+ """
+ Fleet-specific information for authorizations using Fleet cards.
+ """
+ fraud_disputability_likelihood: NotRequired[
+ Literal["neutral", "unknown", "very_likely", "very_unlikely"]
+ ]
+ """
+ Probability that this transaction can be disputed in the event of fraud. Assessed by comparing the characteristics of the authorization to card network rules.
+ """
+ fuel: NotRequired["AuthorizationCreateParamsFuel"]
+ """
+ Information about fuel that was purchased with this transaction.
+ """
+ is_amount_controllable: NotRequired[bool]
+ """
+ If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.
+ """
+ merchant_amount: NotRequired[int]
+ """
+ The total amount to attempt to authorize. This amount is in the provided merchant currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ merchant_currency: NotRequired[str]
+ """
+ The currency of the authorization. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ merchant_data: NotRequired["AuthorizationCreateParamsMerchantData"]
+ """
+ Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
+ """
+ network_data: NotRequired["AuthorizationCreateParamsNetworkData"]
+ """
+ Details about the authorization, such as identifiers, set by the card network.
+ """
+ risk_assessment: NotRequired["AuthorizationCreateParamsRiskAssessment"]
+ """
+ Stripe's assessment of the fraud risk for this authorization.
+ """
+ verification_data: NotRequired["AuthorizationCreateParamsVerificationData"]
+ """
+ Verifications that Stripe performed on information that the cardholder provided to the merchant.
+ """
+ wallet: NotRequired[Literal["apple_pay", "google_pay", "samsung_pay"]]
+ """
+ The digital wallet used for this transaction. One of `apple_pay`, `google_pay`, or `samsung_pay`. Will populate as `null` when no digital wallet was utilized.
+ """
+
+
+class AuthorizationCreateParamsAmountDetails(TypedDict):
+ atm_fee: NotRequired[int]
+ """
+ The ATM withdrawal fee.
+ """
+ cashback_amount: NotRequired[int]
+ """
+ The amount of cash requested by the cardholder.
+ """
+
+
+class AuthorizationCreateParamsFleet(TypedDict):
+ cardholder_prompt_data: NotRequired[
+ "AuthorizationCreateParamsFleetCardholderPromptData"
+ ]
+ """
+ Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
+ """
+ purchase_type: NotRequired[
+ Literal[
+ "fuel_and_non_fuel_purchase", "fuel_purchase", "non_fuel_purchase"
+ ]
+ ]
+ """
+ The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
+ """
+ reported_breakdown: NotRequired[
+ "AuthorizationCreateParamsFleetReportedBreakdown"
+ ]
+ """
+ More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
+ """
+ service_type: NotRequired[
+ Literal["full_service", "non_fuel_transaction", "self_service"]
+ ]
+ """
+ The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
+ """
+
+
+class AuthorizationCreateParamsFleetCardholderPromptData(TypedDict):
+ driver_id: NotRequired[str]
+ """
+ Driver ID.
+ """
+ odometer: NotRequired[int]
+ """
+ Odometer reading.
+ """
+ unspecified_id: NotRequired[str]
+ """
+ An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
+ """
+ user_id: NotRequired[str]
+ """
+ User ID.
+ """
+ vehicle_number: NotRequired[str]
+ """
+ Vehicle number.
+ """
+
+
+class AuthorizationCreateParamsFleetReportedBreakdown(TypedDict):
+ fuel: NotRequired["AuthorizationCreateParamsFleetReportedBreakdownFuel"]
+ """
+ Breakdown of fuel portion of the purchase.
+ """
+ non_fuel: NotRequired[
+ "AuthorizationCreateParamsFleetReportedBreakdownNonFuel"
+ ]
+ """
+ Breakdown of non-fuel portion of the purchase.
+ """
+ tax: NotRequired["AuthorizationCreateParamsFleetReportedBreakdownTax"]
+ """
+ Information about tax included in this transaction.
+ """
+
+
+class AuthorizationCreateParamsFleetReportedBreakdownFuel(TypedDict):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
+ """
+
+
+class AuthorizationCreateParamsFleetReportedBreakdownNonFuel(TypedDict):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
+ """
+
+
+class AuthorizationCreateParamsFleetReportedBreakdownTax(TypedDict):
+ local_amount_decimal: NotRequired[str]
+ """
+ Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+ national_amount_decimal: NotRequired[str]
+ """
+ Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+
+
+class AuthorizationCreateParamsFuel(TypedDict):
+ industry_product_code: NotRequired[str]
+ """
+ [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
+ """
+ quantity_decimal: NotRequired[str]
+ """
+ The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
+ """
+ type: NotRequired[
+ Literal[
+ "diesel",
+ "other",
+ "unleaded_plus",
+ "unleaded_regular",
+ "unleaded_super",
+ ]
+ ]
+ """
+ The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
+ """
+ unit: NotRequired[
+ Literal[
+ "charging_minute",
+ "imperial_gallon",
+ "kilogram",
+ "kilowatt_hour",
+ "liter",
+ "other",
+ "pound",
+ "us_gallon",
+ ]
+ ]
+ """
+ The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
+ """
+ unit_cost_decimal: NotRequired[str]
+ """
+ The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
+ """
+
+
+class AuthorizationCreateParamsMerchantData(TypedDict):
+ category: NotRequired[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ """
+ A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
+ """
+ city: NotRequired[str]
+ """
+ City where the seller is located
+ """
+ country: NotRequired[str]
+ """
+ Country where the seller is located
+ """
+ name: NotRequired[str]
+ """
+ Name of the seller
+ """
+ network_id: NotRequired[str]
+ """
+ Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code where the seller is located
+ """
+ state: NotRequired[str]
+ """
+ State where the seller is located
+ """
+ terminal_id: NotRequired[str]
+ """
+ An ID assigned by the seller to the location of the sale.
+ """
+ url: NotRequired[str]
+ """
+ URL provided by the merchant on a 3DS request
+ """
+
+
+class AuthorizationCreateParamsNetworkData(TypedDict):
+ acquiring_institution_id: NotRequired[str]
+ """
+ Identifier assigned to the acquirer by the card network.
+ """
+
+
+class AuthorizationCreateParamsRiskAssessment(TypedDict):
+ card_testing_risk: NotRequired[
+ "AuthorizationCreateParamsRiskAssessmentCardTestingRisk"
+ ]
+ """
+ Stripe's assessment of this authorization's likelihood of being card testing activity.
+ """
+ merchant_dispute_risk: NotRequired[
+ "AuthorizationCreateParamsRiskAssessmentMerchantDisputeRisk"
+ ]
+ """
+ The dispute risk of the merchant (the seller on a purchase) on an authorization based on all Stripe Issuing activity.
+ """
+
+
+class AuthorizationCreateParamsRiskAssessmentCardTestingRisk(TypedDict):
+ invalid_account_number_decline_rate_past_hour: NotRequired[int]
+ """
+ The % of declines due to a card number not existing in the past hour, taking place at the same merchant. Higher rates correspond to a greater probability of card testing activity, meaning bad actors may be attempting different card number combinations to guess a correct one. Takes on values between 0 and 100.
+ """
+ invalid_credentials_decline_rate_past_hour: NotRequired[int]
+ """
+ The % of declines due to incorrect verification data (like CVV or expiry) in the past hour, taking place at the same merchant. Higher rates correspond to a greater probability of bad actors attempting to utilize valid card credentials at merchants with verification requirements. Takes on values between 0 and 100.
+ """
+ risk_level: Literal[
+ "elevated", "highest", "low", "normal", "not_assessed", "unknown"
+ ]
+ """
+ The likelihood that this authorization is associated with card testing activity. This is assessed by evaluating decline activity over the last hour.
+ """
+
+
+class AuthorizationCreateParamsRiskAssessmentMerchantDisputeRisk(TypedDict):
+ dispute_rate: NotRequired[int]
+ """
+ The dispute rate observed across all Stripe Issuing authorizations for this merchant. For example, a value of 50 means 50% of authorizations from this merchant on Stripe Issuing have resulted in a dispute. Higher values mean a higher likelihood the authorization is disputed. Takes on values between 0 and 100.
+ """
+ risk_level: Literal[
+ "elevated", "highest", "low", "normal", "not_assessed", "unknown"
+ ]
+ """
+ The likelihood that authorizations from this merchant will result in a dispute based on their history on Stripe Issuing.
+ """
+
+
+class AuthorizationCreateParamsVerificationData(TypedDict):
+ address_line1_check: NotRequired[
+ Literal["match", "mismatch", "not_provided"]
+ ]
+ """
+ Whether the cardholder provided an address first line and if it matched the cardholder's `billing.address.line1`.
+ """
+ address_postal_code_check: NotRequired[
+ Literal["match", "mismatch", "not_provided"]
+ ]
+ """
+ Whether the cardholder provided a postal code and if it matched the cardholder's `billing.address.postal_code`.
+ """
+ authentication_exemption: NotRequired[
+ "AuthorizationCreateParamsVerificationDataAuthenticationExemption"
+ ]
+ """
+ The exemption applied to this authorization.
+ """
+ cvc_check: NotRequired[Literal["match", "mismatch", "not_provided"]]
+ """
+ Whether the cardholder provided a CVC and if it matched Stripe's record.
+ """
+ expiry_check: NotRequired[Literal["match", "mismatch", "not_provided"]]
+ """
+ Whether the cardholder provided an expiry date and if it matched Stripe's record.
+ """
+ three_d_secure: NotRequired[
+ "AuthorizationCreateParamsVerificationDataThreeDSecure"
+ ]
+ """
+ 3D Secure details.
+ """
+
+
+class AuthorizationCreateParamsVerificationDataAuthenticationExemption(
+ TypedDict,
+):
+ claimed_by: Literal["acquirer", "issuer"]
+ """
+ The entity that requested the exemption, either the acquiring merchant or the Issuing user.
+ """
+ type: Literal[
+ "low_value_transaction", "transaction_risk_analysis", "unknown"
+ ]
+ """
+ The specific exemption claimed for this authorization.
+ """
+
+
+class AuthorizationCreateParamsVerificationDataThreeDSecure(TypedDict):
+ result: Literal[
+ "attempt_acknowledged", "authenticated", "failed", "required"
+ ]
+ """
+ The outcome of the 3D Secure authentication request.
+ """
diff --git a/stripe/params/test_helpers/issuing/_authorization_expire_params.py b/stripe/params/test_helpers/issuing/_authorization_expire_params.py
new file mode 100644
index 000000000..cd6f2a853
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_authorization_expire_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AuthorizationExpireParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/issuing/_authorization_finalize_amount_params.py b/stripe/params/test_helpers/issuing/_authorization_finalize_amount_params.py
new file mode 100644
index 000000000..233ee6b26
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_authorization_finalize_amount_params.py
@@ -0,0 +1,165 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class AuthorizationFinalizeAmountParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ final_amount: int
+ """
+ The final authorization amount that will be captured by the merchant. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ fleet: NotRequired["AuthorizationFinalizeAmountParamsFleet"]
+ """
+ Fleet-specific information for authorizations using Fleet cards.
+ """
+ fuel: NotRequired["AuthorizationFinalizeAmountParamsFuel"]
+ """
+ Information about fuel that was purchased with this transaction.
+ """
+
+
+class AuthorizationFinalizeAmountParamsFleet(TypedDict):
+ cardholder_prompt_data: NotRequired[
+ "AuthorizationFinalizeAmountParamsFleetCardholderPromptData"
+ ]
+ """
+ Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
+ """
+ purchase_type: NotRequired[
+ Literal[
+ "fuel_and_non_fuel_purchase", "fuel_purchase", "non_fuel_purchase"
+ ]
+ ]
+ """
+ The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
+ """
+ reported_breakdown: NotRequired[
+ "AuthorizationFinalizeAmountParamsFleetReportedBreakdown"
+ ]
+ """
+ More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
+ """
+ service_type: NotRequired[
+ Literal["full_service", "non_fuel_transaction", "self_service"]
+ ]
+ """
+ The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
+ """
+
+
+class AuthorizationFinalizeAmountParamsFleetCardholderPromptData(TypedDict):
+ driver_id: NotRequired[str]
+ """
+ Driver ID.
+ """
+ odometer: NotRequired[int]
+ """
+ Odometer reading.
+ """
+ unspecified_id: NotRequired[str]
+ """
+ An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
+ """
+ user_id: NotRequired[str]
+ """
+ User ID.
+ """
+ vehicle_number: NotRequired[str]
+ """
+ Vehicle number.
+ """
+
+
+class AuthorizationFinalizeAmountParamsFleetReportedBreakdown(TypedDict):
+ fuel: NotRequired[
+ "AuthorizationFinalizeAmountParamsFleetReportedBreakdownFuel"
+ ]
+ """
+ Breakdown of fuel portion of the purchase.
+ """
+ non_fuel: NotRequired[
+ "AuthorizationFinalizeAmountParamsFleetReportedBreakdownNonFuel"
+ ]
+ """
+ Breakdown of non-fuel portion of the purchase.
+ """
+ tax: NotRequired[
+ "AuthorizationFinalizeAmountParamsFleetReportedBreakdownTax"
+ ]
+ """
+ Information about tax included in this transaction.
+ """
+
+
+class AuthorizationFinalizeAmountParamsFleetReportedBreakdownFuel(TypedDict):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
+ """
+
+
+class AuthorizationFinalizeAmountParamsFleetReportedBreakdownNonFuel(
+ TypedDict
+):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
+ """
+
+
+class AuthorizationFinalizeAmountParamsFleetReportedBreakdownTax(TypedDict):
+ local_amount_decimal: NotRequired[str]
+ """
+ Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+ national_amount_decimal: NotRequired[str]
+ """
+ Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+
+
+class AuthorizationFinalizeAmountParamsFuel(TypedDict):
+ industry_product_code: NotRequired[str]
+ """
+ [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
+ """
+ quantity_decimal: NotRequired[str]
+ """
+ The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
+ """
+ type: NotRequired[
+ Literal[
+ "diesel",
+ "other",
+ "unleaded_plus",
+ "unleaded_regular",
+ "unleaded_super",
+ ]
+ ]
+ """
+ The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
+ """
+ unit: NotRequired[
+ Literal[
+ "charging_minute",
+ "imperial_gallon",
+ "kilogram",
+ "kilowatt_hour",
+ "liter",
+ "other",
+ "pound",
+ "us_gallon",
+ ]
+ ]
+ """
+ The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
+ """
+ unit_cost_decimal: NotRequired[str]
+ """
+ The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
+ """
diff --git a/stripe/params/test_helpers/issuing/_authorization_increment_params.py b/stripe/params/test_helpers/issuing/_authorization_increment_params.py
new file mode 100644
index 000000000..6190a1399
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_authorization_increment_params.py
@@ -0,0 +1,19 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AuthorizationIncrementParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ increment_amount: int
+ """
+ The amount to increment the authorization by. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ is_amount_controllable: NotRequired[bool]
+ """
+ If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.
+ """
diff --git a/stripe/params/test_helpers/issuing/_authorization_respond_params.py b/stripe/params/test_helpers/issuing/_authorization_respond_params.py
new file mode 100644
index 000000000..e3a9b0b7d
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_authorization_respond_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AuthorizationRespondParams(TypedDict):
+ confirmed: bool
+ """
+ Whether to simulate the user confirming that the transaction was legitimate (true) or telling Stripe that it was fraudulent (false).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/issuing/_authorization_reverse_params.py b/stripe/params/test_helpers/issuing/_authorization_reverse_params.py
new file mode 100644
index 000000000..34241359a
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_authorization_reverse_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class AuthorizationReverseParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ reverse_amount: NotRequired[int]
+ """
+ The amount to reverse from the authorization. If not provided, the full amount of the authorization will be reversed. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
diff --git a/stripe/params/test_helpers/issuing/_card_deliver_card_params.py b/stripe/params/test_helpers/issuing/_card_deliver_card_params.py
new file mode 100644
index 000000000..7d3c7cee5
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_card_deliver_card_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CardDeliverCardParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/issuing/_card_fail_card_params.py b/stripe/params/test_helpers/issuing/_card_fail_card_params.py
new file mode 100644
index 000000000..b93b5e4f3
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_card_fail_card_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CardFailCardParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/issuing/_card_return_card_params.py b/stripe/params/test_helpers/issuing/_card_return_card_params.py
new file mode 100644
index 000000000..795890f52
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_card_return_card_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CardReturnCardParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/issuing/_card_ship_card_params.py b/stripe/params/test_helpers/issuing/_card_ship_card_params.py
new file mode 100644
index 000000000..f4fa20be2
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_card_ship_card_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CardShipCardParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/issuing/_card_submit_card_params.py b/stripe/params/test_helpers/issuing/_card_submit_card_params.py
new file mode 100644
index 000000000..4497eaa99
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_card_submit_card_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class CardSubmitCardParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/issuing/_personalization_design_activate_params.py b/stripe/params/test_helpers/issuing/_personalization_design_activate_params.py
new file mode 100644
index 000000000..7ec377620
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_personalization_design_activate_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class PersonalizationDesignActivateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/issuing/_personalization_design_deactivate_params.py b/stripe/params/test_helpers/issuing/_personalization_design_deactivate_params.py
new file mode 100644
index 000000000..933677224
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_personalization_design_deactivate_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class PersonalizationDesignDeactivateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/issuing/_personalization_design_reject_params.py b/stripe/params/test_helpers/issuing/_personalization_design_reject_params.py
new file mode 100644
index 000000000..36e4cad3b
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_personalization_design_reject_params.py
@@ -0,0 +1,51 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class PersonalizationDesignRejectParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ rejection_reasons: "PersonalizationDesignRejectParamsRejectionReasons"
+ """
+ The reason(s) the personalization design was rejected.
+ """
+
+
+class PersonalizationDesignRejectParamsRejectionReasons(TypedDict):
+ card_logo: NotRequired[
+ List[
+ Literal[
+ "geographic_location",
+ "inappropriate",
+ "network_name",
+ "non_binary_image",
+ "non_fiat_currency",
+ "other",
+ "other_entity",
+ "promotional_material",
+ ]
+ ]
+ ]
+ """
+ The reason(s) the card logo was rejected.
+ """
+ carrier_text: NotRequired[
+ List[
+ Literal[
+ "geographic_location",
+ "inappropriate",
+ "network_name",
+ "non_fiat_currency",
+ "other",
+ "other_entity",
+ "promotional_material",
+ ]
+ ]
+ ]
+ """
+ The reason(s) the carrier text was rejected.
+ """
diff --git a/stripe/params/test_helpers/issuing/_transaction_create_force_capture_params.py b/stripe/params/test_helpers/issuing/_transaction_create_force_capture_params.py
new file mode 100644
index 000000000..e2818f727
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_transaction_create_force_capture_params.py
@@ -0,0 +1,628 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TransactionCreateForceCaptureParams(TypedDict):
+ amount: int
+ """
+ The total amount to attempt to capture. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ card: str
+ """
+ Card associated with this transaction.
+ """
+ currency: NotRequired[str]
+ """
+ The currency of the capture. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ merchant_data: NotRequired[
+ "TransactionCreateForceCaptureParamsMerchantData"
+ ]
+ """
+ Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
+ """
+ purchase_details: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetails"
+ ]
+ """
+ Additional purchase information that is optionally provided by the merchant.
+ """
+
+
+class TransactionCreateForceCaptureParamsMerchantData(TypedDict):
+ category: NotRequired[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ """
+ A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
+ """
+ city: NotRequired[str]
+ """
+ City where the seller is located
+ """
+ country: NotRequired[str]
+ """
+ Country where the seller is located
+ """
+ name: NotRequired[str]
+ """
+ Name of the seller
+ """
+ network_id: NotRequired[str]
+ """
+ Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code where the seller is located
+ """
+ state: NotRequired[str]
+ """
+ State where the seller is located
+ """
+ terminal_id: NotRequired[str]
+ """
+ An ID assigned by the seller to the location of the sale.
+ """
+ url: NotRequired[str]
+ """
+ URL provided by the merchant on a 3DS request
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetails(TypedDict):
+ fleet: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsFleet"
+ ]
+ """
+ Fleet-specific information for transactions using Fleet cards.
+ """
+ flight: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsFlight"
+ ]
+ """
+ Information about the flight that was purchased with this transaction.
+ """
+ fuel: NotRequired["TransactionCreateForceCaptureParamsPurchaseDetailsFuel"]
+ """
+ Information about fuel that was purchased with this transaction.
+ """
+ lodging: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsLodging"
+ ]
+ """
+ Information about lodging that was purchased with this transaction.
+ """
+ receipt: NotRequired[
+ List["TransactionCreateForceCaptureParamsPurchaseDetailsReceipt"]
+ ]
+ """
+ The line items in the purchase.
+ """
+ reference: NotRequired[str]
+ """
+ A merchant-specific order number.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFleet(TypedDict):
+ cardholder_prompt_data: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsFleetCardholderPromptData"
+ ]
+ """
+ Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
+ """
+ purchase_type: NotRequired[
+ Literal[
+ "fuel_and_non_fuel_purchase", "fuel_purchase", "non_fuel_purchase"
+ ]
+ ]
+ """
+ The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
+ """
+ reported_breakdown: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdown"
+ ]
+ """
+ More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
+ """
+ service_type: NotRequired[
+ Literal["full_service", "non_fuel_transaction", "self_service"]
+ ]
+ """
+ The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFleetCardholderPromptData(
+ TypedDict,
+):
+ driver_id: NotRequired[str]
+ """
+ Driver ID.
+ """
+ odometer: NotRequired[int]
+ """
+ Odometer reading.
+ """
+ unspecified_id: NotRequired[str]
+ """
+ An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
+ """
+ user_id: NotRequired[str]
+ """
+ User ID.
+ """
+ vehicle_number: NotRequired[str]
+ """
+ Vehicle number.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdown(
+ TypedDict,
+):
+ fuel: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownFuel"
+ ]
+ """
+ Breakdown of fuel portion of the purchase.
+ """
+ non_fuel: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel"
+ ]
+ """
+ Breakdown of non-fuel portion of the purchase.
+ """
+ tax: NotRequired[
+ "TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownTax"
+ ]
+ """
+ Information about tax included in this transaction.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownFuel(
+ TypedDict,
+):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel(
+ TypedDict,
+):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownTax(
+ TypedDict,
+):
+ local_amount_decimal: NotRequired[str]
+ """
+ Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+ national_amount_decimal: NotRequired[str]
+ """
+ Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFlight(TypedDict):
+ departure_at: NotRequired[int]
+ """
+ The time that the flight departed.
+ """
+ passenger_name: NotRequired[str]
+ """
+ The name of the passenger.
+ """
+ refundable: NotRequired[bool]
+ """
+ Whether the ticket is refundable.
+ """
+ segments: NotRequired[
+ List["TransactionCreateForceCaptureParamsPurchaseDetailsFlightSegment"]
+ ]
+ """
+ The legs of the trip.
+ """
+ travel_agency: NotRequired[str]
+ """
+ The travel agency that issued the ticket.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFlightSegment(
+ TypedDict,
+):
+ arrival_airport_code: NotRequired[str]
+ """
+ The three-letter IATA airport code of the flight's destination.
+ """
+ carrier: NotRequired[str]
+ """
+ The airline carrier code.
+ """
+ departure_airport_code: NotRequired[str]
+ """
+ The three-letter IATA airport code that the flight departed from.
+ """
+ flight_number: NotRequired[str]
+ """
+ The flight number.
+ """
+ service_class: NotRequired[str]
+ """
+ The flight's service class.
+ """
+ stopover_allowed: NotRequired[bool]
+ """
+ Whether a stopover is allowed on this flight.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsFuel(TypedDict):
+ industry_product_code: NotRequired[str]
+ """
+ [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
+ """
+ quantity_decimal: NotRequired[str]
+ """
+ The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
+ """
+ type: NotRequired[
+ Literal[
+ "diesel",
+ "other",
+ "unleaded_plus",
+ "unleaded_regular",
+ "unleaded_super",
+ ]
+ ]
+ """
+ The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
+ """
+ unit: NotRequired[
+ Literal[
+ "charging_minute",
+ "imperial_gallon",
+ "kilogram",
+ "kilowatt_hour",
+ "liter",
+ "other",
+ "pound",
+ "us_gallon",
+ ]
+ ]
+ """
+ The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
+ """
+ unit_cost_decimal: NotRequired[str]
+ """
+ The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsLodging(TypedDict):
+ check_in_at: NotRequired[int]
+ """
+ The time of checking into the lodging.
+ """
+ nights: NotRequired[int]
+ """
+ The number of nights stayed at the lodging.
+ """
+
+
+class TransactionCreateForceCaptureParamsPurchaseDetailsReceipt(TypedDict):
+ description: NotRequired[str]
+ quantity: NotRequired[str]
+ total: NotRequired[int]
+ unit_cost: NotRequired[int]
diff --git a/stripe/params/test_helpers/issuing/_transaction_create_unlinked_refund_params.py b/stripe/params/test_helpers/issuing/_transaction_create_unlinked_refund_params.py
new file mode 100644
index 000000000..1fa13fae8
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_transaction_create_unlinked_refund_params.py
@@ -0,0 +1,632 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TransactionCreateUnlinkedRefundParams(TypedDict):
+ amount: int
+ """
+ The total amount to attempt to refund. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
+ card: str
+ """
+ Card associated with this unlinked refund transaction.
+ """
+ currency: NotRequired[str]
+ """
+ The currency of the unlinked refund. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ merchant_data: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsMerchantData"
+ ]
+ """
+ Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
+ """
+ purchase_details: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetails"
+ ]
+ """
+ Additional purchase information that is optionally provided by the merchant.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsMerchantData(TypedDict):
+ category: NotRequired[
+ Literal[
+ "ac_refrigeration_repair",
+ "accounting_bookkeeping_services",
+ "advertising_services",
+ "agricultural_cooperative",
+ "airlines_air_carriers",
+ "airports_flying_fields",
+ "ambulance_services",
+ "amusement_parks_carnivals",
+ "antique_reproductions",
+ "antique_shops",
+ "aquariums",
+ "architectural_surveying_services",
+ "art_dealers_and_galleries",
+ "artists_supply_and_craft_shops",
+ "auto_and_home_supply_stores",
+ "auto_body_repair_shops",
+ "auto_paint_shops",
+ "auto_service_shops",
+ "automated_cash_disburse",
+ "automated_fuel_dispensers",
+ "automobile_associations",
+ "automotive_parts_and_accessories_stores",
+ "automotive_tire_stores",
+ "bail_and_bond_payments",
+ "bakeries",
+ "bands_orchestras",
+ "barber_and_beauty_shops",
+ "betting_casino_gambling",
+ "bicycle_shops",
+ "billiard_pool_establishments",
+ "boat_dealers",
+ "boat_rentals_and_leases",
+ "book_stores",
+ "books_periodicals_and_newspapers",
+ "bowling_alleys",
+ "bus_lines",
+ "business_secretarial_schools",
+ "buying_shopping_services",
+ "cable_satellite_and_other_pay_television_and_radio",
+ "camera_and_photographic_supply_stores",
+ "candy_nut_and_confectionery_stores",
+ "car_and_truck_dealers_new_used",
+ "car_and_truck_dealers_used_only",
+ "car_rental_agencies",
+ "car_washes",
+ "carpentry_services",
+ "carpet_upholstery_cleaning",
+ "caterers",
+ "charitable_and_social_service_organizations_fundraising",
+ "chemicals_and_allied_products",
+ "child_care_services",
+ "childrens_and_infants_wear_stores",
+ "chiropodists_podiatrists",
+ "chiropractors",
+ "cigar_stores_and_stands",
+ "civic_social_fraternal_associations",
+ "cleaning_and_maintenance",
+ "clothing_rental",
+ "colleges_universities",
+ "commercial_equipment",
+ "commercial_footwear",
+ "commercial_photography_art_and_graphics",
+ "commuter_transport_and_ferries",
+ "computer_network_services",
+ "computer_programming",
+ "computer_repair",
+ "computer_software_stores",
+ "computers_peripherals_and_software",
+ "concrete_work_services",
+ "construction_materials",
+ "consulting_public_relations",
+ "correspondence_schools",
+ "cosmetic_stores",
+ "counseling_services",
+ "country_clubs",
+ "courier_services",
+ "court_costs",
+ "credit_reporting_agencies",
+ "cruise_lines",
+ "dairy_products_stores",
+ "dance_hall_studios_schools",
+ "dating_escort_services",
+ "dentists_orthodontists",
+ "department_stores",
+ "detective_agencies",
+ "digital_goods_applications",
+ "digital_goods_games",
+ "digital_goods_large_volume",
+ "digital_goods_media",
+ "direct_marketing_catalog_merchant",
+ "direct_marketing_combination_catalog_and_retail_merchant",
+ "direct_marketing_inbound_telemarketing",
+ "direct_marketing_insurance_services",
+ "direct_marketing_other",
+ "direct_marketing_outbound_telemarketing",
+ "direct_marketing_subscription",
+ "direct_marketing_travel",
+ "discount_stores",
+ "doctors",
+ "door_to_door_sales",
+ "drapery_window_covering_and_upholstery_stores",
+ "drinking_places",
+ "drug_stores_and_pharmacies",
+ "drugs_drug_proprietaries_and_druggist_sundries",
+ "dry_cleaners",
+ "durable_goods",
+ "duty_free_stores",
+ "eating_places_restaurants",
+ "educational_services",
+ "electric_razor_stores",
+ "electric_vehicle_charging",
+ "electrical_parts_and_equipment",
+ "electrical_services",
+ "electronics_repair_shops",
+ "electronics_stores",
+ "elementary_secondary_schools",
+ "emergency_services_gcas_visa_use_only",
+ "employment_temp_agencies",
+ "equipment_rental",
+ "exterminating_services",
+ "family_clothing_stores",
+ "fast_food_restaurants",
+ "financial_institutions",
+ "fines_government_administrative_entities",
+ "fireplace_fireplace_screens_and_accessories_stores",
+ "floor_covering_stores",
+ "florists",
+ "florists_supplies_nursery_stock_and_flowers",
+ "freezer_and_locker_meat_provisioners",
+ "fuel_dealers_non_automotive",
+ "funeral_services_crematories",
+ "furniture_home_furnishings_and_equipment_stores_except_appliances",
+ "furniture_repair_refinishing",
+ "furriers_and_fur_shops",
+ "general_services",
+ "gift_card_novelty_and_souvenir_shops",
+ "glass_paint_and_wallpaper_stores",
+ "glassware_crystal_stores",
+ "golf_courses_public",
+ "government_licensed_horse_dog_racing_us_region_only",
+ "government_licensed_online_casions_online_gambling_us_region_only",
+ "government_owned_lotteries_non_us_region",
+ "government_owned_lotteries_us_region_only",
+ "government_services",
+ "grocery_stores_supermarkets",
+ "hardware_equipment_and_supplies",
+ "hardware_stores",
+ "health_and_beauty_spas",
+ "hearing_aids_sales_and_supplies",
+ "heating_plumbing_a_c",
+ "hobby_toy_and_game_shops",
+ "home_supply_warehouse_stores",
+ "hospitals",
+ "hotels_motels_and_resorts",
+ "household_appliance_stores",
+ "industrial_supplies",
+ "information_retrieval_services",
+ "insurance_default",
+ "insurance_underwriting_premiums",
+ "intra_company_purchases",
+ "jewelry_stores_watches_clocks_and_silverware_stores",
+ "landscaping_services",
+ "laundries",
+ "laundry_cleaning_services",
+ "legal_services_attorneys",
+ "luggage_and_leather_goods_stores",
+ "lumber_building_materials_stores",
+ "manual_cash_disburse",
+ "marinas_service_and_supplies",
+ "marketplaces",
+ "masonry_stonework_and_plaster",
+ "massage_parlors",
+ "medical_and_dental_labs",
+ "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
+ "medical_services",
+ "membership_organizations",
+ "mens_and_boys_clothing_and_accessories_stores",
+ "mens_womens_clothing_stores",
+ "metal_service_centers",
+ "miscellaneous_apparel_and_accessory_shops",
+ "miscellaneous_auto_dealers",
+ "miscellaneous_business_services",
+ "miscellaneous_food_stores",
+ "miscellaneous_general_merchandise",
+ "miscellaneous_general_services",
+ "miscellaneous_home_furnishing_specialty_stores",
+ "miscellaneous_publishing_and_printing",
+ "miscellaneous_recreation_services",
+ "miscellaneous_repair_shops",
+ "miscellaneous_specialty_retail",
+ "mobile_home_dealers",
+ "motion_picture_theaters",
+ "motor_freight_carriers_and_trucking",
+ "motor_homes_dealers",
+ "motor_vehicle_supplies_and_new_parts",
+ "motorcycle_shops_and_dealers",
+ "motorcycle_shops_dealers",
+ "music_stores_musical_instruments_pianos_and_sheet_music",
+ "news_dealers_and_newsstands",
+ "non_fi_money_orders",
+ "non_fi_stored_value_card_purchase_load",
+ "nondurable_goods",
+ "nurseries_lawn_and_garden_supply_stores",
+ "nursing_personal_care",
+ "office_and_commercial_furniture",
+ "opticians_eyeglasses",
+ "optometrists_ophthalmologist",
+ "orthopedic_goods_prosthetic_devices",
+ "osteopaths",
+ "package_stores_beer_wine_and_liquor",
+ "paints_varnishes_and_supplies",
+ "parking_lots_garages",
+ "passenger_railways",
+ "pawn_shops",
+ "pet_shops_pet_food_and_supplies",
+ "petroleum_and_petroleum_products",
+ "photo_developing",
+ "photographic_photocopy_microfilm_equipment_and_supplies",
+ "photographic_studios",
+ "picture_video_production",
+ "piece_goods_notions_and_other_dry_goods",
+ "plumbing_heating_equipment_and_supplies",
+ "political_organizations",
+ "postal_services_government_only",
+ "precious_stones_and_metals_watches_and_jewelry",
+ "professional_services",
+ "public_warehousing_and_storage",
+ "quick_copy_repro_and_blueprint",
+ "railroads",
+ "real_estate_agents_and_managers_rentals",
+ "record_stores",
+ "recreational_vehicle_rentals",
+ "religious_goods_stores",
+ "religious_organizations",
+ "roofing_siding_sheet_metal",
+ "secretarial_support_services",
+ "security_brokers_dealers",
+ "service_stations",
+ "sewing_needlework_fabric_and_piece_goods_stores",
+ "shoe_repair_hat_cleaning",
+ "shoe_stores",
+ "small_appliance_repair",
+ "snowmobile_dealers",
+ "special_trade_services",
+ "specialty_cleaning",
+ "sporting_goods_stores",
+ "sporting_recreation_camps",
+ "sports_and_riding_apparel_stores",
+ "sports_clubs_fields",
+ "stamp_and_coin_stores",
+ "stationary_office_supplies_printing_and_writing_paper",
+ "stationery_stores_office_and_school_supply_stores",
+ "swimming_pools_sales",
+ "t_ui_travel_germany",
+ "tailors_alterations",
+ "tax_payments_government_agencies",
+ "tax_preparation_services",
+ "taxicabs_limousines",
+ "telecommunication_equipment_and_telephone_sales",
+ "telecommunication_services",
+ "telegraph_services",
+ "tent_and_awning_shops",
+ "testing_laboratories",
+ "theatrical_ticket_agencies",
+ "timeshares",
+ "tire_retreading_and_repair",
+ "tolls_bridge_fees",
+ "tourist_attractions_and_exhibits",
+ "towing_services",
+ "trailer_parks_campgrounds",
+ "transportation_services",
+ "travel_agencies_tour_operators",
+ "truck_stop_iteration",
+ "truck_utility_trailer_rentals",
+ "typesetting_plate_making_and_related_services",
+ "typewriter_stores",
+ "u_s_federal_government_agencies_or_departments",
+ "uniforms_commercial_clothing",
+ "used_merchandise_and_secondhand_stores",
+ "utilities",
+ "variety_stores",
+ "veterinary_services",
+ "video_amusement_game_supplies",
+ "video_game_arcades",
+ "video_tape_rental_stores",
+ "vocational_trade_schools",
+ "watch_jewelry_repair",
+ "welding_repair",
+ "wholesale_clubs",
+ "wig_and_toupee_stores",
+ "wires_money_orders",
+ "womens_accessory_and_specialty_shops",
+ "womens_ready_to_wear_stores",
+ "wrecking_and_salvage_yards",
+ ]
+ ]
+ """
+ A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
+ """
+ city: NotRequired[str]
+ """
+ City where the seller is located
+ """
+ country: NotRequired[str]
+ """
+ Country where the seller is located
+ """
+ name: NotRequired[str]
+ """
+ Name of the seller
+ """
+ network_id: NotRequired[str]
+ """
+ Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
+ """
+ postal_code: NotRequired[str]
+ """
+ Postal code where the seller is located
+ """
+ state: NotRequired[str]
+ """
+ State where the seller is located
+ """
+ terminal_id: NotRequired[str]
+ """
+ An ID assigned by the seller to the location of the sale.
+ """
+ url: NotRequired[str]
+ """
+ URL provided by the merchant on a 3DS request
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetails(TypedDict):
+ fleet: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleet"
+ ]
+ """
+ Fleet-specific information for transactions using Fleet cards.
+ """
+ flight: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFlight"
+ ]
+ """
+ Information about the flight that was purchased with this transaction.
+ """
+ fuel: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFuel"
+ ]
+ """
+ Information about fuel that was purchased with this transaction.
+ """
+ lodging: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsLodging"
+ ]
+ """
+ Information about lodging that was purchased with this transaction.
+ """
+ receipt: NotRequired[
+ List["TransactionCreateUnlinkedRefundParamsPurchaseDetailsReceipt"]
+ ]
+ """
+ The line items in the purchase.
+ """
+ reference: NotRequired[str]
+ """
+ A merchant-specific order number.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleet(TypedDict):
+ cardholder_prompt_data: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetCardholderPromptData"
+ ]
+ """
+ Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
+ """
+ purchase_type: NotRequired[
+ Literal[
+ "fuel_and_non_fuel_purchase", "fuel_purchase", "non_fuel_purchase"
+ ]
+ ]
+ """
+ The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
+ """
+ reported_breakdown: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdown"
+ ]
+ """
+ More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
+ """
+ service_type: NotRequired[
+ Literal["full_service", "non_fuel_transaction", "self_service"]
+ ]
+ """
+ The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetCardholderPromptData(
+ TypedDict,
+):
+ driver_id: NotRequired[str]
+ """
+ Driver ID.
+ """
+ odometer: NotRequired[int]
+ """
+ Odometer reading.
+ """
+ unspecified_id: NotRequired[str]
+ """
+ An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
+ """
+ user_id: NotRequired[str]
+ """
+ User ID.
+ """
+ vehicle_number: NotRequired[str]
+ """
+ Vehicle number.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdown(
+ TypedDict,
+):
+ fuel: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownFuel"
+ ]
+ """
+ Breakdown of fuel portion of the purchase.
+ """
+ non_fuel: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownNonFuel"
+ ]
+ """
+ Breakdown of non-fuel portion of the purchase.
+ """
+ tax: NotRequired[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownTax"
+ ]
+ """
+ Information about tax included in this transaction.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownFuel(
+ TypedDict,
+):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownNonFuel(
+ TypedDict,
+):
+ gross_amount_decimal: NotRequired[str]
+ """
+ Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownTax(
+ TypedDict,
+):
+ local_amount_decimal: NotRequired[str]
+ """
+ Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+ national_amount_decimal: NotRequired[str]
+ """
+ Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFlight(TypedDict):
+ departure_at: NotRequired[int]
+ """
+ The time that the flight departed.
+ """
+ passenger_name: NotRequired[str]
+ """
+ The name of the passenger.
+ """
+ refundable: NotRequired[bool]
+ """
+ Whether the ticket is refundable.
+ """
+ segments: NotRequired[
+ List[
+ "TransactionCreateUnlinkedRefundParamsPurchaseDetailsFlightSegment"
+ ]
+ ]
+ """
+ The legs of the trip.
+ """
+ travel_agency: NotRequired[str]
+ """
+ The travel agency that issued the ticket.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFlightSegment(
+ TypedDict,
+):
+ arrival_airport_code: NotRequired[str]
+ """
+ The three-letter IATA airport code of the flight's destination.
+ """
+ carrier: NotRequired[str]
+ """
+ The airline carrier code.
+ """
+ departure_airport_code: NotRequired[str]
+ """
+ The three-letter IATA airport code that the flight departed from.
+ """
+ flight_number: NotRequired[str]
+ """
+ The flight number.
+ """
+ service_class: NotRequired[str]
+ """
+ The flight's service class.
+ """
+ stopover_allowed: NotRequired[bool]
+ """
+ Whether a stopover is allowed on this flight.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsFuel(TypedDict):
+ industry_product_code: NotRequired[str]
+ """
+ [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
+ """
+ quantity_decimal: NotRequired[str]
+ """
+ The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
+ """
+ type: NotRequired[
+ Literal[
+ "diesel",
+ "other",
+ "unleaded_plus",
+ "unleaded_regular",
+ "unleaded_super",
+ ]
+ ]
+ """
+ The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
+ """
+ unit: NotRequired[
+ Literal[
+ "charging_minute",
+ "imperial_gallon",
+ "kilogram",
+ "kilowatt_hour",
+ "liter",
+ "other",
+ "pound",
+ "us_gallon",
+ ]
+ ]
+ """
+ The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
+ """
+ unit_cost_decimal: NotRequired[str]
+ """
+ The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsLodging(TypedDict):
+ check_in_at: NotRequired[int]
+ """
+ The time of checking into the lodging.
+ """
+ nights: NotRequired[int]
+ """
+ The number of nights stayed at the lodging.
+ """
+
+
+class TransactionCreateUnlinkedRefundParamsPurchaseDetailsReceipt(TypedDict):
+ description: NotRequired[str]
+ quantity: NotRequired[str]
+ total: NotRequired[int]
+ unit_cost: NotRequired[int]
diff --git a/stripe/params/test_helpers/issuing/_transaction_refund_params.py b/stripe/params/test_helpers/issuing/_transaction_refund_params.py
new file mode 100644
index 000000000..d488f1d6a
--- /dev/null
+++ b/stripe/params/test_helpers/issuing/_transaction_refund_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class TransactionRefundParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ refund_amount: NotRequired[int]
+ """
+ The total amount to attempt to refund. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
+ """
diff --git a/stripe/params/test_helpers/terminal/__init__.py b/stripe/params/test_helpers/terminal/__init__.py
new file mode 100644
index 000000000..6d3da2fd8
--- /dev/null
+++ b/stripe/params/test_helpers/terminal/__init__.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.test_helpers.terminal._reader_present_payment_method_params import (
+ ReaderPresentPaymentMethodParams as ReaderPresentPaymentMethodParams,
+)
+from stripe.params.test_helpers.terminal._reader_succeed_input_collection_params import (
+ ReaderSucceedInputCollectionParams as ReaderSucceedInputCollectionParams,
+)
+from stripe.params.test_helpers.terminal._reader_timeout_input_collection_params import (
+ ReaderTimeoutInputCollectionParams as ReaderTimeoutInputCollectionParams,
+)
diff --git a/stripe/params/test_helpers/terminal/_reader_present_payment_method_params.py b/stripe/params/test_helpers/terminal/_reader_present_payment_method_params.py
new file mode 100644
index 000000000..333fcb456
--- /dev/null
+++ b/stripe/params/test_helpers/terminal/_reader_present_payment_method_params.py
@@ -0,0 +1,66 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ReaderPresentPaymentMethodParams(TypedDict):
+ amount_tip: NotRequired[int]
+ """
+ Simulated on-reader tip amount.
+ """
+ card: NotRequired["ReaderPresentPaymentMethodParamsCard"]
+ """
+ Simulated data for the card payment method.
+ """
+ card_present: NotRequired["ReaderPresentPaymentMethodParamsCardPresent"]
+ """
+ Simulated data for the card_present payment method.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ interac_present: NotRequired[
+ "ReaderPresentPaymentMethodParamsInteracPresent"
+ ]
+ """
+ Simulated data for the interac_present payment method.
+ """
+ type: NotRequired[Literal["card", "card_present", "interac_present"]]
+ """
+ Simulated payment type.
+ """
+
+
+class ReaderPresentPaymentMethodParamsCard(TypedDict):
+ cvc: NotRequired[str]
+ """
+ Card security code.
+ """
+ exp_month: int
+ """
+ Two-digit number representing the card's expiration month.
+ """
+ exp_year: int
+ """
+ Two- or four-digit number representing the card's expiration year.
+ """
+ number: str
+ """
+ The card number, as a string without any separators.
+ """
+
+
+class ReaderPresentPaymentMethodParamsCardPresent(TypedDict):
+ number: NotRequired[str]
+ """
+ The card number, as a string without any separators.
+ """
+
+
+class ReaderPresentPaymentMethodParamsInteracPresent(TypedDict):
+ number: NotRequired[str]
+ """
+ Card Number
+ """
diff --git a/stripe/params/test_helpers/terminal/_reader_succeed_input_collection_params.py b/stripe/params/test_helpers/terminal/_reader_succeed_input_collection_params.py
new file mode 100644
index 000000000..8d3fd43d6
--- /dev/null
+++ b/stripe/params/test_helpers/terminal/_reader_succeed_input_collection_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ReaderSucceedInputCollectionParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ skip_non_required_inputs: NotRequired[Literal["all", "none"]]
+ """
+ This parameter defines the skip behavior for input collection.
+ """
diff --git a/stripe/params/test_helpers/terminal/_reader_timeout_input_collection_params.py b/stripe/params/test_helpers/terminal/_reader_timeout_input_collection_params.py
new file mode 100644
index 000000000..8fbd7604e
--- /dev/null
+++ b/stripe/params/test_helpers/terminal/_reader_timeout_input_collection_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class ReaderTimeoutInputCollectionParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/treasury/__init__.py b/stripe/params/test_helpers/treasury/__init__.py
new file mode 100644
index 000000000..36382d1d5
--- /dev/null
+++ b/stripe/params/test_helpers/treasury/__init__.py
@@ -0,0 +1,41 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.test_helpers.treasury._inbound_transfer_fail_params import (
+ InboundTransferFailParams as InboundTransferFailParams,
+)
+from stripe.params.test_helpers.treasury._inbound_transfer_return_inbound_transfer_params import (
+ InboundTransferReturnInboundTransferParams as InboundTransferReturnInboundTransferParams,
+)
+from stripe.params.test_helpers.treasury._inbound_transfer_succeed_params import (
+ InboundTransferSucceedParams as InboundTransferSucceedParams,
+)
+from stripe.params.test_helpers.treasury._outbound_payment_fail_params import (
+ OutboundPaymentFailParams as OutboundPaymentFailParams,
+)
+from stripe.params.test_helpers.treasury._outbound_payment_post_params import (
+ OutboundPaymentPostParams as OutboundPaymentPostParams,
+)
+from stripe.params.test_helpers.treasury._outbound_payment_return_outbound_payment_params import (
+ OutboundPaymentReturnOutboundPaymentParams as OutboundPaymentReturnOutboundPaymentParams,
+)
+from stripe.params.test_helpers.treasury._outbound_payment_update_params import (
+ OutboundPaymentUpdateParams as OutboundPaymentUpdateParams,
+)
+from stripe.params.test_helpers.treasury._outbound_transfer_fail_params import (
+ OutboundTransferFailParams as OutboundTransferFailParams,
+)
+from stripe.params.test_helpers.treasury._outbound_transfer_post_params import (
+ OutboundTransferPostParams as OutboundTransferPostParams,
+)
+from stripe.params.test_helpers.treasury._outbound_transfer_return_outbound_transfer_params import (
+ OutboundTransferReturnOutboundTransferParams as OutboundTransferReturnOutboundTransferParams,
+)
+from stripe.params.test_helpers.treasury._outbound_transfer_update_params import (
+ OutboundTransferUpdateParams as OutboundTransferUpdateParams,
+)
+from stripe.params.test_helpers.treasury._received_credit_create_params import (
+ ReceivedCreditCreateParams as ReceivedCreditCreateParams,
+)
+from stripe.params.test_helpers.treasury._received_debit_create_params import (
+ ReceivedDebitCreateParams as ReceivedDebitCreateParams,
+)
diff --git a/stripe/params/test_helpers/treasury/_inbound_transfer_fail_params.py b/stripe/params/test_helpers/treasury/_inbound_transfer_fail_params.py
new file mode 100644
index 000000000..5e5877d44
--- /dev/null
+++ b/stripe/params/test_helpers/treasury/_inbound_transfer_fail_params.py
@@ -0,0 +1,38 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class InboundTransferFailParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ failure_details: NotRequired["InboundTransferFailParamsFailureDetails"]
+ """
+ Details about a failed InboundTransfer.
+ """
+
+
+class InboundTransferFailParamsFailureDetails(TypedDict):
+ code: NotRequired[
+ Literal[
+ "account_closed",
+ "account_frozen",
+ "bank_account_restricted",
+ "bank_ownership_changed",
+ "debit_not_authorized",
+ "incorrect_account_holder_address",
+ "incorrect_account_holder_name",
+ "incorrect_account_holder_tax_id",
+ "insufficient_funds",
+ "invalid_account_number",
+ "invalid_currency",
+ "no_account",
+ "other",
+ ]
+ ]
+ """
+ Reason for the failure.
+ """
diff --git a/stripe/params/test_helpers/treasury/_inbound_transfer_return_inbound_transfer_params.py b/stripe/params/test_helpers/treasury/_inbound_transfer_return_inbound_transfer_params.py
new file mode 100644
index 000000000..1a61dde96
--- /dev/null
+++ b/stripe/params/test_helpers/treasury/_inbound_transfer_return_inbound_transfer_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class InboundTransferReturnInboundTransferParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/treasury/_inbound_transfer_succeed_params.py b/stripe/params/test_helpers/treasury/_inbound_transfer_succeed_params.py
new file mode 100644
index 000000000..08a9bd06c
--- /dev/null
+++ b/stripe/params/test_helpers/treasury/_inbound_transfer_succeed_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class InboundTransferSucceedParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/treasury/_outbound_payment_fail_params.py b/stripe/params/test_helpers/treasury/_outbound_payment_fail_params.py
new file mode 100644
index 000000000..62e1640fd
--- /dev/null
+++ b/stripe/params/test_helpers/treasury/_outbound_payment_fail_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class OutboundPaymentFailParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/treasury/_outbound_payment_post_params.py b/stripe/params/test_helpers/treasury/_outbound_payment_post_params.py
new file mode 100644
index 000000000..290792b24
--- /dev/null
+++ b/stripe/params/test_helpers/treasury/_outbound_payment_post_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class OutboundPaymentPostParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/treasury/_outbound_payment_return_outbound_payment_params.py b/stripe/params/test_helpers/treasury/_outbound_payment_return_outbound_payment_params.py
new file mode 100644
index 000000000..1c3a426e9
--- /dev/null
+++ b/stripe/params/test_helpers/treasury/_outbound_payment_return_outbound_payment_params.py
@@ -0,0 +1,37 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class OutboundPaymentReturnOutboundPaymentParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ returned_details: NotRequired[
+ "OutboundPaymentReturnOutboundPaymentParamsReturnedDetails"
+ ]
+ """
+ Optional hash to set the return code.
+ """
+
+
+class OutboundPaymentReturnOutboundPaymentParamsReturnedDetails(TypedDict):
+ code: NotRequired[
+ Literal[
+ "account_closed",
+ "account_frozen",
+ "bank_account_restricted",
+ "bank_ownership_changed",
+ "declined",
+ "incorrect_account_holder_name",
+ "invalid_account_number",
+ "invalid_currency",
+ "no_account",
+ "other",
+ ]
+ ]
+ """
+ The return code to be set on the OutboundPayment object.
+ """
diff --git a/stripe/params/test_helpers/treasury/_outbound_payment_update_params.py b/stripe/params/test_helpers/treasury/_outbound_payment_update_params.py
new file mode 100644
index 000000000..53de8373a
--- /dev/null
+++ b/stripe/params/test_helpers/treasury/_outbound_payment_update_params.py
@@ -0,0 +1,54 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class OutboundPaymentUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ tracking_details: "OutboundPaymentUpdateParamsTrackingDetails"
+ """
+ Details about network-specific tracking information.
+ """
+
+
+class OutboundPaymentUpdateParamsTrackingDetails(TypedDict):
+ ach: NotRequired["OutboundPaymentUpdateParamsTrackingDetailsAch"]
+ """
+ ACH network tracking details.
+ """
+ type: Literal["ach", "us_domestic_wire"]
+ """
+ The US bank account network used to send funds.
+ """
+ us_domestic_wire: NotRequired[
+ "OutboundPaymentUpdateParamsTrackingDetailsUsDomesticWire"
+ ]
+ """
+ US domestic wire network tracking details.
+ """
+
+
+class OutboundPaymentUpdateParamsTrackingDetailsAch(TypedDict):
+ trace_id: str
+ """
+ ACH trace ID for funds sent over the `ach` network.
+ """
+
+
+class OutboundPaymentUpdateParamsTrackingDetailsUsDomesticWire(TypedDict):
+ chips: NotRequired[str]
+ """
+ CHIPS System Sequence Number (SSN) for funds sent over the `us_domestic_wire` network.
+ """
+ imad: NotRequired[str]
+ """
+ IMAD for funds sent over the `us_domestic_wire` network.
+ """
+ omad: NotRequired[str]
+ """
+ OMAD for funds sent over the `us_domestic_wire` network.
+ """
diff --git a/stripe/params/test_helpers/treasury/_outbound_transfer_fail_params.py b/stripe/params/test_helpers/treasury/_outbound_transfer_fail_params.py
new file mode 100644
index 000000000..b85611888
--- /dev/null
+++ b/stripe/params/test_helpers/treasury/_outbound_transfer_fail_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class OutboundTransferFailParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/treasury/_outbound_transfer_post_params.py b/stripe/params/test_helpers/treasury/_outbound_transfer_post_params.py
new file mode 100644
index 000000000..f432ec9c5
--- /dev/null
+++ b/stripe/params/test_helpers/treasury/_outbound_transfer_post_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class OutboundTransferPostParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/test_helpers/treasury/_outbound_transfer_return_outbound_transfer_params.py b/stripe/params/test_helpers/treasury/_outbound_transfer_return_outbound_transfer_params.py
new file mode 100644
index 000000000..ba555bef2
--- /dev/null
+++ b/stripe/params/test_helpers/treasury/_outbound_transfer_return_outbound_transfer_params.py
@@ -0,0 +1,37 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class OutboundTransferReturnOutboundTransferParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ returned_details: NotRequired[
+ "OutboundTransferReturnOutboundTransferParamsReturnedDetails"
+ ]
+ """
+ Details about a returned OutboundTransfer.
+ """
+
+
+class OutboundTransferReturnOutboundTransferParamsReturnedDetails(TypedDict):
+ code: NotRequired[
+ Literal[
+ "account_closed",
+ "account_frozen",
+ "bank_account_restricted",
+ "bank_ownership_changed",
+ "declined",
+ "incorrect_account_holder_name",
+ "invalid_account_number",
+ "invalid_currency",
+ "no_account",
+ "other",
+ ]
+ ]
+ """
+ Reason for the return.
+ """
diff --git a/stripe/params/test_helpers/treasury/_outbound_transfer_update_params.py b/stripe/params/test_helpers/treasury/_outbound_transfer_update_params.py
new file mode 100644
index 000000000..69a268fee
--- /dev/null
+++ b/stripe/params/test_helpers/treasury/_outbound_transfer_update_params.py
@@ -0,0 +1,54 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class OutboundTransferUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ tracking_details: "OutboundTransferUpdateParamsTrackingDetails"
+ """
+ Details about network-specific tracking information.
+ """
+
+
+class OutboundTransferUpdateParamsTrackingDetails(TypedDict):
+ ach: NotRequired["OutboundTransferUpdateParamsTrackingDetailsAch"]
+ """
+ ACH network tracking details.
+ """
+ type: Literal["ach", "us_domestic_wire"]
+ """
+ The US bank account network used to send funds.
+ """
+ us_domestic_wire: NotRequired[
+ "OutboundTransferUpdateParamsTrackingDetailsUsDomesticWire"
+ ]
+ """
+ US domestic wire network tracking details.
+ """
+
+
+class OutboundTransferUpdateParamsTrackingDetailsAch(TypedDict):
+ trace_id: str
+ """
+ ACH trace ID for funds sent over the `ach` network.
+ """
+
+
+class OutboundTransferUpdateParamsTrackingDetailsUsDomesticWire(TypedDict):
+ chips: NotRequired[str]
+ """
+ CHIPS System Sequence Number (SSN) for funds sent over the `us_domestic_wire` network.
+ """
+ imad: NotRequired[str]
+ """
+ IMAD for funds sent over the `us_domestic_wire` network.
+ """
+ omad: NotRequired[str]
+ """
+ OMAD for funds sent over the `us_domestic_wire` network.
+ """
diff --git a/stripe/params/test_helpers/treasury/_received_credit_create_params.py b/stripe/params/test_helpers/treasury/_received_credit_create_params.py
new file mode 100644
index 000000000..674ef687d
--- /dev/null
+++ b/stripe/params/test_helpers/treasury/_received_credit_create_params.py
@@ -0,0 +1,67 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ReceivedCreditCreateParams(TypedDict):
+ amount: int
+ """
+ Amount (in cents) to be transferred.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ The FinancialAccount to send funds to.
+ """
+ initiating_payment_method_details: NotRequired[
+ "ReceivedCreditCreateParamsInitiatingPaymentMethodDetails"
+ ]
+ """
+ Initiating payment method details for the object.
+ """
+ network: Literal["ach", "us_domestic_wire"]
+ """
+ Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
+ """
+
+
+class ReceivedCreditCreateParamsInitiatingPaymentMethodDetails(TypedDict):
+ type: Literal["us_bank_account"]
+ """
+ The source type.
+ """
+ us_bank_account: NotRequired[
+ "ReceivedCreditCreateParamsInitiatingPaymentMethodDetailsUsBankAccount"
+ ]
+ """
+ Optional fields for `us_bank_account`.
+ """
+
+
+class ReceivedCreditCreateParamsInitiatingPaymentMethodDetailsUsBankAccount(
+ TypedDict,
+):
+ account_holder_name: NotRequired[str]
+ """
+ The bank account holder's name.
+ """
+ account_number: NotRequired[str]
+ """
+ The bank account number.
+ """
+ routing_number: NotRequired[str]
+ """
+ The bank account's routing number.
+ """
diff --git a/stripe/params/test_helpers/treasury/_received_debit_create_params.py b/stripe/params/test_helpers/treasury/_received_debit_create_params.py
new file mode 100644
index 000000000..c7b138238
--- /dev/null
+++ b/stripe/params/test_helpers/treasury/_received_debit_create_params.py
@@ -0,0 +1,67 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ReceivedDebitCreateParams(TypedDict):
+ amount: int
+ """
+ Amount (in cents) to be transferred.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ The FinancialAccount to pull funds from.
+ """
+ initiating_payment_method_details: NotRequired[
+ "ReceivedDebitCreateParamsInitiatingPaymentMethodDetails"
+ ]
+ """
+ Initiating payment method details for the object.
+ """
+ network: Literal["ach"]
+ """
+ Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
+ """
+
+
+class ReceivedDebitCreateParamsInitiatingPaymentMethodDetails(TypedDict):
+ type: Literal["us_bank_account"]
+ """
+ The source type.
+ """
+ us_bank_account: NotRequired[
+ "ReceivedDebitCreateParamsInitiatingPaymentMethodDetailsUsBankAccount"
+ ]
+ """
+ Optional fields for `us_bank_account`.
+ """
+
+
+class ReceivedDebitCreateParamsInitiatingPaymentMethodDetailsUsBankAccount(
+ TypedDict,
+):
+ account_holder_name: NotRequired[str]
+ """
+ The bank account holder's name.
+ """
+ account_number: NotRequired[str]
+ """
+ The bank account number.
+ """
+ routing_number: NotRequired[str]
+ """
+ The bank account's routing number.
+ """
diff --git a/stripe/params/treasury/__init__.py b/stripe/params/treasury/__init__.py
new file mode 100644
index 000000000..bb72bfe70
--- /dev/null
+++ b/stripe/params/treasury/__init__.py
@@ -0,0 +1,149 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.treasury._credit_reversal_create_params import (
+ CreditReversalCreateParams as CreditReversalCreateParams,
+)
+from stripe.params.treasury._credit_reversal_list_params import (
+ CreditReversalListParams as CreditReversalListParams,
+)
+from stripe.params.treasury._credit_reversal_retrieve_params import (
+ CreditReversalRetrieveParams as CreditReversalRetrieveParams,
+)
+from stripe.params.treasury._debit_reversal_create_params import (
+ DebitReversalCreateParams as DebitReversalCreateParams,
+)
+from stripe.params.treasury._debit_reversal_list_params import (
+ DebitReversalListParams as DebitReversalListParams,
+)
+from stripe.params.treasury._debit_reversal_retrieve_params import (
+ DebitReversalRetrieveParams as DebitReversalRetrieveParams,
+)
+from stripe.params.treasury._financial_account_close_params import (
+ FinancialAccountCloseParams as FinancialAccountCloseParams,
+)
+from stripe.params.treasury._financial_account_create_params import (
+ FinancialAccountCreateParams as FinancialAccountCreateParams,
+)
+from stripe.params.treasury._financial_account_features_retrieve_params import (
+ FinancialAccountFeaturesRetrieveParams as FinancialAccountFeaturesRetrieveParams,
+)
+from stripe.params.treasury._financial_account_features_update_params import (
+ FinancialAccountFeaturesUpdateParams as FinancialAccountFeaturesUpdateParams,
+)
+from stripe.params.treasury._financial_account_list_params import (
+ FinancialAccountListParams as FinancialAccountListParams,
+)
+from stripe.params.treasury._financial_account_modify_params import (
+ FinancialAccountModifyParams as FinancialAccountModifyParams,
+)
+from stripe.params.treasury._financial_account_retrieve_features_params import (
+ FinancialAccountRetrieveFeaturesParams as FinancialAccountRetrieveFeaturesParams,
+)
+from stripe.params.treasury._financial_account_retrieve_params import (
+ FinancialAccountRetrieveParams as FinancialAccountRetrieveParams,
+)
+from stripe.params.treasury._financial_account_update_features_params import (
+ FinancialAccountUpdateFeaturesParams as FinancialAccountUpdateFeaturesParams,
+)
+from stripe.params.treasury._financial_account_update_params import (
+ FinancialAccountUpdateParams as FinancialAccountUpdateParams,
+)
+from stripe.params.treasury._inbound_transfer_cancel_params import (
+ InboundTransferCancelParams as InboundTransferCancelParams,
+)
+from stripe.params.treasury._inbound_transfer_create_params import (
+ InboundTransferCreateParams as InboundTransferCreateParams,
+)
+from stripe.params.treasury._inbound_transfer_fail_params import (
+ InboundTransferFailParams as InboundTransferFailParams,
+)
+from stripe.params.treasury._inbound_transfer_list_params import (
+ InboundTransferListParams as InboundTransferListParams,
+)
+from stripe.params.treasury._inbound_transfer_retrieve_params import (
+ InboundTransferRetrieveParams as InboundTransferRetrieveParams,
+)
+from stripe.params.treasury._inbound_transfer_return_inbound_transfer_params import (
+ InboundTransferReturnInboundTransferParams as InboundTransferReturnInboundTransferParams,
+)
+from stripe.params.treasury._inbound_transfer_succeed_params import (
+ InboundTransferSucceedParams as InboundTransferSucceedParams,
+)
+from stripe.params.treasury._outbound_payment_cancel_params import (
+ OutboundPaymentCancelParams as OutboundPaymentCancelParams,
+)
+from stripe.params.treasury._outbound_payment_create_params import (
+ OutboundPaymentCreateParams as OutboundPaymentCreateParams,
+)
+from stripe.params.treasury._outbound_payment_fail_params import (
+ OutboundPaymentFailParams as OutboundPaymentFailParams,
+)
+from stripe.params.treasury._outbound_payment_list_params import (
+ OutboundPaymentListParams as OutboundPaymentListParams,
+)
+from stripe.params.treasury._outbound_payment_post_params import (
+ OutboundPaymentPostParams as OutboundPaymentPostParams,
+)
+from stripe.params.treasury._outbound_payment_retrieve_params import (
+ OutboundPaymentRetrieveParams as OutboundPaymentRetrieveParams,
+)
+from stripe.params.treasury._outbound_payment_return_outbound_payment_params import (
+ OutboundPaymentReturnOutboundPaymentParams as OutboundPaymentReturnOutboundPaymentParams,
+)
+from stripe.params.treasury._outbound_payment_update_params import (
+ OutboundPaymentUpdateParams as OutboundPaymentUpdateParams,
+)
+from stripe.params.treasury._outbound_transfer_cancel_params import (
+ OutboundTransferCancelParams as OutboundTransferCancelParams,
+)
+from stripe.params.treasury._outbound_transfer_create_params import (
+ OutboundTransferCreateParams as OutboundTransferCreateParams,
+)
+from stripe.params.treasury._outbound_transfer_fail_params import (
+ OutboundTransferFailParams as OutboundTransferFailParams,
+)
+from stripe.params.treasury._outbound_transfer_list_params import (
+ OutboundTransferListParams as OutboundTransferListParams,
+)
+from stripe.params.treasury._outbound_transfer_post_params import (
+ OutboundTransferPostParams as OutboundTransferPostParams,
+)
+from stripe.params.treasury._outbound_transfer_retrieve_params import (
+ OutboundTransferRetrieveParams as OutboundTransferRetrieveParams,
+)
+from stripe.params.treasury._outbound_transfer_return_outbound_transfer_params import (
+ OutboundTransferReturnOutboundTransferParams as OutboundTransferReturnOutboundTransferParams,
+)
+from stripe.params.treasury._outbound_transfer_update_params import (
+ OutboundTransferUpdateParams as OutboundTransferUpdateParams,
+)
+from stripe.params.treasury._received_credit_create_params import (
+ ReceivedCreditCreateParams as ReceivedCreditCreateParams,
+)
+from stripe.params.treasury._received_credit_list_params import (
+ ReceivedCreditListParams as ReceivedCreditListParams,
+)
+from stripe.params.treasury._received_credit_retrieve_params import (
+ ReceivedCreditRetrieveParams as ReceivedCreditRetrieveParams,
+)
+from stripe.params.treasury._received_debit_create_params import (
+ ReceivedDebitCreateParams as ReceivedDebitCreateParams,
+)
+from stripe.params.treasury._received_debit_list_params import (
+ ReceivedDebitListParams as ReceivedDebitListParams,
+)
+from stripe.params.treasury._received_debit_retrieve_params import (
+ ReceivedDebitRetrieveParams as ReceivedDebitRetrieveParams,
+)
+from stripe.params.treasury._transaction_entry_list_params import (
+ TransactionEntryListParams as TransactionEntryListParams,
+)
+from stripe.params.treasury._transaction_entry_retrieve_params import (
+ TransactionEntryRetrieveParams as TransactionEntryRetrieveParams,
+)
+from stripe.params.treasury._transaction_list_params import (
+ TransactionListParams as TransactionListParams,
+)
+from stripe.params.treasury._transaction_retrieve_params import (
+ TransactionRetrieveParams as TransactionRetrieveParams,
+)
diff --git a/stripe/params/treasury/_credit_reversal_create_params.py b/stripe/params/treasury/_credit_reversal_create_params.py
new file mode 100644
index 000000000..96ad037e2
--- /dev/null
+++ b/stripe/params/treasury/_credit_reversal_create_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import NotRequired
+
+
+class CreditReversalCreateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ received_credit: str
+ """
+ The ReceivedCredit to reverse.
+ """
diff --git a/stripe/params/treasury/_credit_reversal_list_params.py b/stripe/params/treasury/_credit_reversal_list_params.py
new file mode 100644
index 000000000..33b3b7359
--- /dev/null
+++ b/stripe/params/treasury/_credit_reversal_list_params.py
@@ -0,0 +1,36 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class CreditReversalListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ Returns objects associated with this FinancialAccount.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ received_credit: NotRequired[str]
+ """
+ Only return CreditReversals for the ReceivedCredit ID.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["canceled", "posted", "processing"]]
+ """
+ Only return CreditReversals for a given status.
+ """
diff --git a/stripe/params/treasury/_credit_reversal_retrieve_params.py b/stripe/params/treasury/_credit_reversal_retrieve_params.py
new file mode 100644
index 000000000..5e0b9c2e6
--- /dev/null
+++ b/stripe/params/treasury/_credit_reversal_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class CreditReversalRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_debit_reversal_create_params.py b/stripe/params/treasury/_debit_reversal_create_params.py
new file mode 100644
index 000000000..aa873103c
--- /dev/null
+++ b/stripe/params/treasury/_debit_reversal_create_params.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import NotRequired
+
+
+class DebitReversalCreateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ received_debit: str
+ """
+ The ReceivedDebit to reverse.
+ """
diff --git a/stripe/params/treasury/_debit_reversal_list_params.py b/stripe/params/treasury/_debit_reversal_list_params.py
new file mode 100644
index 000000000..66dad5062
--- /dev/null
+++ b/stripe/params/treasury/_debit_reversal_list_params.py
@@ -0,0 +1,40 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class DebitReversalListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ Returns objects associated with this FinancialAccount.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ received_debit: NotRequired[str]
+ """
+ Only return DebitReversals for the ReceivedDebit ID.
+ """
+ resolution: NotRequired[Literal["lost", "won"]]
+ """
+ Only return DebitReversals for a given resolution.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["canceled", "completed", "processing"]]
+ """
+ Only return DebitReversals for a given status.
+ """
diff --git a/stripe/params/treasury/_debit_reversal_retrieve_params.py b/stripe/params/treasury/_debit_reversal_retrieve_params.py
new file mode 100644
index 000000000..c818ddc3c
--- /dev/null
+++ b/stripe/params/treasury/_debit_reversal_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class DebitReversalRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_financial_account_close_params.py b/stripe/params/treasury/_financial_account_close_params.py
new file mode 100644
index 000000000..cff6fa7b2
--- /dev/null
+++ b/stripe/params/treasury/_financial_account_close_params.py
@@ -0,0 +1,33 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class FinancialAccountCloseParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ forwarding_settings: NotRequired[
+ "FinancialAccountCloseParamsForwardingSettings"
+ ]
+ """
+ A different bank account where funds can be deposited/debited in order to get the closing FA's balance to $0
+ """
+
+
+class FinancialAccountCloseParamsForwardingSettings(TypedDict):
+ financial_account: NotRequired[str]
+ """
+ The financial_account id
+ """
+ payment_method: NotRequired[str]
+ """
+ The payment_method or bank account id. This needs to be a verified bank account.
+ """
+ type: Literal["financial_account", "payment_method"]
+ """
+ The type of the bank account provided. This can be either "financial_account" or "payment_method"
+ """
diff --git a/stripe/params/treasury/_financial_account_create_params.py b/stripe/params/treasury/_financial_account_create_params.py
new file mode 100644
index 000000000..f89af2865
--- /dev/null
+++ b/stripe/params/treasury/_financial_account_create_params.py
@@ -0,0 +1,201 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class FinancialAccountCreateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ features: NotRequired["FinancialAccountCreateParamsFeatures"]
+ """
+ Encodes whether a FinancialAccount has access to a particular feature. Stripe or the platform can control features via the requested field.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ nickname: NotRequired["Literal['']|str"]
+ """
+ The nickname for the FinancialAccount.
+ """
+ platform_restrictions: NotRequired[
+ "FinancialAccountCreateParamsPlatformRestrictions"
+ ]
+ """
+ The set of functionalities that the platform can restrict on the FinancialAccount.
+ """
+ supported_currencies: List[str]
+ """
+ The currencies the FinancialAccount can hold a balance in.
+ """
+
+
+class FinancialAccountCreateParamsFeatures(TypedDict):
+ card_issuing: NotRequired[
+ "FinancialAccountCreateParamsFeaturesCardIssuing"
+ ]
+ """
+ Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
+ """
+ deposit_insurance: NotRequired[
+ "FinancialAccountCreateParamsFeaturesDepositInsurance"
+ ]
+ """
+ Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
+ """
+ financial_addresses: NotRequired[
+ "FinancialAccountCreateParamsFeaturesFinancialAddresses"
+ ]
+ """
+ Contains Features that add FinancialAddresses to the FinancialAccount.
+ """
+ inbound_transfers: NotRequired[
+ "FinancialAccountCreateParamsFeaturesInboundTransfers"
+ ]
+ """
+ Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
+ """
+ intra_stripe_flows: NotRequired[
+ "FinancialAccountCreateParamsFeaturesIntraStripeFlows"
+ ]
+ """
+ Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
+ """
+ outbound_payments: NotRequired[
+ "FinancialAccountCreateParamsFeaturesOutboundPayments"
+ ]
+ """
+ Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
+ """
+ outbound_transfers: NotRequired[
+ "FinancialAccountCreateParamsFeaturesOutboundTransfers"
+ ]
+ """
+ Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
+ """
+
+
+class FinancialAccountCreateParamsFeaturesCardIssuing(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountCreateParamsFeaturesDepositInsurance(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountCreateParamsFeaturesFinancialAddresses(TypedDict):
+ aba: NotRequired[
+ "FinancialAccountCreateParamsFeaturesFinancialAddressesAba"
+ ]
+ """
+ Adds an ABA FinancialAddress to the FinancialAccount.
+ """
+
+
+class FinancialAccountCreateParamsFeaturesFinancialAddressesAba(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountCreateParamsFeaturesInboundTransfers(TypedDict):
+ ach: NotRequired["FinancialAccountCreateParamsFeaturesInboundTransfersAch"]
+ """
+ Enables ACH Debits via the InboundTransfers API.
+ """
+
+
+class FinancialAccountCreateParamsFeaturesInboundTransfersAch(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountCreateParamsFeaturesIntraStripeFlows(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountCreateParamsFeaturesOutboundPayments(TypedDict):
+ ach: NotRequired["FinancialAccountCreateParamsFeaturesOutboundPaymentsAch"]
+ """
+ Enables ACH transfers via the OutboundPayments API.
+ """
+ us_domestic_wire: NotRequired[
+ "FinancialAccountCreateParamsFeaturesOutboundPaymentsUsDomesticWire"
+ ]
+ """
+ Enables US domestic wire transfers via the OutboundPayments API.
+ """
+
+
+class FinancialAccountCreateParamsFeaturesOutboundPaymentsAch(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountCreateParamsFeaturesOutboundPaymentsUsDomesticWire(
+ TypedDict,
+):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountCreateParamsFeaturesOutboundTransfers(TypedDict):
+ ach: NotRequired[
+ "FinancialAccountCreateParamsFeaturesOutboundTransfersAch"
+ ]
+ """
+ Enables ACH transfers via the OutboundTransfers API.
+ """
+ us_domestic_wire: NotRequired[
+ "FinancialAccountCreateParamsFeaturesOutboundTransfersUsDomesticWire"
+ ]
+ """
+ Enables US domestic wire transfers via the OutboundTransfers API.
+ """
+
+
+class FinancialAccountCreateParamsFeaturesOutboundTransfersAch(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountCreateParamsFeaturesOutboundTransfersUsDomesticWire(
+ TypedDict,
+):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountCreateParamsPlatformRestrictions(TypedDict):
+ inbound_flows: NotRequired[Literal["restricted", "unrestricted"]]
+ """
+ Restricts all inbound money movement.
+ """
+ outbound_flows: NotRequired[Literal["restricted", "unrestricted"]]
+ """
+ Restricts all outbound money movement.
+ """
diff --git a/stripe/params/treasury/_financial_account_features_retrieve_params.py b/stripe/params/treasury/_financial_account_features_retrieve_params.py
new file mode 100644
index 000000000..005ff4997
--- /dev/null
+++ b/stripe/params/treasury/_financial_account_features_retrieve_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class FinancialAccountFeaturesRetrieveParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_financial_account_features_update_params.py b/stripe/params/treasury/_financial_account_features_update_params.py
new file mode 100644
index 000000000..71344abf9
--- /dev/null
+++ b/stripe/params/treasury/_financial_account_features_update_params.py
@@ -0,0 +1,164 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class FinancialAccountFeaturesUpdateParams(TypedDict):
+ card_issuing: NotRequired[
+ "FinancialAccountFeaturesUpdateParamsCardIssuing"
+ ]
+ """
+ Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
+ """
+ deposit_insurance: NotRequired[
+ "FinancialAccountFeaturesUpdateParamsDepositInsurance"
+ ]
+ """
+ Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_addresses: NotRequired[
+ "FinancialAccountFeaturesUpdateParamsFinancialAddresses"
+ ]
+ """
+ Contains Features that add FinancialAddresses to the FinancialAccount.
+ """
+ inbound_transfers: NotRequired[
+ "FinancialAccountFeaturesUpdateParamsInboundTransfers"
+ ]
+ """
+ Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
+ """
+ intra_stripe_flows: NotRequired[
+ "FinancialAccountFeaturesUpdateParamsIntraStripeFlows"
+ ]
+ """
+ Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
+ """
+ outbound_payments: NotRequired[
+ "FinancialAccountFeaturesUpdateParamsOutboundPayments"
+ ]
+ """
+ Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
+ """
+ outbound_transfers: NotRequired[
+ "FinancialAccountFeaturesUpdateParamsOutboundTransfers"
+ ]
+ """
+ Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
+ """
+
+
+class FinancialAccountFeaturesUpdateParamsCardIssuing(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountFeaturesUpdateParamsDepositInsurance(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountFeaturesUpdateParamsFinancialAddresses(TypedDict):
+ aba: NotRequired[
+ "FinancialAccountFeaturesUpdateParamsFinancialAddressesAba"
+ ]
+ """
+ Adds an ABA FinancialAddress to the FinancialAccount.
+ """
+
+
+class FinancialAccountFeaturesUpdateParamsFinancialAddressesAba(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountFeaturesUpdateParamsInboundTransfers(TypedDict):
+ ach: NotRequired["FinancialAccountFeaturesUpdateParamsInboundTransfersAch"]
+ """
+ Enables ACH Debits via the InboundTransfers API.
+ """
+
+
+class FinancialAccountFeaturesUpdateParamsInboundTransfersAch(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountFeaturesUpdateParamsIntraStripeFlows(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountFeaturesUpdateParamsOutboundPayments(TypedDict):
+ ach: NotRequired["FinancialAccountFeaturesUpdateParamsOutboundPaymentsAch"]
+ """
+ Enables ACH transfers via the OutboundPayments API.
+ """
+ us_domestic_wire: NotRequired[
+ "FinancialAccountFeaturesUpdateParamsOutboundPaymentsUsDomesticWire"
+ ]
+ """
+ Enables US domestic wire transfers via the OutboundPayments API.
+ """
+
+
+class FinancialAccountFeaturesUpdateParamsOutboundPaymentsAch(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountFeaturesUpdateParamsOutboundPaymentsUsDomesticWire(
+ TypedDict,
+):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountFeaturesUpdateParamsOutboundTransfers(TypedDict):
+ ach: NotRequired[
+ "FinancialAccountFeaturesUpdateParamsOutboundTransfersAch"
+ ]
+ """
+ Enables ACH transfers via the OutboundTransfers API.
+ """
+ us_domestic_wire: NotRequired[
+ "FinancialAccountFeaturesUpdateParamsOutboundTransfersUsDomesticWire"
+ ]
+ """
+ Enables US domestic wire transfers via the OutboundTransfers API.
+ """
+
+
+class FinancialAccountFeaturesUpdateParamsOutboundTransfersAch(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountFeaturesUpdateParamsOutboundTransfersUsDomesticWire(
+ TypedDict,
+):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
diff --git a/stripe/params/treasury/_financial_account_list_params.py b/stripe/params/treasury/_financial_account_list_params.py
new file mode 100644
index 000000000..fdcc9de14
--- /dev/null
+++ b/stripe/params/treasury/_financial_account_list_params.py
@@ -0,0 +1,51 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class FinancialAccountListParams(RequestOptions):
+ created: NotRequired["FinancialAccountListParamsCreated|int"]
+ """
+ Only return FinancialAccounts that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ An object ID cursor for use in pagination.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ limit: NotRequired[int]
+ """
+ A limit ranging from 1 to 100 (defaults to 10).
+ """
+ starting_after: NotRequired[str]
+ """
+ An object ID cursor for use in pagination.
+ """
+ status: NotRequired[Literal["closed", "open"]]
+ """
+ Only return FinancialAccounts that have the given status: `open` or `closed`
+ """
+
+
+class FinancialAccountListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/treasury/_financial_account_modify_params.py b/stripe/params/treasury/_financial_account_modify_params.py
new file mode 100644
index 000000000..292576858
--- /dev/null
+++ b/stripe/params/treasury/_financial_account_modify_params.py
@@ -0,0 +1,218 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class FinancialAccountModifyParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ features: NotRequired["FinancialAccountModifyParamsFeatures"]
+ """
+ Encodes whether a FinancialAccount has access to a particular feature, with a status enum and associated `status_details`. Stripe or the platform may control features via the requested field.
+ """
+ forwarding_settings: NotRequired[
+ "FinancialAccountModifyParamsForwardingSettings"
+ ]
+ """
+ A different bank account where funds can be deposited/debited in order to get the closing FA's balance to $0
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ nickname: NotRequired["Literal['']|str"]
+ """
+ The nickname for the FinancialAccount.
+ """
+ platform_restrictions: NotRequired[
+ "FinancialAccountModifyParamsPlatformRestrictions"
+ ]
+ """
+ The set of functionalities that the platform can restrict on the FinancialAccount.
+ """
+
+
+class FinancialAccountModifyParamsFeatures(TypedDict):
+ card_issuing: NotRequired[
+ "FinancialAccountModifyParamsFeaturesCardIssuing"
+ ]
+ """
+ Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
+ """
+ deposit_insurance: NotRequired[
+ "FinancialAccountModifyParamsFeaturesDepositInsurance"
+ ]
+ """
+ Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
+ """
+ financial_addresses: NotRequired[
+ "FinancialAccountModifyParamsFeaturesFinancialAddresses"
+ ]
+ """
+ Contains Features that add FinancialAddresses to the FinancialAccount.
+ """
+ inbound_transfers: NotRequired[
+ "FinancialAccountModifyParamsFeaturesInboundTransfers"
+ ]
+ """
+ Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
+ """
+ intra_stripe_flows: NotRequired[
+ "FinancialAccountModifyParamsFeaturesIntraStripeFlows"
+ ]
+ """
+ Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
+ """
+ outbound_payments: NotRequired[
+ "FinancialAccountModifyParamsFeaturesOutboundPayments"
+ ]
+ """
+ Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
+ """
+ outbound_transfers: NotRequired[
+ "FinancialAccountModifyParamsFeaturesOutboundTransfers"
+ ]
+ """
+ Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
+ """
+
+
+class FinancialAccountModifyParamsFeaturesCardIssuing(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountModifyParamsFeaturesDepositInsurance(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountModifyParamsFeaturesFinancialAddresses(TypedDict):
+ aba: NotRequired[
+ "FinancialAccountModifyParamsFeaturesFinancialAddressesAba"
+ ]
+ """
+ Adds an ABA FinancialAddress to the FinancialAccount.
+ """
+
+
+class FinancialAccountModifyParamsFeaturesFinancialAddressesAba(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountModifyParamsFeaturesInboundTransfers(TypedDict):
+ ach: NotRequired["FinancialAccountModifyParamsFeaturesInboundTransfersAch"]
+ """
+ Enables ACH Debits via the InboundTransfers API.
+ """
+
+
+class FinancialAccountModifyParamsFeaturesInboundTransfersAch(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountModifyParamsFeaturesIntraStripeFlows(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountModifyParamsFeaturesOutboundPayments(TypedDict):
+ ach: NotRequired["FinancialAccountModifyParamsFeaturesOutboundPaymentsAch"]
+ """
+ Enables ACH transfers via the OutboundPayments API.
+ """
+ us_domestic_wire: NotRequired[
+ "FinancialAccountModifyParamsFeaturesOutboundPaymentsUsDomesticWire"
+ ]
+ """
+ Enables US domestic wire transfers via the OutboundPayments API.
+ """
+
+
+class FinancialAccountModifyParamsFeaturesOutboundPaymentsAch(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountModifyParamsFeaturesOutboundPaymentsUsDomesticWire(
+ TypedDict,
+):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountModifyParamsFeaturesOutboundTransfers(TypedDict):
+ ach: NotRequired[
+ "FinancialAccountModifyParamsFeaturesOutboundTransfersAch"
+ ]
+ """
+ Enables ACH transfers via the OutboundTransfers API.
+ """
+ us_domestic_wire: NotRequired[
+ "FinancialAccountModifyParamsFeaturesOutboundTransfersUsDomesticWire"
+ ]
+ """
+ Enables US domestic wire transfers via the OutboundTransfers API.
+ """
+
+
+class FinancialAccountModifyParamsFeaturesOutboundTransfersAch(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountModifyParamsFeaturesOutboundTransfersUsDomesticWire(
+ TypedDict,
+):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountModifyParamsForwardingSettings(TypedDict):
+ financial_account: NotRequired[str]
+ """
+ The financial_account id
+ """
+ payment_method: NotRequired[str]
+ """
+ The payment_method or bank account id. This needs to be a verified bank account.
+ """
+ type: Literal["financial_account", "payment_method"]
+ """
+ The type of the bank account provided. This can be either "financial_account" or "payment_method"
+ """
+
+
+class FinancialAccountModifyParamsPlatformRestrictions(TypedDict):
+ inbound_flows: NotRequired[Literal["restricted", "unrestricted"]]
+ """
+ Restricts all inbound money movement.
+ """
+ outbound_flows: NotRequired[Literal["restricted", "unrestricted"]]
+ """
+ Restricts all outbound money movement.
+ """
diff --git a/stripe/params/treasury/_financial_account_retrieve_features_params.py b/stripe/params/treasury/_financial_account_retrieve_features_params.py
new file mode 100644
index 000000000..0d65da2a9
--- /dev/null
+++ b/stripe/params/treasury/_financial_account_retrieve_features_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class FinancialAccountRetrieveFeaturesParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_financial_account_retrieve_params.py b/stripe/params/treasury/_financial_account_retrieve_params.py
new file mode 100644
index 000000000..0f57a048f
--- /dev/null
+++ b/stripe/params/treasury/_financial_account_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class FinancialAccountRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_financial_account_update_features_params.py b/stripe/params/treasury/_financial_account_update_features_params.py
new file mode 100644
index 000000000..59fcb7257
--- /dev/null
+++ b/stripe/params/treasury/_financial_account_update_features_params.py
@@ -0,0 +1,165 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired, TypedDict
+
+
+class FinancialAccountUpdateFeaturesParams(RequestOptions):
+ card_issuing: NotRequired[
+ "FinancialAccountUpdateFeaturesParamsCardIssuing"
+ ]
+ """
+ Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
+ """
+ deposit_insurance: NotRequired[
+ "FinancialAccountUpdateFeaturesParamsDepositInsurance"
+ ]
+ """
+ Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_addresses: NotRequired[
+ "FinancialAccountUpdateFeaturesParamsFinancialAddresses"
+ ]
+ """
+ Contains Features that add FinancialAddresses to the FinancialAccount.
+ """
+ inbound_transfers: NotRequired[
+ "FinancialAccountUpdateFeaturesParamsInboundTransfers"
+ ]
+ """
+ Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
+ """
+ intra_stripe_flows: NotRequired[
+ "FinancialAccountUpdateFeaturesParamsIntraStripeFlows"
+ ]
+ """
+ Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
+ """
+ outbound_payments: NotRequired[
+ "FinancialAccountUpdateFeaturesParamsOutboundPayments"
+ ]
+ """
+ Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
+ """
+ outbound_transfers: NotRequired[
+ "FinancialAccountUpdateFeaturesParamsOutboundTransfers"
+ ]
+ """
+ Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
+ """
+
+
+class FinancialAccountUpdateFeaturesParamsCardIssuing(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateFeaturesParamsDepositInsurance(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateFeaturesParamsFinancialAddresses(TypedDict):
+ aba: NotRequired[
+ "FinancialAccountUpdateFeaturesParamsFinancialAddressesAba"
+ ]
+ """
+ Adds an ABA FinancialAddress to the FinancialAccount.
+ """
+
+
+class FinancialAccountUpdateFeaturesParamsFinancialAddressesAba(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateFeaturesParamsInboundTransfers(TypedDict):
+ ach: NotRequired["FinancialAccountUpdateFeaturesParamsInboundTransfersAch"]
+ """
+ Enables ACH Debits via the InboundTransfers API.
+ """
+
+
+class FinancialAccountUpdateFeaturesParamsInboundTransfersAch(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateFeaturesParamsIntraStripeFlows(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateFeaturesParamsOutboundPayments(TypedDict):
+ ach: NotRequired["FinancialAccountUpdateFeaturesParamsOutboundPaymentsAch"]
+ """
+ Enables ACH transfers via the OutboundPayments API.
+ """
+ us_domestic_wire: NotRequired[
+ "FinancialAccountUpdateFeaturesParamsOutboundPaymentsUsDomesticWire"
+ ]
+ """
+ Enables US domestic wire transfers via the OutboundPayments API.
+ """
+
+
+class FinancialAccountUpdateFeaturesParamsOutboundPaymentsAch(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateFeaturesParamsOutboundPaymentsUsDomesticWire(
+ TypedDict,
+):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateFeaturesParamsOutboundTransfers(TypedDict):
+ ach: NotRequired[
+ "FinancialAccountUpdateFeaturesParamsOutboundTransfersAch"
+ ]
+ """
+ Enables ACH transfers via the OutboundTransfers API.
+ """
+ us_domestic_wire: NotRequired[
+ "FinancialAccountUpdateFeaturesParamsOutboundTransfersUsDomesticWire"
+ ]
+ """
+ Enables US domestic wire transfers via the OutboundTransfers API.
+ """
+
+
+class FinancialAccountUpdateFeaturesParamsOutboundTransfersAch(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateFeaturesParamsOutboundTransfersUsDomesticWire(
+ TypedDict,
+):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
diff --git a/stripe/params/treasury/_financial_account_update_params.py b/stripe/params/treasury/_financial_account_update_params.py
new file mode 100644
index 000000000..49fa4276b
--- /dev/null
+++ b/stripe/params/treasury/_financial_account_update_params.py
@@ -0,0 +1,217 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class FinancialAccountUpdateParams(TypedDict):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ features: NotRequired["FinancialAccountUpdateParamsFeatures"]
+ """
+ Encodes whether a FinancialAccount has access to a particular feature, with a status enum and associated `status_details`. Stripe or the platform may control features via the requested field.
+ """
+ forwarding_settings: NotRequired[
+ "FinancialAccountUpdateParamsForwardingSettings"
+ ]
+ """
+ A different bank account where funds can be deposited/debited in order to get the closing FA's balance to $0
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ nickname: NotRequired["Literal['']|str"]
+ """
+ The nickname for the FinancialAccount.
+ """
+ platform_restrictions: NotRequired[
+ "FinancialAccountUpdateParamsPlatformRestrictions"
+ ]
+ """
+ The set of functionalities that the platform can restrict on the FinancialAccount.
+ """
+
+
+class FinancialAccountUpdateParamsFeatures(TypedDict):
+ card_issuing: NotRequired[
+ "FinancialAccountUpdateParamsFeaturesCardIssuing"
+ ]
+ """
+ Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
+ """
+ deposit_insurance: NotRequired[
+ "FinancialAccountUpdateParamsFeaturesDepositInsurance"
+ ]
+ """
+ Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
+ """
+ financial_addresses: NotRequired[
+ "FinancialAccountUpdateParamsFeaturesFinancialAddresses"
+ ]
+ """
+ Contains Features that add FinancialAddresses to the FinancialAccount.
+ """
+ inbound_transfers: NotRequired[
+ "FinancialAccountUpdateParamsFeaturesInboundTransfers"
+ ]
+ """
+ Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
+ """
+ intra_stripe_flows: NotRequired[
+ "FinancialAccountUpdateParamsFeaturesIntraStripeFlows"
+ ]
+ """
+ Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
+ """
+ outbound_payments: NotRequired[
+ "FinancialAccountUpdateParamsFeaturesOutboundPayments"
+ ]
+ """
+ Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
+ """
+ outbound_transfers: NotRequired[
+ "FinancialAccountUpdateParamsFeaturesOutboundTransfers"
+ ]
+ """
+ Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
+ """
+
+
+class FinancialAccountUpdateParamsFeaturesCardIssuing(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateParamsFeaturesDepositInsurance(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateParamsFeaturesFinancialAddresses(TypedDict):
+ aba: NotRequired[
+ "FinancialAccountUpdateParamsFeaturesFinancialAddressesAba"
+ ]
+ """
+ Adds an ABA FinancialAddress to the FinancialAccount.
+ """
+
+
+class FinancialAccountUpdateParamsFeaturesFinancialAddressesAba(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateParamsFeaturesInboundTransfers(TypedDict):
+ ach: NotRequired["FinancialAccountUpdateParamsFeaturesInboundTransfersAch"]
+ """
+ Enables ACH Debits via the InboundTransfers API.
+ """
+
+
+class FinancialAccountUpdateParamsFeaturesInboundTransfersAch(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateParamsFeaturesIntraStripeFlows(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateParamsFeaturesOutboundPayments(TypedDict):
+ ach: NotRequired["FinancialAccountUpdateParamsFeaturesOutboundPaymentsAch"]
+ """
+ Enables ACH transfers via the OutboundPayments API.
+ """
+ us_domestic_wire: NotRequired[
+ "FinancialAccountUpdateParamsFeaturesOutboundPaymentsUsDomesticWire"
+ ]
+ """
+ Enables US domestic wire transfers via the OutboundPayments API.
+ """
+
+
+class FinancialAccountUpdateParamsFeaturesOutboundPaymentsAch(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateParamsFeaturesOutboundPaymentsUsDomesticWire(
+ TypedDict,
+):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateParamsFeaturesOutboundTransfers(TypedDict):
+ ach: NotRequired[
+ "FinancialAccountUpdateParamsFeaturesOutboundTransfersAch"
+ ]
+ """
+ Enables ACH transfers via the OutboundTransfers API.
+ """
+ us_domestic_wire: NotRequired[
+ "FinancialAccountUpdateParamsFeaturesOutboundTransfersUsDomesticWire"
+ ]
+ """
+ Enables US domestic wire transfers via the OutboundTransfers API.
+ """
+
+
+class FinancialAccountUpdateParamsFeaturesOutboundTransfersAch(TypedDict):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateParamsFeaturesOutboundTransfersUsDomesticWire(
+ TypedDict,
+):
+ requested: bool
+ """
+ Whether the FinancialAccount should have the Feature.
+ """
+
+
+class FinancialAccountUpdateParamsForwardingSettings(TypedDict):
+ financial_account: NotRequired[str]
+ """
+ The financial_account id
+ """
+ payment_method: NotRequired[str]
+ """
+ The payment_method or bank account id. This needs to be a verified bank account.
+ """
+ type: Literal["financial_account", "payment_method"]
+ """
+ The type of the bank account provided. This can be either "financial_account" or "payment_method"
+ """
+
+
+class FinancialAccountUpdateParamsPlatformRestrictions(TypedDict):
+ inbound_flows: NotRequired[Literal["restricted", "unrestricted"]]
+ """
+ Restricts all inbound money movement.
+ """
+ outbound_flows: NotRequired[Literal["restricted", "unrestricted"]]
+ """
+ Restricts all outbound money movement.
+ """
diff --git a/stripe/params/treasury/_inbound_transfer_cancel_params.py b/stripe/params/treasury/_inbound_transfer_cancel_params.py
new file mode 100644
index 000000000..39ba9fcac
--- /dev/null
+++ b/stripe/params/treasury/_inbound_transfer_cancel_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InboundTransferCancelParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_inbound_transfer_create_params.py b/stripe/params/treasury/_inbound_transfer_create_params.py
new file mode 100644
index 000000000..efc92248e
--- /dev/null
+++ b/stripe/params/treasury/_inbound_transfer_create_params.py
@@ -0,0 +1,40 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import NotRequired
+
+
+class InboundTransferCreateParams(RequestOptions):
+ amount: int
+ """
+ Amount (in cents) to be transferred.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ The FinancialAccount to send funds to.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ origin_payment_method: str
+ """
+ The origin payment method to be debited for the InboundTransfer.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ The complete description that appears on your customers' statements. Maximum 10 characters.
+ """
diff --git a/stripe/params/treasury/_inbound_transfer_fail_params.py b/stripe/params/treasury/_inbound_transfer_fail_params.py
new file mode 100644
index 000000000..8f220ed16
--- /dev/null
+++ b/stripe/params/treasury/_inbound_transfer_fail_params.py
@@ -0,0 +1,39 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class InboundTransferFailParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ failure_details: NotRequired["InboundTransferFailParamsFailureDetails"]
+ """
+ Details about a failed InboundTransfer.
+ """
+
+
+class InboundTransferFailParamsFailureDetails(TypedDict):
+ code: NotRequired[
+ Literal[
+ "account_closed",
+ "account_frozen",
+ "bank_account_restricted",
+ "bank_ownership_changed",
+ "debit_not_authorized",
+ "incorrect_account_holder_address",
+ "incorrect_account_holder_name",
+ "incorrect_account_holder_tax_id",
+ "insufficient_funds",
+ "invalid_account_number",
+ "invalid_currency",
+ "no_account",
+ "other",
+ ]
+ ]
+ """
+ Reason for the failure.
+ """
diff --git a/stripe/params/treasury/_inbound_transfer_list_params.py b/stripe/params/treasury/_inbound_transfer_list_params.py
new file mode 100644
index 000000000..709a65820
--- /dev/null
+++ b/stripe/params/treasury/_inbound_transfer_list_params.py
@@ -0,0 +1,34 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class InboundTransferListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ Returns objects associated with this FinancialAccount.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[
+ Literal["canceled", "failed", "processing", "succeeded"]
+ ]
+ """
+ Only return InboundTransfers that have the given status: `processing`, `succeeded`, `failed` or `canceled`.
+ """
diff --git a/stripe/params/treasury/_inbound_transfer_retrieve_params.py b/stripe/params/treasury/_inbound_transfer_retrieve_params.py
new file mode 100644
index 000000000..e588e70cc
--- /dev/null
+++ b/stripe/params/treasury/_inbound_transfer_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InboundTransferRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_inbound_transfer_return_inbound_transfer_params.py b/stripe/params/treasury/_inbound_transfer_return_inbound_transfer_params.py
new file mode 100644
index 000000000..ada9cdfae
--- /dev/null
+++ b/stripe/params/treasury/_inbound_transfer_return_inbound_transfer_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InboundTransferReturnInboundTransferParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_inbound_transfer_succeed_params.py b/stripe/params/treasury/_inbound_transfer_succeed_params.py
new file mode 100644
index 000000000..e88a1730c
--- /dev/null
+++ b/stripe/params/treasury/_inbound_transfer_succeed_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class InboundTransferSucceedParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_outbound_payment_cancel_params.py b/stripe/params/treasury/_outbound_payment_cancel_params.py
new file mode 100644
index 000000000..e94e9d25e
--- /dev/null
+++ b/stripe/params/treasury/_outbound_payment_cancel_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class OutboundPaymentCancelParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_outbound_payment_create_params.py b/stripe/params/treasury/_outbound_payment_create_params.py
new file mode 100644
index 000000000..89cdf5685
--- /dev/null
+++ b/stripe/params/treasury/_outbound_payment_create_params.py
@@ -0,0 +1,193 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class OutboundPaymentCreateParams(RequestOptions):
+ amount: int
+ """
+ Amount (in cents) to be transferred.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ customer: NotRequired[str]
+ """
+ ID of the customer to whom the OutboundPayment is sent. Must match the Customer attached to the `destination_payment_method` passed in.
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ destination_payment_method: NotRequired[str]
+ """
+ The PaymentMethod to use as the payment instrument for the OutboundPayment. Exclusive with `destination_payment_method_data`.
+ """
+ destination_payment_method_data: NotRequired[
+ "OutboundPaymentCreateParamsDestinationPaymentMethodData"
+ ]
+ """
+ Hash used to generate the PaymentMethod to be used for this OutboundPayment. Exclusive with `destination_payment_method`.
+ """
+ destination_payment_method_options: NotRequired[
+ "OutboundPaymentCreateParamsDestinationPaymentMethodOptions"
+ ]
+ """
+ Payment method-specific configuration for this OutboundPayment.
+ """
+ end_user_details: NotRequired["OutboundPaymentCreateParamsEndUserDetails"]
+ """
+ End user details.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ The FinancialAccount to pull funds from.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ The description that appears on the receiving end for this OutboundPayment (for example, bank statement for external bank transfer). Maximum 10 characters for `ach` payments, 140 characters for `us_domestic_wire` payments, or 500 characters for `stripe` network transfers. The default value is "payment".
+ """
+
+
+class OutboundPaymentCreateParamsDestinationPaymentMethodData(TypedDict):
+ billing_details: NotRequired[
+ "OutboundPaymentCreateParamsDestinationPaymentMethodDataBillingDetails"
+ ]
+ """
+ Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+ """
+ financial_account: NotRequired[str]
+ """
+ Required if type is set to `financial_account`. The FinancialAccount ID to send funds to.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ type: Literal["financial_account", "us_bank_account"]
+ """
+ The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
+ """
+ us_bank_account: NotRequired[
+ "OutboundPaymentCreateParamsDestinationPaymentMethodDataUsBankAccount"
+ ]
+ """
+ Required hash if type is set to `us_bank_account`.
+ """
+
+
+class OutboundPaymentCreateParamsDestinationPaymentMethodDataBillingDetails(
+ TypedDict,
+):
+ address: NotRequired[
+ "Literal['']|OutboundPaymentCreateParamsDestinationPaymentMethodDataBillingDetailsAddress"
+ ]
+ """
+ Billing address.
+ """
+ email: NotRequired["Literal['']|str"]
+ """
+ Email address.
+ """
+ name: NotRequired["Literal['']|str"]
+ """
+ Full name.
+ """
+ phone: NotRequired["Literal['']|str"]
+ """
+ Billing phone number (including extension).
+ """
+
+
+class OutboundPaymentCreateParamsDestinationPaymentMethodDataBillingDetailsAddress(
+ TypedDict,
+):
+ city: NotRequired[str]
+ """
+ City, district, suburb, town, or village.
+ """
+ country: NotRequired[str]
+ """
+ Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ """
+ line1: NotRequired[str]
+ """
+ Address line 1, such as the street, PO Box, or company name.
+ """
+ line2: NotRequired[str]
+ """
+ Address line 2, such as the apartment, suite, unit, or building.
+ """
+ postal_code: NotRequired[str]
+ """
+ ZIP or postal code.
+ """
+ state: NotRequired[str]
+ """
+ State, county, province, or region.
+ """
+
+
+class OutboundPaymentCreateParamsDestinationPaymentMethodDataUsBankAccount(
+ TypedDict,
+):
+ account_holder_type: NotRequired[Literal["company", "individual"]]
+ """
+ Account holder type: individual or company.
+ """
+ account_number: NotRequired[str]
+ """
+ Account number of the bank account.
+ """
+ account_type: NotRequired[Literal["checking", "savings"]]
+ """
+ Account type: checkings or savings. Defaults to checking if omitted.
+ """
+ financial_connections_account: NotRequired[str]
+ """
+ The ID of a Financial Connections Account to use as a payment method.
+ """
+ routing_number: NotRequired[str]
+ """
+ Routing number of the bank account.
+ """
+
+
+class OutboundPaymentCreateParamsDestinationPaymentMethodOptions(TypedDict):
+ us_bank_account: NotRequired[
+ "Literal['']|OutboundPaymentCreateParamsDestinationPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ Optional fields for `us_bank_account`.
+ """
+
+
+class OutboundPaymentCreateParamsDestinationPaymentMethodOptionsUsBankAccount(
+ TypedDict,
+):
+ network: NotRequired[Literal["ach", "us_domestic_wire"]]
+ """
+ Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
+ """
+
+
+class OutboundPaymentCreateParamsEndUserDetails(TypedDict):
+ ip_address: NotRequired[str]
+ """
+ IP address of the user initiating the OutboundPayment. Must be supplied if `present` is set to `true`.
+ """
+ present: bool
+ """
+ `True` if the OutboundPayment creation request is being made on behalf of an end user by a platform. Otherwise, `false`.
+ """
diff --git a/stripe/params/treasury/_outbound_payment_fail_params.py b/stripe/params/treasury/_outbound_payment_fail_params.py
new file mode 100644
index 000000000..ec3d79c76
--- /dev/null
+++ b/stripe/params/treasury/_outbound_payment_fail_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class OutboundPaymentFailParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_outbound_payment_list_params.py b/stripe/params/treasury/_outbound_payment_list_params.py
new file mode 100644
index 000000000..6c663d073
--- /dev/null
+++ b/stripe/params/treasury/_outbound_payment_list_params.py
@@ -0,0 +1,61 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class OutboundPaymentListParams(RequestOptions):
+ created: NotRequired["OutboundPaymentListParamsCreated|int"]
+ """
+ Only return OutboundPayments that were created during the given date interval.
+ """
+ customer: NotRequired[str]
+ """
+ Only return OutboundPayments sent to this customer.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ Returns objects associated with this FinancialAccount.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[
+ Literal["canceled", "failed", "posted", "processing", "returned"]
+ ]
+ """
+ Only return OutboundPayments that have the given status: `processing`, `failed`, `posted`, `returned`, or `canceled`.
+ """
+
+
+class OutboundPaymentListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/treasury/_outbound_payment_post_params.py b/stripe/params/treasury/_outbound_payment_post_params.py
new file mode 100644
index 000000000..308e0cf8f
--- /dev/null
+++ b/stripe/params/treasury/_outbound_payment_post_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class OutboundPaymentPostParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_outbound_payment_retrieve_params.py b/stripe/params/treasury/_outbound_payment_retrieve_params.py
new file mode 100644
index 000000000..8fc79e2dd
--- /dev/null
+++ b/stripe/params/treasury/_outbound_payment_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class OutboundPaymentRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_outbound_payment_return_outbound_payment_params.py b/stripe/params/treasury/_outbound_payment_return_outbound_payment_params.py
new file mode 100644
index 000000000..b5bd84265
--- /dev/null
+++ b/stripe/params/treasury/_outbound_payment_return_outbound_payment_params.py
@@ -0,0 +1,38 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class OutboundPaymentReturnOutboundPaymentParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ returned_details: NotRequired[
+ "OutboundPaymentReturnOutboundPaymentParamsReturnedDetails"
+ ]
+ """
+ Optional hash to set the return code.
+ """
+
+
+class OutboundPaymentReturnOutboundPaymentParamsReturnedDetails(TypedDict):
+ code: NotRequired[
+ Literal[
+ "account_closed",
+ "account_frozen",
+ "bank_account_restricted",
+ "bank_ownership_changed",
+ "declined",
+ "incorrect_account_holder_name",
+ "invalid_account_number",
+ "invalid_currency",
+ "no_account",
+ "other",
+ ]
+ ]
+ """
+ The return code to be set on the OutboundPayment object.
+ """
diff --git a/stripe/params/treasury/_outbound_payment_update_params.py b/stripe/params/treasury/_outbound_payment_update_params.py
new file mode 100644
index 000000000..301b4e96d
--- /dev/null
+++ b/stripe/params/treasury/_outbound_payment_update_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class OutboundPaymentUpdateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ tracking_details: "OutboundPaymentUpdateParamsTrackingDetails"
+ """
+ Details about network-specific tracking information.
+ """
+
+
+class OutboundPaymentUpdateParamsTrackingDetails(TypedDict):
+ ach: NotRequired["OutboundPaymentUpdateParamsTrackingDetailsAch"]
+ """
+ ACH network tracking details.
+ """
+ type: Literal["ach", "us_domestic_wire"]
+ """
+ The US bank account network used to send funds.
+ """
+ us_domestic_wire: NotRequired[
+ "OutboundPaymentUpdateParamsTrackingDetailsUsDomesticWire"
+ ]
+ """
+ US domestic wire network tracking details.
+ """
+
+
+class OutboundPaymentUpdateParamsTrackingDetailsAch(TypedDict):
+ trace_id: str
+ """
+ ACH trace ID for funds sent over the `ach` network.
+ """
+
+
+class OutboundPaymentUpdateParamsTrackingDetailsUsDomesticWire(TypedDict):
+ chips: NotRequired[str]
+ """
+ CHIPS System Sequence Number (SSN) for funds sent over the `us_domestic_wire` network.
+ """
+ imad: NotRequired[str]
+ """
+ IMAD for funds sent over the `us_domestic_wire` network.
+ """
+ omad: NotRequired[str]
+ """
+ OMAD for funds sent over the `us_domestic_wire` network.
+ """
diff --git a/stripe/params/treasury/_outbound_transfer_cancel_params.py b/stripe/params/treasury/_outbound_transfer_cancel_params.py
new file mode 100644
index 000000000..d9e88a78f
--- /dev/null
+++ b/stripe/params/treasury/_outbound_transfer_cancel_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class OutboundTransferCancelParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_outbound_transfer_create_params.py b/stripe/params/treasury/_outbound_transfer_create_params.py
new file mode 100644
index 000000000..9a4728fa4
--- /dev/null
+++ b/stripe/params/treasury/_outbound_transfer_create_params.py
@@ -0,0 +1,81 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class OutboundTransferCreateParams(RequestOptions):
+ amount: int
+ """
+ Amount (in cents) to be transferred.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ destination_payment_method: NotRequired[str]
+ """
+ The PaymentMethod to use as the payment instrument for the OutboundTransfer.
+ """
+ destination_payment_method_data: NotRequired[
+ "OutboundTransferCreateParamsDestinationPaymentMethodData"
+ ]
+ """
+ Hash used to generate the PaymentMethod to be used for this OutboundTransfer. Exclusive with `destination_payment_method`.
+ """
+ destination_payment_method_options: NotRequired[
+ "OutboundTransferCreateParamsDestinationPaymentMethodOptions"
+ ]
+ """
+ Hash describing payment method configuration details.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ The FinancialAccount to pull funds from.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
+ """
+ statement_descriptor: NotRequired[str]
+ """
+ Statement descriptor to be shown on the receiving end of an OutboundTransfer. Maximum 10 characters for `ach` transfers or 140 characters for `us_domestic_wire` transfers. The default value is "transfer".
+ """
+
+
+class OutboundTransferCreateParamsDestinationPaymentMethodData(TypedDict):
+ financial_account: NotRequired[str]
+ """
+ Required if type is set to `financial_account`. The FinancialAccount ID to send funds to.
+ """
+ type: Literal["financial_account"]
+ """
+ The type of the destination.
+ """
+
+
+class OutboundTransferCreateParamsDestinationPaymentMethodOptions(TypedDict):
+ us_bank_account: NotRequired[
+ "Literal['']|OutboundTransferCreateParamsDestinationPaymentMethodOptionsUsBankAccount"
+ ]
+ """
+ Optional fields for `us_bank_account`.
+ """
+
+
+class OutboundTransferCreateParamsDestinationPaymentMethodOptionsUsBankAccount(
+ TypedDict,
+):
+ network: NotRequired[Literal["ach", "us_domestic_wire"]]
+ """
+ Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
+ """
diff --git a/stripe/params/treasury/_outbound_transfer_fail_params.py b/stripe/params/treasury/_outbound_transfer_fail_params.py
new file mode 100644
index 000000000..2da8070b0
--- /dev/null
+++ b/stripe/params/treasury/_outbound_transfer_fail_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class OutboundTransferFailParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_outbound_transfer_list_params.py b/stripe/params/treasury/_outbound_transfer_list_params.py
new file mode 100644
index 000000000..6f9e24782
--- /dev/null
+++ b/stripe/params/treasury/_outbound_transfer_list_params.py
@@ -0,0 +1,34 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class OutboundTransferListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ Returns objects associated with this FinancialAccount.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[
+ Literal["canceled", "failed", "posted", "processing", "returned"]
+ ]
+ """
+ Only return OutboundTransfers that have the given status: `processing`, `canceled`, `failed`, `posted`, or `returned`.
+ """
diff --git a/stripe/params/treasury/_outbound_transfer_post_params.py b/stripe/params/treasury/_outbound_transfer_post_params.py
new file mode 100644
index 000000000..f6372b085
--- /dev/null
+++ b/stripe/params/treasury/_outbound_transfer_post_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class OutboundTransferPostParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_outbound_transfer_retrieve_params.py b/stripe/params/treasury/_outbound_transfer_retrieve_params.py
new file mode 100644
index 000000000..cec275132
--- /dev/null
+++ b/stripe/params/treasury/_outbound_transfer_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class OutboundTransferRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_outbound_transfer_return_outbound_transfer_params.py b/stripe/params/treasury/_outbound_transfer_return_outbound_transfer_params.py
new file mode 100644
index 000000000..dd73d7e87
--- /dev/null
+++ b/stripe/params/treasury/_outbound_transfer_return_outbound_transfer_params.py
@@ -0,0 +1,38 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class OutboundTransferReturnOutboundTransferParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ returned_details: NotRequired[
+ "OutboundTransferReturnOutboundTransferParamsReturnedDetails"
+ ]
+ """
+ Details about a returned OutboundTransfer.
+ """
+
+
+class OutboundTransferReturnOutboundTransferParamsReturnedDetails(TypedDict):
+ code: NotRequired[
+ Literal[
+ "account_closed",
+ "account_frozen",
+ "bank_account_restricted",
+ "bank_ownership_changed",
+ "declined",
+ "incorrect_account_holder_name",
+ "invalid_account_number",
+ "invalid_currency",
+ "no_account",
+ "other",
+ ]
+ ]
+ """
+ Reason for the return.
+ """
diff --git a/stripe/params/treasury/_outbound_transfer_update_params.py b/stripe/params/treasury/_outbound_transfer_update_params.py
new file mode 100644
index 000000000..dcee93420
--- /dev/null
+++ b/stripe/params/treasury/_outbound_transfer_update_params.py
@@ -0,0 +1,55 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class OutboundTransferUpdateParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ tracking_details: "OutboundTransferUpdateParamsTrackingDetails"
+ """
+ Details about network-specific tracking information.
+ """
+
+
+class OutboundTransferUpdateParamsTrackingDetails(TypedDict):
+ ach: NotRequired["OutboundTransferUpdateParamsTrackingDetailsAch"]
+ """
+ ACH network tracking details.
+ """
+ type: Literal["ach", "us_domestic_wire"]
+ """
+ The US bank account network used to send funds.
+ """
+ us_domestic_wire: NotRequired[
+ "OutboundTransferUpdateParamsTrackingDetailsUsDomesticWire"
+ ]
+ """
+ US domestic wire network tracking details.
+ """
+
+
+class OutboundTransferUpdateParamsTrackingDetailsAch(TypedDict):
+ trace_id: str
+ """
+ ACH trace ID for funds sent over the `ach` network.
+ """
+
+
+class OutboundTransferUpdateParamsTrackingDetailsUsDomesticWire(TypedDict):
+ chips: NotRequired[str]
+ """
+ CHIPS System Sequence Number (SSN) for funds sent over the `us_domestic_wire` network.
+ """
+ imad: NotRequired[str]
+ """
+ IMAD for funds sent over the `us_domestic_wire` network.
+ """
+ omad: NotRequired[str]
+ """
+ OMAD for funds sent over the `us_domestic_wire` network.
+ """
diff --git a/stripe/params/treasury/_received_credit_create_params.py b/stripe/params/treasury/_received_credit_create_params.py
new file mode 100644
index 000000000..42911f15e
--- /dev/null
+++ b/stripe/params/treasury/_received_credit_create_params.py
@@ -0,0 +1,68 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ReceivedCreditCreateParams(RequestOptions):
+ amount: int
+ """
+ Amount (in cents) to be transferred.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ The FinancialAccount to send funds to.
+ """
+ initiating_payment_method_details: NotRequired[
+ "ReceivedCreditCreateParamsInitiatingPaymentMethodDetails"
+ ]
+ """
+ Initiating payment method details for the object.
+ """
+ network: Literal["ach", "us_domestic_wire"]
+ """
+ Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
+ """
+
+
+class ReceivedCreditCreateParamsInitiatingPaymentMethodDetails(TypedDict):
+ type: Literal["us_bank_account"]
+ """
+ The source type.
+ """
+ us_bank_account: NotRequired[
+ "ReceivedCreditCreateParamsInitiatingPaymentMethodDetailsUsBankAccount"
+ ]
+ """
+ Optional fields for `us_bank_account`.
+ """
+
+
+class ReceivedCreditCreateParamsInitiatingPaymentMethodDetailsUsBankAccount(
+ TypedDict,
+):
+ account_holder_name: NotRequired[str]
+ """
+ The bank account holder's name.
+ """
+ account_number: NotRequired[str]
+ """
+ The bank account number.
+ """
+ routing_number: NotRequired[str]
+ """
+ The bank account's routing number.
+ """
diff --git a/stripe/params/treasury/_received_credit_list_params.py b/stripe/params/treasury/_received_credit_list_params.py
new file mode 100644
index 000000000..7f0965463
--- /dev/null
+++ b/stripe/params/treasury/_received_credit_list_params.py
@@ -0,0 +1,49 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ReceivedCreditListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ The FinancialAccount that received the funds.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ linked_flows: NotRequired["ReceivedCreditListParamsLinkedFlows"]
+ """
+ Only return ReceivedCredits described by the flow.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["failed", "succeeded"]]
+ """
+ Only return ReceivedCredits that have the given status: `succeeded` or `failed`.
+ """
+
+
+class ReceivedCreditListParamsLinkedFlows(TypedDict):
+ source_flow_type: Literal[
+ "credit_reversal",
+ "other",
+ "outbound_payment",
+ "outbound_transfer",
+ "payout",
+ ]
+ """
+ The source flow type.
+ """
diff --git a/stripe/params/treasury/_received_credit_retrieve_params.py b/stripe/params/treasury/_received_credit_retrieve_params.py
new file mode 100644
index 000000000..552cc933d
--- /dev/null
+++ b/stripe/params/treasury/_received_credit_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ReceivedCreditRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_received_debit_create_params.py b/stripe/params/treasury/_received_debit_create_params.py
new file mode 100644
index 000000000..e5aad3393
--- /dev/null
+++ b/stripe/params/treasury/_received_debit_create_params.py
@@ -0,0 +1,68 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class ReceivedDebitCreateParams(RequestOptions):
+ amount: int
+ """
+ Amount (in cents) to be transferred.
+ """
+ currency: str
+ """
+ Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
+ """
+ description: NotRequired[str]
+ """
+ An arbitrary string attached to the object. Often useful for displaying to users.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ The FinancialAccount to pull funds from.
+ """
+ initiating_payment_method_details: NotRequired[
+ "ReceivedDebitCreateParamsInitiatingPaymentMethodDetails"
+ ]
+ """
+ Initiating payment method details for the object.
+ """
+ network: Literal["ach"]
+ """
+ Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
+ """
+
+
+class ReceivedDebitCreateParamsInitiatingPaymentMethodDetails(TypedDict):
+ type: Literal["us_bank_account"]
+ """
+ The source type.
+ """
+ us_bank_account: NotRequired[
+ "ReceivedDebitCreateParamsInitiatingPaymentMethodDetailsUsBankAccount"
+ ]
+ """
+ Optional fields for `us_bank_account`.
+ """
+
+
+class ReceivedDebitCreateParamsInitiatingPaymentMethodDetailsUsBankAccount(
+ TypedDict,
+):
+ account_holder_name: NotRequired[str]
+ """
+ The bank account holder's name.
+ """
+ account_number: NotRequired[str]
+ """
+ The bank account number.
+ """
+ routing_number: NotRequired[str]
+ """
+ The bank account's routing number.
+ """
diff --git a/stripe/params/treasury/_received_debit_list_params.py b/stripe/params/treasury/_received_debit_list_params.py
new file mode 100644
index 000000000..cd32d32f8
--- /dev/null
+++ b/stripe/params/treasury/_received_debit_list_params.py
@@ -0,0 +1,32 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired
+
+
+class ReceivedDebitListParams(RequestOptions):
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ The FinancialAccount that funds were pulled from.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["failed", "succeeded"]]
+ """
+ Only return ReceivedDebits that have the given status: `succeeded` or `failed`.
+ """
diff --git a/stripe/params/treasury/_received_debit_retrieve_params.py b/stripe/params/treasury/_received_debit_retrieve_params.py
new file mode 100644
index 000000000..88be7910a
--- /dev/null
+++ b/stripe/params/treasury/_received_debit_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class ReceivedDebitRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_transaction_entry_list_params.py b/stripe/params/treasury/_transaction_entry_list_params.py
new file mode 100644
index 000000000..c6b8d011a
--- /dev/null
+++ b/stripe/params/treasury/_transaction_entry_list_params.py
@@ -0,0 +1,79 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TransactionEntryListParams(RequestOptions):
+ created: NotRequired["TransactionEntryListParamsCreated|int"]
+ """
+ Only return TransactionEntries that were created during the given date interval.
+ """
+ effective_at: NotRequired["TransactionEntryListParamsEffectiveAt|int"]
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ Returns objects associated with this FinancialAccount.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ order_by: NotRequired[Literal["created", "effective_at"]]
+ """
+ The results are in reverse chronological order by `created` or `effective_at`. The default is `created`.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ transaction: NotRequired[str]
+ """
+ Only return TransactionEntries associated with this Transaction.
+ """
+
+
+class TransactionEntryListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
+
+
+class TransactionEntryListParamsEffectiveAt(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/treasury/_transaction_entry_retrieve_params.py b/stripe/params/treasury/_transaction_entry_retrieve_params.py
new file mode 100644
index 000000000..fb32213da
--- /dev/null
+++ b/stripe/params/treasury/_transaction_entry_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TransactionEntryRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/treasury/_transaction_list_params.py b/stripe/params/treasury/_transaction_list_params.py
new file mode 100644
index 000000000..6b5afe1e7
--- /dev/null
+++ b/stripe/params/treasury/_transaction_list_params.py
@@ -0,0 +1,91 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class TransactionListParams(RequestOptions):
+ created: NotRequired["TransactionListParamsCreated|int"]
+ """
+ Only return Transactions that were created during the given date interval.
+ """
+ ending_before: NotRequired[str]
+ """
+ A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
+ """
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
+ financial_account: str
+ """
+ Returns objects associated with this FinancialAccount.
+ """
+ limit: NotRequired[int]
+ """
+ A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
+ """
+ order_by: NotRequired[Literal["created", "posted_at"]]
+ """
+ The results are in reverse chronological order by `created` or `posted_at`. The default is `created`.
+ """
+ starting_after: NotRequired[str]
+ """
+ A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
+ """
+ status: NotRequired[Literal["open", "posted", "void"]]
+ """
+ Only return Transactions that have the given status: `open`, `posted`, or `void`.
+ """
+ status_transitions: NotRequired["TransactionListParamsStatusTransitions"]
+ """
+ A filter for the `status_transitions.posted_at` timestamp. When using this filter, `status=posted` and `order_by=posted_at` must also be specified.
+ """
+
+
+class TransactionListParamsCreated(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
+
+
+class TransactionListParamsStatusTransitions(TypedDict):
+ posted_at: NotRequired[
+ "TransactionListParamsStatusTransitionsPostedAt|int"
+ ]
+ """
+ Returns Transactions with `posted_at` within the specified range.
+ """
+
+
+class TransactionListParamsStatusTransitionsPostedAt(TypedDict):
+ gt: NotRequired[int]
+ """
+ Minimum value to filter by (exclusive)
+ """
+ gte: NotRequired[int]
+ """
+ Minimum value to filter by (inclusive)
+ """
+ lt: NotRequired[int]
+ """
+ Maximum value to filter by (exclusive)
+ """
+ lte: NotRequired[int]
+ """
+ Maximum value to filter by (inclusive)
+ """
diff --git a/stripe/params/treasury/_transaction_retrieve_params.py b/stripe/params/treasury/_transaction_retrieve_params.py
new file mode 100644
index 000000000..07744dd96
--- /dev/null
+++ b/stripe/params/treasury/_transaction_retrieve_params.py
@@ -0,0 +1,12 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe._request_options import RequestOptions
+from typing import List
+from typing_extensions import NotRequired
+
+
+class TransactionRetrieveParams(RequestOptions):
+ expand: NotRequired[List[str]]
+ """
+ Specifies which fields in the response should be expanded.
+ """
diff --git a/stripe/params/v2/__init__.py b/stripe/params/v2/__init__.py
new file mode 100644
index 000000000..5874cc472
--- /dev/null
+++ b/stripe/params/v2/__init__.py
@@ -0,0 +1,3 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.v2 import billing as billing, core as core
diff --git a/stripe/params/v2/billing/__init__.py b/stripe/params/v2/billing/__init__.py
new file mode 100644
index 000000000..4d2eee2bd
--- /dev/null
+++ b/stripe/params/v2/billing/__init__.py
@@ -0,0 +1,14 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.v2.billing._meter_event_adjustment_create_params import (
+ MeterEventAdjustmentCreateParams as MeterEventAdjustmentCreateParams,
+)
+from stripe.params.v2.billing._meter_event_create_params import (
+ MeterEventCreateParams as MeterEventCreateParams,
+)
+from stripe.params.v2.billing._meter_event_session_create_params import (
+ MeterEventSessionCreateParams as MeterEventSessionCreateParams,
+)
+from stripe.params.v2.billing._meter_event_stream_create_params import (
+ MeterEventStreamCreateParams as MeterEventStreamCreateParams,
+)
diff --git a/stripe/params/v2/billing/_meter_event_adjustment_create_params.py b/stripe/params/v2/billing/_meter_event_adjustment_create_params.py
new file mode 100644
index 000000000..ee1dd55e6
--- /dev/null
+++ b/stripe/params/v2/billing/_meter_event_adjustment_create_params.py
@@ -0,0 +1,25 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing_extensions import Literal, TypedDict
+
+
+class MeterEventAdjustmentCreateParams(TypedDict):
+ cancel: "MeterEventAdjustmentCreateParamsCancel"
+ """
+ Specifies which event to cancel.
+ """
+ event_name: str
+ """
+ The name of the meter event. Corresponds with the `event_name` field on a meter.
+ """
+ type: Literal["cancel"]
+ """
+ Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet.
+ """
+
+
+class MeterEventAdjustmentCreateParamsCancel(TypedDict):
+ identifier: str
+ """
+ Unique identifier for the event. You can only cancel events within 24 hours of Stripe receiving them.
+ """
diff --git a/stripe/params/v2/billing/_meter_event_create_params.py b/stripe/params/v2/billing/_meter_event_create_params.py
new file mode 100644
index 000000000..1084d505d
--- /dev/null
+++ b/stripe/params/v2/billing/_meter_event_create_params.py
@@ -0,0 +1,30 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict
+from typing_extensions import NotRequired, TypedDict
+
+
+class MeterEventCreateParams(TypedDict):
+ event_name: str
+ """
+ The name of the meter event. Corresponds with the `event_name` field on a meter.
+ """
+ identifier: NotRequired[str]
+ """
+ A unique identifier for the event. If not provided, one will be generated.
+ We recommend using a globally unique identifier for this. We'll enforce
+ uniqueness within a rolling 24 hour period.
+ """
+ payload: Dict[str, str]
+ """
+ The payload of the event. This must contain the fields corresponding to a meter's
+ `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and
+ `value_settings.event_payload_key` (default is `value`). Read more about
+ the
+ [payload](https://docs.stripe.com/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).
+ """
+ timestamp: NotRequired[str]
+ """
+ The time of the event. Must be within the past 35 calendar days or up to
+ 5 minutes in the future. Defaults to current timestamp if not specified.
+ """
diff --git a/stripe/params/v2/billing/_meter_event_session_create_params.py b/stripe/params/v2/billing/_meter_event_session_create_params.py
new file mode 100644
index 000000000..24bc63e9c
--- /dev/null
+++ b/stripe/params/v2/billing/_meter_event_session_create_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing_extensions import TypedDict
+
+
+class MeterEventSessionCreateParams(TypedDict):
+ pass
diff --git a/stripe/params/v2/billing/_meter_event_stream_create_params.py b/stripe/params/v2/billing/_meter_event_stream_create_params.py
new file mode 100644
index 000000000..6fbba915d
--- /dev/null
+++ b/stripe/params/v2/billing/_meter_event_stream_create_params.py
@@ -0,0 +1,37 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import NotRequired, TypedDict
+
+
+class MeterEventStreamCreateParams(TypedDict):
+ events: List["MeterEventStreamCreateParamsEvent"]
+ """
+ List of meter events to include in the request. Supports up to 100 events per request.
+ """
+
+
+class MeterEventStreamCreateParamsEvent(TypedDict):
+ event_name: str
+ """
+ The name of the meter event. Corresponds with the `event_name` field on a meter.
+ """
+ identifier: NotRequired[str]
+ """
+ A unique identifier for the event. If not provided, one will be generated.
+ We recommend using a globally unique identifier for this. We'll enforce
+ uniqueness within a rolling 24 hour period.
+ """
+ payload: Dict[str, str]
+ """
+ The payload of the event. This must contain the fields corresponding to a meter's
+ `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and
+ `value_settings.event_payload_key` (default is `value`). Read more about
+ the
+ [payload](https://docs.stripe.com/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).
+ """
+ timestamp: NotRequired[str]
+ """
+ The time of the event. Must be within the past 35 calendar days or up to
+ 5 minutes in the future. Defaults to current timestamp if not specified.
+ """
diff --git a/stripe/params/v2/core/__init__.py b/stripe/params/v2/core/__init__.py
new file mode 100644
index 000000000..8cfdcfa67
--- /dev/null
+++ b/stripe/params/v2/core/__init__.py
@@ -0,0 +1,32 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from stripe.params.v2.core._event_destination_create_params import (
+ EventDestinationCreateParams as EventDestinationCreateParams,
+)
+from stripe.params.v2.core._event_destination_delete_params import (
+ EventDestinationDeleteParams as EventDestinationDeleteParams,
+)
+from stripe.params.v2.core._event_destination_disable_params import (
+ EventDestinationDisableParams as EventDestinationDisableParams,
+)
+from stripe.params.v2.core._event_destination_enable_params import (
+ EventDestinationEnableParams as EventDestinationEnableParams,
+)
+from stripe.params.v2.core._event_destination_list_params import (
+ EventDestinationListParams as EventDestinationListParams,
+)
+from stripe.params.v2.core._event_destination_ping_params import (
+ EventDestinationPingParams as EventDestinationPingParams,
+)
+from stripe.params.v2.core._event_destination_retrieve_params import (
+ EventDestinationRetrieveParams as EventDestinationRetrieveParams,
+)
+from stripe.params.v2.core._event_destination_update_params import (
+ EventDestinationUpdateParams as EventDestinationUpdateParams,
+)
+from stripe.params.v2.core._event_list_params import (
+ EventListParams as EventListParams,
+)
+from stripe.params.v2.core._event_retrieve_params import (
+ EventRetrieveParams as EventRetrieveParams,
+)
diff --git a/stripe/params/v2/core/_event_destination_create_params.py b/stripe/params/v2/core/_event_destination_create_params.py
new file mode 100644
index 000000000..63aee13ee
--- /dev/null
+++ b/stripe/params/v2/core/_event_destination_create_params.py
@@ -0,0 +1,77 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class EventDestinationCreateParams(TypedDict):
+ description: NotRequired[str]
+ """
+ An optional description of what the event destination is used for.
+ """
+ enabled_events: List[str]
+ """
+ The list of events to enable for this endpoint.
+ """
+ event_payload: Literal["snapshot", "thin"]
+ """
+ Payload type of events being subscribed to.
+ """
+ events_from: NotRequired[List[Literal["other_accounts", "self"]]]
+ """
+ Where events should be routed from.
+ """
+ include: NotRequired[
+ List[
+ Literal["webhook_endpoint.signing_secret", "webhook_endpoint.url"]
+ ]
+ ]
+ """
+ Additional fields to include in the response.
+ """
+ metadata: NotRequired[Dict[str, str]]
+ """
+ Metadata.
+ """
+ name: str
+ """
+ Event destination name.
+ """
+ snapshot_api_version: NotRequired[str]
+ """
+ If using the snapshot event payload, the API version events are rendered as.
+ """
+ type: Literal["amazon_eventbridge", "webhook_endpoint"]
+ """
+ Event destination type.
+ """
+ amazon_eventbridge: NotRequired[
+ "EventDestinationCreateParamsAmazonEventbridge"
+ ]
+ """
+ Amazon EventBridge configuration.
+ """
+ webhook_endpoint: NotRequired[
+ "EventDestinationCreateParamsWebhookEndpoint"
+ ]
+ """
+ Webhook endpoint configuration.
+ """
+
+
+class EventDestinationCreateParamsAmazonEventbridge(TypedDict):
+ aws_account_id: str
+ """
+ The AWS account ID.
+ """
+ aws_region: str
+ """
+ The region of the AWS event source.
+ """
+
+
+class EventDestinationCreateParamsWebhookEndpoint(TypedDict):
+ url: str
+ """
+ The URL of the webhook endpoint.
+ """
diff --git a/stripe/params/v2/core/_event_destination_delete_params.py b/stripe/params/v2/core/_event_destination_delete_params.py
new file mode 100644
index 000000000..d8393ade7
--- /dev/null
+++ b/stripe/params/v2/core/_event_destination_delete_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing_extensions import TypedDict
+
+
+class EventDestinationDeleteParams(TypedDict):
+ pass
diff --git a/stripe/params/v2/core/_event_destination_disable_params.py b/stripe/params/v2/core/_event_destination_disable_params.py
new file mode 100644
index 000000000..e5c8fd247
--- /dev/null
+++ b/stripe/params/v2/core/_event_destination_disable_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing_extensions import TypedDict
+
+
+class EventDestinationDisableParams(TypedDict):
+ pass
diff --git a/stripe/params/v2/core/_event_destination_enable_params.py b/stripe/params/v2/core/_event_destination_enable_params.py
new file mode 100644
index 000000000..8da0fc3ae
--- /dev/null
+++ b/stripe/params/v2/core/_event_destination_enable_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing_extensions import TypedDict
+
+
+class EventDestinationEnableParams(TypedDict):
+ pass
diff --git a/stripe/params/v2/core/_event_destination_list_params.py b/stripe/params/v2/core/_event_destination_list_params.py
new file mode 100644
index 000000000..c0320468a
--- /dev/null
+++ b/stripe/params/v2/core/_event_destination_list_params.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class EventDestinationListParams(TypedDict):
+ include: NotRequired[List[Literal["webhook_endpoint.url"]]]
+ """
+ Additional fields to include in the response. Currently supports `webhook_endpoint.url`.
+ """
+ limit: NotRequired[int]
+ """
+ The page size.
+ """
diff --git a/stripe/params/v2/core/_event_destination_ping_params.py b/stripe/params/v2/core/_event_destination_ping_params.py
new file mode 100644
index 000000000..745aa1ec0
--- /dev/null
+++ b/stripe/params/v2/core/_event_destination_ping_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing_extensions import TypedDict
+
+
+class EventDestinationPingParams(TypedDict):
+ pass
diff --git a/stripe/params/v2/core/_event_destination_retrieve_params.py b/stripe/params/v2/core/_event_destination_retrieve_params.py
new file mode 100644
index 000000000..d43606b1d
--- /dev/null
+++ b/stripe/params/v2/core/_event_destination_retrieve_params.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import List
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class EventDestinationRetrieveParams(TypedDict):
+ include: NotRequired[List[Literal["webhook_endpoint.url"]]]
+ """
+ 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
new file mode 100644
index 000000000..6bd71e403
--- /dev/null
+++ b/stripe/params/v2/core/_event_destination_update_params.py
@@ -0,0 +1,40 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing import Dict, List, Optional
+from typing_extensions import Literal, NotRequired, TypedDict
+
+
+class EventDestinationUpdateParams(TypedDict):
+ description: NotRequired[str]
+ """
+ An optional description of what the event destination is used for.
+ """
+ enabled_events: NotRequired[List[str]]
+ """
+ The list of events to enable for this endpoint.
+ """
+ include: NotRequired[List[Literal["webhook_endpoint.url"]]]
+ """
+ Additional fields to include in the response. Currently supports `webhook_endpoint.url`.
+ """
+ metadata: NotRequired[Dict[str, Optional[str]]]
+ """
+ Metadata.
+ """
+ name: NotRequired[str]
+ """
+ Event destination name.
+ """
+ webhook_endpoint: NotRequired[
+ "EventDestinationUpdateParamsWebhookEndpoint"
+ ]
+ """
+ Webhook endpoint configuration.
+ """
+
+
+class EventDestinationUpdateParamsWebhookEndpoint(TypedDict):
+ url: str
+ """
+ The URL of the webhook endpoint.
+ """
diff --git a/stripe/params/v2/core/_event_list_params.py b/stripe/params/v2/core/_event_list_params.py
new file mode 100644
index 000000000..364815d48
--- /dev/null
+++ b/stripe/params/v2/core/_event_list_params.py
@@ -0,0 +1,14 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing_extensions import NotRequired, TypedDict
+
+
+class EventListParams(TypedDict):
+ limit: NotRequired[int]
+ """
+ The page size.
+ """
+ object_id: str
+ """
+ Primary object ID used to retrieve related events.
+ """
diff --git a/stripe/params/v2/core/_event_retrieve_params.py b/stripe/params/v2/core/_event_retrieve_params.py
new file mode 100644
index 000000000..4684f39bf
--- /dev/null
+++ b/stripe/params/v2/core/_event_retrieve_params.py
@@ -0,0 +1,7 @@
+# -*- coding: utf-8 -*-
+# File generated from our OpenAPI spec
+from typing_extensions import TypedDict
+
+
+class EventRetrieveParams(TypedDict):
+ pass
diff --git a/stripe/radar/_early_fraud_warning.py b/stripe/radar/_early_fraud_warning.py
index 5240ef9f7..14d60429d 100644
--- a/stripe/radar/_early_fraud_warning.py
+++ b/stripe/radar/_early_fraud_warning.py
@@ -3,19 +3,18 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
-from typing import ClassVar, List, Optional
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Optional
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._charge import Charge
from stripe._payment_intent import PaymentIntent
+ from stripe.params.radar._early_fraud_warning_list_params import (
+ EarlyFraudWarningListParams,
+ )
+ from stripe.params.radar._early_fraud_warning_retrieve_params import (
+ EarlyFraudWarningRetrieveParams,
+ )
class EarlyFraudWarning(ListableAPIResource["EarlyFraudWarning"]):
@@ -29,61 +28,6 @@ class EarlyFraudWarning(ListableAPIResource["EarlyFraudWarning"]):
OBJECT_NAME: ClassVar[Literal["radar.early_fraud_warning"]] = (
"radar.early_fraud_warning"
)
-
- class ListParams(RequestOptions):
- charge: NotRequired[str]
- """
- Only return early fraud warnings for the charge specified by this charge ID.
- """
- created: NotRequired["EarlyFraudWarning.ListParamsCreated|int"]
- """
- Only return early fraud warnings that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payment_intent: NotRequired[str]
- """
- Only return early fraud warnings for charges that were created by the PaymentIntent specified by this PaymentIntent ID.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
actionable: bool
"""
An EFW is actionable if it has not received a dispute and has not been fully refunded. You may wish to proactively refund a charge that receives an EFW, in order to avoid receiving a dispute later.
@@ -119,7 +63,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["EarlyFraudWarning.ListParams"]
+ cls, **params: Unpack["EarlyFraudWarningListParams"]
) -> ListObject["EarlyFraudWarning"]:
"""
Returns a list of early fraud warnings.
@@ -139,7 +83,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["EarlyFraudWarning.ListParams"]
+ cls, **params: Unpack["EarlyFraudWarningListParams"]
) -> ListObject["EarlyFraudWarning"]:
"""
Returns a list of early fraud warnings.
@@ -159,7 +103,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["EarlyFraudWarning.RetrieveParams"]
+ cls, id: str, **params: Unpack["EarlyFraudWarningRetrieveParams"]
) -> "EarlyFraudWarning":
"""
Retrieves the details of an early fraud warning that has previously been created.
@@ -172,7 +116,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["EarlyFraudWarning.RetrieveParams"]
+ cls, id: str, **params: Unpack["EarlyFraudWarningRetrieveParams"]
) -> "EarlyFraudWarning":
"""
Retrieves the details of an early fraud warning that has previously been created.
diff --git a/stripe/radar/_early_fraud_warning_service.py b/stripe/radar/_early_fraud_warning_service.py
index a58ec5fd6..20f3ef6d7 100644
--- a/stripe/radar/_early_fraud_warning_service.py
+++ b/stripe/radar/_early_fraud_warning_service.py
@@ -5,68 +5,22 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.radar._early_fraud_warning import EarlyFraudWarning
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.radar._early_fraud_warning_list_params import (
+ EarlyFraudWarningListParams,
+ )
+ from stripe.params.radar._early_fraud_warning_retrieve_params import (
+ EarlyFraudWarningRetrieveParams,
+ )
-class EarlyFraudWarningService(StripeService):
- class ListParams(TypedDict):
- charge: NotRequired[str]
- """
- Only return early fraud warnings for the charge specified by this charge ID.
- """
- created: NotRequired["EarlyFraudWarningService.ListParamsCreated|int"]
- """
- Only return early fraud warnings that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- payment_intent: NotRequired[str]
- """
- Only return early fraud warnings for charges that were created by the PaymentIntent specified by this PaymentIntent ID.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class EarlyFraudWarningService(StripeService):
def list(
self,
- params: Optional["EarlyFraudWarningService.ListParams"] = None,
+ params: Optional["EarlyFraudWarningListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[EarlyFraudWarning]:
"""
@@ -85,7 +39,7 @@ def list(
async def list_async(
self,
- params: Optional["EarlyFraudWarningService.ListParams"] = None,
+ params: Optional["EarlyFraudWarningListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[EarlyFraudWarning]:
"""
@@ -105,7 +59,7 @@ async def list_async(
def retrieve(
self,
early_fraud_warning: str,
- params: Optional["EarlyFraudWarningService.RetrieveParams"] = None,
+ params: Optional["EarlyFraudWarningRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> EarlyFraudWarning:
"""
@@ -129,7 +83,7 @@ def retrieve(
async def retrieve_async(
self,
early_fraud_warning: str,
- params: Optional["EarlyFraudWarningService.RetrieveParams"] = None,
+ params: Optional["EarlyFraudWarningRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> EarlyFraudWarning:
"""
diff --git a/stripe/radar/_value_list.py b/stripe/radar/_value_list.py
index 66176699b..eb9623d1a 100644
--- a/stripe/radar/_value_list.py
+++ b/stripe/radar/_value_list.py
@@ -4,19 +4,25 @@
from stripe._deletable_api_resource import DeletableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Dict, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
+ from stripe.params.radar._value_list_create_params import (
+ ValueListCreateParams,
+ )
+ from stripe.params.radar._value_list_delete_params import (
+ ValueListDeleteParams,
+ )
+ from stripe.params.radar._value_list_list_params import ValueListListParams
+ from stripe.params.radar._value_list_modify_params import (
+ ValueListModifyParams,
+ )
+ from stripe.params.radar._value_list_retrieve_params import (
+ ValueListRetrieveParams,
+ )
from stripe.radar._value_list_item import ValueListItem
@@ -33,117 +39,6 @@ class ValueList(
"""
OBJECT_NAME: ClassVar[Literal["radar.value_list"]] = "radar.value_list"
-
- class CreateParams(RequestOptions):
- alias: str
- """
- The name of the value list for use in rules.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- item_type: NotRequired[
- Literal[
- "card_bin",
- "card_fingerprint",
- "case_sensitive_string",
- "country",
- "customer_id",
- "email",
- "ip_address",
- "sepa_debit_fingerprint",
- "string",
- "us_bank_account_fingerprint",
- ]
- ]
- """
- Type of the items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, `case_sensitive_string`, `customer_id`, `sepa_debit_fingerprint`, or `us_bank_account_fingerprint`. Use `string` if the item type is unknown or mixed.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The human-readable name of the value list.
- """
-
- class DeleteParams(RequestOptions):
- pass
-
- class ListParams(RequestOptions):
- alias: NotRequired[str]
- """
- The alias used to reference the value list when writing rules.
- """
- contains: NotRequired[str]
- """
- A value contained within a value list - returns all value lists containing this value.
- """
- created: NotRequired["ValueList.ListParamsCreated|int"]
- """
- Only return value lists that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- alias: NotRequired[str]
- """
- The name of the value list for use in rules.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- The human-readable name of the value list.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
alias: str
"""
The name of the value list for use in rules.
@@ -201,7 +96,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["ValueList.CreateParams"]) -> "ValueList":
+ def create(cls, **params: Unpack["ValueListCreateParams"]) -> "ValueList":
"""
Creates a new ValueList object, which can then be referenced in rules.
"""
@@ -216,7 +111,7 @@ def create(cls, **params: Unpack["ValueList.CreateParams"]) -> "ValueList":
@classmethod
async def create_async(
- cls, **params: Unpack["ValueList.CreateParams"]
+ cls, **params: Unpack["ValueListCreateParams"]
) -> "ValueList":
"""
Creates a new ValueList object, which can then be referenced in rules.
@@ -232,7 +127,7 @@ async def create_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["ValueList.DeleteParams"]
+ cls, sid: str, **params: Unpack["ValueListDeleteParams"]
) -> "ValueList":
"""
Deletes a ValueList object, also deleting any items contained within the value list. To be deleted, a value list must not be referenced in any rules.
@@ -250,7 +145,7 @@ def _cls_delete(
@overload
@staticmethod
def delete(
- sid: str, **params: Unpack["ValueList.DeleteParams"]
+ sid: str, **params: Unpack["ValueListDeleteParams"]
) -> "ValueList":
"""
Deletes a ValueList object, also deleting any items contained within the value list. To be deleted, a value list must not be referenced in any rules.
@@ -258,9 +153,7 @@ def delete(
...
@overload
- def delete(
- self, **params: Unpack["ValueList.DeleteParams"]
- ) -> "ValueList":
+ def delete(self, **params: Unpack["ValueListDeleteParams"]) -> "ValueList":
"""
Deletes a ValueList object, also deleting any items contained within the value list. To be deleted, a value list must not be referenced in any rules.
"""
@@ -268,7 +161,7 @@ def delete(
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["ValueList.DeleteParams"]
+ self, **params: Unpack["ValueListDeleteParams"]
) -> "ValueList":
"""
Deletes a ValueList object, also deleting any items contained within the value list. To be deleted, a value list must not be referenced in any rules.
@@ -281,7 +174,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["ValueList.DeleteParams"]
+ cls, sid: str, **params: Unpack["ValueListDeleteParams"]
) -> "ValueList":
"""
Deletes a ValueList object, also deleting any items contained within the value list. To be deleted, a value list must not be referenced in any rules.
@@ -299,7 +192,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["ValueList.DeleteParams"]
+ sid: str, **params: Unpack["ValueListDeleteParams"]
) -> "ValueList":
"""
Deletes a ValueList object, also deleting any items contained within the value list. To be deleted, a value list must not be referenced in any rules.
@@ -308,7 +201,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["ValueList.DeleteParams"]
+ self, **params: Unpack["ValueListDeleteParams"]
) -> "ValueList":
"""
Deletes a ValueList object, also deleting any items contained within the value list. To be deleted, a value list must not be referenced in any rules.
@@ -317,7 +210,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["ValueList.DeleteParams"]
+ self, **params: Unpack["ValueListDeleteParams"]
) -> "ValueList":
"""
Deletes a ValueList object, also deleting any items contained within the value list. To be deleted, a value list must not be referenced in any rules.
@@ -330,7 +223,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["ValueList.ListParams"]
+ cls, **params: Unpack["ValueListListParams"]
) -> ListObject["ValueList"]:
"""
Returns a list of ValueList objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -350,7 +243,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["ValueList.ListParams"]
+ cls, **params: Unpack["ValueListListParams"]
) -> ListObject["ValueList"]:
"""
Returns a list of ValueList objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -370,7 +263,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["ValueList.ModifyParams"]
+ cls, id: str, **params: Unpack["ValueListModifyParams"]
) -> "ValueList":
"""
Updates a ValueList object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. Note that item_type is immutable.
@@ -387,7 +280,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["ValueList.ModifyParams"]
+ cls, id: str, **params: Unpack["ValueListModifyParams"]
) -> "ValueList":
"""
Updates a ValueList object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. Note that item_type is immutable.
@@ -404,7 +297,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["ValueList.RetrieveParams"]
+ cls, id: str, **params: Unpack["ValueListRetrieveParams"]
) -> "ValueList":
"""
Retrieves a ValueList object.
@@ -415,7 +308,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["ValueList.RetrieveParams"]
+ cls, id: str, **params: Unpack["ValueListRetrieveParams"]
) -> "ValueList":
"""
Retrieves a ValueList object.
diff --git a/stripe/radar/_value_list_item.py b/stripe/radar/_value_list_item.py
index bac22806e..6ef11fe6f 100644
--- a/stripe/radar/_value_list_item.py
+++ b/stripe/radar/_value_list_item.py
@@ -4,10 +4,23 @@
from stripe._deletable_api_resource import DeletableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, List, Optional, cast, overload
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing import ClassVar, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.radar._value_list_item_create_params import (
+ ValueListItemCreateParams,
+ )
+ from stripe.params.radar._value_list_item_delete_params import (
+ ValueListItemDeleteParams,
+ )
+ from stripe.params.radar._value_list_item_list_params import (
+ ValueListItemListParams,
+ )
+ from stripe.params.radar._value_list_item_retrieve_params import (
+ ValueListItemRetrieveParams,
+ )
class ValueListItem(
@@ -24,78 +37,6 @@ class ValueListItem(
OBJECT_NAME: ClassVar[Literal["radar.value_list_item"]] = (
"radar.value_list_item"
)
-
- class CreateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- value: str
- """
- The value of the item (whose type must match the type of the parent value list).
- """
- value_list: str
- """
- The identifier of the value list which the created item will be added to.
- """
-
- class DeleteParams(RequestOptions):
- pass
-
- class ListParams(RequestOptions):
- created: NotRequired["ValueListItem.ListParamsCreated|int"]
- """
- Only return items that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- value: NotRequired[str]
- """
- Return items belonging to the parent list whose value matches the specified value (using an "is like" match).
- """
- value_list: str
- """
- Identifier for the parent value list this item belongs to.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -131,7 +72,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["ValueListItem.CreateParams"]
+ cls, **params: Unpack["ValueListItemCreateParams"]
) -> "ValueListItem":
"""
Creates a new ValueListItem object, which is added to the specified parent value list.
@@ -147,7 +88,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["ValueListItem.CreateParams"]
+ cls, **params: Unpack["ValueListItemCreateParams"]
) -> "ValueListItem":
"""
Creates a new ValueListItem object, which is added to the specified parent value list.
@@ -163,7 +104,7 @@ async def create_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["ValueListItem.DeleteParams"]
+ cls, sid: str, **params: Unpack["ValueListItemDeleteParams"]
) -> "ValueListItem":
"""
Deletes a ValueListItem object, removing it from its parent value list.
@@ -181,7 +122,7 @@ def _cls_delete(
@overload
@staticmethod
def delete(
- sid: str, **params: Unpack["ValueListItem.DeleteParams"]
+ sid: str, **params: Unpack["ValueListItemDeleteParams"]
) -> "ValueListItem":
"""
Deletes a ValueListItem object, removing it from its parent value list.
@@ -190,7 +131,7 @@ def delete(
@overload
def delete(
- self, **params: Unpack["ValueListItem.DeleteParams"]
+ self, **params: Unpack["ValueListItemDeleteParams"]
) -> "ValueListItem":
"""
Deletes a ValueListItem object, removing it from its parent value list.
@@ -199,7 +140,7 @@ def delete(
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["ValueListItem.DeleteParams"]
+ self, **params: Unpack["ValueListItemDeleteParams"]
) -> "ValueListItem":
"""
Deletes a ValueListItem object, removing it from its parent value list.
@@ -212,7 +153,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["ValueListItem.DeleteParams"]
+ cls, sid: str, **params: Unpack["ValueListItemDeleteParams"]
) -> "ValueListItem":
"""
Deletes a ValueListItem object, removing it from its parent value list.
@@ -230,7 +171,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["ValueListItem.DeleteParams"]
+ sid: str, **params: Unpack["ValueListItemDeleteParams"]
) -> "ValueListItem":
"""
Deletes a ValueListItem object, removing it from its parent value list.
@@ -239,7 +180,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["ValueListItem.DeleteParams"]
+ self, **params: Unpack["ValueListItemDeleteParams"]
) -> "ValueListItem":
"""
Deletes a ValueListItem object, removing it from its parent value list.
@@ -248,7 +189,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["ValueListItem.DeleteParams"]
+ self, **params: Unpack["ValueListItemDeleteParams"]
) -> "ValueListItem":
"""
Deletes a ValueListItem object, removing it from its parent value list.
@@ -261,7 +202,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["ValueListItem.ListParams"]
+ cls, **params: Unpack["ValueListItemListParams"]
) -> ListObject["ValueListItem"]:
"""
Returns a list of ValueListItem objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -281,7 +222,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["ValueListItem.ListParams"]
+ cls, **params: Unpack["ValueListItemListParams"]
) -> ListObject["ValueListItem"]:
"""
Returns a list of ValueListItem objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
@@ -301,7 +242,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["ValueListItem.RetrieveParams"]
+ cls, id: str, **params: Unpack["ValueListItemRetrieveParams"]
) -> "ValueListItem":
"""
Retrieves a ValueListItem object.
@@ -312,7 +253,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["ValueListItem.RetrieveParams"]
+ cls, id: str, **params: Unpack["ValueListItemRetrieveParams"]
) -> "ValueListItem":
"""
Retrieves a ValueListItem object.
diff --git a/stripe/radar/_value_list_item_service.py b/stripe/radar/_value_list_item_service.py
index bc846f1a6..3d1868bd5 100644
--- a/stripe/radar/_value_list_item_service.py
+++ b/stripe/radar/_value_list_item_service.py
@@ -5,86 +5,29 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.radar._value_list_item import ValueListItem
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.radar._value_list_item_create_params import (
+ ValueListItemCreateParams,
+ )
+ from stripe.params.radar._value_list_item_delete_params import (
+ ValueListItemDeleteParams,
+ )
+ from stripe.params.radar._value_list_item_list_params import (
+ ValueListItemListParams,
+ )
+ from stripe.params.radar._value_list_item_retrieve_params import (
+ ValueListItemRetrieveParams,
+ )
-class ValueListItemService(StripeService):
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- value: str
- """
- The value of the item (whose type must match the type of the parent value list).
- """
- value_list: str
- """
- The identifier of the value list which the created item will be added to.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- created: NotRequired["ValueListItemService.ListParamsCreated|int"]
- """
- Only return items that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- value: NotRequired[str]
- """
- Return items belonging to the parent list whose value matches the specified value (using an "is like" match).
- """
- value_list: str
- """
- Identifier for the parent value list this item belongs to.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class ValueListItemService(StripeService):
def delete(
self,
item: str,
- params: Optional["ValueListItemService.DeleteParams"] = None,
+ params: Optional["ValueListItemDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> ValueListItem:
"""
@@ -106,7 +49,7 @@ def delete(
async def delete_async(
self,
item: str,
- params: Optional["ValueListItemService.DeleteParams"] = None,
+ params: Optional["ValueListItemDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> ValueListItem:
"""
@@ -128,7 +71,7 @@ async def delete_async(
def retrieve(
self,
item: str,
- params: Optional["ValueListItemService.RetrieveParams"] = None,
+ params: Optional["ValueListItemRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ValueListItem:
"""
@@ -150,7 +93,7 @@ def retrieve(
async def retrieve_async(
self,
item: str,
- params: Optional["ValueListItemService.RetrieveParams"] = None,
+ params: Optional["ValueListItemRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ValueListItem:
"""
@@ -171,7 +114,7 @@ async def retrieve_async(
def list(
self,
- params: "ValueListItemService.ListParams",
+ params: "ValueListItemListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[ValueListItem]:
"""
@@ -190,7 +133,7 @@ def list(
async def list_async(
self,
- params: "ValueListItemService.ListParams",
+ params: "ValueListItemListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[ValueListItem]:
"""
@@ -209,7 +152,7 @@ async def list_async(
def create(
self,
- params: "ValueListItemService.CreateParams",
+ params: "ValueListItemCreateParams",
options: Optional[RequestOptions] = None,
) -> ValueListItem:
"""
@@ -228,7 +171,7 @@ def create(
async def create_async(
self,
- params: "ValueListItemService.CreateParams",
+ params: "ValueListItemCreateParams",
options: Optional[RequestOptions] = None,
) -> ValueListItem:
"""
diff --git a/stripe/radar/_value_list_service.py b/stripe/radar/_value_list_service.py
index 0471ea1ed..83d292431 100644
--- a/stripe/radar/_value_list_service.py
+++ b/stripe/radar/_value_list_service.py
@@ -5,125 +5,30 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.radar._value_list import ValueList
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.radar._value_list_create_params import (
+ ValueListCreateParams,
+ )
+ from stripe.params.radar._value_list_delete_params import (
+ ValueListDeleteParams,
+ )
+ from stripe.params.radar._value_list_list_params import ValueListListParams
+ from stripe.params.radar._value_list_retrieve_params import (
+ ValueListRetrieveParams,
+ )
+ from stripe.params.radar._value_list_update_params import (
+ ValueListUpdateParams,
+ )
class ValueListService(StripeService):
- class CreateParams(TypedDict):
- alias: str
- """
- The name of the value list for use in rules.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- item_type: NotRequired[
- Literal[
- "card_bin",
- "card_fingerprint",
- "case_sensitive_string",
- "country",
- "customer_id",
- "email",
- "ip_address",
- "sepa_debit_fingerprint",
- "string",
- "us_bank_account_fingerprint",
- ]
- ]
- """
- Type of the items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, `case_sensitive_string`, `customer_id`, `sepa_debit_fingerprint`, or `us_bank_account_fingerprint`. Use `string` if the item type is unknown or mixed.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: str
- """
- The human-readable name of the value list.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- alias: NotRequired[str]
- """
- The alias used to reference the value list when writing rules.
- """
- contains: NotRequired[str]
- """
- A value contained within a value list - returns all value lists containing this value.
- """
- created: NotRequired["ValueListService.ListParamsCreated|int"]
- """
- Only return value lists that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- alias: NotRequired[str]
- """
- The name of the value list for use in rules.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- name: NotRequired[str]
- """
- The human-readable name of the value list.
- """
-
def delete(
self,
value_list: str,
- params: Optional["ValueListService.DeleteParams"] = None,
+ params: Optional["ValueListDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> ValueList:
"""
@@ -145,7 +50,7 @@ def delete(
async def delete_async(
self,
value_list: str,
- params: Optional["ValueListService.DeleteParams"] = None,
+ params: Optional["ValueListDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> ValueList:
"""
@@ -167,7 +72,7 @@ async def delete_async(
def retrieve(
self,
value_list: str,
- params: Optional["ValueListService.RetrieveParams"] = None,
+ params: Optional["ValueListRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ValueList:
"""
@@ -189,7 +94,7 @@ def retrieve(
async def retrieve_async(
self,
value_list: str,
- params: Optional["ValueListService.RetrieveParams"] = None,
+ params: Optional["ValueListRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ValueList:
"""
@@ -211,7 +116,7 @@ async def retrieve_async(
def update(
self,
value_list: str,
- params: Optional["ValueListService.UpdateParams"] = None,
+ params: Optional["ValueListUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> ValueList:
"""
@@ -233,7 +138,7 @@ def update(
async def update_async(
self,
value_list: str,
- params: Optional["ValueListService.UpdateParams"] = None,
+ params: Optional["ValueListUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> ValueList:
"""
@@ -254,7 +159,7 @@ async def update_async(
def list(
self,
- params: Optional["ValueListService.ListParams"] = None,
+ params: Optional["ValueListListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ValueList]:
"""
@@ -273,7 +178,7 @@ def list(
async def list_async(
self,
- params: Optional["ValueListService.ListParams"] = None,
+ params: Optional["ValueListListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ValueList]:
"""
@@ -292,7 +197,7 @@ async def list_async(
def create(
self,
- params: "ValueListService.CreateParams",
+ params: "ValueListCreateParams",
options: Optional[RequestOptions] = None,
) -> ValueList:
"""
@@ -311,7 +216,7 @@ def create(
async def create_async(
self,
- params: "ValueListService.CreateParams",
+ params: "ValueListCreateParams",
options: Optional[RequestOptions] = None,
) -> ValueList:
"""
diff --git a/stripe/reporting/_report_run.py b/stripe/reporting/_report_run.py
index 49495e3c3..aba84bc9a 100644
--- a/stripe/reporting/_report_run.py
+++ b/stripe/reporting/_report_run.py
@@ -3,19 +3,21 @@
from stripe._createable_api_resource import CreateableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from typing import ClassVar, List, Optional, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._file import File
+ from stripe.params.reporting._report_run_create_params import (
+ ReportRunCreateParams,
+ )
+ from stripe.params.reporting._report_run_list_params import (
+ ReportRunListParams,
+ )
+ from stripe.params.reporting._report_run_retrieve_params import (
+ ReportRunRetrieveParams,
+ )
class ReportRun(
@@ -71,742 +73,6 @@ class Parameters(StripeObject):
Defaults to `Etc/UTC`. The output timezone for all timestamps in the report. A list of possible time zone values is maintained at the [IANA Time Zone Database](http://www.iana.org/time-zones). Has no effect on `interval_start` or `interval_end`.
"""
- class CreateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- parameters: NotRequired["ReportRun.CreateParamsParameters"]
- """
- Parameters specifying how the report should be run. Different Report Types have different required and optional parameters, listed in the [API Access to Reports](https://stripe.com/docs/reporting/statements/api) documentation.
- """
- report_type: str
- """
- The ID of the [report type](https://stripe.com/docs/reporting/statements/api#report-types) to run, such as `"balance.summary.1"`.
- """
-
- class CreateParamsParameters(TypedDict):
- columns: NotRequired[List[str]]
- """
- The set of report columns to include in the report output. If omitted, the Report Type is run with its default column set.
- """
- connected_account: NotRequired[str]
- """
- Connected account ID to filter for in the report run.
- """
- currency: NotRequired[str]
- """
- Currency of objects to be included in the report run.
- """
- interval_end: NotRequired[int]
- """
- Ending timestamp of data to be included in the report run (exclusive).
- """
- interval_start: NotRequired[int]
- """
- Starting timestamp of data to be included in the report run.
- """
- payout: NotRequired[str]
- """
- Payout ID by which to filter the report run.
- """
- reporting_category: NotRequired[
- Literal[
- "advance",
- "advance_funding",
- "anticipation_repayment",
- "charge",
- "charge_failure",
- "climate_order_purchase",
- "climate_order_refund",
- "connect_collection_transfer",
- "connect_reserved_funds",
- "contribution",
- "dispute",
- "dispute_reversal",
- "fee",
- "financing_paydown",
- "financing_paydown_reversal",
- "financing_payout",
- "financing_payout_reversal",
- "issuing_authorization_hold",
- "issuing_authorization_release",
- "issuing_dispute",
- "issuing_transaction",
- "network_cost",
- "other_adjustment",
- "partial_capture_reversal",
- "payout",
- "payout_reversal",
- "platform_earning",
- "platform_earning_refund",
- "refund",
- "refund_failure",
- "risk_reserved_funds",
- "tax",
- "topup",
- "topup_reversal",
- "transfer",
- "transfer_reversal",
- "unreconciled_customer_funds",
- ]
- ]
- """
- Category of balance transactions to be included in the report run.
- """
- timezone: NotRequired[
- Literal[
- "Africa/Abidjan",
- "Africa/Accra",
- "Africa/Addis_Ababa",
- "Africa/Algiers",
- "Africa/Asmara",
- "Africa/Asmera",
- "Africa/Bamako",
- "Africa/Bangui",
- "Africa/Banjul",
- "Africa/Bissau",
- "Africa/Blantyre",
- "Africa/Brazzaville",
- "Africa/Bujumbura",
- "Africa/Cairo",
- "Africa/Casablanca",
- "Africa/Ceuta",
- "Africa/Conakry",
- "Africa/Dakar",
- "Africa/Dar_es_Salaam",
- "Africa/Djibouti",
- "Africa/Douala",
- "Africa/El_Aaiun",
- "Africa/Freetown",
- "Africa/Gaborone",
- "Africa/Harare",
- "Africa/Johannesburg",
- "Africa/Juba",
- "Africa/Kampala",
- "Africa/Khartoum",
- "Africa/Kigali",
- "Africa/Kinshasa",
- "Africa/Lagos",
- "Africa/Libreville",
- "Africa/Lome",
- "Africa/Luanda",
- "Africa/Lubumbashi",
- "Africa/Lusaka",
- "Africa/Malabo",
- "Africa/Maputo",
- "Africa/Maseru",
- "Africa/Mbabane",
- "Africa/Mogadishu",
- "Africa/Monrovia",
- "Africa/Nairobi",
- "Africa/Ndjamena",
- "Africa/Niamey",
- "Africa/Nouakchott",
- "Africa/Ouagadougou",
- "Africa/Porto-Novo",
- "Africa/Sao_Tome",
- "Africa/Timbuktu",
- "Africa/Tripoli",
- "Africa/Tunis",
- "Africa/Windhoek",
- "America/Adak",
- "America/Anchorage",
- "America/Anguilla",
- "America/Antigua",
- "America/Araguaina",
- "America/Argentina/Buenos_Aires",
- "America/Argentina/Catamarca",
- "America/Argentina/ComodRivadavia",
- "America/Argentina/Cordoba",
- "America/Argentina/Jujuy",
- "America/Argentina/La_Rioja",
- "America/Argentina/Mendoza",
- "America/Argentina/Rio_Gallegos",
- "America/Argentina/Salta",
- "America/Argentina/San_Juan",
- "America/Argentina/San_Luis",
- "America/Argentina/Tucuman",
- "America/Argentina/Ushuaia",
- "America/Aruba",
- "America/Asuncion",
- "America/Atikokan",
- "America/Atka",
- "America/Bahia",
- "America/Bahia_Banderas",
- "America/Barbados",
- "America/Belem",
- "America/Belize",
- "America/Blanc-Sablon",
- "America/Boa_Vista",
- "America/Bogota",
- "America/Boise",
- "America/Buenos_Aires",
- "America/Cambridge_Bay",
- "America/Campo_Grande",
- "America/Cancun",
- "America/Caracas",
- "America/Catamarca",
- "America/Cayenne",
- "America/Cayman",
- "America/Chicago",
- "America/Chihuahua",
- "America/Ciudad_Juarez",
- "America/Coral_Harbour",
- "America/Cordoba",
- "America/Costa_Rica",
- "America/Coyhaique",
- "America/Creston",
- "America/Cuiaba",
- "America/Curacao",
- "America/Danmarkshavn",
- "America/Dawson",
- "America/Dawson_Creek",
- "America/Denver",
- "America/Detroit",
- "America/Dominica",
- "America/Edmonton",
- "America/Eirunepe",
- "America/El_Salvador",
- "America/Ensenada",
- "America/Fort_Nelson",
- "America/Fort_Wayne",
- "America/Fortaleza",
- "America/Glace_Bay",
- "America/Godthab",
- "America/Goose_Bay",
- "America/Grand_Turk",
- "America/Grenada",
- "America/Guadeloupe",
- "America/Guatemala",
- "America/Guayaquil",
- "America/Guyana",
- "America/Halifax",
- "America/Havana",
- "America/Hermosillo",
- "America/Indiana/Indianapolis",
- "America/Indiana/Knox",
- "America/Indiana/Marengo",
- "America/Indiana/Petersburg",
- "America/Indiana/Tell_City",
- "America/Indiana/Vevay",
- "America/Indiana/Vincennes",
- "America/Indiana/Winamac",
- "America/Indianapolis",
- "America/Inuvik",
- "America/Iqaluit",
- "America/Jamaica",
- "America/Jujuy",
- "America/Juneau",
- "America/Kentucky/Louisville",
- "America/Kentucky/Monticello",
- "America/Knox_IN",
- "America/Kralendijk",
- "America/La_Paz",
- "America/Lima",
- "America/Los_Angeles",
- "America/Louisville",
- "America/Lower_Princes",
- "America/Maceio",
- "America/Managua",
- "America/Manaus",
- "America/Marigot",
- "America/Martinique",
- "America/Matamoros",
- "America/Mazatlan",
- "America/Mendoza",
- "America/Menominee",
- "America/Merida",
- "America/Metlakatla",
- "America/Mexico_City",
- "America/Miquelon",
- "America/Moncton",
- "America/Monterrey",
- "America/Montevideo",
- "America/Montreal",
- "America/Montserrat",
- "America/Nassau",
- "America/New_York",
- "America/Nipigon",
- "America/Nome",
- "America/Noronha",
- "America/North_Dakota/Beulah",
- "America/North_Dakota/Center",
- "America/North_Dakota/New_Salem",
- "America/Nuuk",
- "America/Ojinaga",
- "America/Panama",
- "America/Pangnirtung",
- "America/Paramaribo",
- "America/Phoenix",
- "America/Port-au-Prince",
- "America/Port_of_Spain",
- "America/Porto_Acre",
- "America/Porto_Velho",
- "America/Puerto_Rico",
- "America/Punta_Arenas",
- "America/Rainy_River",
- "America/Rankin_Inlet",
- "America/Recife",
- "America/Regina",
- "America/Resolute",
- "America/Rio_Branco",
- "America/Rosario",
- "America/Santa_Isabel",
- "America/Santarem",
- "America/Santiago",
- "America/Santo_Domingo",
- "America/Sao_Paulo",
- "America/Scoresbysund",
- "America/Shiprock",
- "America/Sitka",
- "America/St_Barthelemy",
- "America/St_Johns",
- "America/St_Kitts",
- "America/St_Lucia",
- "America/St_Thomas",
- "America/St_Vincent",
- "America/Swift_Current",
- "America/Tegucigalpa",
- "America/Thule",
- "America/Thunder_Bay",
- "America/Tijuana",
- "America/Toronto",
- "America/Tortola",
- "America/Vancouver",
- "America/Virgin",
- "America/Whitehorse",
- "America/Winnipeg",
- "America/Yakutat",
- "America/Yellowknife",
- "Antarctica/Casey",
- "Antarctica/Davis",
- "Antarctica/DumontDUrville",
- "Antarctica/Macquarie",
- "Antarctica/Mawson",
- "Antarctica/McMurdo",
- "Antarctica/Palmer",
- "Antarctica/Rothera",
- "Antarctica/South_Pole",
- "Antarctica/Syowa",
- "Antarctica/Troll",
- "Antarctica/Vostok",
- "Arctic/Longyearbyen",
- "Asia/Aden",
- "Asia/Almaty",
- "Asia/Amman",
- "Asia/Anadyr",
- "Asia/Aqtau",
- "Asia/Aqtobe",
- "Asia/Ashgabat",
- "Asia/Ashkhabad",
- "Asia/Atyrau",
- "Asia/Baghdad",
- "Asia/Bahrain",
- "Asia/Baku",
- "Asia/Bangkok",
- "Asia/Barnaul",
- "Asia/Beirut",
- "Asia/Bishkek",
- "Asia/Brunei",
- "Asia/Calcutta",
- "Asia/Chita",
- "Asia/Choibalsan",
- "Asia/Chongqing",
- "Asia/Chungking",
- "Asia/Colombo",
- "Asia/Dacca",
- "Asia/Damascus",
- "Asia/Dhaka",
- "Asia/Dili",
- "Asia/Dubai",
- "Asia/Dushanbe",
- "Asia/Famagusta",
- "Asia/Gaza",
- "Asia/Harbin",
- "Asia/Hebron",
- "Asia/Ho_Chi_Minh",
- "Asia/Hong_Kong",
- "Asia/Hovd",
- "Asia/Irkutsk",
- "Asia/Istanbul",
- "Asia/Jakarta",
- "Asia/Jayapura",
- "Asia/Jerusalem",
- "Asia/Kabul",
- "Asia/Kamchatka",
- "Asia/Karachi",
- "Asia/Kashgar",
- "Asia/Kathmandu",
- "Asia/Katmandu",
- "Asia/Khandyga",
- "Asia/Kolkata",
- "Asia/Krasnoyarsk",
- "Asia/Kuala_Lumpur",
- "Asia/Kuching",
- "Asia/Kuwait",
- "Asia/Macao",
- "Asia/Macau",
- "Asia/Magadan",
- "Asia/Makassar",
- "Asia/Manila",
- "Asia/Muscat",
- "Asia/Nicosia",
- "Asia/Novokuznetsk",
- "Asia/Novosibirsk",
- "Asia/Omsk",
- "Asia/Oral",
- "Asia/Phnom_Penh",
- "Asia/Pontianak",
- "Asia/Pyongyang",
- "Asia/Qatar",
- "Asia/Qostanay",
- "Asia/Qyzylorda",
- "Asia/Rangoon",
- "Asia/Riyadh",
- "Asia/Saigon",
- "Asia/Sakhalin",
- "Asia/Samarkand",
- "Asia/Seoul",
- "Asia/Shanghai",
- "Asia/Singapore",
- "Asia/Srednekolymsk",
- "Asia/Taipei",
- "Asia/Tashkent",
- "Asia/Tbilisi",
- "Asia/Tehran",
- "Asia/Tel_Aviv",
- "Asia/Thimbu",
- "Asia/Thimphu",
- "Asia/Tokyo",
- "Asia/Tomsk",
- "Asia/Ujung_Pandang",
- "Asia/Ulaanbaatar",
- "Asia/Ulan_Bator",
- "Asia/Urumqi",
- "Asia/Ust-Nera",
- "Asia/Vientiane",
- "Asia/Vladivostok",
- "Asia/Yakutsk",
- "Asia/Yangon",
- "Asia/Yekaterinburg",
- "Asia/Yerevan",
- "Atlantic/Azores",
- "Atlantic/Bermuda",
- "Atlantic/Canary",
- "Atlantic/Cape_Verde",
- "Atlantic/Faeroe",
- "Atlantic/Faroe",
- "Atlantic/Jan_Mayen",
- "Atlantic/Madeira",
- "Atlantic/Reykjavik",
- "Atlantic/South_Georgia",
- "Atlantic/St_Helena",
- "Atlantic/Stanley",
- "Australia/ACT",
- "Australia/Adelaide",
- "Australia/Brisbane",
- "Australia/Broken_Hill",
- "Australia/Canberra",
- "Australia/Currie",
- "Australia/Darwin",
- "Australia/Eucla",
- "Australia/Hobart",
- "Australia/LHI",
- "Australia/Lindeman",
- "Australia/Lord_Howe",
- "Australia/Melbourne",
- "Australia/NSW",
- "Australia/North",
- "Australia/Perth",
- "Australia/Queensland",
- "Australia/South",
- "Australia/Sydney",
- "Australia/Tasmania",
- "Australia/Victoria",
- "Australia/West",
- "Australia/Yancowinna",
- "Brazil/Acre",
- "Brazil/DeNoronha",
- "Brazil/East",
- "Brazil/West",
- "CET",
- "CST6CDT",
- "Canada/Atlantic",
- "Canada/Central",
- "Canada/Eastern",
- "Canada/Mountain",
- "Canada/Newfoundland",
- "Canada/Pacific",
- "Canada/Saskatchewan",
- "Canada/Yukon",
- "Chile/Continental",
- "Chile/EasterIsland",
- "Cuba",
- "EET",
- "EST",
- "EST5EDT",
- "Egypt",
- "Eire",
- "Etc/GMT",
- "Etc/GMT+0",
- "Etc/GMT+1",
- "Etc/GMT+10",
- "Etc/GMT+11",
- "Etc/GMT+12",
- "Etc/GMT+2",
- "Etc/GMT+3",
- "Etc/GMT+4",
- "Etc/GMT+5",
- "Etc/GMT+6",
- "Etc/GMT+7",
- "Etc/GMT+8",
- "Etc/GMT+9",
- "Etc/GMT-0",
- "Etc/GMT-1",
- "Etc/GMT-10",
- "Etc/GMT-11",
- "Etc/GMT-12",
- "Etc/GMT-13",
- "Etc/GMT-14",
- "Etc/GMT-2",
- "Etc/GMT-3",
- "Etc/GMT-4",
- "Etc/GMT-5",
- "Etc/GMT-6",
- "Etc/GMT-7",
- "Etc/GMT-8",
- "Etc/GMT-9",
- "Etc/GMT0",
- "Etc/Greenwich",
- "Etc/UCT",
- "Etc/UTC",
- "Etc/Universal",
- "Etc/Zulu",
- "Europe/Amsterdam",
- "Europe/Andorra",
- "Europe/Astrakhan",
- "Europe/Athens",
- "Europe/Belfast",
- "Europe/Belgrade",
- "Europe/Berlin",
- "Europe/Bratislava",
- "Europe/Brussels",
- "Europe/Bucharest",
- "Europe/Budapest",
- "Europe/Busingen",
- "Europe/Chisinau",
- "Europe/Copenhagen",
- "Europe/Dublin",
- "Europe/Gibraltar",
- "Europe/Guernsey",
- "Europe/Helsinki",
- "Europe/Isle_of_Man",
- "Europe/Istanbul",
- "Europe/Jersey",
- "Europe/Kaliningrad",
- "Europe/Kiev",
- "Europe/Kirov",
- "Europe/Kyiv",
- "Europe/Lisbon",
- "Europe/Ljubljana",
- "Europe/London",
- "Europe/Luxembourg",
- "Europe/Madrid",
- "Europe/Malta",
- "Europe/Mariehamn",
- "Europe/Minsk",
- "Europe/Monaco",
- "Europe/Moscow",
- "Europe/Nicosia",
- "Europe/Oslo",
- "Europe/Paris",
- "Europe/Podgorica",
- "Europe/Prague",
- "Europe/Riga",
- "Europe/Rome",
- "Europe/Samara",
- "Europe/San_Marino",
- "Europe/Sarajevo",
- "Europe/Saratov",
- "Europe/Simferopol",
- "Europe/Skopje",
- "Europe/Sofia",
- "Europe/Stockholm",
- "Europe/Tallinn",
- "Europe/Tirane",
- "Europe/Tiraspol",
- "Europe/Ulyanovsk",
- "Europe/Uzhgorod",
- "Europe/Vaduz",
- "Europe/Vatican",
- "Europe/Vienna",
- "Europe/Vilnius",
- "Europe/Volgograd",
- "Europe/Warsaw",
- "Europe/Zagreb",
- "Europe/Zaporozhye",
- "Europe/Zurich",
- "Factory",
- "GB",
- "GB-Eire",
- "GMT",
- "GMT+0",
- "GMT-0",
- "GMT0",
- "Greenwich",
- "HST",
- "Hongkong",
- "Iceland",
- "Indian/Antananarivo",
- "Indian/Chagos",
- "Indian/Christmas",
- "Indian/Cocos",
- "Indian/Comoro",
- "Indian/Kerguelen",
- "Indian/Mahe",
- "Indian/Maldives",
- "Indian/Mauritius",
- "Indian/Mayotte",
- "Indian/Reunion",
- "Iran",
- "Israel",
- "Jamaica",
- "Japan",
- "Kwajalein",
- "Libya",
- "MET",
- "MST",
- "MST7MDT",
- "Mexico/BajaNorte",
- "Mexico/BajaSur",
- "Mexico/General",
- "NZ",
- "NZ-CHAT",
- "Navajo",
- "PRC",
- "PST8PDT",
- "Pacific/Apia",
- "Pacific/Auckland",
- "Pacific/Bougainville",
- "Pacific/Chatham",
- "Pacific/Chuuk",
- "Pacific/Easter",
- "Pacific/Efate",
- "Pacific/Enderbury",
- "Pacific/Fakaofo",
- "Pacific/Fiji",
- "Pacific/Funafuti",
- "Pacific/Galapagos",
- "Pacific/Gambier",
- "Pacific/Guadalcanal",
- "Pacific/Guam",
- "Pacific/Honolulu",
- "Pacific/Johnston",
- "Pacific/Kanton",
- "Pacific/Kiritimati",
- "Pacific/Kosrae",
- "Pacific/Kwajalein",
- "Pacific/Majuro",
- "Pacific/Marquesas",
- "Pacific/Midway",
- "Pacific/Nauru",
- "Pacific/Niue",
- "Pacific/Norfolk",
- "Pacific/Noumea",
- "Pacific/Pago_Pago",
- "Pacific/Palau",
- "Pacific/Pitcairn",
- "Pacific/Pohnpei",
- "Pacific/Ponape",
- "Pacific/Port_Moresby",
- "Pacific/Rarotonga",
- "Pacific/Saipan",
- "Pacific/Samoa",
- "Pacific/Tahiti",
- "Pacific/Tarawa",
- "Pacific/Tongatapu",
- "Pacific/Truk",
- "Pacific/Wake",
- "Pacific/Wallis",
- "Pacific/Yap",
- "Poland",
- "Portugal",
- "ROC",
- "ROK",
- "Singapore",
- "Turkey",
- "UCT",
- "US/Alaska",
- "US/Aleutian",
- "US/Arizona",
- "US/Central",
- "US/East-Indiana",
- "US/Eastern",
- "US/Hawaii",
- "US/Indiana-Starke",
- "US/Michigan",
- "US/Mountain",
- "US/Pacific",
- "US/Pacific-New",
- "US/Samoa",
- "UTC",
- "Universal",
- "W-SU",
- "WET",
- "Zulu",
- ]
- ]
- """
- Defaults to `Etc/UTC`. The output timezone for all timestamps in the report. A list of possible time zone values is maintained at the [IANA Time Zone Database](http://www.iana.org/time-zones). Has no effect on `interval_start` or `interval_end`.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["ReportRun.ListParamsCreated|int"]
- """
- Only return Report Runs that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -851,7 +117,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["ReportRun.CreateParams"]) -> "ReportRun":
+ def create(cls, **params: Unpack["ReportRunCreateParams"]) -> "ReportRun":
"""
Creates a new object and begin running the report. (Certain report types require a [live-mode API key](https://stripe.com/docs/keys#test-live-modes).)
"""
@@ -866,7 +132,7 @@ def create(cls, **params: Unpack["ReportRun.CreateParams"]) -> "ReportRun":
@classmethod
async def create_async(
- cls, **params: Unpack["ReportRun.CreateParams"]
+ cls, **params: Unpack["ReportRunCreateParams"]
) -> "ReportRun":
"""
Creates a new object and begin running the report. (Certain report types require a [live-mode API key](https://stripe.com/docs/keys#test-live-modes).)
@@ -882,7 +148,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["ReportRun.ListParams"]
+ cls, **params: Unpack["ReportRunListParams"]
) -> ListObject["ReportRun"]:
"""
Returns a list of Report Runs, with the most recent appearing first.
@@ -902,7 +168,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["ReportRun.ListParams"]
+ cls, **params: Unpack["ReportRunListParams"]
) -> ListObject["ReportRun"]:
"""
Returns a list of Report Runs, with the most recent appearing first.
@@ -922,7 +188,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["ReportRun.RetrieveParams"]
+ cls, id: str, **params: Unpack["ReportRunRetrieveParams"]
) -> "ReportRun":
"""
Retrieves the details of an existing Report Run.
@@ -933,7 +199,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["ReportRun.RetrieveParams"]
+ cls, id: str, **params: Unpack["ReportRunRetrieveParams"]
) -> "ReportRun":
"""
Retrieves the details of an existing Report Run.
diff --git a/stripe/reporting/_report_run_service.py b/stripe/reporting/_report_run_service.py
index 87524ecd8..e1a028e01 100644
--- a/stripe/reporting/_report_run_service.py
+++ b/stripe/reporting/_report_run_service.py
@@ -5,750 +5,25 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.reporting._report_run import ReportRun
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.reporting._report_run_create_params import (
+ ReportRunCreateParams,
+ )
+ from stripe.params.reporting._report_run_list_params import (
+ ReportRunListParams,
+ )
+ from stripe.params.reporting._report_run_retrieve_params import (
+ ReportRunRetrieveParams,
+ )
-class ReportRunService(StripeService):
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- parameters: NotRequired["ReportRunService.CreateParamsParameters"]
- """
- Parameters specifying how the report should be run. Different Report Types have different required and optional parameters, listed in the [API Access to Reports](https://stripe.com/docs/reporting/statements/api) documentation.
- """
- report_type: str
- """
- The ID of the [report type](https://stripe.com/docs/reporting/statements/api#report-types) to run, such as `"balance.summary.1"`.
- """
-
- class CreateParamsParameters(TypedDict):
- columns: NotRequired[List[str]]
- """
- The set of report columns to include in the report output. If omitted, the Report Type is run with its default column set.
- """
- connected_account: NotRequired[str]
- """
- Connected account ID to filter for in the report run.
- """
- currency: NotRequired[str]
- """
- Currency of objects to be included in the report run.
- """
- interval_end: NotRequired[int]
- """
- Ending timestamp of data to be included in the report run (exclusive).
- """
- interval_start: NotRequired[int]
- """
- Starting timestamp of data to be included in the report run.
- """
- payout: NotRequired[str]
- """
- Payout ID by which to filter the report run.
- """
- reporting_category: NotRequired[
- Literal[
- "advance",
- "advance_funding",
- "anticipation_repayment",
- "charge",
- "charge_failure",
- "climate_order_purchase",
- "climate_order_refund",
- "connect_collection_transfer",
- "connect_reserved_funds",
- "contribution",
- "dispute",
- "dispute_reversal",
- "fee",
- "financing_paydown",
- "financing_paydown_reversal",
- "financing_payout",
- "financing_payout_reversal",
- "issuing_authorization_hold",
- "issuing_authorization_release",
- "issuing_dispute",
- "issuing_transaction",
- "network_cost",
- "other_adjustment",
- "partial_capture_reversal",
- "payout",
- "payout_reversal",
- "platform_earning",
- "platform_earning_refund",
- "refund",
- "refund_failure",
- "risk_reserved_funds",
- "tax",
- "topup",
- "topup_reversal",
- "transfer",
- "transfer_reversal",
- "unreconciled_customer_funds",
- ]
- ]
- """
- Category of balance transactions to be included in the report run.
- """
- timezone: NotRequired[
- Literal[
- "Africa/Abidjan",
- "Africa/Accra",
- "Africa/Addis_Ababa",
- "Africa/Algiers",
- "Africa/Asmara",
- "Africa/Asmera",
- "Africa/Bamako",
- "Africa/Bangui",
- "Africa/Banjul",
- "Africa/Bissau",
- "Africa/Blantyre",
- "Africa/Brazzaville",
- "Africa/Bujumbura",
- "Africa/Cairo",
- "Africa/Casablanca",
- "Africa/Ceuta",
- "Africa/Conakry",
- "Africa/Dakar",
- "Africa/Dar_es_Salaam",
- "Africa/Djibouti",
- "Africa/Douala",
- "Africa/El_Aaiun",
- "Africa/Freetown",
- "Africa/Gaborone",
- "Africa/Harare",
- "Africa/Johannesburg",
- "Africa/Juba",
- "Africa/Kampala",
- "Africa/Khartoum",
- "Africa/Kigali",
- "Africa/Kinshasa",
- "Africa/Lagos",
- "Africa/Libreville",
- "Africa/Lome",
- "Africa/Luanda",
- "Africa/Lubumbashi",
- "Africa/Lusaka",
- "Africa/Malabo",
- "Africa/Maputo",
- "Africa/Maseru",
- "Africa/Mbabane",
- "Africa/Mogadishu",
- "Africa/Monrovia",
- "Africa/Nairobi",
- "Africa/Ndjamena",
- "Africa/Niamey",
- "Africa/Nouakchott",
- "Africa/Ouagadougou",
- "Africa/Porto-Novo",
- "Africa/Sao_Tome",
- "Africa/Timbuktu",
- "Africa/Tripoli",
- "Africa/Tunis",
- "Africa/Windhoek",
- "America/Adak",
- "America/Anchorage",
- "America/Anguilla",
- "America/Antigua",
- "America/Araguaina",
- "America/Argentina/Buenos_Aires",
- "America/Argentina/Catamarca",
- "America/Argentina/ComodRivadavia",
- "America/Argentina/Cordoba",
- "America/Argentina/Jujuy",
- "America/Argentina/La_Rioja",
- "America/Argentina/Mendoza",
- "America/Argentina/Rio_Gallegos",
- "America/Argentina/Salta",
- "America/Argentina/San_Juan",
- "America/Argentina/San_Luis",
- "America/Argentina/Tucuman",
- "America/Argentina/Ushuaia",
- "America/Aruba",
- "America/Asuncion",
- "America/Atikokan",
- "America/Atka",
- "America/Bahia",
- "America/Bahia_Banderas",
- "America/Barbados",
- "America/Belem",
- "America/Belize",
- "America/Blanc-Sablon",
- "America/Boa_Vista",
- "America/Bogota",
- "America/Boise",
- "America/Buenos_Aires",
- "America/Cambridge_Bay",
- "America/Campo_Grande",
- "America/Cancun",
- "America/Caracas",
- "America/Catamarca",
- "America/Cayenne",
- "America/Cayman",
- "America/Chicago",
- "America/Chihuahua",
- "America/Ciudad_Juarez",
- "America/Coral_Harbour",
- "America/Cordoba",
- "America/Costa_Rica",
- "America/Coyhaique",
- "America/Creston",
- "America/Cuiaba",
- "America/Curacao",
- "America/Danmarkshavn",
- "America/Dawson",
- "America/Dawson_Creek",
- "America/Denver",
- "America/Detroit",
- "America/Dominica",
- "America/Edmonton",
- "America/Eirunepe",
- "America/El_Salvador",
- "America/Ensenada",
- "America/Fort_Nelson",
- "America/Fort_Wayne",
- "America/Fortaleza",
- "America/Glace_Bay",
- "America/Godthab",
- "America/Goose_Bay",
- "America/Grand_Turk",
- "America/Grenada",
- "America/Guadeloupe",
- "America/Guatemala",
- "America/Guayaquil",
- "America/Guyana",
- "America/Halifax",
- "America/Havana",
- "America/Hermosillo",
- "America/Indiana/Indianapolis",
- "America/Indiana/Knox",
- "America/Indiana/Marengo",
- "America/Indiana/Petersburg",
- "America/Indiana/Tell_City",
- "America/Indiana/Vevay",
- "America/Indiana/Vincennes",
- "America/Indiana/Winamac",
- "America/Indianapolis",
- "America/Inuvik",
- "America/Iqaluit",
- "America/Jamaica",
- "America/Jujuy",
- "America/Juneau",
- "America/Kentucky/Louisville",
- "America/Kentucky/Monticello",
- "America/Knox_IN",
- "America/Kralendijk",
- "America/La_Paz",
- "America/Lima",
- "America/Los_Angeles",
- "America/Louisville",
- "America/Lower_Princes",
- "America/Maceio",
- "America/Managua",
- "America/Manaus",
- "America/Marigot",
- "America/Martinique",
- "America/Matamoros",
- "America/Mazatlan",
- "America/Mendoza",
- "America/Menominee",
- "America/Merida",
- "America/Metlakatla",
- "America/Mexico_City",
- "America/Miquelon",
- "America/Moncton",
- "America/Monterrey",
- "America/Montevideo",
- "America/Montreal",
- "America/Montserrat",
- "America/Nassau",
- "America/New_York",
- "America/Nipigon",
- "America/Nome",
- "America/Noronha",
- "America/North_Dakota/Beulah",
- "America/North_Dakota/Center",
- "America/North_Dakota/New_Salem",
- "America/Nuuk",
- "America/Ojinaga",
- "America/Panama",
- "America/Pangnirtung",
- "America/Paramaribo",
- "America/Phoenix",
- "America/Port-au-Prince",
- "America/Port_of_Spain",
- "America/Porto_Acre",
- "America/Porto_Velho",
- "America/Puerto_Rico",
- "America/Punta_Arenas",
- "America/Rainy_River",
- "America/Rankin_Inlet",
- "America/Recife",
- "America/Regina",
- "America/Resolute",
- "America/Rio_Branco",
- "America/Rosario",
- "America/Santa_Isabel",
- "America/Santarem",
- "America/Santiago",
- "America/Santo_Domingo",
- "America/Sao_Paulo",
- "America/Scoresbysund",
- "America/Shiprock",
- "America/Sitka",
- "America/St_Barthelemy",
- "America/St_Johns",
- "America/St_Kitts",
- "America/St_Lucia",
- "America/St_Thomas",
- "America/St_Vincent",
- "America/Swift_Current",
- "America/Tegucigalpa",
- "America/Thule",
- "America/Thunder_Bay",
- "America/Tijuana",
- "America/Toronto",
- "America/Tortola",
- "America/Vancouver",
- "America/Virgin",
- "America/Whitehorse",
- "America/Winnipeg",
- "America/Yakutat",
- "America/Yellowknife",
- "Antarctica/Casey",
- "Antarctica/Davis",
- "Antarctica/DumontDUrville",
- "Antarctica/Macquarie",
- "Antarctica/Mawson",
- "Antarctica/McMurdo",
- "Antarctica/Palmer",
- "Antarctica/Rothera",
- "Antarctica/South_Pole",
- "Antarctica/Syowa",
- "Antarctica/Troll",
- "Antarctica/Vostok",
- "Arctic/Longyearbyen",
- "Asia/Aden",
- "Asia/Almaty",
- "Asia/Amman",
- "Asia/Anadyr",
- "Asia/Aqtau",
- "Asia/Aqtobe",
- "Asia/Ashgabat",
- "Asia/Ashkhabad",
- "Asia/Atyrau",
- "Asia/Baghdad",
- "Asia/Bahrain",
- "Asia/Baku",
- "Asia/Bangkok",
- "Asia/Barnaul",
- "Asia/Beirut",
- "Asia/Bishkek",
- "Asia/Brunei",
- "Asia/Calcutta",
- "Asia/Chita",
- "Asia/Choibalsan",
- "Asia/Chongqing",
- "Asia/Chungking",
- "Asia/Colombo",
- "Asia/Dacca",
- "Asia/Damascus",
- "Asia/Dhaka",
- "Asia/Dili",
- "Asia/Dubai",
- "Asia/Dushanbe",
- "Asia/Famagusta",
- "Asia/Gaza",
- "Asia/Harbin",
- "Asia/Hebron",
- "Asia/Ho_Chi_Minh",
- "Asia/Hong_Kong",
- "Asia/Hovd",
- "Asia/Irkutsk",
- "Asia/Istanbul",
- "Asia/Jakarta",
- "Asia/Jayapura",
- "Asia/Jerusalem",
- "Asia/Kabul",
- "Asia/Kamchatka",
- "Asia/Karachi",
- "Asia/Kashgar",
- "Asia/Kathmandu",
- "Asia/Katmandu",
- "Asia/Khandyga",
- "Asia/Kolkata",
- "Asia/Krasnoyarsk",
- "Asia/Kuala_Lumpur",
- "Asia/Kuching",
- "Asia/Kuwait",
- "Asia/Macao",
- "Asia/Macau",
- "Asia/Magadan",
- "Asia/Makassar",
- "Asia/Manila",
- "Asia/Muscat",
- "Asia/Nicosia",
- "Asia/Novokuznetsk",
- "Asia/Novosibirsk",
- "Asia/Omsk",
- "Asia/Oral",
- "Asia/Phnom_Penh",
- "Asia/Pontianak",
- "Asia/Pyongyang",
- "Asia/Qatar",
- "Asia/Qostanay",
- "Asia/Qyzylorda",
- "Asia/Rangoon",
- "Asia/Riyadh",
- "Asia/Saigon",
- "Asia/Sakhalin",
- "Asia/Samarkand",
- "Asia/Seoul",
- "Asia/Shanghai",
- "Asia/Singapore",
- "Asia/Srednekolymsk",
- "Asia/Taipei",
- "Asia/Tashkent",
- "Asia/Tbilisi",
- "Asia/Tehran",
- "Asia/Tel_Aviv",
- "Asia/Thimbu",
- "Asia/Thimphu",
- "Asia/Tokyo",
- "Asia/Tomsk",
- "Asia/Ujung_Pandang",
- "Asia/Ulaanbaatar",
- "Asia/Ulan_Bator",
- "Asia/Urumqi",
- "Asia/Ust-Nera",
- "Asia/Vientiane",
- "Asia/Vladivostok",
- "Asia/Yakutsk",
- "Asia/Yangon",
- "Asia/Yekaterinburg",
- "Asia/Yerevan",
- "Atlantic/Azores",
- "Atlantic/Bermuda",
- "Atlantic/Canary",
- "Atlantic/Cape_Verde",
- "Atlantic/Faeroe",
- "Atlantic/Faroe",
- "Atlantic/Jan_Mayen",
- "Atlantic/Madeira",
- "Atlantic/Reykjavik",
- "Atlantic/South_Georgia",
- "Atlantic/St_Helena",
- "Atlantic/Stanley",
- "Australia/ACT",
- "Australia/Adelaide",
- "Australia/Brisbane",
- "Australia/Broken_Hill",
- "Australia/Canberra",
- "Australia/Currie",
- "Australia/Darwin",
- "Australia/Eucla",
- "Australia/Hobart",
- "Australia/LHI",
- "Australia/Lindeman",
- "Australia/Lord_Howe",
- "Australia/Melbourne",
- "Australia/NSW",
- "Australia/North",
- "Australia/Perth",
- "Australia/Queensland",
- "Australia/South",
- "Australia/Sydney",
- "Australia/Tasmania",
- "Australia/Victoria",
- "Australia/West",
- "Australia/Yancowinna",
- "Brazil/Acre",
- "Brazil/DeNoronha",
- "Brazil/East",
- "Brazil/West",
- "CET",
- "CST6CDT",
- "Canada/Atlantic",
- "Canada/Central",
- "Canada/Eastern",
- "Canada/Mountain",
- "Canada/Newfoundland",
- "Canada/Pacific",
- "Canada/Saskatchewan",
- "Canada/Yukon",
- "Chile/Continental",
- "Chile/EasterIsland",
- "Cuba",
- "EET",
- "EST",
- "EST5EDT",
- "Egypt",
- "Eire",
- "Etc/GMT",
- "Etc/GMT+0",
- "Etc/GMT+1",
- "Etc/GMT+10",
- "Etc/GMT+11",
- "Etc/GMT+12",
- "Etc/GMT+2",
- "Etc/GMT+3",
- "Etc/GMT+4",
- "Etc/GMT+5",
- "Etc/GMT+6",
- "Etc/GMT+7",
- "Etc/GMT+8",
- "Etc/GMT+9",
- "Etc/GMT-0",
- "Etc/GMT-1",
- "Etc/GMT-10",
- "Etc/GMT-11",
- "Etc/GMT-12",
- "Etc/GMT-13",
- "Etc/GMT-14",
- "Etc/GMT-2",
- "Etc/GMT-3",
- "Etc/GMT-4",
- "Etc/GMT-5",
- "Etc/GMT-6",
- "Etc/GMT-7",
- "Etc/GMT-8",
- "Etc/GMT-9",
- "Etc/GMT0",
- "Etc/Greenwich",
- "Etc/UCT",
- "Etc/UTC",
- "Etc/Universal",
- "Etc/Zulu",
- "Europe/Amsterdam",
- "Europe/Andorra",
- "Europe/Astrakhan",
- "Europe/Athens",
- "Europe/Belfast",
- "Europe/Belgrade",
- "Europe/Berlin",
- "Europe/Bratislava",
- "Europe/Brussels",
- "Europe/Bucharest",
- "Europe/Budapest",
- "Europe/Busingen",
- "Europe/Chisinau",
- "Europe/Copenhagen",
- "Europe/Dublin",
- "Europe/Gibraltar",
- "Europe/Guernsey",
- "Europe/Helsinki",
- "Europe/Isle_of_Man",
- "Europe/Istanbul",
- "Europe/Jersey",
- "Europe/Kaliningrad",
- "Europe/Kiev",
- "Europe/Kirov",
- "Europe/Kyiv",
- "Europe/Lisbon",
- "Europe/Ljubljana",
- "Europe/London",
- "Europe/Luxembourg",
- "Europe/Madrid",
- "Europe/Malta",
- "Europe/Mariehamn",
- "Europe/Minsk",
- "Europe/Monaco",
- "Europe/Moscow",
- "Europe/Nicosia",
- "Europe/Oslo",
- "Europe/Paris",
- "Europe/Podgorica",
- "Europe/Prague",
- "Europe/Riga",
- "Europe/Rome",
- "Europe/Samara",
- "Europe/San_Marino",
- "Europe/Sarajevo",
- "Europe/Saratov",
- "Europe/Simferopol",
- "Europe/Skopje",
- "Europe/Sofia",
- "Europe/Stockholm",
- "Europe/Tallinn",
- "Europe/Tirane",
- "Europe/Tiraspol",
- "Europe/Ulyanovsk",
- "Europe/Uzhgorod",
- "Europe/Vaduz",
- "Europe/Vatican",
- "Europe/Vienna",
- "Europe/Vilnius",
- "Europe/Volgograd",
- "Europe/Warsaw",
- "Europe/Zagreb",
- "Europe/Zaporozhye",
- "Europe/Zurich",
- "Factory",
- "GB",
- "GB-Eire",
- "GMT",
- "GMT+0",
- "GMT-0",
- "GMT0",
- "Greenwich",
- "HST",
- "Hongkong",
- "Iceland",
- "Indian/Antananarivo",
- "Indian/Chagos",
- "Indian/Christmas",
- "Indian/Cocos",
- "Indian/Comoro",
- "Indian/Kerguelen",
- "Indian/Mahe",
- "Indian/Maldives",
- "Indian/Mauritius",
- "Indian/Mayotte",
- "Indian/Reunion",
- "Iran",
- "Israel",
- "Jamaica",
- "Japan",
- "Kwajalein",
- "Libya",
- "MET",
- "MST",
- "MST7MDT",
- "Mexico/BajaNorte",
- "Mexico/BajaSur",
- "Mexico/General",
- "NZ",
- "NZ-CHAT",
- "Navajo",
- "PRC",
- "PST8PDT",
- "Pacific/Apia",
- "Pacific/Auckland",
- "Pacific/Bougainville",
- "Pacific/Chatham",
- "Pacific/Chuuk",
- "Pacific/Easter",
- "Pacific/Efate",
- "Pacific/Enderbury",
- "Pacific/Fakaofo",
- "Pacific/Fiji",
- "Pacific/Funafuti",
- "Pacific/Galapagos",
- "Pacific/Gambier",
- "Pacific/Guadalcanal",
- "Pacific/Guam",
- "Pacific/Honolulu",
- "Pacific/Johnston",
- "Pacific/Kanton",
- "Pacific/Kiritimati",
- "Pacific/Kosrae",
- "Pacific/Kwajalein",
- "Pacific/Majuro",
- "Pacific/Marquesas",
- "Pacific/Midway",
- "Pacific/Nauru",
- "Pacific/Niue",
- "Pacific/Norfolk",
- "Pacific/Noumea",
- "Pacific/Pago_Pago",
- "Pacific/Palau",
- "Pacific/Pitcairn",
- "Pacific/Pohnpei",
- "Pacific/Ponape",
- "Pacific/Port_Moresby",
- "Pacific/Rarotonga",
- "Pacific/Saipan",
- "Pacific/Samoa",
- "Pacific/Tahiti",
- "Pacific/Tarawa",
- "Pacific/Tongatapu",
- "Pacific/Truk",
- "Pacific/Wake",
- "Pacific/Wallis",
- "Pacific/Yap",
- "Poland",
- "Portugal",
- "ROC",
- "ROK",
- "Singapore",
- "Turkey",
- "UCT",
- "US/Alaska",
- "US/Aleutian",
- "US/Arizona",
- "US/Central",
- "US/East-Indiana",
- "US/Eastern",
- "US/Hawaii",
- "US/Indiana-Starke",
- "US/Michigan",
- "US/Mountain",
- "US/Pacific",
- "US/Pacific-New",
- "US/Samoa",
- "UTC",
- "Universal",
- "W-SU",
- "WET",
- "Zulu",
- ]
- ]
- """
- Defaults to `Etc/UTC`. The output timezone for all timestamps in the report. A list of possible time zone values is maintained at the [IANA Time Zone Database](http://www.iana.org/time-zones). Has no effect on `interval_start` or `interval_end`.
- """
-
- class ListParams(TypedDict):
- created: NotRequired["ReportRunService.ListParamsCreated|int"]
- """
- Only return Report Runs that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class ReportRunService(StripeService):
def list(
self,
- params: Optional["ReportRunService.ListParams"] = None,
+ params: Optional["ReportRunListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ReportRun]:
"""
@@ -767,7 +42,7 @@ def list(
async def list_async(
self,
- params: Optional["ReportRunService.ListParams"] = None,
+ params: Optional["ReportRunListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ReportRun]:
"""
@@ -786,7 +61,7 @@ async def list_async(
def create(
self,
- params: "ReportRunService.CreateParams",
+ params: "ReportRunCreateParams",
options: Optional[RequestOptions] = None,
) -> ReportRun:
"""
@@ -805,7 +80,7 @@ def create(
async def create_async(
self,
- params: "ReportRunService.CreateParams",
+ params: "ReportRunCreateParams",
options: Optional[RequestOptions] = None,
) -> ReportRun:
"""
@@ -825,7 +100,7 @@ async def create_async(
def retrieve(
self,
report_run: str,
- params: Optional["ReportRunService.RetrieveParams"] = None,
+ params: Optional["ReportRunRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ReportRun:
"""
@@ -847,7 +122,7 @@ def retrieve(
async def retrieve_async(
self,
report_run: str,
- params: Optional["ReportRunService.RetrieveParams"] = None,
+ params: Optional["ReportRunRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ReportRun:
"""
diff --git a/stripe/reporting/_report_type.py b/stripe/reporting/_report_type.py
index af722ea57..8d765a769 100644
--- a/stripe/reporting/_report_type.py
+++ b/stripe/reporting/_report_type.py
@@ -2,9 +2,16 @@
# File generated from our OpenAPI spec
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from typing import ClassVar, List, Optional
-from typing_extensions import Literal, NotRequired, Unpack
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.reporting._report_type_list_params import (
+ ReportTypeListParams,
+ )
+ from stripe.params.reporting._report_type_retrieve_params import (
+ ReportTypeRetrieveParams,
+ )
class ReportType(ListableAPIResource["ReportType"]):
@@ -22,19 +29,6 @@ class ReportType(ListableAPIResource["ReportType"]):
OBJECT_NAME: ClassVar[Literal["reporting.report_type"]] = (
"reporting.report_type"
)
-
- class ListParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
data_available_end: int
"""
Most recent time for which this Report Type is available. Measured in seconds since the Unix epoch.
@@ -74,7 +68,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["ReportType.ListParams"]
+ cls, **params: Unpack["ReportTypeListParams"]
) -> ListObject["ReportType"]:
"""
Returns a full list of Report Types.
@@ -94,7 +88,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["ReportType.ListParams"]
+ cls, **params: Unpack["ReportTypeListParams"]
) -> ListObject["ReportType"]:
"""
Returns a full list of Report Types.
@@ -114,7 +108,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["ReportType.RetrieveParams"]
+ cls, id: str, **params: Unpack["ReportTypeRetrieveParams"]
) -> "ReportType":
"""
Retrieves the details of a Report Type. (Certain report types require a [live-mode API key](https://stripe.com/docs/keys#test-live-modes).)
@@ -125,7 +119,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["ReportType.RetrieveParams"]
+ cls, id: str, **params: Unpack["ReportTypeRetrieveParams"]
) -> "ReportType":
"""
Retrieves the details of a Report Type. (Certain report types require a [live-mode API key](https://stripe.com/docs/keys#test-live-modes).)
diff --git a/stripe/reporting/_report_type_service.py b/stripe/reporting/_report_type_service.py
index c8a058197..1cc909988 100644
--- a/stripe/reporting/_report_type_service.py
+++ b/stripe/reporting/_report_type_service.py
@@ -5,26 +5,22 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.reporting._report_type import ReportType
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.reporting._report_type_list_params import (
+ ReportTypeListParams,
+ )
+ from stripe.params.reporting._report_type_retrieve_params import (
+ ReportTypeRetrieveParams,
+ )
-class ReportTypeService(StripeService):
- class ListParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class ReportTypeService(StripeService):
def list(
self,
- params: Optional["ReportTypeService.ListParams"] = None,
+ params: Optional["ReportTypeListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ReportType]:
"""
@@ -43,7 +39,7 @@ def list(
async def list_async(
self,
- params: Optional["ReportTypeService.ListParams"] = None,
+ params: Optional["ReportTypeListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ReportType]:
"""
@@ -63,7 +59,7 @@ async def list_async(
def retrieve(
self,
report_type: str,
- params: Optional["ReportTypeService.RetrieveParams"] = None,
+ params: Optional["ReportTypeRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ReportType:
"""
@@ -85,7 +81,7 @@ def retrieve(
async def retrieve_async(
self,
report_type: str,
- params: Optional["ReportTypeService.RetrieveParams"] = None,
+ params: Optional["ReportTypeRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ReportType:
"""
diff --git a/stripe/sigma/_scheduled_query_run.py b/stripe/sigma/_scheduled_query_run.py
index f3c2b855e..7aa8a2f25 100644
--- a/stripe/sigma/_scheduled_query_run.py
+++ b/stripe/sigma/_scheduled_query_run.py
@@ -2,13 +2,18 @@
# File generated from our OpenAPI spec
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
-from typing import ClassVar, List, Optional
-from typing_extensions import Literal, NotRequired, Unpack, TYPE_CHECKING
+from typing import ClassVar, Optional
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._file import File
+ from stripe.params.sigma._scheduled_query_run_list_params import (
+ ScheduledQueryRunListParams,
+ )
+ from stripe.params.sigma._scheduled_query_run_retrieve_params import (
+ ScheduledQueryRunRetrieveParams,
+ )
class ScheduledQueryRun(ListableAPIResource["ScheduledQueryRun"]):
@@ -29,30 +34,6 @@ class Error(StripeObject):
Information about the run failure.
"""
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -97,7 +78,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["ScheduledQueryRun.ListParams"]
+ cls, **params: Unpack["ScheduledQueryRunListParams"]
) -> ListObject["ScheduledQueryRun"]:
"""
Returns a list of scheduled query runs.
@@ -117,7 +98,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["ScheduledQueryRun.ListParams"]
+ cls, **params: Unpack["ScheduledQueryRunListParams"]
) -> ListObject["ScheduledQueryRun"]:
"""
Returns a list of scheduled query runs.
@@ -137,7 +118,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["ScheduledQueryRun.RetrieveParams"]
+ cls, id: str, **params: Unpack["ScheduledQueryRunRetrieveParams"]
) -> "ScheduledQueryRun":
"""
Retrieves the details of an scheduled query run.
@@ -148,7 +129,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["ScheduledQueryRun.RetrieveParams"]
+ cls, id: str, **params: Unpack["ScheduledQueryRunRetrieveParams"]
) -> "ScheduledQueryRun":
"""
Retrieves the details of an scheduled query run.
diff --git a/stripe/sigma/_scheduled_query_run_service.py b/stripe/sigma/_scheduled_query_run_service.py
index 47fa4a029..b79c861e6 100644
--- a/stripe/sigma/_scheduled_query_run_service.py
+++ b/stripe/sigma/_scheduled_query_run_service.py
@@ -5,38 +5,22 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.sigma._scheduled_query_run import ScheduledQueryRun
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.sigma._scheduled_query_run_list_params import (
+ ScheduledQueryRunListParams,
+ )
+ from stripe.params.sigma._scheduled_query_run_retrieve_params import (
+ ScheduledQueryRunRetrieveParams,
+ )
-class ScheduledQueryRunService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class ScheduledQueryRunService(StripeService):
def list(
self,
- params: Optional["ScheduledQueryRunService.ListParams"] = None,
+ params: Optional["ScheduledQueryRunListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ScheduledQueryRun]:
"""
@@ -55,7 +39,7 @@ def list(
async def list_async(
self,
- params: Optional["ScheduledQueryRunService.ListParams"] = None,
+ params: Optional["ScheduledQueryRunListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[ScheduledQueryRun]:
"""
@@ -75,7 +59,7 @@ async def list_async(
def retrieve(
self,
scheduled_query_run: str,
- params: Optional["ScheduledQueryRunService.RetrieveParams"] = None,
+ params: Optional["ScheduledQueryRunRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ScheduledQueryRun:
"""
@@ -97,7 +81,7 @@ def retrieve(
async def retrieve_async(
self,
scheduled_query_run: str,
- params: Optional["ScheduledQueryRunService.RetrieveParams"] = None,
+ params: Optional["ScheduledQueryRunRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ScheduledQueryRun:
"""
diff --git a/stripe/tax/_calculation.py b/stripe/tax/_calculation.py
index 163a51860..f3a19992c 100644
--- a/stripe/tax/_calculation.py
+++ b/stripe/tax/_calculation.py
@@ -2,19 +2,21 @@
# File generated from our OpenAPI spec
from stripe._createable_api_resource import CreateableAPIResource
from stripe._list_object import ListObject
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, List, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
+ from stripe.params.tax._calculation_create_params import (
+ CalculationCreateParams,
+ )
+ from stripe.params.tax._calculation_list_line_items_params import (
+ CalculationListLineItemsParams,
+ )
+ from stripe.params.tax._calculation_retrieve_params import (
+ CalculationRetrieveParams,
+ )
from stripe.tax._calculation_line_item import CalculationLineItem
@@ -439,322 +441,6 @@ class FlatAmount(StripeObject):
"""
_inner_class_types = {"tax_rate_details": TaxRateDetails}
- class CreateParams(RequestOptions):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: NotRequired[str]
- """
- The ID of an existing customer to use for this calculation. If provided, the customer's address and tax IDs are copied to `customer_details`.
- """
- customer_details: NotRequired[
- "Calculation.CreateParamsCustomerDetails"
- ]
- """
- Details about the customer, including address and tax IDs.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- line_items: List["Calculation.CreateParamsLineItem"]
- """
- A list of items the customer is purchasing.
- """
- ship_from_details: NotRequired[
- "Calculation.CreateParamsShipFromDetails"
- ]
- """
- Details about the address from which the goods are being shipped.
- """
- shipping_cost: NotRequired["Calculation.CreateParamsShippingCost"]
- """
- Shipping cost details to be used for the calculation.
- """
- tax_date: NotRequired[int]
- """
- Timestamp of date at which the tax rules and rates in effect applies for the calculation. Measured in seconds since the Unix epoch. Can be up to 48 hours in the past, and up to 48 hours in the future.
- """
-
- class CreateParamsCustomerDetails(TypedDict):
- address: NotRequired["Calculation.CreateParamsCustomerDetailsAddress"]
- """
- The customer's postal address (for example, home or business location).
- """
- address_source: NotRequired[Literal["billing", "shipping"]]
- """
- The type of customer address provided.
- """
- ip_address: NotRequired[str]
- """
- The customer's IP address (IPv4 or IPv6).
- """
- tax_ids: NotRequired[
- List["Calculation.CreateParamsCustomerDetailsTaxId"]
- ]
- """
- The customer's tax IDs. Stripe Tax might consider a transaction with applicable tax IDs to be B2B, which might affect the tax calculation result. Stripe Tax doesn't validate tax IDs for correctness.
- """
- taxability_override: NotRequired[
- Literal["customer_exempt", "none", "reverse_charge"]
- ]
- """
- Overrides the tax calculation result to allow you to not collect tax from your customer. Use this if you've manually checked your customer's tax exemptions. Prefer providing the customer's `tax_ids` where possible, which automatically determines whether `reverse_charge` applies.
- """
-
- class CreateParamsCustomerDetailsAddress(TypedDict):
- city: NotRequired["Literal['']|str"]
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired["Literal['']|str"]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired["Literal['']|str"]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired["Literal['']|str"]
- """
- ZIP or postal code.
- """
- state: NotRequired["Literal['']|str"]
- """
- State, county, province, or region. We recommend sending [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code value when possible.
- """
-
- class CreateParamsCustomerDetailsTaxId(TypedDict):
- type: Literal[
- "ad_nrt",
- "ae_trn",
- "al_tin",
- "am_tin",
- "ao_tin",
- "ar_cuit",
- "au_abn",
- "au_arn",
- "aw_tin",
- "az_tin",
- "ba_tin",
- "bb_tin",
- "bd_bin",
- "bf_ifu",
- "bg_uic",
- "bh_vat",
- "bj_ifu",
- "bo_tin",
- "br_cnpj",
- "br_cpf",
- "bs_tin",
- "by_tin",
- "ca_bn",
- "ca_gst_hst",
- "ca_pst_bc",
- "ca_pst_mb",
- "ca_pst_sk",
- "ca_qst",
- "cd_nif",
- "ch_uid",
- "ch_vat",
- "cl_tin",
- "cm_niu",
- "cn_tin",
- "co_nit",
- "cr_tin",
- "cv_nif",
- "de_stn",
- "do_rcn",
- "ec_ruc",
- "eg_tin",
- "es_cif",
- "et_tin",
- "eu_oss_vat",
- "eu_vat",
- "gb_vat",
- "ge_vat",
- "gn_nif",
- "hk_br",
- "hr_oib",
- "hu_tin",
- "id_npwp",
- "il_vat",
- "in_gst",
- "is_vat",
- "jp_cn",
- "jp_rn",
- "jp_trn",
- "ke_pin",
- "kg_tin",
- "kh_tin",
- "kr_brn",
- "kz_bin",
- "la_tin",
- "li_uid",
- "li_vat",
- "ma_vat",
- "md_vat",
- "me_pib",
- "mk_vat",
- "mr_nif",
- "mx_rfc",
- "my_frp",
- "my_itn",
- "my_sst",
- "ng_tin",
- "no_vat",
- "no_voec",
- "np_pan",
- "nz_gst",
- "om_vat",
- "pe_ruc",
- "ph_tin",
- "ro_tin",
- "rs_pib",
- "ru_inn",
- "ru_kpp",
- "sa_vat",
- "sg_gst",
- "sg_uen",
- "si_tin",
- "sn_ninea",
- "sr_fin",
- "sv_nit",
- "th_vat",
- "tj_tin",
- "tr_tin",
- "tw_vat",
- "tz_vat",
- "ua_vat",
- "ug_tin",
- "us_ein",
- "uy_ruc",
- "uz_tin",
- "uz_vat",
- "ve_rif",
- "vn_tin",
- "za_vat",
- "zm_tin",
- "zw_tin",
- ]
- """
- Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
- """
- value: str
- """
- Value of the tax ID.
- """
-
- class CreateParamsLineItem(TypedDict):
- amount: int
- """
- A positive integer representing the line item's total price in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes are calculated on top of this amount.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- """
- product: NotRequired[str]
- """
- If provided, the product's `tax_code` will be used as the line item's `tax_code`.
- """
- quantity: NotRequired[int]
- """
- The number of units of the item being purchased. Used to calculate the per-unit price from the total `amount` for the line. For example, if `amount=100` and `quantity=4`, the calculated unit price is 25.
- """
- reference: NotRequired[str]
- """
- A custom identifier for this line item, which must be unique across the line items in the calculation. The reference helps identify each line item in exported [tax reports](https://stripe.com/docs/tax/reports).
- """
- tax_behavior: NotRequired[Literal["exclusive", "inclusive"]]
- """
- Specifies whether the `amount` includes taxes. Defaults to `exclusive`.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID to use for this line item. If not provided, we will use the tax code from the provided `product` param. If neither `tax_code` nor `product` is provided, we will use the default tax code from your Tax Settings.
- """
-
- class CreateParamsShipFromDetails(TypedDict):
- address: "Calculation.CreateParamsShipFromDetailsAddress"
- """
- The address from which the goods are being shipped from.
- """
-
- class CreateParamsShipFromDetailsAddress(TypedDict):
- city: NotRequired["Literal['']|str"]
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired["Literal['']|str"]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired["Literal['']|str"]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired["Literal['']|str"]
- """
- ZIP or postal code.
- """
- state: NotRequired["Literal['']|str"]
- """
- State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix, such as "NY" or "TX".
- """
-
- class CreateParamsShippingCost(TypedDict):
- amount: NotRequired[int]
- """
- A positive integer in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) representing the shipping charge. If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes are calculated on top of this amount.
- """
- shipping_rate: NotRequired[str]
- """
- If provided, the [shipping rate](https://stripe.com/docs/api/shipping_rates/object)'s `amount`, `tax_code` and `tax_behavior` are used. If you provide a shipping rate, then you cannot pass the `amount`, `tax_code`, or `tax_behavior` parameters.
- """
- tax_behavior: NotRequired[Literal["exclusive", "inclusive"]]
- """
- Specifies whether the `amount` includes taxes. If `tax_behavior=inclusive`, then the amount includes taxes. Defaults to `exclusive`.
- """
- tax_code: NotRequired[str]
- """
- The [tax code](https://stripe.com/docs/tax/tax-categories) used to calculate tax on shipping. If not provided, the default shipping tax code from your [Tax Settings](https://dashboard.stripe.com/settings/tax) is used.
- """
-
- class ListLineItemsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount_total: int
"""
Total amount after taxes in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
@@ -815,7 +501,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["Calculation.CreateParams"]
+ cls, **params: Unpack["CalculationCreateParams"]
) -> "Calculation":
"""
Calculates tax based on the input and returns a Tax Calculation object.
@@ -831,7 +517,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["Calculation.CreateParams"]
+ cls, **params: Unpack["CalculationCreateParams"]
) -> "Calculation":
"""
Calculates tax based on the input and returns a Tax Calculation object.
@@ -849,7 +535,7 @@ async def create_async(
def _cls_list_line_items(
cls,
calculation: str,
- **params: Unpack["Calculation.ListLineItemsParams"],
+ **params: Unpack["CalculationListLineItemsParams"],
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
@@ -868,7 +554,7 @@ def _cls_list_line_items(
@overload
@staticmethod
def list_line_items(
- calculation: str, **params: Unpack["Calculation.ListLineItemsParams"]
+ calculation: str, **params: Unpack["CalculationListLineItemsParams"]
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
@@ -877,7 +563,7 @@ def list_line_items(
@overload
def list_line_items(
- self, **params: Unpack["Calculation.ListLineItemsParams"]
+ self, **params: Unpack["CalculationListLineItemsParams"]
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
@@ -886,7 +572,7 @@ def list_line_items(
@class_method_variant("_cls_list_line_items")
def list_line_items( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Calculation.ListLineItemsParams"]
+ self, **params: Unpack["CalculationListLineItemsParams"]
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
@@ -906,7 +592,7 @@ def list_line_items( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_list_line_items_async(
cls,
calculation: str,
- **params: Unpack["Calculation.ListLineItemsParams"],
+ **params: Unpack["CalculationListLineItemsParams"],
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
@@ -925,7 +611,7 @@ async def _cls_list_line_items_async(
@overload
@staticmethod
async def list_line_items_async(
- calculation: str, **params: Unpack["Calculation.ListLineItemsParams"]
+ calculation: str, **params: Unpack["CalculationListLineItemsParams"]
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
@@ -934,7 +620,7 @@ async def list_line_items_async(
@overload
async def list_line_items_async(
- self, **params: Unpack["Calculation.ListLineItemsParams"]
+ self, **params: Unpack["CalculationListLineItemsParams"]
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
@@ -943,7 +629,7 @@ async def list_line_items_async(
@class_method_variant("_cls_list_line_items_async")
async def list_line_items_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Calculation.ListLineItemsParams"]
+ self, **params: Unpack["CalculationListLineItemsParams"]
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
@@ -961,7 +647,7 @@ async def list_line_items_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Calculation.RetrieveParams"]
+ cls, id: str, **params: Unpack["CalculationRetrieveParams"]
) -> "Calculation":
"""
Retrieves a Tax Calculation object, if the calculation hasn't expired.
@@ -972,7 +658,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Calculation.RetrieveParams"]
+ cls, id: str, **params: Unpack["CalculationRetrieveParams"]
) -> "Calculation":
"""
Retrieves a Tax Calculation object, 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 c4718e359..f2ccdc142 100644
--- a/stripe/tax/_calculation_line_item_service.py
+++ b/stripe/tax/_calculation_line_item_service.py
@@ -5,33 +5,20 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.tax._calculation_line_item import CalculationLineItem
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.tax._calculation_line_item_list_params import (
+ CalculationLineItemListParams,
+ )
-class CalculationLineItemService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
+class CalculationLineItemService(StripeService):
def list(
self,
calculation: str,
- params: Optional["CalculationLineItemService.ListParams"] = None,
+ params: Optional["CalculationLineItemListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[CalculationLineItem]:
"""
@@ -53,7 +40,7 @@ def list(
async def list_async(
self,
calculation: str,
- params: Optional["CalculationLineItemService.ListParams"] = None,
+ 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 39165d7a9..c038acf79 100644
--- a/stripe/tax/_calculation_service.py
+++ b/stripe/tax/_calculation_service.py
@@ -7,8 +7,16 @@
from stripe.tax._calculation_line_item_service import (
CalculationLineItemService,
)
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.tax._calculation_create_params import (
+ CalculationCreateParams,
+ )
+ from stripe.params.tax._calculation_retrieve_params import (
+ CalculationRetrieveParams,
+ )
class CalculationService(StripeService):
@@ -16,312 +24,10 @@ def __init__(self, requestor):
super().__init__(requestor)
self.line_items = CalculationLineItemService(self._requestor)
- class CreateParams(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: NotRequired[str]
- """
- The ID of an existing customer to use for this calculation. If provided, the customer's address and tax IDs are copied to `customer_details`.
- """
- customer_details: NotRequired[
- "CalculationService.CreateParamsCustomerDetails"
- ]
- """
- Details about the customer, including address and tax IDs.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- line_items: List["CalculationService.CreateParamsLineItem"]
- """
- A list of items the customer is purchasing.
- """
- ship_from_details: NotRequired[
- "CalculationService.CreateParamsShipFromDetails"
- ]
- """
- Details about the address from which the goods are being shipped.
- """
- shipping_cost: NotRequired[
- "CalculationService.CreateParamsShippingCost"
- ]
- """
- Shipping cost details to be used for the calculation.
- """
- tax_date: NotRequired[int]
- """
- Timestamp of date at which the tax rules and rates in effect applies for the calculation. Measured in seconds since the Unix epoch. Can be up to 48 hours in the past, and up to 48 hours in the future.
- """
-
- class CreateParamsCustomerDetails(TypedDict):
- address: NotRequired[
- "CalculationService.CreateParamsCustomerDetailsAddress"
- ]
- """
- The customer's postal address (for example, home or business location).
- """
- address_source: NotRequired[Literal["billing", "shipping"]]
- """
- The type of customer address provided.
- """
- ip_address: NotRequired[str]
- """
- The customer's IP address (IPv4 or IPv6).
- """
- tax_ids: NotRequired[
- List["CalculationService.CreateParamsCustomerDetailsTaxId"]
- ]
- """
- The customer's tax IDs. Stripe Tax might consider a transaction with applicable tax IDs to be B2B, which might affect the tax calculation result. Stripe Tax doesn't validate tax IDs for correctness.
- """
- taxability_override: NotRequired[
- Literal["customer_exempt", "none", "reverse_charge"]
- ]
- """
- Overrides the tax calculation result to allow you to not collect tax from your customer. Use this if you've manually checked your customer's tax exemptions. Prefer providing the customer's `tax_ids` where possible, which automatically determines whether `reverse_charge` applies.
- """
-
- class CreateParamsCustomerDetailsAddress(TypedDict):
- city: NotRequired["Literal['']|str"]
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired["Literal['']|str"]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired["Literal['']|str"]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired["Literal['']|str"]
- """
- ZIP or postal code.
- """
- state: NotRequired["Literal['']|str"]
- """
- State, county, province, or region. We recommend sending [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code value when possible.
- """
-
- class CreateParamsCustomerDetailsTaxId(TypedDict):
- type: Literal[
- "ad_nrt",
- "ae_trn",
- "al_tin",
- "am_tin",
- "ao_tin",
- "ar_cuit",
- "au_abn",
- "au_arn",
- "aw_tin",
- "az_tin",
- "ba_tin",
- "bb_tin",
- "bd_bin",
- "bf_ifu",
- "bg_uic",
- "bh_vat",
- "bj_ifu",
- "bo_tin",
- "br_cnpj",
- "br_cpf",
- "bs_tin",
- "by_tin",
- "ca_bn",
- "ca_gst_hst",
- "ca_pst_bc",
- "ca_pst_mb",
- "ca_pst_sk",
- "ca_qst",
- "cd_nif",
- "ch_uid",
- "ch_vat",
- "cl_tin",
- "cm_niu",
- "cn_tin",
- "co_nit",
- "cr_tin",
- "cv_nif",
- "de_stn",
- "do_rcn",
- "ec_ruc",
- "eg_tin",
- "es_cif",
- "et_tin",
- "eu_oss_vat",
- "eu_vat",
- "gb_vat",
- "ge_vat",
- "gn_nif",
- "hk_br",
- "hr_oib",
- "hu_tin",
- "id_npwp",
- "il_vat",
- "in_gst",
- "is_vat",
- "jp_cn",
- "jp_rn",
- "jp_trn",
- "ke_pin",
- "kg_tin",
- "kh_tin",
- "kr_brn",
- "kz_bin",
- "la_tin",
- "li_uid",
- "li_vat",
- "ma_vat",
- "md_vat",
- "me_pib",
- "mk_vat",
- "mr_nif",
- "mx_rfc",
- "my_frp",
- "my_itn",
- "my_sst",
- "ng_tin",
- "no_vat",
- "no_voec",
- "np_pan",
- "nz_gst",
- "om_vat",
- "pe_ruc",
- "ph_tin",
- "ro_tin",
- "rs_pib",
- "ru_inn",
- "ru_kpp",
- "sa_vat",
- "sg_gst",
- "sg_uen",
- "si_tin",
- "sn_ninea",
- "sr_fin",
- "sv_nit",
- "th_vat",
- "tj_tin",
- "tr_tin",
- "tw_vat",
- "tz_vat",
- "ua_vat",
- "ug_tin",
- "us_ein",
- "uy_ruc",
- "uz_tin",
- "uz_vat",
- "ve_rif",
- "vn_tin",
- "za_vat",
- "zm_tin",
- "zw_tin",
- ]
- """
- Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
- """
- value: str
- """
- Value of the tax ID.
- """
-
- class CreateParamsLineItem(TypedDict):
- amount: int
- """
- A positive integer representing the line item's total price in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes are calculated on top of this amount.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- """
- product: NotRequired[str]
- """
- If provided, the product's `tax_code` will be used as the line item's `tax_code`.
- """
- quantity: NotRequired[int]
- """
- The number of units of the item being purchased. Used to calculate the per-unit price from the total `amount` for the line. For example, if `amount=100` and `quantity=4`, the calculated unit price is 25.
- """
- reference: NotRequired[str]
- """
- A custom identifier for this line item, which must be unique across the line items in the calculation. The reference helps identify each line item in exported [tax reports](https://stripe.com/docs/tax/reports).
- """
- tax_behavior: NotRequired[Literal["exclusive", "inclusive"]]
- """
- Specifies whether the `amount` includes taxes. Defaults to `exclusive`.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID to use for this line item. If not provided, we will use the tax code from the provided `product` param. If neither `tax_code` nor `product` is provided, we will use the default tax code from your Tax Settings.
- """
-
- class CreateParamsShipFromDetails(TypedDict):
- address: "CalculationService.CreateParamsShipFromDetailsAddress"
- """
- The address from which the goods are being shipped from.
- """
-
- class CreateParamsShipFromDetailsAddress(TypedDict):
- city: NotRequired["Literal['']|str"]
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired["Literal['']|str"]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired["Literal['']|str"]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired["Literal['']|str"]
- """
- ZIP or postal code.
- """
- state: NotRequired["Literal['']|str"]
- """
- State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix, such as "NY" or "TX".
- """
-
- class CreateParamsShippingCost(TypedDict):
- amount: NotRequired[int]
- """
- A positive integer in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) representing the shipping charge. If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes are calculated on top of this amount.
- """
- shipping_rate: NotRequired[str]
- """
- If provided, the [shipping rate](https://stripe.com/docs/api/shipping_rates/object)'s `amount`, `tax_code` and `tax_behavior` are used. If you provide a shipping rate, then you cannot pass the `amount`, `tax_code`, or `tax_behavior` parameters.
- """
- tax_behavior: NotRequired[Literal["exclusive", "inclusive"]]
- """
- Specifies whether the `amount` includes taxes. If `tax_behavior=inclusive`, then the amount includes taxes. Defaults to `exclusive`.
- """
- tax_code: NotRequired[str]
- """
- The [tax code](https://stripe.com/docs/tax/tax-categories) used to calculate tax on shipping. If not provided, the default shipping tax code from your [Tax Settings](https://dashboard.stripe.com/settings/tax) is used.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
def retrieve(
self,
calculation: str,
- params: Optional["CalculationService.RetrieveParams"] = None,
+ params: Optional["CalculationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Calculation:
"""
@@ -343,7 +49,7 @@ def retrieve(
async def retrieve_async(
self,
calculation: str,
- params: Optional["CalculationService.RetrieveParams"] = None,
+ params: Optional["CalculationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Calculation:
"""
@@ -364,7 +70,7 @@ async def retrieve_async(
def create(
self,
- params: "CalculationService.CreateParams",
+ params: "CalculationCreateParams",
options: Optional[RequestOptions] = None,
) -> Calculation:
"""
@@ -383,7 +89,7 @@ def create(
async def create_async(
self,
- params: "CalculationService.CreateParams",
+ params: "CalculationCreateParams",
options: Optional[RequestOptions] = None,
) -> Calculation:
"""
diff --git a/stripe/tax/_registration.py b/stripe/tax/_registration.py
index 5d57edf20..f4a56e526 100644
--- a/stripe/tax/_registration.py
+++ b/stripe/tax/_registration.py
@@ -3,12 +3,25 @@
from stripe._createable_api_resource import CreateableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import sanitize_id
-from typing import ClassVar, List, Optional, Union, cast
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing import ClassVar, List, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.tax._registration_create_params import (
+ RegistrationCreateParams,
+ )
+ from stripe.params.tax._registration_list_params import (
+ RegistrationListParams,
+ )
+ from stripe.params.tax._registration_modify_params import (
+ RegistrationModifyParams,
+ )
+ from stripe.params.tax._registration_retrieve_params import (
+ RegistrationRetrieveParams,
+ )
class Registration(
@@ -1216,1934 +1229,6 @@ class Zw(StripeObject):
}
_field_remappings = {"in_": "in", "is_": "is"}
- class CreateParams(RequestOptions):
- active_from: Union[Literal["now"], int]
- """
- Time at which the Tax Registration becomes active. It can be either `now` to indicate the current time, or a future timestamp measured in seconds since the Unix epoch.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- country_options: "Registration.CreateParamsCountryOptions"
- """
- Specific options for a registration in the specified `country`.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- If set, the Tax Registration stops being active at this time. If not set, the Tax Registration will be active indefinitely. Timestamp measured in seconds since the Unix epoch.
- """
-
- _CreateParamsCountryOptionsBase = TypedDict(
- "CreateParamsCountryOptions",
- {
- "in": NotRequired["Registration.CreateParamsCountryOptionsIn"],
- "is": NotRequired["Registration.CreateParamsCountryOptionsIs"],
- },
- )
-
- class CreateParamsCountryOptions(_CreateParamsCountryOptionsBase):
- ae: NotRequired["Registration.CreateParamsCountryOptionsAe"]
- """
- Options for the registration in AE.
- """
- al: NotRequired["Registration.CreateParamsCountryOptionsAl"]
- """
- Options for the registration in AL.
- """
- am: NotRequired["Registration.CreateParamsCountryOptionsAm"]
- """
- Options for the registration in AM.
- """
- ao: NotRequired["Registration.CreateParamsCountryOptionsAo"]
- """
- Options for the registration in AO.
- """
- at: NotRequired["Registration.CreateParamsCountryOptionsAt"]
- """
- Options for the registration in AT.
- """
- au: NotRequired["Registration.CreateParamsCountryOptionsAu"]
- """
- Options for the registration in AU.
- """
- aw: NotRequired["Registration.CreateParamsCountryOptionsAw"]
- """
- Options for the registration in AW.
- """
- az: NotRequired["Registration.CreateParamsCountryOptionsAz"]
- """
- Options for the registration in AZ.
- """
- ba: NotRequired["Registration.CreateParamsCountryOptionsBa"]
- """
- Options for the registration in BA.
- """
- bb: NotRequired["Registration.CreateParamsCountryOptionsBb"]
- """
- Options for the registration in BB.
- """
- bd: NotRequired["Registration.CreateParamsCountryOptionsBd"]
- """
- Options for the registration in BD.
- """
- be: NotRequired["Registration.CreateParamsCountryOptionsBe"]
- """
- Options for the registration in BE.
- """
- bf: NotRequired["Registration.CreateParamsCountryOptionsBf"]
- """
- Options for the registration in BF.
- """
- bg: NotRequired["Registration.CreateParamsCountryOptionsBg"]
- """
- Options for the registration in BG.
- """
- bh: NotRequired["Registration.CreateParamsCountryOptionsBh"]
- """
- Options for the registration in BH.
- """
- bj: NotRequired["Registration.CreateParamsCountryOptionsBj"]
- """
- Options for the registration in BJ.
- """
- bs: NotRequired["Registration.CreateParamsCountryOptionsBs"]
- """
- Options for the registration in BS.
- """
- by: NotRequired["Registration.CreateParamsCountryOptionsBy"]
- """
- Options for the registration in BY.
- """
- ca: NotRequired["Registration.CreateParamsCountryOptionsCa"]
- """
- Options for the registration in CA.
- """
- cd: NotRequired["Registration.CreateParamsCountryOptionsCd"]
- """
- Options for the registration in CD.
- """
- ch: NotRequired["Registration.CreateParamsCountryOptionsCh"]
- """
- Options for the registration in CH.
- """
- cl: NotRequired["Registration.CreateParamsCountryOptionsCl"]
- """
- Options for the registration in CL.
- """
- cm: NotRequired["Registration.CreateParamsCountryOptionsCm"]
- """
- Options for the registration in CM.
- """
- co: NotRequired["Registration.CreateParamsCountryOptionsCo"]
- """
- Options for the registration in CO.
- """
- cr: NotRequired["Registration.CreateParamsCountryOptionsCr"]
- """
- Options for the registration in CR.
- """
- cv: NotRequired["Registration.CreateParamsCountryOptionsCv"]
- """
- Options for the registration in CV.
- """
- cy: NotRequired["Registration.CreateParamsCountryOptionsCy"]
- """
- Options for the registration in CY.
- """
- cz: NotRequired["Registration.CreateParamsCountryOptionsCz"]
- """
- Options for the registration in CZ.
- """
- de: NotRequired["Registration.CreateParamsCountryOptionsDe"]
- """
- Options for the registration in DE.
- """
- dk: NotRequired["Registration.CreateParamsCountryOptionsDk"]
- """
- Options for the registration in DK.
- """
- ec: NotRequired["Registration.CreateParamsCountryOptionsEc"]
- """
- Options for the registration in EC.
- """
- ee: NotRequired["Registration.CreateParamsCountryOptionsEe"]
- """
- Options for the registration in EE.
- """
- eg: NotRequired["Registration.CreateParamsCountryOptionsEg"]
- """
- Options for the registration in EG.
- """
- es: NotRequired["Registration.CreateParamsCountryOptionsEs"]
- """
- Options for the registration in ES.
- """
- et: NotRequired["Registration.CreateParamsCountryOptionsEt"]
- """
- Options for the registration in ET.
- """
- fi: NotRequired["Registration.CreateParamsCountryOptionsFi"]
- """
- Options for the registration in FI.
- """
- fr: NotRequired["Registration.CreateParamsCountryOptionsFr"]
- """
- Options for the registration in FR.
- """
- gb: NotRequired["Registration.CreateParamsCountryOptionsGb"]
- """
- Options for the registration in GB.
- """
- ge: NotRequired["Registration.CreateParamsCountryOptionsGe"]
- """
- Options for the registration in GE.
- """
- gn: NotRequired["Registration.CreateParamsCountryOptionsGn"]
- """
- Options for the registration in GN.
- """
- gr: NotRequired["Registration.CreateParamsCountryOptionsGr"]
- """
- Options for the registration in GR.
- """
- hr: NotRequired["Registration.CreateParamsCountryOptionsHr"]
- """
- Options for the registration in HR.
- """
- hu: NotRequired["Registration.CreateParamsCountryOptionsHu"]
- """
- Options for the registration in HU.
- """
- id: NotRequired["Registration.CreateParamsCountryOptionsId"]
- """
- Options for the registration in ID.
- """
- ie: NotRequired["Registration.CreateParamsCountryOptionsIe"]
- """
- Options for the registration in IE.
- """
- it: NotRequired["Registration.CreateParamsCountryOptionsIt"]
- """
- Options for the registration in IT.
- """
- jp: NotRequired["Registration.CreateParamsCountryOptionsJp"]
- """
- Options for the registration in JP.
- """
- ke: NotRequired["Registration.CreateParamsCountryOptionsKe"]
- """
- Options for the registration in KE.
- """
- kg: NotRequired["Registration.CreateParamsCountryOptionsKg"]
- """
- Options for the registration in KG.
- """
- kh: NotRequired["Registration.CreateParamsCountryOptionsKh"]
- """
- Options for the registration in KH.
- """
- kr: NotRequired["Registration.CreateParamsCountryOptionsKr"]
- """
- Options for the registration in KR.
- """
- kz: NotRequired["Registration.CreateParamsCountryOptionsKz"]
- """
- Options for the registration in KZ.
- """
- la: NotRequired["Registration.CreateParamsCountryOptionsLa"]
- """
- Options for the registration in LA.
- """
- lt: NotRequired["Registration.CreateParamsCountryOptionsLt"]
- """
- Options for the registration in LT.
- """
- lu: NotRequired["Registration.CreateParamsCountryOptionsLu"]
- """
- Options for the registration in LU.
- """
- lv: NotRequired["Registration.CreateParamsCountryOptionsLv"]
- """
- Options for the registration in LV.
- """
- ma: NotRequired["Registration.CreateParamsCountryOptionsMa"]
- """
- Options for the registration in MA.
- """
- md: NotRequired["Registration.CreateParamsCountryOptionsMd"]
- """
- Options for the registration in MD.
- """
- me: NotRequired["Registration.CreateParamsCountryOptionsMe"]
- """
- Options for the registration in ME.
- """
- mk: NotRequired["Registration.CreateParamsCountryOptionsMk"]
- """
- Options for the registration in MK.
- """
- mr: NotRequired["Registration.CreateParamsCountryOptionsMr"]
- """
- Options for the registration in MR.
- """
- mt: NotRequired["Registration.CreateParamsCountryOptionsMt"]
- """
- Options for the registration in MT.
- """
- mx: NotRequired["Registration.CreateParamsCountryOptionsMx"]
- """
- Options for the registration in MX.
- """
- my: NotRequired["Registration.CreateParamsCountryOptionsMy"]
- """
- Options for the registration in MY.
- """
- ng: NotRequired["Registration.CreateParamsCountryOptionsNg"]
- """
- Options for the registration in NG.
- """
- nl: NotRequired["Registration.CreateParamsCountryOptionsNl"]
- """
- Options for the registration in NL.
- """
- no: NotRequired["Registration.CreateParamsCountryOptionsNo"]
- """
- Options for the registration in NO.
- """
- np: NotRequired["Registration.CreateParamsCountryOptionsNp"]
- """
- Options for the registration in NP.
- """
- nz: NotRequired["Registration.CreateParamsCountryOptionsNz"]
- """
- Options for the registration in NZ.
- """
- om: NotRequired["Registration.CreateParamsCountryOptionsOm"]
- """
- Options for the registration in OM.
- """
- pe: NotRequired["Registration.CreateParamsCountryOptionsPe"]
- """
- Options for the registration in PE.
- """
- ph: NotRequired["Registration.CreateParamsCountryOptionsPh"]
- """
- Options for the registration in PH.
- """
- pl: NotRequired["Registration.CreateParamsCountryOptionsPl"]
- """
- Options for the registration in PL.
- """
- pt: NotRequired["Registration.CreateParamsCountryOptionsPt"]
- """
- Options for the registration in PT.
- """
- ro: NotRequired["Registration.CreateParamsCountryOptionsRo"]
- """
- Options for the registration in RO.
- """
- rs: NotRequired["Registration.CreateParamsCountryOptionsRs"]
- """
- Options for the registration in RS.
- """
- ru: NotRequired["Registration.CreateParamsCountryOptionsRu"]
- """
- Options for the registration in RU.
- """
- sa: NotRequired["Registration.CreateParamsCountryOptionsSa"]
- """
- Options for the registration in SA.
- """
- se: NotRequired["Registration.CreateParamsCountryOptionsSe"]
- """
- Options for the registration in SE.
- """
- sg: NotRequired["Registration.CreateParamsCountryOptionsSg"]
- """
- Options for the registration in SG.
- """
- si: NotRequired["Registration.CreateParamsCountryOptionsSi"]
- """
- Options for the registration in SI.
- """
- sk: NotRequired["Registration.CreateParamsCountryOptionsSk"]
- """
- Options for the registration in SK.
- """
- sn: NotRequired["Registration.CreateParamsCountryOptionsSn"]
- """
- Options for the registration in SN.
- """
- sr: NotRequired["Registration.CreateParamsCountryOptionsSr"]
- """
- Options for the registration in SR.
- """
- th: NotRequired["Registration.CreateParamsCountryOptionsTh"]
- """
- Options for the registration in TH.
- """
- tj: NotRequired["Registration.CreateParamsCountryOptionsTj"]
- """
- Options for the registration in TJ.
- """
- tr: NotRequired["Registration.CreateParamsCountryOptionsTr"]
- """
- Options for the registration in TR.
- """
- tz: NotRequired["Registration.CreateParamsCountryOptionsTz"]
- """
- Options for the registration in TZ.
- """
- ua: NotRequired["Registration.CreateParamsCountryOptionsUa"]
- """
- Options for the registration in UA.
- """
- ug: NotRequired["Registration.CreateParamsCountryOptionsUg"]
- """
- Options for the registration in UG.
- """
- us: NotRequired["Registration.CreateParamsCountryOptionsUs"]
- """
- Options for the registration in US.
- """
- uy: NotRequired["Registration.CreateParamsCountryOptionsUy"]
- """
- Options for the registration in UY.
- """
- uz: NotRequired["Registration.CreateParamsCountryOptionsUz"]
- """
- Options for the registration in UZ.
- """
- vn: NotRequired["Registration.CreateParamsCountryOptionsVn"]
- """
- Options for the registration in VN.
- """
- za: NotRequired["Registration.CreateParamsCountryOptionsZa"]
- """
- Options for the registration in ZA.
- """
- zm: NotRequired["Registration.CreateParamsCountryOptionsZm"]
- """
- Options for the registration in ZM.
- """
- zw: NotRequired["Registration.CreateParamsCountryOptionsZw"]
- """
- Options for the registration in ZW.
- """
-
- class CreateParamsCountryOptionsAe(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsAeStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsAeStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsAl(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsAlStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsAlStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsAm(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsAo(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsAoStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsAoStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsAt(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsAtStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsAtStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsAu(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsAuStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsAuStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsAw(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsAwStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsAwStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsAz(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBa(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsBaStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBaStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsBb(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsBbStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBbStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsBd(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsBdStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBdStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsBe(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsBeStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsBeStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsBf(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsBfStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBfStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsBg(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsBgStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsBgStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsBh(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsBhStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBhStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsBj(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBs(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsBsStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBsStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsBy(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsCa(TypedDict):
- province_standard: NotRequired[
- "Registration.CreateParamsCountryOptionsCaProvinceStandard"
- ]
- """
- Options for the provincial tax registration.
- """
- type: Literal["province_standard", "simplified", "standard"]
- """
- Type of registration to be created in Canada.
- """
-
- class CreateParamsCountryOptionsCaProvinceStandard(TypedDict):
- province: str
- """
- Two-letter CA province code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)).
- """
-
- class CreateParamsCountryOptionsCd(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsCdStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsCdStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsCh(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsChStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsChStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsCl(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsCm(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsCo(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsCr(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsCv(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsCy(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsCyStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsCyStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsCz(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsCzStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsCzStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsDe(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsDeStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsDeStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsDk(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsDkStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsDkStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsEc(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsEe(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsEeStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsEeStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsEg(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsEs(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsEsStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsEsStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsEt(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsEtStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsEtStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsFi(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsFiStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsFiStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsFr(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsFrStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsFrStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsGb(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsGbStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsGbStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsGe(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsGn(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsGnStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsGnStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsGr(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsGrStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsGrStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsHr(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsHrStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsHrStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsHu(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsHuStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsHuStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsId(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsIe(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsIeStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsIeStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsIn(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsIs(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsIsStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsIsStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsIt(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsItStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsItStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsJp(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsJpStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsJpStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsKe(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsKg(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsKh(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsKr(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsKz(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsLa(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsLt(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsLtStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsLtStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsLu(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsLuStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsLuStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsLv(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsLvStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsLvStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsMa(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsMd(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsMe(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsMeStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsMeStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsMk(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsMkStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsMkStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsMr(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsMrStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsMrStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsMt(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsMtStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsMtStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsMx(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsMy(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsNg(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsNl(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsNlStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsNlStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsNo(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsNoStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsNoStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsNp(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsNz(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsNzStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsNzStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsOm(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsOmStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsOmStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsPe(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsPh(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsPl(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsPlStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsPlStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsPt(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsPtStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsPtStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsRo(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsRoStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsRoStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsRs(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsRsStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsRsStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsRu(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsSa(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsSe(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsSeStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsSeStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsSg(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsSgStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsSgStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsSi(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsSiStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsSiStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsSk(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsSkStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsSkStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsSn(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsSr(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsSrStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsSrStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsTh(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsTj(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsTr(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsTz(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsUa(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsUg(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsUs(TypedDict):
- local_amusement_tax: NotRequired[
- "Registration.CreateParamsCountryOptionsUsLocalAmusementTax"
- ]
- """
- Options for the local amusement tax registration.
- """
- local_lease_tax: NotRequired[
- "Registration.CreateParamsCountryOptionsUsLocalLeaseTax"
- ]
- """
- Options for the local lease tax registration.
- """
- state: str
- """
- 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",
- "state_communications_tax",
- "state_retail_delivery_fee",
- "state_sales_tax",
- ]
- """
- Type of registration to be created in the US.
- """
-
- class CreateParamsCountryOptionsUsLocalAmusementTax(TypedDict):
- jurisdiction: str
- """
- A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. Supported FIPS codes are: `14000` (Chicago), `06613` (Bloomington), `21696` (East Dundee), `24582` (Evanston), `45421` (Lynwood), `48892` (Midlothian), `64343` (River Grove), and `68081` (Schiller Park).
- """
-
- class CreateParamsCountryOptionsUsLocalLeaseTax(TypedDict):
- jurisdiction: str
- """
- 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 CreateParamsCountryOptionsUy(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsUyStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsUyStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsUz(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsVn(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsZa(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsZaStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsZaStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsZm(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsZw(TypedDict):
- standard: NotRequired[
- "Registration.CreateParamsCountryOptionsZwStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsZwStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["active", "all", "expired", "scheduled"]]
- """
- The status of the Tax Registration.
- """
-
- class ModifyParams(RequestOptions):
- active_from: NotRequired["Literal['now']|int"]
- """
- Time at which the registration becomes active. It can be either `now` to indicate the current time, or a timestamp measured in seconds since the Unix epoch.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired["Literal['']|Literal['now']|int"]
- """
- If set, the registration stops being active at this time. If not set, the registration will be active indefinitely. It can be either `now` to indicate the current time, or a timestamp measured in seconds since the Unix epoch.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
active_from: int
"""
Time at which the registration becomes active. Measured in seconds since the Unix epoch.
@@ -3180,7 +1265,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["Registration.CreateParams"]
+ cls, **params: Unpack["RegistrationCreateParams"]
) -> "Registration":
"""
Creates a new Tax Registration object.
@@ -3196,7 +1281,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["Registration.CreateParams"]
+ cls, **params: Unpack["RegistrationCreateParams"]
) -> "Registration":
"""
Creates a new Tax Registration object.
@@ -3212,7 +1297,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["Registration.ListParams"]
+ cls, **params: Unpack["RegistrationListParams"]
) -> ListObject["Registration"]:
"""
Returns a list of Tax Registration objects.
@@ -3232,7 +1317,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Registration.ListParams"]
+ cls, **params: Unpack["RegistrationListParams"]
) -> ListObject["Registration"]:
"""
Returns a list of Tax Registration objects.
@@ -3252,7 +1337,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Registration.ModifyParams"]
+ cls, id: str, **params: Unpack["RegistrationModifyParams"]
) -> "Registration":
"""
Updates an existing Tax Registration object.
@@ -3271,7 +1356,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Registration.ModifyParams"]
+ cls, id: str, **params: Unpack["RegistrationModifyParams"]
) -> "Registration":
"""
Updates an existing Tax Registration object.
@@ -3290,7 +1375,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Registration.RetrieveParams"]
+ cls, id: str, **params: Unpack["RegistrationRetrieveParams"]
) -> "Registration":
"""
Returns a Tax Registration object.
@@ -3301,7 +1386,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Registration.RetrieveParams"]
+ cls, id: str, **params: Unpack["RegistrationRetrieveParams"]
) -> "Registration":
"""
Returns a Tax Registration object.
diff --git a/stripe/tax/_registration_service.py b/stripe/tax/_registration_service.py
index 1dee2416b..88367ceb4 100644
--- a/stripe/tax/_registration_service.py
+++ b/stripe/tax/_registration_service.py
@@ -5,1946 +5,28 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.tax._registration import Registration
-from typing import List, Optional, Union, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
-
-class RegistrationService(StripeService):
- class CreateParams(TypedDict):
- active_from: Union[Literal["now"], int]
- """
- Time at which the Tax Registration becomes active. It can be either `now` to indicate the current time, or a future timestamp measured in seconds since the Unix epoch.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- country_options: "RegistrationService.CreateParamsCountryOptions"
- """
- Specific options for a registration in the specified `country`.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired[int]
- """
- If set, the Tax Registration stops being active at this time. If not set, the Tax Registration will be active indefinitely. Timestamp measured in seconds since the Unix epoch.
- """
-
- _CreateParamsCountryOptionsBase = TypedDict(
- "CreateParamsCountryOptions",
- {
- "in": NotRequired[
- "RegistrationService.CreateParamsCountryOptionsIn"
- ],
- "is": NotRequired[
- "RegistrationService.CreateParamsCountryOptionsIs"
- ],
- },
+if TYPE_CHECKING:
+ from stripe.params.tax._registration_create_params import (
+ RegistrationCreateParams,
+ )
+ from stripe.params.tax._registration_list_params import (
+ RegistrationListParams,
+ )
+ from stripe.params.tax._registration_retrieve_params import (
+ RegistrationRetrieveParams,
+ )
+ from stripe.params.tax._registration_update_params import (
+ RegistrationUpdateParams,
)
- class CreateParamsCountryOptions(_CreateParamsCountryOptionsBase):
- ae: NotRequired["RegistrationService.CreateParamsCountryOptionsAe"]
- """
- Options for the registration in AE.
- """
- al: NotRequired["RegistrationService.CreateParamsCountryOptionsAl"]
- """
- Options for the registration in AL.
- """
- am: NotRequired["RegistrationService.CreateParamsCountryOptionsAm"]
- """
- Options for the registration in AM.
- """
- ao: NotRequired["RegistrationService.CreateParamsCountryOptionsAo"]
- """
- Options for the registration in AO.
- """
- at: NotRequired["RegistrationService.CreateParamsCountryOptionsAt"]
- """
- Options for the registration in AT.
- """
- au: NotRequired["RegistrationService.CreateParamsCountryOptionsAu"]
- """
- Options for the registration in AU.
- """
- aw: NotRequired["RegistrationService.CreateParamsCountryOptionsAw"]
- """
- Options for the registration in AW.
- """
- az: NotRequired["RegistrationService.CreateParamsCountryOptionsAz"]
- """
- Options for the registration in AZ.
- """
- ba: NotRequired["RegistrationService.CreateParamsCountryOptionsBa"]
- """
- Options for the registration in BA.
- """
- bb: NotRequired["RegistrationService.CreateParamsCountryOptionsBb"]
- """
- Options for the registration in BB.
- """
- bd: NotRequired["RegistrationService.CreateParamsCountryOptionsBd"]
- """
- Options for the registration in BD.
- """
- be: NotRequired["RegistrationService.CreateParamsCountryOptionsBe"]
- """
- Options for the registration in BE.
- """
- bf: NotRequired["RegistrationService.CreateParamsCountryOptionsBf"]
- """
- Options for the registration in BF.
- """
- bg: NotRequired["RegistrationService.CreateParamsCountryOptionsBg"]
- """
- Options for the registration in BG.
- """
- bh: NotRequired["RegistrationService.CreateParamsCountryOptionsBh"]
- """
- Options for the registration in BH.
- """
- bj: NotRequired["RegistrationService.CreateParamsCountryOptionsBj"]
- """
- Options for the registration in BJ.
- """
- bs: NotRequired["RegistrationService.CreateParamsCountryOptionsBs"]
- """
- Options for the registration in BS.
- """
- by: NotRequired["RegistrationService.CreateParamsCountryOptionsBy"]
- """
- Options for the registration in BY.
- """
- ca: NotRequired["RegistrationService.CreateParamsCountryOptionsCa"]
- """
- Options for the registration in CA.
- """
- cd: NotRequired["RegistrationService.CreateParamsCountryOptionsCd"]
- """
- Options for the registration in CD.
- """
- ch: NotRequired["RegistrationService.CreateParamsCountryOptionsCh"]
- """
- Options for the registration in CH.
- """
- cl: NotRequired["RegistrationService.CreateParamsCountryOptionsCl"]
- """
- Options for the registration in CL.
- """
- cm: NotRequired["RegistrationService.CreateParamsCountryOptionsCm"]
- """
- Options for the registration in CM.
- """
- co: NotRequired["RegistrationService.CreateParamsCountryOptionsCo"]
- """
- Options for the registration in CO.
- """
- cr: NotRequired["RegistrationService.CreateParamsCountryOptionsCr"]
- """
- Options for the registration in CR.
- """
- cv: NotRequired["RegistrationService.CreateParamsCountryOptionsCv"]
- """
- Options for the registration in CV.
- """
- cy: NotRequired["RegistrationService.CreateParamsCountryOptionsCy"]
- """
- Options for the registration in CY.
- """
- cz: NotRequired["RegistrationService.CreateParamsCountryOptionsCz"]
- """
- Options for the registration in CZ.
- """
- de: NotRequired["RegistrationService.CreateParamsCountryOptionsDe"]
- """
- Options for the registration in DE.
- """
- dk: NotRequired["RegistrationService.CreateParamsCountryOptionsDk"]
- """
- Options for the registration in DK.
- """
- ec: NotRequired["RegistrationService.CreateParamsCountryOptionsEc"]
- """
- Options for the registration in EC.
- """
- ee: NotRequired["RegistrationService.CreateParamsCountryOptionsEe"]
- """
- Options for the registration in EE.
- """
- eg: NotRequired["RegistrationService.CreateParamsCountryOptionsEg"]
- """
- Options for the registration in EG.
- """
- es: NotRequired["RegistrationService.CreateParamsCountryOptionsEs"]
- """
- Options for the registration in ES.
- """
- et: NotRequired["RegistrationService.CreateParamsCountryOptionsEt"]
- """
- Options for the registration in ET.
- """
- fi: NotRequired["RegistrationService.CreateParamsCountryOptionsFi"]
- """
- Options for the registration in FI.
- """
- fr: NotRequired["RegistrationService.CreateParamsCountryOptionsFr"]
- """
- Options for the registration in FR.
- """
- gb: NotRequired["RegistrationService.CreateParamsCountryOptionsGb"]
- """
- Options for the registration in GB.
- """
- ge: NotRequired["RegistrationService.CreateParamsCountryOptionsGe"]
- """
- Options for the registration in GE.
- """
- gn: NotRequired["RegistrationService.CreateParamsCountryOptionsGn"]
- """
- Options for the registration in GN.
- """
- gr: NotRequired["RegistrationService.CreateParamsCountryOptionsGr"]
- """
- Options for the registration in GR.
- """
- hr: NotRequired["RegistrationService.CreateParamsCountryOptionsHr"]
- """
- Options for the registration in HR.
- """
- hu: NotRequired["RegistrationService.CreateParamsCountryOptionsHu"]
- """
- Options for the registration in HU.
- """
- id: NotRequired["RegistrationService.CreateParamsCountryOptionsId"]
- """
- Options for the registration in ID.
- """
- ie: NotRequired["RegistrationService.CreateParamsCountryOptionsIe"]
- """
- Options for the registration in IE.
- """
- it: NotRequired["RegistrationService.CreateParamsCountryOptionsIt"]
- """
- Options for the registration in IT.
- """
- jp: NotRequired["RegistrationService.CreateParamsCountryOptionsJp"]
- """
- Options for the registration in JP.
- """
- ke: NotRequired["RegistrationService.CreateParamsCountryOptionsKe"]
- """
- Options for the registration in KE.
- """
- kg: NotRequired["RegistrationService.CreateParamsCountryOptionsKg"]
- """
- Options for the registration in KG.
- """
- kh: NotRequired["RegistrationService.CreateParamsCountryOptionsKh"]
- """
- Options for the registration in KH.
- """
- kr: NotRequired["RegistrationService.CreateParamsCountryOptionsKr"]
- """
- Options for the registration in KR.
- """
- kz: NotRequired["RegistrationService.CreateParamsCountryOptionsKz"]
- """
- Options for the registration in KZ.
- """
- la: NotRequired["RegistrationService.CreateParamsCountryOptionsLa"]
- """
- Options for the registration in LA.
- """
- lt: NotRequired["RegistrationService.CreateParamsCountryOptionsLt"]
- """
- Options for the registration in LT.
- """
- lu: NotRequired["RegistrationService.CreateParamsCountryOptionsLu"]
- """
- Options for the registration in LU.
- """
- lv: NotRequired["RegistrationService.CreateParamsCountryOptionsLv"]
- """
- Options for the registration in LV.
- """
- ma: NotRequired["RegistrationService.CreateParamsCountryOptionsMa"]
- """
- Options for the registration in MA.
- """
- md: NotRequired["RegistrationService.CreateParamsCountryOptionsMd"]
- """
- Options for the registration in MD.
- """
- me: NotRequired["RegistrationService.CreateParamsCountryOptionsMe"]
- """
- Options for the registration in ME.
- """
- mk: NotRequired["RegistrationService.CreateParamsCountryOptionsMk"]
- """
- Options for the registration in MK.
- """
- mr: NotRequired["RegistrationService.CreateParamsCountryOptionsMr"]
- """
- Options for the registration in MR.
- """
- mt: NotRequired["RegistrationService.CreateParamsCountryOptionsMt"]
- """
- Options for the registration in MT.
- """
- mx: NotRequired["RegistrationService.CreateParamsCountryOptionsMx"]
- """
- Options for the registration in MX.
- """
- my: NotRequired["RegistrationService.CreateParamsCountryOptionsMy"]
- """
- Options for the registration in MY.
- """
- ng: NotRequired["RegistrationService.CreateParamsCountryOptionsNg"]
- """
- Options for the registration in NG.
- """
- nl: NotRequired["RegistrationService.CreateParamsCountryOptionsNl"]
- """
- Options for the registration in NL.
- """
- no: NotRequired["RegistrationService.CreateParamsCountryOptionsNo"]
- """
- Options for the registration in NO.
- """
- np: NotRequired["RegistrationService.CreateParamsCountryOptionsNp"]
- """
- Options for the registration in NP.
- """
- nz: NotRequired["RegistrationService.CreateParamsCountryOptionsNz"]
- """
- Options for the registration in NZ.
- """
- om: NotRequired["RegistrationService.CreateParamsCountryOptionsOm"]
- """
- Options for the registration in OM.
- """
- pe: NotRequired["RegistrationService.CreateParamsCountryOptionsPe"]
- """
- Options for the registration in PE.
- """
- ph: NotRequired["RegistrationService.CreateParamsCountryOptionsPh"]
- """
- Options for the registration in PH.
- """
- pl: NotRequired["RegistrationService.CreateParamsCountryOptionsPl"]
- """
- Options for the registration in PL.
- """
- pt: NotRequired["RegistrationService.CreateParamsCountryOptionsPt"]
- """
- Options for the registration in PT.
- """
- ro: NotRequired["RegistrationService.CreateParamsCountryOptionsRo"]
- """
- Options for the registration in RO.
- """
- rs: NotRequired["RegistrationService.CreateParamsCountryOptionsRs"]
- """
- Options for the registration in RS.
- """
- ru: NotRequired["RegistrationService.CreateParamsCountryOptionsRu"]
- """
- Options for the registration in RU.
- """
- sa: NotRequired["RegistrationService.CreateParamsCountryOptionsSa"]
- """
- Options for the registration in SA.
- """
- se: NotRequired["RegistrationService.CreateParamsCountryOptionsSe"]
- """
- Options for the registration in SE.
- """
- sg: NotRequired["RegistrationService.CreateParamsCountryOptionsSg"]
- """
- Options for the registration in SG.
- """
- si: NotRequired["RegistrationService.CreateParamsCountryOptionsSi"]
- """
- Options for the registration in SI.
- """
- sk: NotRequired["RegistrationService.CreateParamsCountryOptionsSk"]
- """
- Options for the registration in SK.
- """
- sn: NotRequired["RegistrationService.CreateParamsCountryOptionsSn"]
- """
- Options for the registration in SN.
- """
- sr: NotRequired["RegistrationService.CreateParamsCountryOptionsSr"]
- """
- Options for the registration in SR.
- """
- th: NotRequired["RegistrationService.CreateParamsCountryOptionsTh"]
- """
- Options for the registration in TH.
- """
- tj: NotRequired["RegistrationService.CreateParamsCountryOptionsTj"]
- """
- Options for the registration in TJ.
- """
- tr: NotRequired["RegistrationService.CreateParamsCountryOptionsTr"]
- """
- Options for the registration in TR.
- """
- tz: NotRequired["RegistrationService.CreateParamsCountryOptionsTz"]
- """
- Options for the registration in TZ.
- """
- ua: NotRequired["RegistrationService.CreateParamsCountryOptionsUa"]
- """
- Options for the registration in UA.
- """
- ug: NotRequired["RegistrationService.CreateParamsCountryOptionsUg"]
- """
- Options for the registration in UG.
- """
- us: NotRequired["RegistrationService.CreateParamsCountryOptionsUs"]
- """
- Options for the registration in US.
- """
- uy: NotRequired["RegistrationService.CreateParamsCountryOptionsUy"]
- """
- Options for the registration in UY.
- """
- uz: NotRequired["RegistrationService.CreateParamsCountryOptionsUz"]
- """
- Options for the registration in UZ.
- """
- vn: NotRequired["RegistrationService.CreateParamsCountryOptionsVn"]
- """
- Options for the registration in VN.
- """
- za: NotRequired["RegistrationService.CreateParamsCountryOptionsZa"]
- """
- Options for the registration in ZA.
- """
- zm: NotRequired["RegistrationService.CreateParamsCountryOptionsZm"]
- """
- Options for the registration in ZM.
- """
- zw: NotRequired["RegistrationService.CreateParamsCountryOptionsZw"]
- """
- Options for the registration in ZW.
- """
-
- class CreateParamsCountryOptionsAe(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsAeStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsAeStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsAl(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsAlStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsAlStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsAm(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsAo(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsAoStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsAoStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsAt(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsAtStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsAtStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsAu(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsAuStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsAuStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsAw(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsAwStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsAwStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsAz(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBa(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsBaStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBaStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsBb(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsBbStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBbStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsBd(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsBdStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBdStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsBe(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsBeStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsBeStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsBf(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsBfStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBfStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsBg(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsBgStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsBgStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsBh(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsBhStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBhStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsBj(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBs(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsBsStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsBsStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsBy(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsCa(TypedDict):
- province_standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsCaProvinceStandard"
- ]
- """
- Options for the provincial tax registration.
- """
- type: Literal["province_standard", "simplified", "standard"]
- """
- Type of registration to be created in Canada.
- """
-
- class CreateParamsCountryOptionsCaProvinceStandard(TypedDict):
- province: str
- """
- Two-letter CA province code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)).
- """
-
- class CreateParamsCountryOptionsCd(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsCdStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsCdStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsCh(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsChStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsChStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsCl(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsCm(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsCo(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsCr(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsCv(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsCy(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsCyStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsCyStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsCz(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsCzStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsCzStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsDe(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsDeStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsDeStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsDk(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsDkStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsDkStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsEc(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsEe(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsEeStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsEeStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsEg(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsEs(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsEsStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsEsStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsEt(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsEtStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsEtStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsFi(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsFiStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsFiStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsFr(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsFrStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsFrStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsGb(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsGbStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsGbStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsGe(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsGn(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsGnStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsGnStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsGr(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsGrStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsGrStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsHr(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsHrStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsHrStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsHu(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsHuStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsHuStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsId(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsIe(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsIeStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsIeStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsIn(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsIs(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsIsStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsIsStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsIt(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsItStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsItStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsJp(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsJpStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsJpStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsKe(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsKg(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsKh(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsKr(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsKz(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsLa(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsLt(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsLtStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsLtStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsLu(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsLuStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsLuStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsLv(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsLvStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsLvStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsMa(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsMd(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsMe(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsMeStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsMeStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsMk(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsMkStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsMkStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsMr(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsMrStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsMrStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsMt(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsMtStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsMtStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsMx(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsMy(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsNg(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsNl(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsNlStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsNlStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsNo(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsNoStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsNoStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsNp(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsNz(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsNzStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsNzStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsOm(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsOmStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsOmStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsPe(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsPh(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsPl(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsPlStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsPlStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsPt(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsPtStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsPtStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsRo(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsRoStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsRoStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsRs(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsRsStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsRsStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsRu(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsSa(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsSe(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsSeStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsSeStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsSg(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsSgStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsSgStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsSi(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsSiStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsSiStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsSk(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsSkStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["ioss", "oss_non_union", "oss_union", "standard"]
- """
- Type of registration to be created in an EU country.
- """
-
- class CreateParamsCountryOptionsSkStandard(TypedDict):
- place_of_supply_scheme: Literal[
- "inbound_goods", "small_seller", "standard"
- ]
- """
- Place of supply scheme used in an EU standard registration.
- """
-
- class CreateParamsCountryOptionsSn(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsSr(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsSrStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsSrStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsTh(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsTj(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsTr(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsTz(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsUa(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsUg(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsUs(TypedDict):
- local_amusement_tax: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsUsLocalAmusementTax"
- ]
- """
- Options for the local amusement tax registration.
- """
- local_lease_tax: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsUsLocalLeaseTax"
- ]
- """
- Options for the local lease tax registration.
- """
- state: str
- """
- 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",
- "state_communications_tax",
- "state_retail_delivery_fee",
- "state_sales_tax",
- ]
- """
- Type of registration to be created in the US.
- """
-
- class CreateParamsCountryOptionsUsLocalAmusementTax(TypedDict):
- jurisdiction: str
- """
- A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. Supported FIPS codes are: `14000` (Chicago), `06613` (Bloomington), `21696` (East Dundee), `24582` (Evanston), `45421` (Lynwood), `48892` (Midlothian), `64343` (River Grove), and `68081` (Schiller Park).
- """
-
- class CreateParamsCountryOptionsUsLocalLeaseTax(TypedDict):
- jurisdiction: str
- """
- 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 CreateParamsCountryOptionsUy(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsUyStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsUyStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsUz(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsVn(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsZa(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsZaStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsZaStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class CreateParamsCountryOptionsZm(TypedDict):
- type: Literal["simplified"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsZw(TypedDict):
- standard: NotRequired[
- "RegistrationService.CreateParamsCountryOptionsZwStandard"
- ]
- """
- Options for the standard registration.
- """
- type: Literal["standard"]
- """
- Type of registration to be created in `country`.
- """
-
- class CreateParamsCountryOptionsZwStandard(TypedDict):
- place_of_supply_scheme: NotRequired[
- Literal["inbound_goods", "standard"]
- ]
- """
- Place of supply scheme used in an standard registration.
- """
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["active", "all", "expired", "scheduled"]]
- """
- The status of the Tax Registration.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- active_from: NotRequired["Literal['now']|int"]
- """
- Time at which the registration becomes active. It can be either `now` to indicate the current time, or a timestamp measured in seconds since the Unix epoch.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- expires_at: NotRequired["Literal['']|Literal['now']|int"]
- """
- If set, the registration stops being active at this time. If not set, the registration will be active indefinitely. It can be either `now` to indicate the current time, or a timestamp measured in seconds since the Unix epoch.
- """
+class RegistrationService(StripeService):
def list(
self,
- params: Optional["RegistrationService.ListParams"] = None,
+ params: Optional["RegistrationListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Registration]:
"""
@@ -1963,7 +45,7 @@ def list(
async def list_async(
self,
- params: Optional["RegistrationService.ListParams"] = None,
+ params: Optional["RegistrationListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Registration]:
"""
@@ -1982,7 +64,7 @@ async def list_async(
def create(
self,
- params: "RegistrationService.CreateParams",
+ params: "RegistrationCreateParams",
options: Optional[RequestOptions] = None,
) -> Registration:
"""
@@ -2001,7 +83,7 @@ def create(
async def create_async(
self,
- params: "RegistrationService.CreateParams",
+ params: "RegistrationCreateParams",
options: Optional[RequestOptions] = None,
) -> Registration:
"""
@@ -2021,7 +103,7 @@ async def create_async(
def retrieve(
self,
id: str,
- params: Optional["RegistrationService.RetrieveParams"] = None,
+ params: Optional["RegistrationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Registration:
"""
@@ -2041,7 +123,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["RegistrationService.RetrieveParams"] = None,
+ params: Optional["RegistrationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Registration:
"""
@@ -2061,7 +143,7 @@ async def retrieve_async(
def update(
self,
id: str,
- params: Optional["RegistrationService.UpdateParams"] = None,
+ params: Optional["RegistrationUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Registration:
"""
@@ -2083,7 +165,7 @@ def update(
async def update_async(
self,
id: str,
- params: Optional["RegistrationService.UpdateParams"] = None,
+ params: Optional["RegistrationUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Registration:
"""
diff --git a/stripe/tax/_settings.py b/stripe/tax/_settings.py
index fd6b9921f..c67ed2f99 100644
--- a/stripe/tax/_settings.py
+++ b/stripe/tax/_settings.py
@@ -1,11 +1,16 @@
# -*- coding: utf-8 -*-
# File generated from our OpenAPI spec
-from stripe._request_options import RequestOptions
from stripe._singleton_api_resource import SingletonAPIResource
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from typing import ClassVar, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.tax._settings_modify_params import SettingsModifyParams
+ from stripe.params.tax._settings_retrieve_params import (
+ SettingsRetrieveParams,
+ )
class Settings(
@@ -80,70 +85,6 @@ class Pending(StripeObject):
pending: Optional[Pending]
_inner_class_types = {"active": Active, "pending": Pending}
- class ModifyParams(RequestOptions):
- defaults: NotRequired["Settings.ModifyParamsDefaults"]
- """
- Default configuration to be used on Stripe Tax calculations.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- head_office: NotRequired["Settings.ModifyParamsHeadOffice"]
- """
- The place where your business is located.
- """
-
- class ModifyParamsDefaults(TypedDict):
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "inferred_by_currency"]
- ]
- """
- Specifies the default [tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#tax-behavior) to be used when the item's price has unspecified tax behavior. One of inclusive, exclusive, or inferred_by_currency. Once specified, it cannot be changed back to null.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
-
- class ModifyParamsHeadOffice(TypedDict):
- address: "Settings.ModifyParamsHeadOfficeAddress"
- """
- The location of the business for tax purposes.
- """
-
- class ModifyParamsHeadOfficeAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix, such as "NY" or "TX".
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
defaults: Defaults
head_office: Optional[HeadOffice]
"""
@@ -164,7 +105,7 @@ class RetrieveParams(RequestOptions):
status_details: StatusDetails
@classmethod
- def modify(cls, **params: Unpack["Settings.ModifyParams"]) -> "Settings":
+ def modify(cls, **params: Unpack["SettingsModifyParams"]) -> "Settings":
"""
Updates Tax Settings parameters used in tax calculations. All parameters are editable but none can be removed once set.
"""
@@ -179,7 +120,7 @@ def modify(cls, **params: Unpack["Settings.ModifyParams"]) -> "Settings":
@classmethod
async def modify_async(
- cls, **params: Unpack["Settings.ModifyParams"]
+ cls, **params: Unpack["SettingsModifyParams"]
) -> "Settings":
"""
Updates Tax Settings parameters used in tax calculations. All parameters are editable but none can be removed once set.
@@ -195,7 +136,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, **params: Unpack["Settings.RetrieveParams"]
+ cls, **params: Unpack["SettingsRetrieveParams"]
) -> "Settings":
"""
Retrieves Tax Settings for a merchant.
@@ -206,7 +147,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, **params: Unpack["Settings.RetrieveParams"]
+ cls, **params: Unpack["SettingsRetrieveParams"]
) -> "Settings":
"""
Retrieves Tax Settings for a merchant.
diff --git a/stripe/tax/_settings_service.py b/stripe/tax/_settings_service.py
index f8c3f917b..2d2db2631 100644
--- a/stripe/tax/_settings_service.py
+++ b/stripe/tax/_settings_service.py
@@ -3,78 +3,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe.tax._settings import Settings
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.tax._settings_retrieve_params import (
+ SettingsRetrieveParams,
+ )
+ from stripe.params.tax._settings_update_params import SettingsUpdateParams
-class SettingsService(StripeService):
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- defaults: NotRequired["SettingsService.UpdateParamsDefaults"]
- """
- Default configuration to be used on Stripe Tax calculations.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- head_office: NotRequired["SettingsService.UpdateParamsHeadOffice"]
- """
- The place where your business is located.
- """
-
- class UpdateParamsDefaults(TypedDict):
- tax_behavior: NotRequired[
- Literal["exclusive", "inclusive", "inferred_by_currency"]
- ]
- """
- Specifies the default [tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#tax-behavior) to be used when the item's price has unspecified tax behavior. One of inclusive, exclusive, or inferred_by_currency. Once specified, it cannot be changed back to null.
- """
- tax_code: NotRequired[str]
- """
- A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
- """
-
- class UpdateParamsHeadOffice(TypedDict):
- address: "SettingsService.UpdateParamsHeadOfficeAddress"
- """
- The location of the business for tax purposes.
- """
-
- class UpdateParamsHeadOfficeAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix, such as "NY" or "TX".
- """
+class SettingsService(StripeService):
def retrieve(
self,
- params: Optional["SettingsService.RetrieveParams"] = None,
+ params: Optional["SettingsRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Settings:
"""
@@ -93,7 +35,7 @@ def retrieve(
async def retrieve_async(
self,
- params: Optional["SettingsService.RetrieveParams"] = None,
+ params: Optional["SettingsRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Settings:
"""
@@ -112,7 +54,7 @@ async def retrieve_async(
def update(
self,
- params: Optional["SettingsService.UpdateParams"] = None,
+ params: Optional["SettingsUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Settings:
"""
@@ -131,7 +73,7 @@ def update(
async def update_async(
self,
- params: Optional["SettingsService.UpdateParams"] = None,
+ params: Optional["SettingsUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Settings:
"""
diff --git a/stripe/tax/_transaction.py b/stripe/tax/_transaction.py
index 91016c0a4..d2851fee2 100644
--- a/stripe/tax/_transaction.py
+++ b/stripe/tax/_transaction.py
@@ -2,19 +2,24 @@
# File generated from our OpenAPI spec
from stripe._api_resource import APIResource
from stripe._list_object import ListObject
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
+ from stripe.params.tax._transaction_create_from_calculation_params import (
+ TransactionCreateFromCalculationParams,
+ )
+ from stripe.params.tax._transaction_create_reversal_params import (
+ TransactionCreateReversalParams,
+ )
+ from stripe.params.tax._transaction_list_line_items_params import (
+ TransactionListLineItemsParams,
+ )
+ from stripe.params.tax._transaction_retrieve_params import (
+ TransactionRetrieveParams,
+ )
from stripe.tax._transaction_line_item import TransactionLineItem
@@ -355,126 +360,6 @@ class TaxRateDetails(StripeObject):
"""
_inner_class_types = {"tax_breakdown": TaxBreakdown}
- class CreateFromCalculationParams(RequestOptions):
- calculation: str
- """
- Tax Calculation ID to be used as input when creating the transaction.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- posted_at: NotRequired[int]
- """
- The Unix timestamp representing when the tax liability is assumed or reduced, which determines the liability posting period and handling in tax liability reports. The timestamp must fall within the `tax_date` and the current time, unless the `tax_date` is scheduled in advance. Defaults to the current time.
- """
- reference: str
- """
- A custom order or sale identifier, such as 'myOrder_123'. Must be unique across all transactions, including reversals.
- """
-
- class CreateReversalParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- flat_amount: NotRequired[int]
- """
- A flat amount to reverse across the entire transaction, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative. This value represents the total amount to refund from the transaction, including taxes.
- """
- line_items: NotRequired[
- List["Transaction.CreateReversalParamsLineItem"]
- ]
- """
- The line item amounts to reverse.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mode: Literal["full", "partial"]
- """
- If `partial`, the provided line item or shipping cost amounts are reversed. If `full`, the original transaction is fully reversed.
- """
- original_transaction: str
- """
- The ID of the Transaction to partially or fully reverse.
- """
- reference: str
- """
- A custom identifier for this reversal, such as `myOrder_123-refund_1`, which must be unique across all transactions. The reference helps identify this reversal transaction in exported [tax reports](https://stripe.com/docs/tax/reports).
- """
- shipping_cost: NotRequired[
- "Transaction.CreateReversalParamsShippingCost"
- ]
- """
- The shipping cost to reverse.
- """
-
- class CreateReversalParamsLineItem(TypedDict):
- amount: int
- """
- The amount to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
- """
- amount_tax: int
- """
- The amount of tax to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- """
- original_line_item: str
- """
- The `id` of the line item to reverse in the original transaction.
- """
- quantity: NotRequired[int]
- """
- The quantity reversed. Appears in [tax exports](https://stripe.com/docs/tax/reports), but does not affect the amount of tax reversed.
- """
- reference: str
- """
- A custom identifier for this line item in the reversal transaction, such as 'L1-refund'.
- """
-
- class CreateReversalParamsShippingCost(TypedDict):
- amount: int
- """
- The amount to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
- """
- amount_tax: int
- """
- The amount of tax to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
- """
-
- class ListLineItemsParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -539,7 +424,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create_from_calculation(
- cls, **params: Unpack["Transaction.CreateFromCalculationParams"]
+ cls, **params: Unpack["TransactionCreateFromCalculationParams"]
) -> "Transaction":
"""
Creates a Tax Transaction from a calculation, if that calculation hasn't expired. Calculations expire after 90 days.
@@ -555,7 +440,7 @@ def create_from_calculation(
@classmethod
async def create_from_calculation_async(
- cls, **params: Unpack["Transaction.CreateFromCalculationParams"]
+ cls, **params: Unpack["TransactionCreateFromCalculationParams"]
) -> "Transaction":
"""
Creates a Tax Transaction from a calculation, if that calculation hasn't expired. Calculations expire after 90 days.
@@ -571,7 +456,7 @@ async def create_from_calculation_async(
@classmethod
def create_reversal(
- cls, **params: Unpack["Transaction.CreateReversalParams"]
+ cls, **params: Unpack["TransactionCreateReversalParams"]
) -> "Transaction":
"""
Partially or fully reverses a previously created Transaction.
@@ -587,7 +472,7 @@ def create_reversal(
@classmethod
async def create_reversal_async(
- cls, **params: Unpack["Transaction.CreateReversalParams"]
+ cls, **params: Unpack["TransactionCreateReversalParams"]
) -> "Transaction":
"""
Partially or fully reverses a previously created Transaction.
@@ -605,7 +490,7 @@ async def create_reversal_async(
def _cls_list_line_items(
cls,
transaction: str,
- **params: Unpack["Transaction.ListLineItemsParams"],
+ **params: Unpack["TransactionListLineItemsParams"],
) -> ListObject["TransactionLineItem"]:
"""
Retrieves the line items of a committed standalone transaction as a collection.
@@ -624,7 +509,7 @@ def _cls_list_line_items(
@overload
@staticmethod
def list_line_items(
- transaction: str, **params: Unpack["Transaction.ListLineItemsParams"]
+ transaction: str, **params: Unpack["TransactionListLineItemsParams"]
) -> ListObject["TransactionLineItem"]:
"""
Retrieves the line items of a committed standalone transaction as a collection.
@@ -633,7 +518,7 @@ def list_line_items(
@overload
def list_line_items(
- self, **params: Unpack["Transaction.ListLineItemsParams"]
+ self, **params: Unpack["TransactionListLineItemsParams"]
) -> ListObject["TransactionLineItem"]:
"""
Retrieves the line items of a committed standalone transaction as a collection.
@@ -642,7 +527,7 @@ def list_line_items(
@class_method_variant("_cls_list_line_items")
def list_line_items( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Transaction.ListLineItemsParams"]
+ self, **params: Unpack["TransactionListLineItemsParams"]
) -> ListObject["TransactionLineItem"]:
"""
Retrieves the line items of a committed standalone transaction as a collection.
@@ -662,7 +547,7 @@ def list_line_items( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_list_line_items_async(
cls,
transaction: str,
- **params: Unpack["Transaction.ListLineItemsParams"],
+ **params: Unpack["TransactionListLineItemsParams"],
) -> ListObject["TransactionLineItem"]:
"""
Retrieves the line items of a committed standalone transaction as a collection.
@@ -681,7 +566,7 @@ async def _cls_list_line_items_async(
@overload
@staticmethod
async def list_line_items_async(
- transaction: str, **params: Unpack["Transaction.ListLineItemsParams"]
+ transaction: str, **params: Unpack["TransactionListLineItemsParams"]
) -> ListObject["TransactionLineItem"]:
"""
Retrieves the line items of a committed standalone transaction as a collection.
@@ -690,7 +575,7 @@ async def list_line_items_async(
@overload
async def list_line_items_async(
- self, **params: Unpack["Transaction.ListLineItemsParams"]
+ self, **params: Unpack["TransactionListLineItemsParams"]
) -> ListObject["TransactionLineItem"]:
"""
Retrieves the line items of a committed standalone transaction as a collection.
@@ -699,7 +584,7 @@ async def list_line_items_async(
@class_method_variant("_cls_list_line_items_async")
async def list_line_items_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Transaction.ListLineItemsParams"]
+ self, **params: Unpack["TransactionListLineItemsParams"]
) -> ListObject["TransactionLineItem"]:
"""
Retrieves the line items of a committed standalone transaction as a collection.
@@ -717,7 +602,7 @@ async def list_line_items_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Transaction.RetrieveParams"]
+ cls, id: str, **params: Unpack["TransactionRetrieveParams"]
) -> "Transaction":
"""
Retrieves a Tax Transaction object.
@@ -728,7 +613,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Transaction.RetrieveParams"]
+ cls, id: str, **params: Unpack["TransactionRetrieveParams"]
) -> "Transaction":
"""
Retrieves a Tax Transaction object.
diff --git a/stripe/tax/_transaction_line_item_service.py b/stripe/tax/_transaction_line_item_service.py
index 7fc5be384..f1762c07b 100644
--- a/stripe/tax/_transaction_line_item_service.py
+++ b/stripe/tax/_transaction_line_item_service.py
@@ -5,33 +5,20 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.tax._transaction_line_item import TransactionLineItem
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.tax._transaction_line_item_list_params import (
+ TransactionLineItemListParams,
+ )
-class TransactionLineItemService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
+class TransactionLineItemService(StripeService):
def list(
self,
transaction: str,
- params: Optional["TransactionLineItemService.ListParams"] = None,
+ params: Optional["TransactionLineItemListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[TransactionLineItem]:
"""
@@ -53,7 +40,7 @@ def list(
async def list_async(
self,
transaction: str,
- params: Optional["TransactionLineItemService.ListParams"] = None,
+ 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 85c9c1596..812c4ed48 100644
--- a/stripe/tax/_transaction_service.py
+++ b/stripe/tax/_transaction_service.py
@@ -7,8 +7,19 @@
from stripe.tax._transaction_line_item_service import (
TransactionLineItemService,
)
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.tax._transaction_create_from_calculation_params import (
+ TransactionCreateFromCalculationParams,
+ )
+ from stripe.params.tax._transaction_create_reversal_params import (
+ TransactionCreateReversalParams,
+ )
+ from stripe.params.tax._transaction_retrieve_params import (
+ TransactionRetrieveParams,
+ )
class TransactionService(StripeService):
@@ -16,112 +27,10 @@ def __init__(self, requestor):
super().__init__(requestor)
self.line_items = TransactionLineItemService(self._requestor)
- class CreateFromCalculationParams(TypedDict):
- calculation: str
- """
- Tax Calculation ID to be used as input when creating the transaction.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- posted_at: NotRequired[int]
- """
- The Unix timestamp representing when the tax liability is assumed or reduced, which determines the liability posting period and handling in tax liability reports. The timestamp must fall within the `tax_date` and the current time, unless the `tax_date` is scheduled in advance. Defaults to the current time.
- """
- reference: str
- """
- A custom order or sale identifier, such as 'myOrder_123'. Must be unique across all transactions, including reversals.
- """
-
- class CreateReversalParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- flat_amount: NotRequired[int]
- """
- A flat amount to reverse across the entire transaction, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative. This value represents the total amount to refund from the transaction, including taxes.
- """
- line_items: NotRequired[
- List["TransactionService.CreateReversalParamsLineItem"]
- ]
- """
- The line item amounts to reverse.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mode: Literal["full", "partial"]
- """
- If `partial`, the provided line item or shipping cost amounts are reversed. If `full`, the original transaction is fully reversed.
- """
- original_transaction: str
- """
- The ID of the Transaction to partially or fully reverse.
- """
- reference: str
- """
- A custom identifier for this reversal, such as `myOrder_123-refund_1`, which must be unique across all transactions. The reference helps identify this reversal transaction in exported [tax reports](https://stripe.com/docs/tax/reports).
- """
- shipping_cost: NotRequired[
- "TransactionService.CreateReversalParamsShippingCost"
- ]
- """
- The shipping cost to reverse.
- """
-
- class CreateReversalParamsLineItem(TypedDict):
- amount: int
- """
- The amount to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
- """
- amount_tax: int
- """
- The amount of tax to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- """
- original_line_item: str
- """
- The `id` of the line item to reverse in the original transaction.
- """
- quantity: NotRequired[int]
- """
- The quantity reversed. Appears in [tax exports](https://stripe.com/docs/tax/reports), but does not affect the amount of tax reversed.
- """
- reference: str
- """
- A custom identifier for this line item in the reversal transaction, such as 'L1-refund'.
- """
-
- class CreateReversalParamsShippingCost(TypedDict):
- amount: int
- """
- The amount to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
- """
- amount_tax: int
- """
- The amount of tax to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
def retrieve(
self,
transaction: str,
- params: Optional["TransactionService.RetrieveParams"] = None,
+ params: Optional["TransactionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
@@ -143,7 +52,7 @@ def retrieve(
async def retrieve_async(
self,
transaction: str,
- params: Optional["TransactionService.RetrieveParams"] = None,
+ params: Optional["TransactionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
@@ -164,7 +73,7 @@ async def retrieve_async(
def create_from_calculation(
self,
- params: "TransactionService.CreateFromCalculationParams",
+ params: "TransactionCreateFromCalculationParams",
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
@@ -183,7 +92,7 @@ def create_from_calculation(
async def create_from_calculation_async(
self,
- params: "TransactionService.CreateFromCalculationParams",
+ params: "TransactionCreateFromCalculationParams",
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
@@ -202,7 +111,7 @@ async def create_from_calculation_async(
def create_reversal(
self,
- params: "TransactionService.CreateReversalParams",
+ params: "TransactionCreateReversalParams",
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
@@ -221,7 +130,7 @@ def create_reversal(
async def create_reversal_async(
self,
- params: "TransactionService.CreateReversalParams",
+ params: "TransactionCreateReversalParams",
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
diff --git a/stripe/terminal/_configuration.py b/stripe/terminal/_configuration.py
index 390bfabc9..494521596 100644
--- a/stripe/terminal/_configuration.py
+++ b/stripe/terminal/_configuration.py
@@ -5,21 +5,29 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._file import File
+ from stripe.params.terminal._configuration_create_params import (
+ ConfigurationCreateParams,
+ )
+ from stripe.params.terminal._configuration_delete_params import (
+ ConfigurationDeleteParams,
+ )
+ from stripe.params.terminal._configuration_list_params import (
+ ConfigurationListParams,
+ )
+ from stripe.params.terminal._configuration_modify_params import (
+ ConfigurationModifyParams,
+ )
+ from stripe.params.terminal._configuration_retrieve_params import (
+ ConfigurationRetrieveParams,
+ )
class Configuration(
@@ -483,1119 +491,6 @@ class PersonalPsk(StripeObject):
"personal_psk": PersonalPsk,
}
- class CreateParams(RequestOptions):
- bbpos_wisepad3: NotRequired["Configuration.CreateParamsBbposWisepad3"]
- """
- An object containing device type specific settings for BBPOS WisePad 3 readers
- """
- bbpos_wisepos_e: NotRequired["Configuration.CreateParamsBbposWiseposE"]
- """
- An object containing device type specific settings for BBPOS WisePOS E readers
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- name: NotRequired[str]
- """
- Name of the configuration
- """
- offline: NotRequired["Literal['']|Configuration.CreateParamsOffline"]
- """
- Configurations for collecting transactions offline.
- """
- reboot_window: NotRequired["Configuration.CreateParamsRebootWindow"]
- """
- Reboot time settings for readers that support customized reboot time configuration.
- """
- stripe_s700: NotRequired["Configuration.CreateParamsStripeS700"]
- """
- An object containing device type specific settings for Stripe S700 readers
- """
- tipping: NotRequired["Literal['']|Configuration.CreateParamsTipping"]
- """
- Tipping configurations for readers supporting on-reader tips
- """
- verifone_p400: NotRequired["Configuration.CreateParamsVerifoneP400"]
- """
- An object containing device type specific settings for Verifone P400 readers
- """
- wifi: NotRequired["Literal['']|Configuration.CreateParamsWifi"]
- """
- Configurations for connecting to a WiFi network.
- """
-
- class CreateParamsBbposWisepad3(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image you would like displayed on the reader.
- """
-
- class CreateParamsBbposWiseposE(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image to display on the reader
- """
-
- class CreateParamsOffline(TypedDict):
- enabled: bool
- """
- Determines whether to allow transactions to be collected while reader is offline. Defaults to false.
- """
-
- class CreateParamsRebootWindow(TypedDict):
- end_hour: int
- """
- Integer between 0 to 23 that represents the end hour of the reboot time window. The value must be different than the start_hour.
- """
- start_hour: int
- """
- Integer between 0 to 23 that represents the start hour of the reboot time window.
- """
-
- class CreateParamsStripeS700(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image you would like displayed on the reader.
- """
-
- class CreateParamsTipping(TypedDict):
- aed: NotRequired["Configuration.CreateParamsTippingAed"]
- """
- Tipping configuration for AED
- """
- aud: NotRequired["Configuration.CreateParamsTippingAud"]
- """
- Tipping configuration for AUD
- """
- bgn: NotRequired["Configuration.CreateParamsTippingBgn"]
- """
- Tipping configuration for BGN
- """
- cad: NotRequired["Configuration.CreateParamsTippingCad"]
- """
- Tipping configuration for CAD
- """
- chf: NotRequired["Configuration.CreateParamsTippingChf"]
- """
- Tipping configuration for CHF
- """
- czk: NotRequired["Configuration.CreateParamsTippingCzk"]
- """
- Tipping configuration for CZK
- """
- dkk: NotRequired["Configuration.CreateParamsTippingDkk"]
- """
- Tipping configuration for DKK
- """
- eur: NotRequired["Configuration.CreateParamsTippingEur"]
- """
- Tipping configuration for EUR
- """
- gbp: NotRequired["Configuration.CreateParamsTippingGbp"]
- """
- Tipping configuration for GBP
- """
- hkd: NotRequired["Configuration.CreateParamsTippingHkd"]
- """
- Tipping configuration for HKD
- """
- huf: NotRequired["Configuration.CreateParamsTippingHuf"]
- """
- Tipping configuration for HUF
- """
- jpy: NotRequired["Configuration.CreateParamsTippingJpy"]
- """
- Tipping configuration for JPY
- """
- mxn: NotRequired["Configuration.CreateParamsTippingMxn"]
- """
- Tipping configuration for MXN
- """
- myr: NotRequired["Configuration.CreateParamsTippingMyr"]
- """
- Tipping configuration for MYR
- """
- nok: NotRequired["Configuration.CreateParamsTippingNok"]
- """
- Tipping configuration for NOK
- """
- nzd: NotRequired["Configuration.CreateParamsTippingNzd"]
- """
- Tipping configuration for NZD
- """
- pln: NotRequired["Configuration.CreateParamsTippingPln"]
- """
- Tipping configuration for PLN
- """
- ron: NotRequired["Configuration.CreateParamsTippingRon"]
- """
- Tipping configuration for RON
- """
- sek: NotRequired["Configuration.CreateParamsTippingSek"]
- """
- Tipping configuration for SEK
- """
- sgd: NotRequired["Configuration.CreateParamsTippingSgd"]
- """
- Tipping configuration for SGD
- """
- usd: NotRequired["Configuration.CreateParamsTippingUsd"]
- """
- Tipping configuration for USD
- """
-
- class CreateParamsTippingAed(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingAud(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingBgn(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingCad(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingChf(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingCzk(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingDkk(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingEur(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingGbp(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingHkd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingHuf(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingJpy(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingMxn(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingMyr(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingNok(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingNzd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingPln(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingRon(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingSek(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingSgd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingUsd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsVerifoneP400(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image you would like displayed on the reader.
- """
-
- class CreateParamsWifi(TypedDict):
- enterprise_eap_peap: NotRequired[
- "Configuration.CreateParamsWifiEnterpriseEapPeap"
- ]
- """
- Credentials for a WPA-Enterprise WiFi network using the EAP-PEAP authentication method.
- """
- enterprise_eap_tls: NotRequired[
- "Configuration.CreateParamsWifiEnterpriseEapTls"
- ]
- """
- Credentials for a WPA-Enterprise WiFi network using the EAP-TLS authentication method.
- """
- personal_psk: NotRequired["Configuration.CreateParamsWifiPersonalPsk"]
- """
- Credentials for a WPA-Personal WiFi network.
- """
- type: Literal[
- "enterprise_eap_peap", "enterprise_eap_tls", "personal_psk"
- ]
- """
- Security type of the WiFi network. Fill out the hash with the corresponding name to provide the set of credentials for this security type.
- """
-
- class CreateParamsWifiEnterpriseEapPeap(TypedDict):
- ca_certificate_file: NotRequired[str]
- """
- A File ID representing a PEM file containing the server certificate
- """
- password: str
- """
- Password for connecting to the WiFi network
- """
- ssid: str
- """
- Name of the WiFi network
- """
- username: str
- """
- Username for connecting to the WiFi network
- """
-
- class CreateParamsWifiEnterpriseEapTls(TypedDict):
- ca_certificate_file: NotRequired[str]
- """
- A File ID representing a PEM file containing the server certificate
- """
- client_certificate_file: str
- """
- A File ID representing a PEM file containing the client certificate
- """
- private_key_file: str
- """
- A File ID representing a PEM file containing the client RSA private key
- """
- private_key_file_password: NotRequired[str]
- """
- Password for the private key file
- """
- ssid: str
- """
- Name of the WiFi network
- """
-
- class CreateParamsWifiPersonalPsk(TypedDict):
- password: str
- """
- Password for connecting to the WiFi network
- """
- ssid: str
- """
- Name of the WiFi network
- """
-
- class DeleteParams(RequestOptions):
- pass
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- is_account_default: NotRequired[bool]
- """
- if present, only return the account default or non-default configurations.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ModifyParams(RequestOptions):
- bbpos_wisepad3: NotRequired[
- "Literal['']|Configuration.ModifyParamsBbposWisepad3"
- ]
- """
- An object containing device type specific settings for BBPOS WisePad 3 readers
- """
- bbpos_wisepos_e: NotRequired[
- "Literal['']|Configuration.ModifyParamsBbposWiseposE"
- ]
- """
- An object containing device type specific settings for BBPOS WisePOS E readers
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- name: NotRequired[str]
- """
- Name of the configuration
- """
- offline: NotRequired["Literal['']|Configuration.ModifyParamsOffline"]
- """
- Configurations for collecting transactions offline.
- """
- reboot_window: NotRequired[
- "Literal['']|Configuration.ModifyParamsRebootWindow"
- ]
- """
- Reboot time settings for readers that support customized reboot time configuration.
- """
- stripe_s700: NotRequired[
- "Literal['']|Configuration.ModifyParamsStripeS700"
- ]
- """
- An object containing device type specific settings for Stripe S700 readers
- """
- tipping: NotRequired["Literal['']|Configuration.ModifyParamsTipping"]
- """
- Tipping configurations for readers supporting on-reader tips
- """
- verifone_p400: NotRequired[
- "Literal['']|Configuration.ModifyParamsVerifoneP400"
- ]
- """
- An object containing device type specific settings for Verifone P400 readers
- """
- wifi: NotRequired["Literal['']|Configuration.ModifyParamsWifi"]
- """
- Configurations for connecting to a WiFi network.
- """
-
- class ModifyParamsBbposWisepad3(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image you would like displayed on the reader.
- """
-
- class ModifyParamsBbposWiseposE(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image to display on the reader
- """
-
- class ModifyParamsOffline(TypedDict):
- enabled: bool
- """
- Determines whether to allow transactions to be collected while reader is offline. Defaults to false.
- """
-
- class ModifyParamsRebootWindow(TypedDict):
- end_hour: int
- """
- Integer between 0 to 23 that represents the end hour of the reboot time window. The value must be different than the start_hour.
- """
- start_hour: int
- """
- Integer between 0 to 23 that represents the start hour of the reboot time window.
- """
-
- class ModifyParamsStripeS700(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image you would like displayed on the reader.
- """
-
- class ModifyParamsTipping(TypedDict):
- aed: NotRequired["Configuration.ModifyParamsTippingAed"]
- """
- Tipping configuration for AED
- """
- aud: NotRequired["Configuration.ModifyParamsTippingAud"]
- """
- Tipping configuration for AUD
- """
- bgn: NotRequired["Configuration.ModifyParamsTippingBgn"]
- """
- Tipping configuration for BGN
- """
- cad: NotRequired["Configuration.ModifyParamsTippingCad"]
- """
- Tipping configuration for CAD
- """
- chf: NotRequired["Configuration.ModifyParamsTippingChf"]
- """
- Tipping configuration for CHF
- """
- czk: NotRequired["Configuration.ModifyParamsTippingCzk"]
- """
- Tipping configuration for CZK
- """
- dkk: NotRequired["Configuration.ModifyParamsTippingDkk"]
- """
- Tipping configuration for DKK
- """
- eur: NotRequired["Configuration.ModifyParamsTippingEur"]
- """
- Tipping configuration for EUR
- """
- gbp: NotRequired["Configuration.ModifyParamsTippingGbp"]
- """
- Tipping configuration for GBP
- """
- hkd: NotRequired["Configuration.ModifyParamsTippingHkd"]
- """
- Tipping configuration for HKD
- """
- huf: NotRequired["Configuration.ModifyParamsTippingHuf"]
- """
- Tipping configuration for HUF
- """
- jpy: NotRequired["Configuration.ModifyParamsTippingJpy"]
- """
- Tipping configuration for JPY
- """
- mxn: NotRequired["Configuration.ModifyParamsTippingMxn"]
- """
- Tipping configuration for MXN
- """
- myr: NotRequired["Configuration.ModifyParamsTippingMyr"]
- """
- Tipping configuration for MYR
- """
- nok: NotRequired["Configuration.ModifyParamsTippingNok"]
- """
- Tipping configuration for NOK
- """
- nzd: NotRequired["Configuration.ModifyParamsTippingNzd"]
- """
- Tipping configuration for NZD
- """
- pln: NotRequired["Configuration.ModifyParamsTippingPln"]
- """
- Tipping configuration for PLN
- """
- ron: NotRequired["Configuration.ModifyParamsTippingRon"]
- """
- Tipping configuration for RON
- """
- sek: NotRequired["Configuration.ModifyParamsTippingSek"]
- """
- Tipping configuration for SEK
- """
- sgd: NotRequired["Configuration.ModifyParamsTippingSgd"]
- """
- Tipping configuration for SGD
- """
- usd: NotRequired["Configuration.ModifyParamsTippingUsd"]
- """
- Tipping configuration for USD
- """
-
- class ModifyParamsTippingAed(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingAud(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingBgn(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingCad(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingChf(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingCzk(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingDkk(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingEur(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingGbp(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingHkd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingHuf(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingJpy(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingMxn(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingMyr(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingNok(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingNzd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingPln(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingRon(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingSek(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingSgd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsTippingUsd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class ModifyParamsVerifoneP400(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image you would like displayed on the reader.
- """
-
- class ModifyParamsWifi(TypedDict):
- enterprise_eap_peap: NotRequired[
- "Configuration.ModifyParamsWifiEnterpriseEapPeap"
- ]
- """
- Credentials for a WPA-Enterprise WiFi network using the EAP-PEAP authentication method.
- """
- enterprise_eap_tls: NotRequired[
- "Configuration.ModifyParamsWifiEnterpriseEapTls"
- ]
- """
- Credentials for a WPA-Enterprise WiFi network using the EAP-TLS authentication method.
- """
- personal_psk: NotRequired["Configuration.ModifyParamsWifiPersonalPsk"]
- """
- Credentials for a WPA-Personal WiFi network.
- """
- type: Literal[
- "enterprise_eap_peap", "enterprise_eap_tls", "personal_psk"
- ]
- """
- Security type of the WiFi network. Fill out the hash with the corresponding name to provide the set of credentials for this security type.
- """
-
- class ModifyParamsWifiEnterpriseEapPeap(TypedDict):
- ca_certificate_file: NotRequired[str]
- """
- A File ID representing a PEM file containing the server certificate
- """
- password: str
- """
- Password for connecting to the WiFi network
- """
- ssid: str
- """
- Name of the WiFi network
- """
- username: str
- """
- Username for connecting to the WiFi network
- """
-
- class ModifyParamsWifiEnterpriseEapTls(TypedDict):
- ca_certificate_file: NotRequired[str]
- """
- A File ID representing a PEM file containing the server certificate
- """
- client_certificate_file: str
- """
- A File ID representing a PEM file containing the client certificate
- """
- private_key_file: str
- """
- A File ID representing a PEM file containing the client RSA private key
- """
- private_key_file_password: NotRequired[str]
- """
- Password for the private key file
- """
- ssid: str
- """
- Name of the WiFi network
- """
-
- class ModifyParamsWifiPersonalPsk(TypedDict):
- password: str
- """
- Password for connecting to the WiFi network
- """
- ssid: str
- """
- Name of the WiFi network
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
bbpos_wisepad3: Optional[BbposWisepad3]
bbpos_wisepos_e: Optional[BbposWiseposE]
deleted: Optional[Literal[True]]
@@ -1631,7 +526,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["Configuration.CreateParams"]
+ cls, **params: Unpack["ConfigurationCreateParams"]
) -> "Configuration":
"""
Creates a new Configuration object.
@@ -1647,7 +542,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["Configuration.CreateParams"]
+ cls, **params: Unpack["ConfigurationCreateParams"]
) -> "Configuration":
"""
Creates a new Configuration object.
@@ -1663,7 +558,7 @@ async def create_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["Configuration.DeleteParams"]
+ cls, sid: str, **params: Unpack["ConfigurationDeleteParams"]
) -> "Configuration":
"""
Deletes a Configuration object.
@@ -1681,7 +576,7 @@ def _cls_delete(
@overload
@staticmethod
def delete(
- sid: str, **params: Unpack["Configuration.DeleteParams"]
+ sid: str, **params: Unpack["ConfigurationDeleteParams"]
) -> "Configuration":
"""
Deletes a Configuration object.
@@ -1690,7 +585,7 @@ def delete(
@overload
def delete(
- self, **params: Unpack["Configuration.DeleteParams"]
+ self, **params: Unpack["ConfigurationDeleteParams"]
) -> "Configuration":
"""
Deletes a Configuration object.
@@ -1699,7 +594,7 @@ def delete(
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Configuration.DeleteParams"]
+ self, **params: Unpack["ConfigurationDeleteParams"]
) -> "Configuration":
"""
Deletes a Configuration object.
@@ -1712,7 +607,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["Configuration.DeleteParams"]
+ cls, sid: str, **params: Unpack["ConfigurationDeleteParams"]
) -> "Configuration":
"""
Deletes a Configuration object.
@@ -1730,7 +625,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["Configuration.DeleteParams"]
+ sid: str, **params: Unpack["ConfigurationDeleteParams"]
) -> "Configuration":
"""
Deletes a Configuration object.
@@ -1739,7 +634,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["Configuration.DeleteParams"]
+ self, **params: Unpack["ConfigurationDeleteParams"]
) -> "Configuration":
"""
Deletes a Configuration object.
@@ -1748,7 +643,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Configuration.DeleteParams"]
+ self, **params: Unpack["ConfigurationDeleteParams"]
) -> "Configuration":
"""
Deletes a Configuration object.
@@ -1761,7 +656,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["Configuration.ListParams"]
+ cls, **params: Unpack["ConfigurationListParams"]
) -> ListObject["Configuration"]:
"""
Returns a list of Configuration objects.
@@ -1781,7 +676,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Configuration.ListParams"]
+ cls, **params: Unpack["ConfigurationListParams"]
) -> ListObject["Configuration"]:
"""
Returns a list of Configuration objects.
@@ -1801,7 +696,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Configuration.ModifyParams"]
+ cls, id: str, **params: Unpack["ConfigurationModifyParams"]
) -> "Configuration":
"""
Updates a new Configuration object.
@@ -1818,7 +713,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Configuration.ModifyParams"]
+ cls, id: str, **params: Unpack["ConfigurationModifyParams"]
) -> "Configuration":
"""
Updates a new Configuration object.
@@ -1835,7 +730,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Configuration.RetrieveParams"]
+ cls, id: str, **params: Unpack["ConfigurationRetrieveParams"]
) -> "Configuration":
"""
Retrieves a Configuration object.
@@ -1846,7 +741,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Configuration.RetrieveParams"]
+ cls, id: str, **params: Unpack["ConfigurationRetrieveParams"]
) -> "Configuration":
"""
Retrieves a Configuration object.
diff --git a/stripe/terminal/_configuration_service.py b/stripe/terminal/_configuration_service.py
index cd79f7e8e..f7f3350c2 100644
--- a/stripe/terminal/_configuration_service.py
+++ b/stripe/terminal/_configuration_service.py
@@ -5,1148 +5,32 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.terminal._configuration import Configuration
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.terminal._configuration_create_params import (
+ ConfigurationCreateParams,
+ )
+ from stripe.params.terminal._configuration_delete_params import (
+ ConfigurationDeleteParams,
+ )
+ from stripe.params.terminal._configuration_list_params import (
+ ConfigurationListParams,
+ )
+ from stripe.params.terminal._configuration_retrieve_params import (
+ ConfigurationRetrieveParams,
+ )
+ from stripe.params.terminal._configuration_update_params import (
+ ConfigurationUpdateParams,
+ )
class ConfigurationService(StripeService):
- class CreateParams(TypedDict):
- bbpos_wisepad3: NotRequired[
- "ConfigurationService.CreateParamsBbposWisepad3"
- ]
- """
- An object containing device type specific settings for BBPOS WisePad 3 readers
- """
- bbpos_wisepos_e: NotRequired[
- "ConfigurationService.CreateParamsBbposWiseposE"
- ]
- """
- An object containing device type specific settings for BBPOS WisePOS E readers
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- name: NotRequired[str]
- """
- Name of the configuration
- """
- offline: NotRequired[
- "Literal['']|ConfigurationService.CreateParamsOffline"
- ]
- """
- Configurations for collecting transactions offline.
- """
- reboot_window: NotRequired[
- "ConfigurationService.CreateParamsRebootWindow"
- ]
- """
- Reboot time settings for readers that support customized reboot time configuration.
- """
- stripe_s700: NotRequired["ConfigurationService.CreateParamsStripeS700"]
- """
- An object containing device type specific settings for Stripe S700 readers
- """
- tipping: NotRequired[
- "Literal['']|ConfigurationService.CreateParamsTipping"
- ]
- """
- Tipping configurations for readers supporting on-reader tips
- """
- verifone_p400: NotRequired[
- "ConfigurationService.CreateParamsVerifoneP400"
- ]
- """
- An object containing device type specific settings for Verifone P400 readers
- """
- wifi: NotRequired["Literal['']|ConfigurationService.CreateParamsWifi"]
- """
- Configurations for connecting to a WiFi network.
- """
-
- class CreateParamsBbposWisepad3(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image you would like displayed on the reader.
- """
-
- class CreateParamsBbposWiseposE(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image to display on the reader
- """
-
- class CreateParamsOffline(TypedDict):
- enabled: bool
- """
- Determines whether to allow transactions to be collected while reader is offline. Defaults to false.
- """
-
- class CreateParamsRebootWindow(TypedDict):
- end_hour: int
- """
- Integer between 0 to 23 that represents the end hour of the reboot time window. The value must be different than the start_hour.
- """
- start_hour: int
- """
- Integer between 0 to 23 that represents the start hour of the reboot time window.
- """
-
- class CreateParamsStripeS700(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image you would like displayed on the reader.
- """
-
- class CreateParamsTipping(TypedDict):
- aed: NotRequired["ConfigurationService.CreateParamsTippingAed"]
- """
- Tipping configuration for AED
- """
- aud: NotRequired["ConfigurationService.CreateParamsTippingAud"]
- """
- Tipping configuration for AUD
- """
- bgn: NotRequired["ConfigurationService.CreateParamsTippingBgn"]
- """
- Tipping configuration for BGN
- """
- cad: NotRequired["ConfigurationService.CreateParamsTippingCad"]
- """
- Tipping configuration for CAD
- """
- chf: NotRequired["ConfigurationService.CreateParamsTippingChf"]
- """
- Tipping configuration for CHF
- """
- czk: NotRequired["ConfigurationService.CreateParamsTippingCzk"]
- """
- Tipping configuration for CZK
- """
- dkk: NotRequired["ConfigurationService.CreateParamsTippingDkk"]
- """
- Tipping configuration for DKK
- """
- eur: NotRequired["ConfigurationService.CreateParamsTippingEur"]
- """
- Tipping configuration for EUR
- """
- gbp: NotRequired["ConfigurationService.CreateParamsTippingGbp"]
- """
- Tipping configuration for GBP
- """
- hkd: NotRequired["ConfigurationService.CreateParamsTippingHkd"]
- """
- Tipping configuration for HKD
- """
- huf: NotRequired["ConfigurationService.CreateParamsTippingHuf"]
- """
- Tipping configuration for HUF
- """
- jpy: NotRequired["ConfigurationService.CreateParamsTippingJpy"]
- """
- Tipping configuration for JPY
- """
- mxn: NotRequired["ConfigurationService.CreateParamsTippingMxn"]
- """
- Tipping configuration for MXN
- """
- myr: NotRequired["ConfigurationService.CreateParamsTippingMyr"]
- """
- Tipping configuration for MYR
- """
- nok: NotRequired["ConfigurationService.CreateParamsTippingNok"]
- """
- Tipping configuration for NOK
- """
- nzd: NotRequired["ConfigurationService.CreateParamsTippingNzd"]
- """
- Tipping configuration for NZD
- """
- pln: NotRequired["ConfigurationService.CreateParamsTippingPln"]
- """
- Tipping configuration for PLN
- """
- ron: NotRequired["ConfigurationService.CreateParamsTippingRon"]
- """
- Tipping configuration for RON
- """
- sek: NotRequired["ConfigurationService.CreateParamsTippingSek"]
- """
- Tipping configuration for SEK
- """
- sgd: NotRequired["ConfigurationService.CreateParamsTippingSgd"]
- """
- Tipping configuration for SGD
- """
- usd: NotRequired["ConfigurationService.CreateParamsTippingUsd"]
- """
- Tipping configuration for USD
- """
-
- class CreateParamsTippingAed(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingAud(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingBgn(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingCad(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingChf(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingCzk(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingDkk(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingEur(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingGbp(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingHkd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingHuf(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingJpy(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingMxn(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingMyr(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingNok(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingNzd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingPln(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingRon(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingSek(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingSgd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsTippingUsd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class CreateParamsVerifoneP400(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image you would like displayed on the reader.
- """
-
- class CreateParamsWifi(TypedDict):
- enterprise_eap_peap: NotRequired[
- "ConfigurationService.CreateParamsWifiEnterpriseEapPeap"
- ]
- """
- Credentials for a WPA-Enterprise WiFi network using the EAP-PEAP authentication method.
- """
- enterprise_eap_tls: NotRequired[
- "ConfigurationService.CreateParamsWifiEnterpriseEapTls"
- ]
- """
- Credentials for a WPA-Enterprise WiFi network using the EAP-TLS authentication method.
- """
- personal_psk: NotRequired[
- "ConfigurationService.CreateParamsWifiPersonalPsk"
- ]
- """
- Credentials for a WPA-Personal WiFi network.
- """
- type: Literal[
- "enterprise_eap_peap", "enterprise_eap_tls", "personal_psk"
- ]
- """
- Security type of the WiFi network. Fill out the hash with the corresponding name to provide the set of credentials for this security type.
- """
-
- class CreateParamsWifiEnterpriseEapPeap(TypedDict):
- ca_certificate_file: NotRequired[str]
- """
- A File ID representing a PEM file containing the server certificate
- """
- password: str
- """
- Password for connecting to the WiFi network
- """
- ssid: str
- """
- Name of the WiFi network
- """
- username: str
- """
- Username for connecting to the WiFi network
- """
-
- class CreateParamsWifiEnterpriseEapTls(TypedDict):
- ca_certificate_file: NotRequired[str]
- """
- A File ID representing a PEM file containing the server certificate
- """
- client_certificate_file: str
- """
- A File ID representing a PEM file containing the client certificate
- """
- private_key_file: str
- """
- A File ID representing a PEM file containing the client RSA private key
- """
- private_key_file_password: NotRequired[str]
- """
- Password for the private key file
- """
- ssid: str
- """
- Name of the WiFi network
- """
-
- class CreateParamsWifiPersonalPsk(TypedDict):
- password: str
- """
- Password for connecting to the WiFi network
- """
- ssid: str
- """
- Name of the WiFi network
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- is_account_default: NotRequired[bool]
- """
- if present, only return the account default or non-default configurations.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- bbpos_wisepad3: NotRequired[
- "Literal['']|ConfigurationService.UpdateParamsBbposWisepad3"
- ]
- """
- An object containing device type specific settings for BBPOS WisePad 3 readers
- """
- bbpos_wisepos_e: NotRequired[
- "Literal['']|ConfigurationService.UpdateParamsBbposWiseposE"
- ]
- """
- An object containing device type specific settings for BBPOS WisePOS E readers
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- name: NotRequired[str]
- """
- Name of the configuration
- """
- offline: NotRequired[
- "Literal['']|ConfigurationService.UpdateParamsOffline"
- ]
- """
- Configurations for collecting transactions offline.
- """
- reboot_window: NotRequired[
- "Literal['']|ConfigurationService.UpdateParamsRebootWindow"
- ]
- """
- Reboot time settings for readers that support customized reboot time configuration.
- """
- stripe_s700: NotRequired[
- "Literal['']|ConfigurationService.UpdateParamsStripeS700"
- ]
- """
- An object containing device type specific settings for Stripe S700 readers
- """
- tipping: NotRequired[
- "Literal['']|ConfigurationService.UpdateParamsTipping"
- ]
- """
- Tipping configurations for readers supporting on-reader tips
- """
- verifone_p400: NotRequired[
- "Literal['']|ConfigurationService.UpdateParamsVerifoneP400"
- ]
- """
- An object containing device type specific settings for Verifone P400 readers
- """
- wifi: NotRequired["Literal['']|ConfigurationService.UpdateParamsWifi"]
- """
- Configurations for connecting to a WiFi network.
- """
-
- class UpdateParamsBbposWisepad3(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image you would like displayed on the reader.
- """
-
- class UpdateParamsBbposWiseposE(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image to display on the reader
- """
-
- class UpdateParamsOffline(TypedDict):
- enabled: bool
- """
- Determines whether to allow transactions to be collected while reader is offline. Defaults to false.
- """
-
- class UpdateParamsRebootWindow(TypedDict):
- end_hour: int
- """
- Integer between 0 to 23 that represents the end hour of the reboot time window. The value must be different than the start_hour.
- """
- start_hour: int
- """
- Integer between 0 to 23 that represents the start hour of the reboot time window.
- """
-
- class UpdateParamsStripeS700(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image you would like displayed on the reader.
- """
-
- class UpdateParamsTipping(TypedDict):
- aed: NotRequired["ConfigurationService.UpdateParamsTippingAed"]
- """
- Tipping configuration for AED
- """
- aud: NotRequired["ConfigurationService.UpdateParamsTippingAud"]
- """
- Tipping configuration for AUD
- """
- bgn: NotRequired["ConfigurationService.UpdateParamsTippingBgn"]
- """
- Tipping configuration for BGN
- """
- cad: NotRequired["ConfigurationService.UpdateParamsTippingCad"]
- """
- Tipping configuration for CAD
- """
- chf: NotRequired["ConfigurationService.UpdateParamsTippingChf"]
- """
- Tipping configuration for CHF
- """
- czk: NotRequired["ConfigurationService.UpdateParamsTippingCzk"]
- """
- Tipping configuration for CZK
- """
- dkk: NotRequired["ConfigurationService.UpdateParamsTippingDkk"]
- """
- Tipping configuration for DKK
- """
- eur: NotRequired["ConfigurationService.UpdateParamsTippingEur"]
- """
- Tipping configuration for EUR
- """
- gbp: NotRequired["ConfigurationService.UpdateParamsTippingGbp"]
- """
- Tipping configuration for GBP
- """
- hkd: NotRequired["ConfigurationService.UpdateParamsTippingHkd"]
- """
- Tipping configuration for HKD
- """
- huf: NotRequired["ConfigurationService.UpdateParamsTippingHuf"]
- """
- Tipping configuration for HUF
- """
- jpy: NotRequired["ConfigurationService.UpdateParamsTippingJpy"]
- """
- Tipping configuration for JPY
- """
- mxn: NotRequired["ConfigurationService.UpdateParamsTippingMxn"]
- """
- Tipping configuration for MXN
- """
- myr: NotRequired["ConfigurationService.UpdateParamsTippingMyr"]
- """
- Tipping configuration for MYR
- """
- nok: NotRequired["ConfigurationService.UpdateParamsTippingNok"]
- """
- Tipping configuration for NOK
- """
- nzd: NotRequired["ConfigurationService.UpdateParamsTippingNzd"]
- """
- Tipping configuration for NZD
- """
- pln: NotRequired["ConfigurationService.UpdateParamsTippingPln"]
- """
- Tipping configuration for PLN
- """
- ron: NotRequired["ConfigurationService.UpdateParamsTippingRon"]
- """
- Tipping configuration for RON
- """
- sek: NotRequired["ConfigurationService.UpdateParamsTippingSek"]
- """
- Tipping configuration for SEK
- """
- sgd: NotRequired["ConfigurationService.UpdateParamsTippingSgd"]
- """
- Tipping configuration for SGD
- """
- usd: NotRequired["ConfigurationService.UpdateParamsTippingUsd"]
- """
- Tipping configuration for USD
- """
-
- class UpdateParamsTippingAed(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingAud(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingBgn(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingCad(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingChf(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingCzk(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingDkk(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingEur(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingGbp(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingHkd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingHuf(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingJpy(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingMxn(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingMyr(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingNok(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingNzd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingPln(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingRon(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingSek(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingSgd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsTippingUsd(TypedDict):
- fixed_amounts: NotRequired[List[int]]
- """
- Fixed amounts displayed when collecting a tip
- """
- percentages: NotRequired[List[int]]
- """
- Percentages displayed when collecting a tip
- """
- smart_tip_threshold: NotRequired[int]
- """
- Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
- """
-
- class UpdateParamsVerifoneP400(TypedDict):
- splashscreen: NotRequired["Literal['']|str"]
- """
- A File ID representing an image you would like displayed on the reader.
- """
-
- class UpdateParamsWifi(TypedDict):
- enterprise_eap_peap: NotRequired[
- "ConfigurationService.UpdateParamsWifiEnterpriseEapPeap"
- ]
- """
- Credentials for a WPA-Enterprise WiFi network using the EAP-PEAP authentication method.
- """
- enterprise_eap_tls: NotRequired[
- "ConfigurationService.UpdateParamsWifiEnterpriseEapTls"
- ]
- """
- Credentials for a WPA-Enterprise WiFi network using the EAP-TLS authentication method.
- """
- personal_psk: NotRequired[
- "ConfigurationService.UpdateParamsWifiPersonalPsk"
- ]
- """
- Credentials for a WPA-Personal WiFi network.
- """
- type: Literal[
- "enterprise_eap_peap", "enterprise_eap_tls", "personal_psk"
- ]
- """
- Security type of the WiFi network. Fill out the hash with the corresponding name to provide the set of credentials for this security type.
- """
-
- class UpdateParamsWifiEnterpriseEapPeap(TypedDict):
- ca_certificate_file: NotRequired[str]
- """
- A File ID representing a PEM file containing the server certificate
- """
- password: str
- """
- Password for connecting to the WiFi network
- """
- ssid: str
- """
- Name of the WiFi network
- """
- username: str
- """
- Username for connecting to the WiFi network
- """
-
- class UpdateParamsWifiEnterpriseEapTls(TypedDict):
- ca_certificate_file: NotRequired[str]
- """
- A File ID representing a PEM file containing the server certificate
- """
- client_certificate_file: str
- """
- A File ID representing a PEM file containing the client certificate
- """
- private_key_file: str
- """
- A File ID representing a PEM file containing the client RSA private key
- """
- private_key_file_password: NotRequired[str]
- """
- Password for the private key file
- """
- ssid: str
- """
- Name of the WiFi network
- """
-
- class UpdateParamsWifiPersonalPsk(TypedDict):
- password: str
- """
- Password for connecting to the WiFi network
- """
- ssid: str
- """
- Name of the WiFi network
- """
-
def delete(
self,
configuration: str,
- params: Optional["ConfigurationService.DeleteParams"] = None,
+ params: Optional["ConfigurationDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Configuration:
"""
@@ -1168,7 +52,7 @@ def delete(
async def delete_async(
self,
configuration: str,
- params: Optional["ConfigurationService.DeleteParams"] = None,
+ params: Optional["ConfigurationDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Configuration:
"""
@@ -1190,7 +74,7 @@ async def delete_async(
def retrieve(
self,
configuration: str,
- params: Optional["ConfigurationService.RetrieveParams"] = None,
+ params: Optional["ConfigurationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Configuration:
"""
@@ -1212,7 +96,7 @@ def retrieve(
async def retrieve_async(
self,
configuration: str,
- params: Optional["ConfigurationService.RetrieveParams"] = None,
+ params: Optional["ConfigurationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Configuration:
"""
@@ -1234,7 +118,7 @@ async def retrieve_async(
def update(
self,
configuration: str,
- params: Optional["ConfigurationService.UpdateParams"] = None,
+ params: Optional["ConfigurationUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Configuration:
"""
@@ -1256,7 +140,7 @@ def update(
async def update_async(
self,
configuration: str,
- params: Optional["ConfigurationService.UpdateParams"] = None,
+ params: Optional["ConfigurationUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Configuration:
"""
@@ -1277,7 +161,7 @@ async def update_async(
def list(
self,
- params: Optional["ConfigurationService.ListParams"] = None,
+ params: Optional["ConfigurationListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Configuration]:
"""
@@ -1296,7 +180,7 @@ def list(
async def list_async(
self,
- params: Optional["ConfigurationService.ListParams"] = None,
+ params: Optional["ConfigurationListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Configuration]:
"""
@@ -1315,7 +199,7 @@ async def list_async(
def create(
self,
- params: Optional["ConfigurationService.CreateParams"] = None,
+ params: Optional["ConfigurationCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Configuration:
"""
@@ -1334,7 +218,7 @@ def create(
async def create_async(
self,
- params: Optional["ConfigurationService.CreateParams"] = None,
+ params: Optional["ConfigurationCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Configuration:
"""
diff --git a/stripe/terminal/_connection_token.py b/stripe/terminal/_connection_token.py
index 4500eefe1..0804333cb 100644
--- a/stripe/terminal/_connection_token.py
+++ b/stripe/terminal/_connection_token.py
@@ -1,9 +1,13 @@
# -*- coding: utf-8 -*-
# File generated from our OpenAPI spec
from stripe._createable_api_resource import CreateableAPIResource
-from stripe._request_options import RequestOptions
-from typing import ClassVar, List, Optional, cast
-from typing_extensions import Literal, NotRequired, Unpack
+from typing import ClassVar, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.terminal._connection_token_create_params import (
+ ConnectionTokenCreateParams,
+ )
class ConnectionToken(CreateableAPIResource["ConnectionToken"]):
@@ -16,17 +20,6 @@ class ConnectionToken(CreateableAPIResource["ConnectionToken"]):
OBJECT_NAME: ClassVar[Literal["terminal.connection_token"]] = (
"terminal.connection_token"
)
-
- class CreateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- 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://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://docs.stripe.com/terminal/fleet/locations-and-zones?dashboard-or-api=api#connection-tokens).
@@ -42,7 +35,7 @@ class CreateParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["ConnectionToken.CreateParams"]
+ cls, **params: Unpack["ConnectionTokenCreateParams"]
) -> "ConnectionToken":
"""
To connect to a reader the Stripe Terminal SDK needs to retrieve a short-lived connection token from Stripe, proxied through your server. On your backend, add an endpoint that creates and returns a connection token.
@@ -58,7 +51,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["ConnectionToken.CreateParams"]
+ cls, **params: Unpack["ConnectionTokenCreateParams"]
) -> "ConnectionToken":
"""
To connect to a reader the Stripe Terminal SDK needs to retrieve a short-lived connection token from Stripe, proxied through your server. On your backend, add an endpoint that creates and returns a connection token.
diff --git a/stripe/terminal/_connection_token_service.py b/stripe/terminal/_connection_token_service.py
index 0cd94935a..c7649e1e4 100644
--- a/stripe/terminal/_connection_token_service.py
+++ b/stripe/terminal/_connection_token_service.py
@@ -3,24 +3,19 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe.terminal._connection_token import ConnectionToken
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.terminal._connection_token_create_params import (
+ ConnectionTokenCreateParams,
+ )
-class ConnectionTokenService(StripeService):
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- 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://docs.stripe.com/terminal/fleet/locations-and-zones?dashboard-or-api=api#connection-tokens).
- """
+class ConnectionTokenService(StripeService):
def create(
self,
- params: Optional["ConnectionTokenService.CreateParams"] = None,
+ params: Optional["ConnectionTokenCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> ConnectionToken:
"""
@@ -39,7 +34,7 @@ def create(
async def create_async(
self,
- params: Optional["ConnectionTokenService.CreateParams"] = None,
+ params: Optional["ConnectionTokenCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> ConnectionToken:
"""
diff --git a/stripe/terminal/_location.py b/stripe/terminal/_location.py
index 5804f88eb..d7d44b6b7 100644
--- a/stripe/terminal/_location.py
+++ b/stripe/terminal/_location.py
@@ -4,12 +4,26 @@
from stripe._deletable_api_resource import DeletableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import Literal, NotRequired, TypedDict, Unpack
+from typing import ClassVar, Dict, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.terminal._location_create_params import (
+ LocationCreateParams,
+ )
+ from stripe.params.terminal._location_delete_params import (
+ LocationDeleteParams,
+ )
+ from stripe.params.terminal._location_list_params import LocationListParams
+ from stripe.params.terminal._location_modify_params import (
+ LocationModifyParams,
+ )
+ from stripe.params.terminal._location_retrieve_params import (
+ LocationRetrieveParams,
+ )
class Location(
@@ -112,289 +126,6 @@ class AddressKanji(StripeObject):
Town/cho-me.
"""
- class CreateParams(RequestOptions):
- address: NotRequired["Location.CreateParamsAddress"]
- """
- The full address of the location.
- """
- address_kana: NotRequired["Location.CreateParamsAddressKana"]
- """
- The Kana variation of the full address of the location (Japan only).
- """
- address_kanji: NotRequired["Location.CreateParamsAddressKanji"]
- """
- The Kanji variation of the full address of the location (Japan only).
- """
- configuration_overrides: NotRequired[str]
- """
- The ID of a configuration that will be used to customize all readers in this location.
- """
- display_name: NotRequired[str]
- """
- A name for the location. Maximum length is 1000 characters.
- """
- display_name_kana: NotRequired[str]
- """
- The Kana variation of the name for the location (Japan only). Maximum length is 1000 characters.
- """
- display_name_kanji: NotRequired[str]
- """
- The Kanji variation of the name for the location (Japan only). Maximum length is 1000 characters.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- phone: NotRequired[str]
- """
- The phone number for the location.
- """
-
- class CreateParamsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class DeleteParams(RequestOptions):
- pass
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class ModifyParams(RequestOptions):
- address: NotRequired["Location.ModifyParamsAddress"]
- """
- The full address of the location. You can't change the location's `country`. If you need to modify the `country` field, create a new `Location` object and re-register any existing readers to that location.
- """
- address_kana: NotRequired["Location.ModifyParamsAddressKana"]
- """
- The Kana variation of the full address of the location (Japan only).
- """
- address_kanji: NotRequired["Location.ModifyParamsAddressKanji"]
- """
- The Kanji variation of the full address of the location (Japan only).
- """
- configuration_overrides: NotRequired["Literal['']|str"]
- """
- The ID of a configuration that will be used to customize all readers in this location.
- """
- display_name: NotRequired["Literal['']|str"]
- """
- A name for the location.
- """
- display_name_kana: NotRequired["Literal['']|str"]
- """
- The Kana variation of the name for the location (Japan only).
- """
- display_name_kanji: NotRequired["Literal['']|str"]
- """
- The Kanji variation of the name for the location (Japan only).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- phone: NotRequired["Literal['']|str"]
- """
- The phone number for the location.
- """
-
- class ModifyParamsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class ModifyParamsAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class ModifyParamsAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
address: Address
address_kana: Optional[AddressKana]
address_kanji: Optional[AddressKanji]
@@ -440,7 +171,7 @@ class RetrieveParams(RequestOptions):
"""
@classmethod
- def create(cls, **params: Unpack["Location.CreateParams"]) -> "Location":
+ def create(cls, **params: Unpack["LocationCreateParams"]) -> "Location":
"""
Creates a new Location object.
For further details, including which address fields are required in each country, see the [Manage locations](https://docs.stripe.com/docs/terminal/fleet/locations) guide.
@@ -456,7 +187,7 @@ def create(cls, **params: Unpack["Location.CreateParams"]) -> "Location":
@classmethod
async def create_async(
- cls, **params: Unpack["Location.CreateParams"]
+ cls, **params: Unpack["LocationCreateParams"]
) -> "Location":
"""
Creates a new Location object.
@@ -473,7 +204,7 @@ async def create_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["Location.DeleteParams"]
+ cls, sid: str, **params: Unpack["LocationDeleteParams"]
) -> "Location":
"""
Deletes a Location object.
@@ -491,7 +222,7 @@ def _cls_delete(
@overload
@staticmethod
def delete(
- sid: str, **params: Unpack["Location.DeleteParams"]
+ sid: str, **params: Unpack["LocationDeleteParams"]
) -> "Location":
"""
Deletes a Location object.
@@ -499,7 +230,7 @@ def delete(
...
@overload
- def delete(self, **params: Unpack["Location.DeleteParams"]) -> "Location":
+ def delete(self, **params: Unpack["LocationDeleteParams"]) -> "Location":
"""
Deletes a Location object.
"""
@@ -507,7 +238,7 @@ def delete(self, **params: Unpack["Location.DeleteParams"]) -> "Location":
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Location.DeleteParams"]
+ self, **params: Unpack["LocationDeleteParams"]
) -> "Location":
"""
Deletes a Location object.
@@ -520,7 +251,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["Location.DeleteParams"]
+ cls, sid: str, **params: Unpack["LocationDeleteParams"]
) -> "Location":
"""
Deletes a Location object.
@@ -538,7 +269,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["Location.DeleteParams"]
+ sid: str, **params: Unpack["LocationDeleteParams"]
) -> "Location":
"""
Deletes a Location object.
@@ -547,7 +278,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["Location.DeleteParams"]
+ self, **params: Unpack["LocationDeleteParams"]
) -> "Location":
"""
Deletes a Location object.
@@ -556,7 +287,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Location.DeleteParams"]
+ self, **params: Unpack["LocationDeleteParams"]
) -> "Location":
"""
Deletes a Location object.
@@ -569,7 +300,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["Location.ListParams"]
+ cls, **params: Unpack["LocationListParams"]
) -> ListObject["Location"]:
"""
Returns a list of Location objects.
@@ -589,7 +320,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Location.ListParams"]
+ cls, **params: Unpack["LocationListParams"]
) -> ListObject["Location"]:
"""
Returns a list of Location objects.
@@ -609,7 +340,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Location.ModifyParams"]
+ cls, id: str, **params: Unpack["LocationModifyParams"]
) -> "Location":
"""
Updates a Location object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -626,7 +357,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Location.ModifyParams"]
+ cls, id: str, **params: Unpack["LocationModifyParams"]
) -> "Location":
"""
Updates a Location object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -643,7 +374,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Location.RetrieveParams"]
+ cls, id: str, **params: Unpack["LocationRetrieveParams"]
) -> "Location":
"""
Retrieves a Location object.
@@ -654,7 +385,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Location.RetrieveParams"]
+ cls, id: str, **params: Unpack["LocationRetrieveParams"]
) -> "Location":
"""
Retrieves a Location object.
diff --git a/stripe/terminal/_location_service.py b/stripe/terminal/_location_service.py
index 8b382c801..2a32f51cf 100644
--- a/stripe/terminal/_location_service.py
+++ b/stripe/terminal/_location_service.py
@@ -5,298 +5,30 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.terminal._location import Location
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.terminal._location_create_params import (
+ LocationCreateParams,
+ )
+ from stripe.params.terminal._location_delete_params import (
+ LocationDeleteParams,
+ )
+ from stripe.params.terminal._location_list_params import LocationListParams
+ from stripe.params.terminal._location_retrieve_params import (
+ LocationRetrieveParams,
+ )
+ from stripe.params.terminal._location_update_params import (
+ LocationUpdateParams,
+ )
class LocationService(StripeService):
- class CreateParams(TypedDict):
- address: NotRequired["LocationService.CreateParamsAddress"]
- """
- The full address of the location.
- """
- address_kana: NotRequired["LocationService.CreateParamsAddressKana"]
- """
- The Kana variation of the full address of the location (Japan only).
- """
- address_kanji: NotRequired["LocationService.CreateParamsAddressKanji"]
- """
- The Kanji variation of the full address of the location (Japan only).
- """
- configuration_overrides: NotRequired[str]
- """
- The ID of a configuration that will be used to customize all readers in this location.
- """
- display_name: NotRequired[str]
- """
- A name for the location. Maximum length is 1000 characters.
- """
- display_name_kana: NotRequired[str]
- """
- The Kana variation of the name for the location (Japan only). Maximum length is 1000 characters.
- """
- display_name_kanji: NotRequired[str]
- """
- The Kanji variation of the name for the location (Japan only). Maximum length is 1000 characters.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- phone: NotRequired[str]
- """
- The phone number for the location.
- """
-
- class CreateParamsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: str
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class CreateParamsAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- address: NotRequired["LocationService.UpdateParamsAddress"]
- """
- The full address of the location. You can't change the location's `country`. If you need to modify the `country` field, create a new `Location` object and re-register any existing readers to that location.
- """
- address_kana: NotRequired["LocationService.UpdateParamsAddressKana"]
- """
- The Kana variation of the full address of the location (Japan only).
- """
- address_kanji: NotRequired["LocationService.UpdateParamsAddressKanji"]
- """
- The Kanji variation of the full address of the location (Japan only).
- """
- configuration_overrides: NotRequired["Literal['']|str"]
- """
- The ID of a configuration that will be used to customize all readers in this location.
- """
- display_name: NotRequired["Literal['']|str"]
- """
- A name for the location.
- """
- display_name_kana: NotRequired["Literal['']|str"]
- """
- The Kana variation of the name for the location (Japan only).
- """
- display_name_kanji: NotRequired["Literal['']|str"]
- """
- The Kanji variation of the name for the location (Japan only).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- phone: NotRequired["Literal['']|str"]
- """
- The phone number for the location.
- """
-
- class UpdateParamsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class UpdateParamsAddressKana(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
- class UpdateParamsAddressKanji(TypedDict):
- city: NotRequired[str]
- """
- City or ward.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Block or building number.
- """
- line2: NotRequired[str]
- """
- Building details.
- """
- postal_code: NotRequired[str]
- """
- Postal code.
- """
- state: NotRequired[str]
- """
- Prefecture.
- """
- town: NotRequired[str]
- """
- Town or cho-me.
- """
-
def delete(
self,
location: str,
- params: Optional["LocationService.DeleteParams"] = None,
+ params: Optional["LocationDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Location:
"""
@@ -318,7 +50,7 @@ def delete(
async def delete_async(
self,
location: str,
- params: Optional["LocationService.DeleteParams"] = None,
+ params: Optional["LocationDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Location:
"""
@@ -340,7 +72,7 @@ async def delete_async(
def retrieve(
self,
location: str,
- params: Optional["LocationService.RetrieveParams"] = None,
+ params: Optional["LocationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Location:
"""
@@ -362,7 +94,7 @@ def retrieve(
async def retrieve_async(
self,
location: str,
- params: Optional["LocationService.RetrieveParams"] = None,
+ params: Optional["LocationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Location:
"""
@@ -384,7 +116,7 @@ async def retrieve_async(
def update(
self,
location: str,
- params: Optional["LocationService.UpdateParams"] = None,
+ params: Optional["LocationUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Location:
"""
@@ -406,7 +138,7 @@ def update(
async def update_async(
self,
location: str,
- params: Optional["LocationService.UpdateParams"] = None,
+ params: Optional["LocationUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Location:
"""
@@ -427,7 +159,7 @@ async def update_async(
def list(
self,
- params: Optional["LocationService.ListParams"] = None,
+ params: Optional["LocationListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Location]:
"""
@@ -446,7 +178,7 @@ def list(
async def list_async(
self,
- params: Optional["LocationService.ListParams"] = None,
+ params: Optional["LocationListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Location]:
"""
@@ -465,7 +197,7 @@ async def list_async(
def create(
self,
- params: Optional["LocationService.CreateParams"] = None,
+ params: Optional["LocationCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Location:
"""
@@ -485,7 +217,7 @@ def create(
async def create_async(
self,
- params: Optional["LocationService.CreateParams"] = None,
+ params: Optional["LocationCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Location:
"""
diff --git a/stripe/terminal/_reader.py b/stripe/terminal/_reader.py
index f27b82d46..13985a6a2 100644
--- a/stripe/terminal/_reader.py
+++ b/stripe/terminal/_reader.py
@@ -5,20 +5,12 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._test_helpers import APIResourceTestHelpers
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- Type,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Type, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._charge import Charge
@@ -26,6 +18,46 @@
from stripe._payment_method import PaymentMethod
from stripe._refund import Refund
from stripe._setup_intent import SetupIntent
+ from stripe.params.terminal._reader_cancel_action_params import (
+ ReaderCancelActionParams,
+ )
+ from stripe.params.terminal._reader_collect_inputs_params import (
+ ReaderCollectInputsParams,
+ )
+ from stripe.params.terminal._reader_collect_payment_method_params import (
+ ReaderCollectPaymentMethodParams,
+ )
+ from stripe.params.terminal._reader_confirm_payment_intent_params import (
+ ReaderConfirmPaymentIntentParams,
+ )
+ from stripe.params.terminal._reader_create_params import ReaderCreateParams
+ from stripe.params.terminal._reader_delete_params import ReaderDeleteParams
+ from stripe.params.terminal._reader_list_params import ReaderListParams
+ from stripe.params.terminal._reader_modify_params import ReaderModifyParams
+ from stripe.params.terminal._reader_present_payment_method_params import (
+ ReaderPresentPaymentMethodParams,
+ )
+ from stripe.params.terminal._reader_process_payment_intent_params import (
+ ReaderProcessPaymentIntentParams,
+ )
+ from stripe.params.terminal._reader_process_setup_intent_params import (
+ ReaderProcessSetupIntentParams,
+ )
+ from stripe.params.terminal._reader_refund_payment_params import (
+ ReaderRefundPaymentParams,
+ )
+ from stripe.params.terminal._reader_retrieve_params import (
+ ReaderRetrieveParams,
+ )
+ from stripe.params.terminal._reader_set_reader_display_params import (
+ ReaderSetReaderDisplayParams,
+ )
+ from stripe.params.terminal._reader_succeed_input_collection_params import (
+ ReaderSucceedInputCollectionParams,
+ )
+ from stripe.params.terminal._reader_timeout_input_collection_params import (
+ ReaderTimeoutInputCollectionParams,
+ )
from stripe.terminal._location import Location
@@ -480,497 +512,6 @@ class LineItem(StripeObject):
"set_reader_display": SetReaderDisplay,
}
- class CancelActionParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CollectInputsParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- inputs: List["Reader.CollectInputsParamsInput"]
- """
- List of inputs to be collected using the Reader
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class CollectInputsParamsInput(TypedDict):
- custom_text: "Reader.CollectInputsParamsInputCustomText"
- """
- Customize the text which will be displayed while collecting this input
- """
- required: NotRequired[bool]
- """
- Indicate that this input is required, disabling the skip button
- """
- selection: NotRequired["Reader.CollectInputsParamsInputSelection"]
- """
- Options for the `selection` input
- """
- toggles: NotRequired[List["Reader.CollectInputsParamsInputToggle"]]
- """
- List of toggles to be displayed and customization for the toggles
- """
- type: Literal[
- "email", "numeric", "phone", "selection", "signature", "text"
- ]
- """
- The type of input to collect
- """
-
- class CollectInputsParamsInputCustomText(TypedDict):
- description: NotRequired[str]
- """
- The description which will be displayed when collecting this input
- """
- skip_button: NotRequired[str]
- """
- The skip button text
- """
- submit_button: NotRequired[str]
- """
- The submit button text
- """
- title: str
- """
- The title which will be displayed when collecting this input
- """
-
- class CollectInputsParamsInputSelection(TypedDict):
- choices: List["Reader.CollectInputsParamsInputSelectionChoice"]
- """
- List of choices for the `selection` input
- """
-
- class CollectInputsParamsInputSelectionChoice(TypedDict):
- id: str
- """
- The unique identifier for this choice
- """
- style: NotRequired[Literal["primary", "secondary"]]
- """
- The style of the button which will be shown for this choice
- """
- text: str
- """
- The text which will be shown on the button for this choice
- """
-
- class CollectInputsParamsInputToggle(TypedDict):
- default_value: NotRequired[Literal["disabled", "enabled"]]
- """
- The default value of the toggle
- """
- description: NotRequired[str]
- """
- The description which will be displayed for the toggle
- """
- title: NotRequired[str]
- """
- The title which will be displayed for the toggle
- """
-
- class CollectPaymentMethodParams(RequestOptions):
- collect_config: NotRequired[
- "Reader.CollectPaymentMethodParamsCollectConfig"
- ]
- """
- Configuration overrides.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- payment_intent: str
- """
- PaymentIntent ID.
- """
-
- class CollectPaymentMethodParamsCollectConfig(TypedDict):
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
- """
- enable_customer_cancellation: NotRequired[bool]
- """
- Enables cancel button on transaction screens.
- """
- skip_tipping: NotRequired[bool]
- """
- Override showing a tipping selection screen on this transaction.
- """
- tipping: NotRequired[
- "Reader.CollectPaymentMethodParamsCollectConfigTipping"
- ]
- """
- Tipping configuration for this transaction.
- """
-
- class CollectPaymentMethodParamsCollectConfigTipping(TypedDict):
- amount_eligible: NotRequired[int]
- """
- Amount used to calculate tip suggestions on tipping selection screen for this transaction. Must be a positive integer in the smallest currency unit (e.g., 100 cents to represent $1.00 or 100 to represent ¥100, a zero-decimal currency).
- """
-
- class ConfirmPaymentIntentParams(RequestOptions):
- confirm_config: NotRequired[
- "Reader.ConfirmPaymentIntentParamsConfirmConfig"
- ]
- """
- Configuration overrides.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- payment_intent: str
- """
- PaymentIntent ID.
- """
-
- class ConfirmPaymentIntentParamsConfirmConfig(TypedDict):
- return_url: NotRequired[str]
- """
- The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
- """
-
- class CreateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- label: NotRequired[str]
- """
- Custom label given to the reader for easier identification. If no label is specified, the registration code will be used.
- """
- location: NotRequired[str]
- """
- The location to assign the reader to.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- registration_code: str
- """
- A code generated by the reader used for registering to an account.
- """
-
- class DeleteParams(RequestOptions):
- pass
-
- class ListParams(RequestOptions):
- device_type: NotRequired[
- Literal[
- "bbpos_chipper2x",
- "bbpos_wisepad3",
- "bbpos_wisepos_e",
- "mobile_phone_reader",
- "simulated_stripe_s700",
- "simulated_wisepos_e",
- "stripe_m2",
- "stripe_s700",
- "verifone_P400",
- ]
- ]
- """
- Filters readers by device type
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- location: NotRequired[str]
- """
- A location ID to filter the response list to only readers at the specific location
- """
- serial_number: NotRequired[str]
- """
- Filters readers by serial number
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["offline", "online"]]
- """
- A status filter to filter readers to only offline or online readers
- """
-
- class ModifyParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- label: NotRequired["Literal['']|str"]
- """
- The new label of the reader.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class PresentPaymentMethodParams(RequestOptions):
- amount_tip: NotRequired[int]
- """
- Simulated on-reader tip amount.
- """
- card: NotRequired["Reader.PresentPaymentMethodParamsCard"]
- """
- Simulated data for the card payment method.
- """
- card_present: NotRequired[
- "Reader.PresentPaymentMethodParamsCardPresent"
- ]
- """
- Simulated data for the card_present payment method.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- interac_present: NotRequired[
- "Reader.PresentPaymentMethodParamsInteracPresent"
- ]
- """
- Simulated data for the interac_present payment method.
- """
- type: NotRequired[Literal["card", "card_present", "interac_present"]]
- """
- Simulated payment type.
- """
-
- class PresentPaymentMethodParamsCard(TypedDict):
- cvc: NotRequired[str]
- """
- Card security code.
- """
- exp_month: int
- """
- Two-digit number representing the card's expiration month.
- """
- exp_year: int
- """
- Two- or four-digit number representing the card's expiration year.
- """
- number: str
- """
- The card number, as a string without any separators.
- """
-
- class PresentPaymentMethodParamsCardPresent(TypedDict):
- number: NotRequired[str]
- """
- The card number, as a string without any separators.
- """
-
- class PresentPaymentMethodParamsInteracPresent(TypedDict):
- number: NotRequired[str]
- """
- Card Number
- """
-
- class ProcessPaymentIntentParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- payment_intent: str
- """
- PaymentIntent ID
- """
- process_config: NotRequired[
- "Reader.ProcessPaymentIntentParamsProcessConfig"
- ]
- """
- Configuration overrides
- """
-
- class ProcessPaymentIntentParamsProcessConfig(TypedDict):
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
- """
- enable_customer_cancellation: NotRequired[bool]
- """
- Enables cancel button on transaction screens.
- """
- return_url: NotRequired[str]
- """
- The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
- """
- skip_tipping: NotRequired[bool]
- """
- Override showing a tipping selection screen on this transaction.
- """
- tipping: NotRequired[
- "Reader.ProcessPaymentIntentParamsProcessConfigTipping"
- ]
- """
- Tipping configuration for this transaction.
- """
-
- class ProcessPaymentIntentParamsProcessConfigTipping(TypedDict):
- amount_eligible: NotRequired[int]
- """
- Amount used to calculate tip suggestions on tipping selection screen for this transaction. Must be a positive integer in the smallest currency unit (e.g., 100 cents to represent $1.00 or 100 to represent ¥100, a zero-decimal currency).
- """
-
- class ProcessSetupIntentParams(RequestOptions):
- allow_redisplay: Literal["always", "limited", "unspecified"]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- process_config: NotRequired[
- "Reader.ProcessSetupIntentParamsProcessConfig"
- ]
- """
- Configuration overrides
- """
- setup_intent: str
- """
- SetupIntent ID
- """
-
- class ProcessSetupIntentParamsProcessConfig(TypedDict):
- enable_customer_cancellation: NotRequired[bool]
- """
- Enables cancel button on transaction screens.
- """
-
- class RefundPaymentParams(RequestOptions):
- amount: NotRequired[int]
- """
- A positive integer in __cents__ representing how much of this charge to refund.
- """
- charge: NotRequired[str]
- """
- ID of the Charge to refund.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- payment_intent: NotRequired[str]
- """
- ID of the PaymentIntent to refund.
- """
- refund_application_fee: NotRequired[bool]
- """
- Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.
- """
- refund_payment_config: NotRequired[
- "Reader.RefundPaymentParamsRefundPaymentConfig"
- ]
- """
- Configuration overrides
- """
- reverse_transfer: NotRequired[bool]
- """
- Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount). A transfer can be reversed only by the application that created the charge.
- """
-
- class RefundPaymentParamsRefundPaymentConfig(TypedDict):
- enable_customer_cancellation: NotRequired[bool]
- """
- Enables cancel button on transaction screens.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SetReaderDisplayParams(RequestOptions):
- cart: NotRequired["Reader.SetReaderDisplayParamsCart"]
- """
- Cart
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- type: Literal["cart"]
- """
- Type
- """
-
- class SetReaderDisplayParamsCart(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- line_items: List["Reader.SetReaderDisplayParamsCartLineItem"]
- """
- Array of line items that were purchased.
- """
- tax: NotRequired[int]
- """
- The amount of tax in cents.
- """
- total: int
- """
- Total balance of cart due in cents.
- """
-
- class SetReaderDisplayParamsCartLineItem(TypedDict):
- amount: int
- """
- The price of the item in cents.
- """
- description: str
- """
- The description or name of the item.
- """
- quantity: int
- """
- The quantity of the line item being purchased.
- """
-
- class SucceedInputCollectionParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- skip_non_required_inputs: NotRequired[Literal["all", "none"]]
- """
- This parameter defines the skip behavior for input collection.
- """
-
- class TimeoutInputCollectionParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
action: Optional[Action]
"""
The most recent action performed by the reader.
@@ -1036,7 +577,7 @@ class TimeoutInputCollectionParams(RequestOptions):
@classmethod
def _cls_cancel_action(
- cls, reader: str, **params: Unpack["Reader.CancelActionParams"]
+ cls, reader: str, **params: Unpack["ReaderCancelActionParams"]
) -> "Reader":
"""
Cancels the current reader action.
@@ -1055,7 +596,7 @@ def _cls_cancel_action(
@overload
@staticmethod
def cancel_action(
- reader: str, **params: Unpack["Reader.CancelActionParams"]
+ reader: str, **params: Unpack["ReaderCancelActionParams"]
) -> "Reader":
"""
Cancels the current reader action.
@@ -1064,7 +605,7 @@ def cancel_action(
@overload
def cancel_action(
- self, **params: Unpack["Reader.CancelActionParams"]
+ self, **params: Unpack["ReaderCancelActionParams"]
) -> "Reader":
"""
Cancels the current reader action.
@@ -1073,7 +614,7 @@ def cancel_action(
@class_method_variant("_cls_cancel_action")
def cancel_action( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.CancelActionParams"]
+ self, **params: Unpack["ReaderCancelActionParams"]
) -> "Reader":
"""
Cancels the current reader action.
@@ -1091,7 +632,7 @@ def cancel_action( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_cancel_action_async(
- cls, reader: str, **params: Unpack["Reader.CancelActionParams"]
+ cls, reader: str, **params: Unpack["ReaderCancelActionParams"]
) -> "Reader":
"""
Cancels the current reader action.
@@ -1110,7 +651,7 @@ async def _cls_cancel_action_async(
@overload
@staticmethod
async def cancel_action_async(
- reader: str, **params: Unpack["Reader.CancelActionParams"]
+ reader: str, **params: Unpack["ReaderCancelActionParams"]
) -> "Reader":
"""
Cancels the current reader action.
@@ -1119,7 +660,7 @@ async def cancel_action_async(
@overload
async def cancel_action_async(
- self, **params: Unpack["Reader.CancelActionParams"]
+ self, **params: Unpack["ReaderCancelActionParams"]
) -> "Reader":
"""
Cancels the current reader action.
@@ -1128,7 +669,7 @@ async def cancel_action_async(
@class_method_variant("_cls_cancel_action_async")
async def cancel_action_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.CancelActionParams"]
+ self, **params: Unpack["ReaderCancelActionParams"]
) -> "Reader":
"""
Cancels the current reader action.
@@ -1146,7 +687,7 @@ async def cancel_action_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_collect_inputs(
- cls, reader: str, **params: Unpack["Reader.CollectInputsParams"]
+ cls, reader: str, **params: Unpack["ReaderCollectInputsParams"]
) -> "Reader":
"""
Initiates an input collection flow on a Reader.
@@ -1165,7 +706,7 @@ def _cls_collect_inputs(
@overload
@staticmethod
def collect_inputs(
- reader: str, **params: Unpack["Reader.CollectInputsParams"]
+ reader: str, **params: Unpack["ReaderCollectInputsParams"]
) -> "Reader":
"""
Initiates an input collection flow on a Reader.
@@ -1174,7 +715,7 @@ def collect_inputs(
@overload
def collect_inputs(
- self, **params: Unpack["Reader.CollectInputsParams"]
+ self, **params: Unpack["ReaderCollectInputsParams"]
) -> "Reader":
"""
Initiates an input collection flow on a Reader.
@@ -1183,7 +724,7 @@ def collect_inputs(
@class_method_variant("_cls_collect_inputs")
def collect_inputs( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.CollectInputsParams"]
+ self, **params: Unpack["ReaderCollectInputsParams"]
) -> "Reader":
"""
Initiates an input collection flow on a Reader.
@@ -1201,7 +742,7 @@ def collect_inputs( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_collect_inputs_async(
- cls, reader: str, **params: Unpack["Reader.CollectInputsParams"]
+ cls, reader: str, **params: Unpack["ReaderCollectInputsParams"]
) -> "Reader":
"""
Initiates an input collection flow on a Reader.
@@ -1220,7 +761,7 @@ async def _cls_collect_inputs_async(
@overload
@staticmethod
async def collect_inputs_async(
- reader: str, **params: Unpack["Reader.CollectInputsParams"]
+ reader: str, **params: Unpack["ReaderCollectInputsParams"]
) -> "Reader":
"""
Initiates an input collection flow on a Reader.
@@ -1229,7 +770,7 @@ async def collect_inputs_async(
@overload
async def collect_inputs_async(
- self, **params: Unpack["Reader.CollectInputsParams"]
+ self, **params: Unpack["ReaderCollectInputsParams"]
) -> "Reader":
"""
Initiates an input collection flow on a Reader.
@@ -1238,7 +779,7 @@ async def collect_inputs_async(
@class_method_variant("_cls_collect_inputs_async")
async def collect_inputs_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.CollectInputsParams"]
+ self, **params: Unpack["ReaderCollectInputsParams"]
) -> "Reader":
"""
Initiates an input collection flow on a Reader.
@@ -1256,7 +797,7 @@ async def collect_inputs_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_collect_payment_method(
- cls, reader: str, **params: Unpack["Reader.CollectPaymentMethodParams"]
+ cls, reader: str, **params: Unpack["ReaderCollectPaymentMethodParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader and updates the PaymentIntent with card details before manual confirmation.
@@ -1275,7 +816,7 @@ def _cls_collect_payment_method(
@overload
@staticmethod
def collect_payment_method(
- reader: str, **params: Unpack["Reader.CollectPaymentMethodParams"]
+ reader: str, **params: Unpack["ReaderCollectPaymentMethodParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader and updates the PaymentIntent with card details before manual confirmation.
@@ -1284,7 +825,7 @@ def collect_payment_method(
@overload
def collect_payment_method(
- self, **params: Unpack["Reader.CollectPaymentMethodParams"]
+ self, **params: Unpack["ReaderCollectPaymentMethodParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader and updates the PaymentIntent with card details before manual confirmation.
@@ -1293,7 +834,7 @@ def collect_payment_method(
@class_method_variant("_cls_collect_payment_method")
def collect_payment_method( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.CollectPaymentMethodParams"]
+ self, **params: Unpack["ReaderCollectPaymentMethodParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader and updates the PaymentIntent with card details before manual confirmation.
@@ -1311,7 +852,7 @@ def collect_payment_method( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_collect_payment_method_async(
- cls, reader: str, **params: Unpack["Reader.CollectPaymentMethodParams"]
+ cls, reader: str, **params: Unpack["ReaderCollectPaymentMethodParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader and updates the PaymentIntent with card details before manual confirmation.
@@ -1330,7 +871,7 @@ async def _cls_collect_payment_method_async(
@overload
@staticmethod
async def collect_payment_method_async(
- reader: str, **params: Unpack["Reader.CollectPaymentMethodParams"]
+ reader: str, **params: Unpack["ReaderCollectPaymentMethodParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader and updates the PaymentIntent with card details before manual confirmation.
@@ -1339,7 +880,7 @@ async def collect_payment_method_async(
@overload
async def collect_payment_method_async(
- self, **params: Unpack["Reader.CollectPaymentMethodParams"]
+ self, **params: Unpack["ReaderCollectPaymentMethodParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader and updates the PaymentIntent with card details before manual confirmation.
@@ -1348,7 +889,7 @@ async def collect_payment_method_async(
@class_method_variant("_cls_collect_payment_method_async")
async def collect_payment_method_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.CollectPaymentMethodParams"]
+ self, **params: Unpack["ReaderCollectPaymentMethodParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader and updates the PaymentIntent with card details before manual confirmation.
@@ -1366,7 +907,7 @@ async def collect_payment_method_async( # pyright: ignore[reportGeneralTypeIssu
@classmethod
def _cls_confirm_payment_intent(
- cls, reader: str, **params: Unpack["Reader.ConfirmPaymentIntentParams"]
+ cls, reader: str, **params: Unpack["ReaderConfirmPaymentIntentParams"]
) -> "Reader":
"""
Finalizes a payment on a Reader.
@@ -1385,7 +926,7 @@ def _cls_confirm_payment_intent(
@overload
@staticmethod
def confirm_payment_intent(
- reader: str, **params: Unpack["Reader.ConfirmPaymentIntentParams"]
+ reader: str, **params: Unpack["ReaderConfirmPaymentIntentParams"]
) -> "Reader":
"""
Finalizes a payment on a Reader.
@@ -1394,7 +935,7 @@ def confirm_payment_intent(
@overload
def confirm_payment_intent(
- self, **params: Unpack["Reader.ConfirmPaymentIntentParams"]
+ self, **params: Unpack["ReaderConfirmPaymentIntentParams"]
) -> "Reader":
"""
Finalizes a payment on a Reader.
@@ -1403,7 +944,7 @@ def confirm_payment_intent(
@class_method_variant("_cls_confirm_payment_intent")
def confirm_payment_intent( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.ConfirmPaymentIntentParams"]
+ self, **params: Unpack["ReaderConfirmPaymentIntentParams"]
) -> "Reader":
"""
Finalizes a payment on a Reader.
@@ -1421,7 +962,7 @@ def confirm_payment_intent( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_confirm_payment_intent_async(
- cls, reader: str, **params: Unpack["Reader.ConfirmPaymentIntentParams"]
+ cls, reader: str, **params: Unpack["ReaderConfirmPaymentIntentParams"]
) -> "Reader":
"""
Finalizes a payment on a Reader.
@@ -1440,7 +981,7 @@ async def _cls_confirm_payment_intent_async(
@overload
@staticmethod
async def confirm_payment_intent_async(
- reader: str, **params: Unpack["Reader.ConfirmPaymentIntentParams"]
+ reader: str, **params: Unpack["ReaderConfirmPaymentIntentParams"]
) -> "Reader":
"""
Finalizes a payment on a Reader.
@@ -1449,7 +990,7 @@ async def confirm_payment_intent_async(
@overload
async def confirm_payment_intent_async(
- self, **params: Unpack["Reader.ConfirmPaymentIntentParams"]
+ self, **params: Unpack["ReaderConfirmPaymentIntentParams"]
) -> "Reader":
"""
Finalizes a payment on a Reader.
@@ -1458,7 +999,7 @@ async def confirm_payment_intent_async(
@class_method_variant("_cls_confirm_payment_intent_async")
async def confirm_payment_intent_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.ConfirmPaymentIntentParams"]
+ self, **params: Unpack["ReaderConfirmPaymentIntentParams"]
) -> "Reader":
"""
Finalizes a payment on a Reader.
@@ -1475,7 +1016,7 @@ async def confirm_payment_intent_async( # pyright: ignore[reportGeneralTypeIssu
)
@classmethod
- def create(cls, **params: Unpack["Reader.CreateParams"]) -> "Reader":
+ def create(cls, **params: Unpack["ReaderCreateParams"]) -> "Reader":
"""
Creates a new Reader object.
"""
@@ -1490,7 +1031,7 @@ def create(cls, **params: Unpack["Reader.CreateParams"]) -> "Reader":
@classmethod
async def create_async(
- cls, **params: Unpack["Reader.CreateParams"]
+ cls, **params: Unpack["ReaderCreateParams"]
) -> "Reader":
"""
Creates a new Reader object.
@@ -1506,7 +1047,7 @@ async def create_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["Reader.DeleteParams"]
+ cls, sid: str, **params: Unpack["ReaderDeleteParams"]
) -> "Reader":
"""
Deletes a Reader object.
@@ -1523,14 +1064,14 @@ def _cls_delete(
@overload
@staticmethod
- def delete(sid: str, **params: Unpack["Reader.DeleteParams"]) -> "Reader":
+ def delete(sid: str, **params: Unpack["ReaderDeleteParams"]) -> "Reader":
"""
Deletes a Reader object.
"""
...
@overload
- def delete(self, **params: Unpack["Reader.DeleteParams"]) -> "Reader":
+ def delete(self, **params: Unpack["ReaderDeleteParams"]) -> "Reader":
"""
Deletes a Reader object.
"""
@@ -1538,7 +1079,7 @@ def delete(self, **params: Unpack["Reader.DeleteParams"]) -> "Reader":
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.DeleteParams"]
+ self, **params: Unpack["ReaderDeleteParams"]
) -> "Reader":
"""
Deletes a Reader object.
@@ -1551,7 +1092,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["Reader.DeleteParams"]
+ cls, sid: str, **params: Unpack["ReaderDeleteParams"]
) -> "Reader":
"""
Deletes a Reader object.
@@ -1569,7 +1110,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["Reader.DeleteParams"]
+ sid: str, **params: Unpack["ReaderDeleteParams"]
) -> "Reader":
"""
Deletes a Reader object.
@@ -1578,7 +1119,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["Reader.DeleteParams"]
+ self, **params: Unpack["ReaderDeleteParams"]
) -> "Reader":
"""
Deletes a Reader object.
@@ -1587,7 +1128,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.DeleteParams"]
+ self, **params: Unpack["ReaderDeleteParams"]
) -> "Reader":
"""
Deletes a Reader object.
@@ -1600,7 +1141,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["Reader.ListParams"]
+ cls, **params: Unpack["ReaderListParams"]
) -> ListObject["Reader"]:
"""
Returns a list of Reader objects.
@@ -1620,7 +1161,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Reader.ListParams"]
+ cls, **params: Unpack["ReaderListParams"]
) -> ListObject["Reader"]:
"""
Returns a list of Reader objects.
@@ -1640,7 +1181,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["Reader.ModifyParams"]
+ cls, id: str, **params: Unpack["ReaderModifyParams"]
) -> "Reader":
"""
Updates a Reader object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -1657,7 +1198,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["Reader.ModifyParams"]
+ cls, id: str, **params: Unpack["ReaderModifyParams"]
) -> "Reader":
"""
Updates a Reader object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
@@ -1674,7 +1215,7 @@ async def modify_async(
@classmethod
def _cls_process_payment_intent(
- cls, reader: str, **params: Unpack["Reader.ProcessPaymentIntentParams"]
+ cls, reader: str, **params: Unpack["ReaderProcessPaymentIntentParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader.
@@ -1693,7 +1234,7 @@ def _cls_process_payment_intent(
@overload
@staticmethod
def process_payment_intent(
- reader: str, **params: Unpack["Reader.ProcessPaymentIntentParams"]
+ reader: str, **params: Unpack["ReaderProcessPaymentIntentParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader.
@@ -1702,7 +1243,7 @@ def process_payment_intent(
@overload
def process_payment_intent(
- self, **params: Unpack["Reader.ProcessPaymentIntentParams"]
+ self, **params: Unpack["ReaderProcessPaymentIntentParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader.
@@ -1711,7 +1252,7 @@ def process_payment_intent(
@class_method_variant("_cls_process_payment_intent")
def process_payment_intent( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.ProcessPaymentIntentParams"]
+ self, **params: Unpack["ReaderProcessPaymentIntentParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader.
@@ -1729,7 +1270,7 @@ def process_payment_intent( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_process_payment_intent_async(
- cls, reader: str, **params: Unpack["Reader.ProcessPaymentIntentParams"]
+ cls, reader: str, **params: Unpack["ReaderProcessPaymentIntentParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader.
@@ -1748,7 +1289,7 @@ async def _cls_process_payment_intent_async(
@overload
@staticmethod
async def process_payment_intent_async(
- reader: str, **params: Unpack["Reader.ProcessPaymentIntentParams"]
+ reader: str, **params: Unpack["ReaderProcessPaymentIntentParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader.
@@ -1757,7 +1298,7 @@ async def process_payment_intent_async(
@overload
async def process_payment_intent_async(
- self, **params: Unpack["Reader.ProcessPaymentIntentParams"]
+ self, **params: Unpack["ReaderProcessPaymentIntentParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader.
@@ -1766,7 +1307,7 @@ async def process_payment_intent_async(
@class_method_variant("_cls_process_payment_intent_async")
async def process_payment_intent_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.ProcessPaymentIntentParams"]
+ self, **params: Unpack["ReaderProcessPaymentIntentParams"]
) -> "Reader":
"""
Initiates a payment flow on a Reader.
@@ -1784,7 +1325,7 @@ async def process_payment_intent_async( # pyright: ignore[reportGeneralTypeIssu
@classmethod
def _cls_process_setup_intent(
- cls, reader: str, **params: Unpack["Reader.ProcessSetupIntentParams"]
+ cls, reader: str, **params: Unpack["ReaderProcessSetupIntentParams"]
) -> "Reader":
"""
Initiates a setup intent flow on a Reader.
@@ -1803,7 +1344,7 @@ def _cls_process_setup_intent(
@overload
@staticmethod
def process_setup_intent(
- reader: str, **params: Unpack["Reader.ProcessSetupIntentParams"]
+ reader: str, **params: Unpack["ReaderProcessSetupIntentParams"]
) -> "Reader":
"""
Initiates a setup intent flow on a Reader.
@@ -1812,7 +1353,7 @@ def process_setup_intent(
@overload
def process_setup_intent(
- self, **params: Unpack["Reader.ProcessSetupIntentParams"]
+ self, **params: Unpack["ReaderProcessSetupIntentParams"]
) -> "Reader":
"""
Initiates a setup intent flow on a Reader.
@@ -1821,7 +1362,7 @@ def process_setup_intent(
@class_method_variant("_cls_process_setup_intent")
def process_setup_intent( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.ProcessSetupIntentParams"]
+ self, **params: Unpack["ReaderProcessSetupIntentParams"]
) -> "Reader":
"""
Initiates a setup intent flow on a Reader.
@@ -1839,7 +1380,7 @@ def process_setup_intent( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_process_setup_intent_async(
- cls, reader: str, **params: Unpack["Reader.ProcessSetupIntentParams"]
+ cls, reader: str, **params: Unpack["ReaderProcessSetupIntentParams"]
) -> "Reader":
"""
Initiates a setup intent flow on a Reader.
@@ -1858,7 +1399,7 @@ async def _cls_process_setup_intent_async(
@overload
@staticmethod
async def process_setup_intent_async(
- reader: str, **params: Unpack["Reader.ProcessSetupIntentParams"]
+ reader: str, **params: Unpack["ReaderProcessSetupIntentParams"]
) -> "Reader":
"""
Initiates a setup intent flow on a Reader.
@@ -1867,7 +1408,7 @@ async def process_setup_intent_async(
@overload
async def process_setup_intent_async(
- self, **params: Unpack["Reader.ProcessSetupIntentParams"]
+ self, **params: Unpack["ReaderProcessSetupIntentParams"]
) -> "Reader":
"""
Initiates a setup intent flow on a Reader.
@@ -1876,7 +1417,7 @@ async def process_setup_intent_async(
@class_method_variant("_cls_process_setup_intent_async")
async def process_setup_intent_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.ProcessSetupIntentParams"]
+ self, **params: Unpack["ReaderProcessSetupIntentParams"]
) -> "Reader":
"""
Initiates a setup intent flow on a Reader.
@@ -1894,7 +1435,7 @@ async def process_setup_intent_async( # pyright: ignore[reportGeneralTypeIssues
@classmethod
def _cls_refund_payment(
- cls, reader: str, **params: Unpack["Reader.RefundPaymentParams"]
+ cls, reader: str, **params: Unpack["ReaderRefundPaymentParams"]
) -> "Reader":
"""
Initiates a refund on a Reader
@@ -1913,7 +1454,7 @@ def _cls_refund_payment(
@overload
@staticmethod
def refund_payment(
- reader: str, **params: Unpack["Reader.RefundPaymentParams"]
+ reader: str, **params: Unpack["ReaderRefundPaymentParams"]
) -> "Reader":
"""
Initiates a refund on a Reader
@@ -1922,7 +1463,7 @@ def refund_payment(
@overload
def refund_payment(
- self, **params: Unpack["Reader.RefundPaymentParams"]
+ self, **params: Unpack["ReaderRefundPaymentParams"]
) -> "Reader":
"""
Initiates a refund on a Reader
@@ -1931,7 +1472,7 @@ def refund_payment(
@class_method_variant("_cls_refund_payment")
def refund_payment( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.RefundPaymentParams"]
+ self, **params: Unpack["ReaderRefundPaymentParams"]
) -> "Reader":
"""
Initiates a refund on a Reader
@@ -1949,7 +1490,7 @@ def refund_payment( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_refund_payment_async(
- cls, reader: str, **params: Unpack["Reader.RefundPaymentParams"]
+ cls, reader: str, **params: Unpack["ReaderRefundPaymentParams"]
) -> "Reader":
"""
Initiates a refund on a Reader
@@ -1968,7 +1509,7 @@ async def _cls_refund_payment_async(
@overload
@staticmethod
async def refund_payment_async(
- reader: str, **params: Unpack["Reader.RefundPaymentParams"]
+ reader: str, **params: Unpack["ReaderRefundPaymentParams"]
) -> "Reader":
"""
Initiates a refund on a Reader
@@ -1977,7 +1518,7 @@ async def refund_payment_async(
@overload
async def refund_payment_async(
- self, **params: Unpack["Reader.RefundPaymentParams"]
+ self, **params: Unpack["ReaderRefundPaymentParams"]
) -> "Reader":
"""
Initiates a refund on a Reader
@@ -1986,7 +1527,7 @@ async def refund_payment_async(
@class_method_variant("_cls_refund_payment_async")
async def refund_payment_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.RefundPaymentParams"]
+ self, **params: Unpack["ReaderRefundPaymentParams"]
) -> "Reader":
"""
Initiates a refund on a Reader
@@ -2004,7 +1545,7 @@ async def refund_payment_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Reader.RetrieveParams"]
+ cls, id: str, **params: Unpack["ReaderRetrieveParams"]
) -> "Reader":
"""
Retrieves a Reader object.
@@ -2015,7 +1556,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Reader.RetrieveParams"]
+ cls, id: str, **params: Unpack["ReaderRetrieveParams"]
) -> "Reader":
"""
Retrieves a Reader object.
@@ -2026,7 +1567,7 @@ async def retrieve_async(
@classmethod
def _cls_set_reader_display(
- cls, reader: str, **params: Unpack["Reader.SetReaderDisplayParams"]
+ cls, reader: str, **params: Unpack["ReaderSetReaderDisplayParams"]
) -> "Reader":
"""
Sets reader display to show cart details.
@@ -2045,7 +1586,7 @@ def _cls_set_reader_display(
@overload
@staticmethod
def set_reader_display(
- reader: str, **params: Unpack["Reader.SetReaderDisplayParams"]
+ reader: str, **params: Unpack["ReaderSetReaderDisplayParams"]
) -> "Reader":
"""
Sets reader display to show cart details.
@@ -2054,7 +1595,7 @@ def set_reader_display(
@overload
def set_reader_display(
- self, **params: Unpack["Reader.SetReaderDisplayParams"]
+ self, **params: Unpack["ReaderSetReaderDisplayParams"]
) -> "Reader":
"""
Sets reader display to show cart details.
@@ -2063,7 +1604,7 @@ def set_reader_display(
@class_method_variant("_cls_set_reader_display")
def set_reader_display( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.SetReaderDisplayParams"]
+ self, **params: Unpack["ReaderSetReaderDisplayParams"]
) -> "Reader":
"""
Sets reader display to show cart details.
@@ -2081,7 +1622,7 @@ def set_reader_display( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_set_reader_display_async(
- cls, reader: str, **params: Unpack["Reader.SetReaderDisplayParams"]
+ cls, reader: str, **params: Unpack["ReaderSetReaderDisplayParams"]
) -> "Reader":
"""
Sets reader display to show cart details.
@@ -2100,7 +1641,7 @@ async def _cls_set_reader_display_async(
@overload
@staticmethod
async def set_reader_display_async(
- reader: str, **params: Unpack["Reader.SetReaderDisplayParams"]
+ reader: str, **params: Unpack["ReaderSetReaderDisplayParams"]
) -> "Reader":
"""
Sets reader display to show cart details.
@@ -2109,7 +1650,7 @@ async def set_reader_display_async(
@overload
async def set_reader_display_async(
- self, **params: Unpack["Reader.SetReaderDisplayParams"]
+ self, **params: Unpack["ReaderSetReaderDisplayParams"]
) -> "Reader":
"""
Sets reader display to show cart details.
@@ -2118,7 +1659,7 @@ async def set_reader_display_async(
@class_method_variant("_cls_set_reader_display_async")
async def set_reader_display_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.SetReaderDisplayParams"]
+ self, **params: Unpack["ReaderSetReaderDisplayParams"]
) -> "Reader":
"""
Sets reader display to show cart details.
@@ -2141,7 +1682,7 @@ class TestHelpers(APIResourceTestHelpers["Reader"]):
def _cls_present_payment_method(
cls,
reader: str,
- **params: Unpack["Reader.PresentPaymentMethodParams"],
+ **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.
@@ -2160,7 +1701,7 @@ def _cls_present_payment_method(
@overload
@staticmethod
def present_payment_method(
- reader: str, **params: Unpack["Reader.PresentPaymentMethodParams"]
+ 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.
@@ -2169,7 +1710,7 @@ def present_payment_method(
@overload
def present_payment_method(
- self, **params: Unpack["Reader.PresentPaymentMethodParams"]
+ self, **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.
@@ -2178,7 +1719,7 @@ def present_payment_method(
@class_method_variant("_cls_present_payment_method")
def present_payment_method( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.PresentPaymentMethodParams"]
+ self, **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.
@@ -2198,7 +1739,7 @@ def present_payment_method( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_present_payment_method_async(
cls,
reader: str,
- **params: Unpack["Reader.PresentPaymentMethodParams"],
+ **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.
@@ -2217,7 +1758,7 @@ async def _cls_present_payment_method_async(
@overload
@staticmethod
async def present_payment_method_async(
- reader: str, **params: Unpack["Reader.PresentPaymentMethodParams"]
+ 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.
@@ -2226,7 +1767,7 @@ async def present_payment_method_async(
@overload
async def present_payment_method_async(
- self, **params: Unpack["Reader.PresentPaymentMethodParams"]
+ self, **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.
@@ -2235,7 +1776,7 @@ async def present_payment_method_async(
@class_method_variant("_cls_present_payment_method_async")
async def present_payment_method_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.PresentPaymentMethodParams"]
+ self, **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.
@@ -2255,7 +1796,7 @@ async def present_payment_method_async( # pyright: ignore[reportGeneralTypeIssu
def _cls_succeed_input_collection(
cls,
reader: str,
- **params: Unpack["Reader.SucceedInputCollectionParams"],
+ **params: Unpack["ReaderSucceedInputCollectionParams"],
) -> "Reader":
"""
Use this endpoint to trigger a successful input collection on a simulated reader.
@@ -2274,8 +1815,7 @@ def _cls_succeed_input_collection(
@overload
@staticmethod
def succeed_input_collection(
- reader: str,
- **params: Unpack["Reader.SucceedInputCollectionParams"],
+ reader: str, **params: Unpack["ReaderSucceedInputCollectionParams"]
) -> "Reader":
"""
Use this endpoint to trigger a successful input collection on a simulated reader.
@@ -2284,7 +1824,7 @@ def succeed_input_collection(
@overload
def succeed_input_collection(
- self, **params: Unpack["Reader.SucceedInputCollectionParams"]
+ self, **params: Unpack["ReaderSucceedInputCollectionParams"]
) -> "Reader":
"""
Use this endpoint to trigger a successful input collection on a simulated reader.
@@ -2293,7 +1833,7 @@ def succeed_input_collection(
@class_method_variant("_cls_succeed_input_collection")
def succeed_input_collection( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.SucceedInputCollectionParams"]
+ self, **params: Unpack["ReaderSucceedInputCollectionParams"]
) -> "Reader":
"""
Use this endpoint to trigger a successful input collection on a simulated reader.
@@ -2313,7 +1853,7 @@ def succeed_input_collection( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_succeed_input_collection_async(
cls,
reader: str,
- **params: Unpack["Reader.SucceedInputCollectionParams"],
+ **params: Unpack["ReaderSucceedInputCollectionParams"],
) -> "Reader":
"""
Use this endpoint to trigger a successful input collection on a simulated reader.
@@ -2332,8 +1872,7 @@ async def _cls_succeed_input_collection_async(
@overload
@staticmethod
async def succeed_input_collection_async(
- reader: str,
- **params: Unpack["Reader.SucceedInputCollectionParams"],
+ reader: str, **params: Unpack["ReaderSucceedInputCollectionParams"]
) -> "Reader":
"""
Use this endpoint to trigger a successful input collection on a simulated reader.
@@ -2342,7 +1881,7 @@ async def succeed_input_collection_async(
@overload
async def succeed_input_collection_async(
- self, **params: Unpack["Reader.SucceedInputCollectionParams"]
+ self, **params: Unpack["ReaderSucceedInputCollectionParams"]
) -> "Reader":
"""
Use this endpoint to trigger a successful input collection on a simulated reader.
@@ -2351,7 +1890,7 @@ async def succeed_input_collection_async(
@class_method_variant("_cls_succeed_input_collection_async")
async def succeed_input_collection_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.SucceedInputCollectionParams"]
+ self, **params: Unpack["ReaderSucceedInputCollectionParams"]
) -> "Reader":
"""
Use this endpoint to trigger a successful input collection on a simulated reader.
@@ -2371,7 +1910,7 @@ async def succeed_input_collection_async( # pyright: ignore[reportGeneralTypeIs
def _cls_timeout_input_collection(
cls,
reader: str,
- **params: Unpack["Reader.TimeoutInputCollectionParams"],
+ **params: Unpack["ReaderTimeoutInputCollectionParams"],
) -> "Reader":
"""
Use this endpoint to complete an input collection with a timeout error on a simulated reader.
@@ -2390,8 +1929,7 @@ def _cls_timeout_input_collection(
@overload
@staticmethod
def timeout_input_collection(
- reader: str,
- **params: Unpack["Reader.TimeoutInputCollectionParams"],
+ reader: str, **params: Unpack["ReaderTimeoutInputCollectionParams"]
) -> "Reader":
"""
Use this endpoint to complete an input collection with a timeout error on a simulated reader.
@@ -2400,7 +1938,7 @@ def timeout_input_collection(
@overload
def timeout_input_collection(
- self, **params: Unpack["Reader.TimeoutInputCollectionParams"]
+ self, **params: Unpack["ReaderTimeoutInputCollectionParams"]
) -> "Reader":
"""
Use this endpoint to complete an input collection with a timeout error on a simulated reader.
@@ -2409,7 +1947,7 @@ def timeout_input_collection(
@class_method_variant("_cls_timeout_input_collection")
def timeout_input_collection( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.TimeoutInputCollectionParams"]
+ self, **params: Unpack["ReaderTimeoutInputCollectionParams"]
) -> "Reader":
"""
Use this endpoint to complete an input collection with a timeout error on a simulated reader.
@@ -2429,7 +1967,7 @@ def timeout_input_collection( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_timeout_input_collection_async(
cls,
reader: str,
- **params: Unpack["Reader.TimeoutInputCollectionParams"],
+ **params: Unpack["ReaderTimeoutInputCollectionParams"],
) -> "Reader":
"""
Use this endpoint to complete an input collection with a timeout error on a simulated reader.
@@ -2448,8 +1986,7 @@ async def _cls_timeout_input_collection_async(
@overload
@staticmethod
async def timeout_input_collection_async(
- reader: str,
- **params: Unpack["Reader.TimeoutInputCollectionParams"],
+ reader: str, **params: Unpack["ReaderTimeoutInputCollectionParams"]
) -> "Reader":
"""
Use this endpoint to complete an input collection with a timeout error on a simulated reader.
@@ -2458,7 +1995,7 @@ async def timeout_input_collection_async(
@overload
async def timeout_input_collection_async(
- self, **params: Unpack["Reader.TimeoutInputCollectionParams"]
+ self, **params: Unpack["ReaderTimeoutInputCollectionParams"]
) -> "Reader":
"""
Use this endpoint to complete an input collection with a timeout error on a simulated reader.
@@ -2467,7 +2004,7 @@ async def timeout_input_collection_async(
@class_method_variant("_cls_timeout_input_collection_async")
async def timeout_input_collection_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["Reader.TimeoutInputCollectionParams"]
+ self, **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 1ec6c8d57..ff9eabaaf 100644
--- a/stripe/terminal/_reader_service.py
+++ b/stripe/terminal/_reader_service.py
@@ -5,434 +5,48 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.terminal._reader import Reader
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.terminal._reader_cancel_action_params import (
+ ReaderCancelActionParams,
+ )
+ from stripe.params.terminal._reader_collect_inputs_params import (
+ ReaderCollectInputsParams,
+ )
+ from stripe.params.terminal._reader_collect_payment_method_params import (
+ ReaderCollectPaymentMethodParams,
+ )
+ from stripe.params.terminal._reader_confirm_payment_intent_params import (
+ ReaderConfirmPaymentIntentParams,
+ )
+ from stripe.params.terminal._reader_create_params import ReaderCreateParams
+ from stripe.params.terminal._reader_delete_params import ReaderDeleteParams
+ from stripe.params.terminal._reader_list_params import ReaderListParams
+ from stripe.params.terminal._reader_process_payment_intent_params import (
+ ReaderProcessPaymentIntentParams,
+ )
+ from stripe.params.terminal._reader_process_setup_intent_params import (
+ ReaderProcessSetupIntentParams,
+ )
+ from stripe.params.terminal._reader_refund_payment_params import (
+ ReaderRefundPaymentParams,
+ )
+ from stripe.params.terminal._reader_retrieve_params import (
+ ReaderRetrieveParams,
+ )
+ from stripe.params.terminal._reader_set_reader_display_params import (
+ ReaderSetReaderDisplayParams,
+ )
+ from stripe.params.terminal._reader_update_params import ReaderUpdateParams
class ReaderService(StripeService):
- class CancelActionParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CollectInputsParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- inputs: List["ReaderService.CollectInputsParamsInput"]
- """
- List of inputs to be collected using the Reader
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
- class CollectInputsParamsInput(TypedDict):
- custom_text: "ReaderService.CollectInputsParamsInputCustomText"
- """
- Customize the text which will be displayed while collecting this input
- """
- required: NotRequired[bool]
- """
- Indicate that this input is required, disabling the skip button
- """
- selection: NotRequired[
- "ReaderService.CollectInputsParamsInputSelection"
- ]
- """
- Options for the `selection` input
- """
- toggles: NotRequired[
- List["ReaderService.CollectInputsParamsInputToggle"]
- ]
- """
- List of toggles to be displayed and customization for the toggles
- """
- type: Literal[
- "email", "numeric", "phone", "selection", "signature", "text"
- ]
- """
- The type of input to collect
- """
-
- class CollectInputsParamsInputCustomText(TypedDict):
- description: NotRequired[str]
- """
- The description which will be displayed when collecting this input
- """
- skip_button: NotRequired[str]
- """
- The skip button text
- """
- submit_button: NotRequired[str]
- """
- The submit button text
- """
- title: str
- """
- The title which will be displayed when collecting this input
- """
-
- class CollectInputsParamsInputSelection(TypedDict):
- choices: List["ReaderService.CollectInputsParamsInputSelectionChoice"]
- """
- List of choices for the `selection` input
- """
-
- class CollectInputsParamsInputSelectionChoice(TypedDict):
- id: str
- """
- The unique identifier for this choice
- """
- style: NotRequired[Literal["primary", "secondary"]]
- """
- The style of the button which will be shown for this choice
- """
- text: str
- """
- The text which will be shown on the button for this choice
- """
-
- class CollectInputsParamsInputToggle(TypedDict):
- default_value: NotRequired[Literal["disabled", "enabled"]]
- """
- The default value of the toggle
- """
- description: NotRequired[str]
- """
- The description which will be displayed for the toggle
- """
- title: NotRequired[str]
- """
- The title which will be displayed for the toggle
- """
-
- class CollectPaymentMethodParams(TypedDict):
- collect_config: NotRequired[
- "ReaderService.CollectPaymentMethodParamsCollectConfig"
- ]
- """
- Configuration overrides.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- payment_intent: str
- """
- PaymentIntent ID.
- """
-
- class CollectPaymentMethodParamsCollectConfig(TypedDict):
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
- """
- enable_customer_cancellation: NotRequired[bool]
- """
- Enables cancel button on transaction screens.
- """
- skip_tipping: NotRequired[bool]
- """
- Override showing a tipping selection screen on this transaction.
- """
- tipping: NotRequired[
- "ReaderService.CollectPaymentMethodParamsCollectConfigTipping"
- ]
- """
- Tipping configuration for this transaction.
- """
-
- class CollectPaymentMethodParamsCollectConfigTipping(TypedDict):
- amount_eligible: NotRequired[int]
- """
- Amount used to calculate tip suggestions on tipping selection screen for this transaction. Must be a positive integer in the smallest currency unit (e.g., 100 cents to represent $1.00 or 100 to represent ¥100, a zero-decimal currency).
- """
-
- class ConfirmPaymentIntentParams(TypedDict):
- confirm_config: NotRequired[
- "ReaderService.ConfirmPaymentIntentParamsConfirmConfig"
- ]
- """
- Configuration overrides.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- payment_intent: str
- """
- PaymentIntent ID.
- """
-
- class ConfirmPaymentIntentParamsConfirmConfig(TypedDict):
- return_url: NotRequired[str]
- """
- The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
- """
-
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- label: NotRequired[str]
- """
- Custom label given to the reader for easier identification. If no label is specified, the registration code will be used.
- """
- location: NotRequired[str]
- """
- The location to assign the reader to.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- registration_code: str
- """
- A code generated by the reader used for registering to an account.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- device_type: NotRequired[
- Literal[
- "bbpos_chipper2x",
- "bbpos_wisepad3",
- "bbpos_wisepos_e",
- "mobile_phone_reader",
- "simulated_stripe_s700",
- "simulated_wisepos_e",
- "stripe_m2",
- "stripe_s700",
- "verifone_P400",
- ]
- ]
- """
- Filters readers by device type
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- location: NotRequired[str]
- """
- A location ID to filter the response list to only readers at the specific location
- """
- serial_number: NotRequired[str]
- """
- Filters readers by serial number
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["offline", "online"]]
- """
- A status filter to filter readers to only offline or online readers
- """
-
- class ProcessPaymentIntentParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- payment_intent: str
- """
- PaymentIntent ID
- """
- process_config: NotRequired[
- "ReaderService.ProcessPaymentIntentParamsProcessConfig"
- ]
- """
- Configuration overrides
- """
-
- class ProcessPaymentIntentParamsProcessConfig(TypedDict):
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
- """
- enable_customer_cancellation: NotRequired[bool]
- """
- Enables cancel button on transaction screens.
- """
- return_url: NotRequired[str]
- """
- The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
- """
- skip_tipping: NotRequired[bool]
- """
- Override showing a tipping selection screen on this transaction.
- """
- tipping: NotRequired[
- "ReaderService.ProcessPaymentIntentParamsProcessConfigTipping"
- ]
- """
- Tipping configuration for this transaction.
- """
-
- class ProcessPaymentIntentParamsProcessConfigTipping(TypedDict):
- amount_eligible: NotRequired[int]
- """
- Amount used to calculate tip suggestions on tipping selection screen for this transaction. Must be a positive integer in the smallest currency unit (e.g., 100 cents to represent $1.00 or 100 to represent ¥100, a zero-decimal currency).
- """
-
- class ProcessSetupIntentParams(TypedDict):
- allow_redisplay: Literal["always", "limited", "unspecified"]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- process_config: NotRequired[
- "ReaderService.ProcessSetupIntentParamsProcessConfig"
- ]
- """
- Configuration overrides
- """
- setup_intent: str
- """
- SetupIntent ID
- """
-
- class ProcessSetupIntentParamsProcessConfig(TypedDict):
- enable_customer_cancellation: NotRequired[bool]
- """
- Enables cancel button on transaction screens.
- """
-
- class RefundPaymentParams(TypedDict):
- amount: NotRequired[int]
- """
- A positive integer in __cents__ representing how much of this charge to refund.
- """
- charge: NotRequired[str]
- """
- ID of the Charge to refund.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- payment_intent: NotRequired[str]
- """
- ID of the PaymentIntent to refund.
- """
- refund_application_fee: NotRequired[bool]
- """
- Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.
- """
- refund_payment_config: NotRequired[
- "ReaderService.RefundPaymentParamsRefundPaymentConfig"
- ]
- """
- Configuration overrides
- """
- reverse_transfer: NotRequired[bool]
- """
- Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount). A transfer can be reversed only by the application that created the charge.
- """
-
- class RefundPaymentParamsRefundPaymentConfig(TypedDict):
- enable_customer_cancellation: NotRequired[bool]
- """
- Enables cancel button on transaction screens.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SetReaderDisplayParams(TypedDict):
- cart: NotRequired["ReaderService.SetReaderDisplayParamsCart"]
- """
- Cart
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- type: Literal["cart"]
- """
- Type
- """
-
- class SetReaderDisplayParamsCart(TypedDict):
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- line_items: List["ReaderService.SetReaderDisplayParamsCartLineItem"]
- """
- Array of line items that were purchased.
- """
- tax: NotRequired[int]
- """
- The amount of tax in cents.
- """
- total: int
- """
- Total balance of cart due in cents.
- """
-
- class SetReaderDisplayParamsCartLineItem(TypedDict):
- amount: int
- """
- The price of the item in cents.
- """
- description: str
- """
- The description or name of the item.
- """
- quantity: int
- """
- The quantity of the line item being purchased.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- label: NotRequired["Literal['']|str"]
- """
- The new label of the reader.
- """
- metadata: NotRequired["Literal['']|Dict[str, str]"]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
-
def delete(
self,
reader: str,
- params: Optional["ReaderService.DeleteParams"] = None,
+ params: Optional["ReaderDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -454,7 +68,7 @@ def delete(
async def delete_async(
self,
reader: str,
- params: Optional["ReaderService.DeleteParams"] = None,
+ params: Optional["ReaderDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -476,7 +90,7 @@ async def delete_async(
def retrieve(
self,
reader: str,
- params: Optional["ReaderService.RetrieveParams"] = None,
+ params: Optional["ReaderRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -498,7 +112,7 @@ def retrieve(
async def retrieve_async(
self,
reader: str,
- params: Optional["ReaderService.RetrieveParams"] = None,
+ params: Optional["ReaderRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -520,7 +134,7 @@ async def retrieve_async(
def update(
self,
reader: str,
- params: Optional["ReaderService.UpdateParams"] = None,
+ params: Optional["ReaderUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -542,7 +156,7 @@ def update(
async def update_async(
self,
reader: str,
- params: Optional["ReaderService.UpdateParams"] = None,
+ params: Optional["ReaderUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -563,7 +177,7 @@ async def update_async(
def list(
self,
- params: Optional["ReaderService.ListParams"] = None,
+ params: Optional["ReaderListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Reader]:
"""
@@ -582,7 +196,7 @@ def list(
async def list_async(
self,
- params: Optional["ReaderService.ListParams"] = None,
+ params: Optional["ReaderListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[Reader]:
"""
@@ -601,7 +215,7 @@ async def list_async(
def create(
self,
- params: "ReaderService.CreateParams",
+ params: "ReaderCreateParams",
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -620,7 +234,7 @@ def create(
async def create_async(
self,
- params: "ReaderService.CreateParams",
+ params: "ReaderCreateParams",
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -640,7 +254,7 @@ async def create_async(
def cancel_action(
self,
reader: str,
- params: Optional["ReaderService.CancelActionParams"] = None,
+ params: Optional["ReaderCancelActionParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -662,7 +276,7 @@ def cancel_action(
async def cancel_action_async(
self,
reader: str,
- params: Optional["ReaderService.CancelActionParams"] = None,
+ params: Optional["ReaderCancelActionParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -684,7 +298,7 @@ async def cancel_action_async(
def collect_inputs(
self,
reader: str,
- params: "ReaderService.CollectInputsParams",
+ params: "ReaderCollectInputsParams",
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -706,7 +320,7 @@ def collect_inputs(
async def collect_inputs_async(
self,
reader: str,
- params: "ReaderService.CollectInputsParams",
+ params: "ReaderCollectInputsParams",
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -728,7 +342,7 @@ async def collect_inputs_async(
def collect_payment_method(
self,
reader: str,
- params: "ReaderService.CollectPaymentMethodParams",
+ params: "ReaderCollectPaymentMethodParams",
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -750,7 +364,7 @@ def collect_payment_method(
async def collect_payment_method_async(
self,
reader: str,
- params: "ReaderService.CollectPaymentMethodParams",
+ params: "ReaderCollectPaymentMethodParams",
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -772,7 +386,7 @@ async def collect_payment_method_async(
def confirm_payment_intent(
self,
reader: str,
- params: "ReaderService.ConfirmPaymentIntentParams",
+ params: "ReaderConfirmPaymentIntentParams",
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -794,7 +408,7 @@ def confirm_payment_intent(
async def confirm_payment_intent_async(
self,
reader: str,
- params: "ReaderService.ConfirmPaymentIntentParams",
+ params: "ReaderConfirmPaymentIntentParams",
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -816,7 +430,7 @@ async def confirm_payment_intent_async(
def process_payment_intent(
self,
reader: str,
- params: "ReaderService.ProcessPaymentIntentParams",
+ params: "ReaderProcessPaymentIntentParams",
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -838,7 +452,7 @@ def process_payment_intent(
async def process_payment_intent_async(
self,
reader: str,
- params: "ReaderService.ProcessPaymentIntentParams",
+ params: "ReaderProcessPaymentIntentParams",
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -860,7 +474,7 @@ async def process_payment_intent_async(
def process_setup_intent(
self,
reader: str,
- params: "ReaderService.ProcessSetupIntentParams",
+ params: "ReaderProcessSetupIntentParams",
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -882,7 +496,7 @@ def process_setup_intent(
async def process_setup_intent_async(
self,
reader: str,
- params: "ReaderService.ProcessSetupIntentParams",
+ params: "ReaderProcessSetupIntentParams",
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -904,7 +518,7 @@ async def process_setup_intent_async(
def refund_payment(
self,
reader: str,
- params: Optional["ReaderService.RefundPaymentParams"] = None,
+ params: Optional["ReaderRefundPaymentParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -926,7 +540,7 @@ def refund_payment(
async def refund_payment_async(
self,
reader: str,
- params: Optional["ReaderService.RefundPaymentParams"] = None,
+ params: Optional["ReaderRefundPaymentParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -948,7 +562,7 @@ async def refund_payment_async(
def set_reader_display(
self,
reader: str,
- params: "ReaderService.SetReaderDisplayParams",
+ params: "ReaderSetReaderDisplayParams",
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -970,7 +584,7 @@ def set_reader_display(
async def set_reader_display_async(
self,
reader: str,
- params: "ReaderService.SetReaderDisplayParams",
+ params: "ReaderSetReaderDisplayParams",
options: Optional[RequestOptions] = None,
) -> Reader:
"""
diff --git a/stripe/test_helpers/_confirmation_token_service.py b/stripe/test_helpers/_confirmation_token_service.py
index 204cce1d6..84d2730dc 100644
--- a/stripe/test_helpers/_confirmation_token_service.py
+++ b/stripe/test_helpers/_confirmation_token_service.py
@@ -3,916 +3,19 @@
from stripe._confirmation_token import ConfirmationToken
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.test_helpers._confirmation_token_create_params import (
+ ConfirmationTokenCreateParams,
+ )
-class ConfirmationTokenService(StripeService):
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- payment_method: NotRequired[str]
- """
- ID of an existing PaymentMethod.
- """
- payment_method_data: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodData"
- ]
- """
- If provided, this hash will be used to create a PaymentMethod.
- """
- payment_method_options: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodOptions"
- ]
- """
- Payment-method-specific configuration for this ConfirmationToken.
- """
- return_url: NotRequired[str]
- """
- Return URL used to confirm the Intent.
- """
- setup_future_usage: NotRequired[Literal["off_session", "on_session"]]
- """
- Indicates that you intend to make future payments with this ConfirmationToken's payment method.
-
- The presence of this property will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete.
- """
- shipping: NotRequired["ConfirmationTokenService.CreateParamsShipping"]
- """
- Shipping information for this ConfirmationToken.
- """
-
- class CreateParamsPaymentMethodData(TypedDict):
- acss_debit: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataAcssDebit"
- ]
- """
- If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
- """
- affirm: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataAffirm"
- ]
- """
- If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
- """
- afterpay_clearpay: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataAfterpayClearpay"
- ]
- """
- If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
- """
- alipay: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataAlipay"
- ]
- """
- If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
- """
- allow_redisplay: NotRequired[
- Literal["always", "limited", "unspecified"]
- ]
- """
- This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
- """
- alma: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataAlma"
- ]
- """
- If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
- """
- amazon_pay: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataAmazonPay"
- ]
- """
- If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
- """
- au_becs_debit: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataAuBecsDebit"
- ]
- """
- If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
- """
- bacs_debit: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataBacsDebit"
- ]
- """
- If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
- """
- bancontact: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataBancontact"
- ]
- """
- If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
- """
- billie: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataBillie"
- ]
- """
- If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
- """
- billing_details: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- blik: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataBlik"
- ]
- """
- If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
- """
- boleto: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataBoleto"
- ]
- """
- If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
- """
- cashapp: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataCashapp"
- ]
- """
- If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
- """
- crypto: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataCrypto"
- ]
- """
- If this is a Crypto PaymentMethod, this hash contains details about the Crypto payment method.
- """
- customer_balance: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataCustomerBalance"
- ]
- """
- If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
- """
- eps: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataEps"
- ]
- """
- If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
- """
- fpx: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataFpx"
- ]
- """
- If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
- """
- giropay: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataGiropay"
- ]
- """
- If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
- """
- grabpay: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataGrabpay"
- ]
- """
- If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
- """
- ideal: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataIdeal"
- ]
- """
- If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
- """
- interac_present: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataInteracPresent"
- ]
- """
- If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
- """
- kakao_pay: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataKakaoPay"
- ]
- """
- If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
- """
- klarna: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataKlarna"
- ]
- """
- If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
- """
- konbini: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataKonbini"
- ]
- """
- If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
- """
- kr_card: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataKrCard"
- ]
- """
- If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
- """
- link: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataLink"
- ]
- """
- If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
- """
- mb_way: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataMbWay"
- ]
- """
- If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- mobilepay: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataMobilepay"
- ]
- """
- If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
- """
- multibanco: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataMultibanco"
- ]
- """
- If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
- """
- naver_pay: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataNaverPay"
- ]
- """
- If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
- """
- nz_bank_account: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataNzBankAccount"
- ]
- """
- If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
- """
- oxxo: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataOxxo"
- ]
- """
- If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
- """
- p24: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataP24"
- ]
- """
- If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
- """
- pay_by_bank: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataPayByBank"
- ]
- """
- If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
- """
- payco: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataPayco"
- ]
- """
- If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
- """
- paynow: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataPaynow"
- ]
- """
- If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
- """
- paypal: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataPaypal"
- ]
- """
- If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
- """
- pix: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataPix"
- ]
- """
- If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
- """
- promptpay: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataPromptpay"
- ]
- """
- If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
- """
- radar_options: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataRadarOptions"
- ]
- """
- Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
- """
- revolut_pay: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataRevolutPay"
- ]
- """
- If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
- """
- samsung_pay: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataSamsungPay"
- ]
- """
- If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
- """
- satispay: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataSatispay"
- ]
- """
- If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
- """
- sepa_debit: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataSepaDebit"
- ]
- """
- If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
- """
- sofort: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataSofort"
- ]
- """
- If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
- """
- swish: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataSwish"
- ]
- """
- If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
- """
- twint: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataTwint"
- ]
- """
- If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
- """
- type: Literal[
- "acss_debit",
- "affirm",
- "afterpay_clearpay",
- "alipay",
- "alma",
- "amazon_pay",
- "au_becs_debit",
- "bacs_debit",
- "bancontact",
- "billie",
- "blik",
- "boleto",
- "cashapp",
- "crypto",
- "customer_balance",
- "eps",
- "fpx",
- "giropay",
- "grabpay",
- "ideal",
- "kakao_pay",
- "klarna",
- "konbini",
- "kr_card",
- "link",
- "mb_way",
- "mobilepay",
- "multibanco",
- "naver_pay",
- "nz_bank_account",
- "oxxo",
- "p24",
- "pay_by_bank",
- "payco",
- "paynow",
- "paypal",
- "pix",
- "promptpay",
- "revolut_pay",
- "samsung_pay",
- "satispay",
- "sepa_debit",
- "sofort",
- "swish",
- "twint",
- "us_bank_account",
- "wechat_pay",
- "zip",
- ]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataUsBankAccount"
- ]
- """
- If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
- """
- wechat_pay: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataWechatPay"
- ]
- """
- If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
- """
- zip: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataZip"
- ]
- """
- If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
- """
-
- class CreateParamsPaymentMethodDataAcssDebit(TypedDict):
- account_number: str
- """
- Customer's bank account number.
- """
- institution_number: str
- """
- Institution number of the customer's bank.
- """
- transit_number: str
- """
- Transit number of the customer's bank.
- """
-
- class CreateParamsPaymentMethodDataAffirm(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAfterpayClearpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAlipay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAlma(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAmazonPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataAuBecsDebit(TypedDict):
- account_number: str
- """
- The account number for the bank account.
- """
- bsb_number: str
- """
- Bank-State-Branch number of the bank account.
- """
-
- class CreateParamsPaymentMethodDataBacsDebit(TypedDict):
- account_number: NotRequired[str]
- """
- Account number of the bank account that the funds will be debited from.
- """
- sort_code: NotRequired[str]
- """
- Sort code of the bank account. (e.g., `10-20-30`)
- """
-
- class CreateParamsPaymentMethodDataBancontact(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBillie(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|ConfirmationTokenService.CreateParamsPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
- tax_id: NotRequired[str]
- """
- Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
- """
-
- class CreateParamsPaymentMethodDataBillingDetailsAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsPaymentMethodDataBlik(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataBoleto(TypedDict):
- tax_id: str
- """
- The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
- """
-
- class CreateParamsPaymentMethodDataCashapp(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataCrypto(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataCustomerBalance(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataEps(TypedDict):
- bank: NotRequired[
- Literal[
- "arzte_und_apotheker_bank",
- "austrian_anadi_bank_ag",
- "bank_austria",
- "bankhaus_carl_spangler",
- "bankhaus_schelhammer_und_schattera_ag",
- "bawag_psk_ag",
- "bks_bank_ag",
- "brull_kallmus_bank_ag",
- "btv_vier_lander_bank",
- "capital_bank_grawe_gruppe_ag",
- "deutsche_bank_ag",
- "dolomitenbank",
- "easybank_ag",
- "erste_bank_und_sparkassen",
- "hypo_alpeadriabank_international_ag",
- "hypo_bank_burgenland_aktiengesellschaft",
- "hypo_noe_lb_fur_niederosterreich_u_wien",
- "hypo_oberosterreich_salzburg_steiermark",
- "hypo_tirol_bank_ag",
- "hypo_vorarlberg_bank_ag",
- "marchfelder_bank",
- "oberbank_ag",
- "raiffeisen_bankengruppe_osterreich",
- "schoellerbank_ag",
- "sparda_bank_wien",
- "volksbank_gruppe",
- "volkskreditbank_ag",
- "vr_bank_braunau",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataFpx(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type for FPX transaction
- """
- bank: Literal[
- "affin_bank",
- "agrobank",
- "alliance_bank",
- "ambank",
- "bank_islam",
- "bank_muamalat",
- "bank_of_china",
- "bank_rakyat",
- "bsn",
- "cimb",
- "deutsche_bank",
- "hong_leong_bank",
- "hsbc",
- "kfh",
- "maybank2e",
- "maybank2u",
- "ocbc",
- "pb_enterprise",
- "public_bank",
- "rhb",
- "standard_chartered",
- "uob",
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataGiropay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataGrabpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataIdeal(TypedDict):
- bank: NotRequired[
- Literal[
- "abn_amro",
- "asn_bank",
- "bunq",
- "buut",
- "handelsbanken",
- "ing",
- "knab",
- "moneyou",
- "n26",
- "nn",
- "rabobank",
- "regiobank",
- "revolut",
- "sns_bank",
- "triodos_bank",
- "van_lanschot",
- "yoursafe",
- ]
- ]
- """
- The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
- """
-
- class CreateParamsPaymentMethodDataInteracPresent(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKakaoPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKlarna(TypedDict):
- dob: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodDataKlarnaDob"
- ]
- """
- Customer's date of birth
- """
-
- class CreateParamsPaymentMethodDataKlarnaDob(TypedDict):
- day: int
- """
- The day of birth, between 1 and 31.
- """
- month: int
- """
- The month of birth, between 1 and 12.
- """
- year: int
- """
- The four-digit year of birth.
- """
-
- class CreateParamsPaymentMethodDataKonbini(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataKrCard(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataLink(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMbWay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMobilepay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataMultibanco(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataNaverPay(TypedDict):
- funding: NotRequired[Literal["card", "points"]]
- """
- Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
- """
-
- class CreateParamsPaymentMethodDataNzBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod's billing details.
- """
- account_number: str
- """
- The account number for the bank account.
- """
- bank_code: str
- """
- The numeric code for the bank account's bank.
- """
- branch_code: str
- """
- The numeric code for the bank account's bank branch.
- """
- reference: NotRequired[str]
- suffix: str
- """
- The suffix of the bank account number.
- """
-
- class CreateParamsPaymentMethodDataOxxo(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataP24(TypedDict):
- bank: NotRequired[
- Literal[
- "alior_bank",
- "bank_millennium",
- "bank_nowy_bfg_sa",
- "bank_pekao_sa",
- "banki_spbdzielcze",
- "blik",
- "bnp_paribas",
- "boz",
- "citi_handlowy",
- "credit_agricole",
- "envelobank",
- "etransfer_pocztowy24",
- "getin_bank",
- "ideabank",
- "ing",
- "inteligo",
- "mbank_mtransfer",
- "nest_przelew",
- "noble_pay",
- "pbac_z_ipko",
- "plus_bank",
- "santander_przelew24",
- "tmobile_usbugi_bankowe",
- "toyota_bank",
- "velobank",
- "volkswagen_bank",
- ]
- ]
- """
- The customer's bank.
- """
-
- class CreateParamsPaymentMethodDataPayByBank(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPayco(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPaynow(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPaypal(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPix(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataPromptpay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataRadarOptions(TypedDict):
- session: NotRequired[str]
- """
- A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
- """
-
- class CreateParamsPaymentMethodDataRevolutPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSamsungPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSatispay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataSepaDebit(TypedDict):
- iban: str
- """
- IBAN of the bank account.
- """
-
- class CreateParamsPaymentMethodDataSofort(TypedDict):
- country: Literal["AT", "BE", "DE", "ES", "IT", "NL"]
- """
- Two-letter ISO code representing the country the bank account is located in.
- """
-
- class CreateParamsPaymentMethodDataSwish(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataTwint(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class CreateParamsPaymentMethodDataWechatPay(TypedDict):
- pass
-
- class CreateParamsPaymentMethodDataZip(TypedDict):
- pass
-
- class CreateParamsPaymentMethodOptions(TypedDict):
- card: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodOptionsCard"
- ]
- """
- Configuration for any card payments confirmed using this ConfirmationToken.
- """
-
- class CreateParamsPaymentMethodOptionsCard(TypedDict):
- installments: NotRequired[
- "ConfirmationTokenService.CreateParamsPaymentMethodOptionsCardInstallments"
- ]
- """
- Installment configuration for payments confirmed using this ConfirmationToken.
- """
-
- class CreateParamsPaymentMethodOptionsCardInstallments(TypedDict):
- plan: "ConfirmationTokenService.CreateParamsPaymentMethodOptionsCardInstallmentsPlan"
- """
- The selected installment plan to use for this payment attempt.
- This parameter can only be provided during confirmation.
- """
-
- class CreateParamsPaymentMethodOptionsCardInstallmentsPlan(TypedDict):
- count: NotRequired[int]
- """
- For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
- """
- interval: NotRequired[Literal["month"]]
- """
- For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
- One of `month`.
- """
- type: Literal["bonus", "fixed_count", "revolving"]
- """
- Type of installment plan, one of `fixed_count`, `bonus`, or `revolving`.
- """
-
- class CreateParamsShipping(TypedDict):
- address: "ConfirmationTokenService.CreateParamsShippingAddress"
- """
- Shipping address
- """
- name: str
- """
- Recipient name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Recipient phone (including extension)
- """
-
- class CreateParamsShippingAddress(TypedDict):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
+class ConfirmationTokenService(StripeService):
def create(
self,
- params: Optional["ConfirmationTokenService.CreateParams"] = None,
+ params: Optional["ConfirmationTokenCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> ConfirmationToken:
"""
@@ -931,7 +34,7 @@ def create(
async def create_async(
self,
- params: Optional["ConfirmationTokenService.CreateParams"] = None,
+ params: Optional["ConfirmationTokenCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> ConfirmationToken:
"""
diff --git a/stripe/test_helpers/_customer_service.py b/stripe/test_helpers/_customer_service.py
index c0a884d96..ee3fd2888 100644
--- a/stripe/test_helpers/_customer_service.py
+++ b/stripe/test_helpers/_customer_service.py
@@ -6,33 +6,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.test_helpers._customer_fund_cash_balance_params import (
+ CustomerFundCashBalanceParams,
+ )
-class CustomerService(StripeService):
- class FundCashBalanceParams(TypedDict):
- amount: int
- """
- Amount to be used for this test cash balance transaction. A positive integer representing how much to fund in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to fund $1.00 or 100 to fund ¥100, a zero-decimal currency).
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- reference: NotRequired[str]
- """
- A description of the test funding. This simulates free-text references supplied by customers when making bank transfers to their cash balance. You can use this to test how Stripe's [reconciliation algorithm](https://stripe.com/docs/payments/customer-balance/reconciliation) applies to different user inputs.
- """
+class CustomerService(StripeService):
def fund_cash_balance(
self,
customer: str,
- params: "CustomerService.FundCashBalanceParams",
+ params: "CustomerFundCashBalanceParams",
options: Optional[RequestOptions] = None,
) -> CustomerCashBalanceTransaction:
"""
@@ -54,7 +41,7 @@ def fund_cash_balance(
async def fund_cash_balance_async(
self,
customer: str,
- params: "CustomerService.FundCashBalanceParams",
+ params: "CustomerFundCashBalanceParams",
options: Optional[RequestOptions] = None,
) -> CustomerCashBalanceTransaction:
"""
diff --git a/stripe/test_helpers/_refund_service.py b/stripe/test_helpers/_refund_service.py
index e8f1f5a63..6c8297e01 100644
--- a/stripe/test_helpers/_refund_service.py
+++ b/stripe/test_helpers/_refund_service.py
@@ -4,21 +4,20 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.test_helpers._refund_expire_params import (
+ RefundExpireParams,
+ )
-class RefundService(StripeService):
- class ExpireParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class RefundService(StripeService):
def expire(
self,
refund: str,
- params: Optional["RefundService.ExpireParams"] = None,
+ params: Optional["RefundExpireParams"] = None,
options: Optional[RequestOptions] = None,
) -> Refund:
"""
@@ -40,7 +39,7 @@ def expire(
async def expire_async(
self,
refund: str,
- params: Optional["RefundService.ExpireParams"] = None,
+ 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 df06b4e03..ebc506b42 100644
--- a/stripe/test_helpers/_test_clock.py
+++ b/stripe/test_helpers/_test_clock.py
@@ -4,11 +4,27 @@
from stripe._deletable_api_resource import DeletableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, List, Optional, cast, overload
-from typing_extensions import Literal, NotRequired, Unpack
+from typing import ClassVar, Optional, cast, overload
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.test_helpers._test_clock_advance_params import (
+ TestClockAdvanceParams,
+ )
+ from stripe.params.test_helpers._test_clock_create_params import (
+ TestClockCreateParams,
+ )
+ from stripe.params.test_helpers._test_clock_delete_params import (
+ TestClockDeleteParams,
+ )
+ from stripe.params.test_helpers._test_clock_list_params import (
+ TestClockListParams,
+ )
+ from stripe.params.test_helpers._test_clock_retrieve_params import (
+ TestClockRetrieveParams,
+ )
class TestClock(
@@ -36,57 +52,6 @@ class Advancing(StripeObject):
advancing: Optional[Advancing]
_inner_class_types = {"advancing": Advancing}
- class AdvanceParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- frozen_time: int
- """
- The time to advance the test clock. Must be after the test clock's current frozen time. Cannot be more than two intervals in the future from the shortest subscription in this test clock. If there are no subscriptions in this test clock, it cannot be more than two years in the future.
- """
-
- class CreateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- frozen_time: int
- """
- The initial frozen time for this test clock.
- """
- name: NotRequired[str]
- """
- The name for this test clock.
- """
-
- class DeleteParams(RequestOptions):
- pass
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
created: int
"""
Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -127,7 +92,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def _cls_advance(
- cls, test_clock: str, **params: Unpack["TestClock.AdvanceParams"]
+ 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.
@@ -146,7 +111,7 @@ def _cls_advance(
@overload
@staticmethod
def advance(
- test_clock: str, **params: Unpack["TestClock.AdvanceParams"]
+ 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.
@@ -155,7 +120,7 @@ def advance(
@overload
def advance(
- self, **params: Unpack["TestClock.AdvanceParams"]
+ self, **params: Unpack["TestClockAdvanceParams"]
) -> "TestClock":
"""
Starts advancing a test clock to a specified time in the future. Advancement is done when status changes to Ready.
@@ -164,7 +129,7 @@ def advance(
@class_method_variant("_cls_advance")
def advance( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["TestClock.AdvanceParams"]
+ self, **params: Unpack["TestClockAdvanceParams"]
) -> "TestClock":
"""
Starts advancing a test clock to a specified time in the future. Advancement is done when status changes to Ready.
@@ -182,7 +147,7 @@ def advance( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_advance_async(
- cls, test_clock: str, **params: Unpack["TestClock.AdvanceParams"]
+ 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.
@@ -201,7 +166,7 @@ async def _cls_advance_async(
@overload
@staticmethod
async def advance_async(
- test_clock: str, **params: Unpack["TestClock.AdvanceParams"]
+ 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.
@@ -210,7 +175,7 @@ async def advance_async(
@overload
async def advance_async(
- self, **params: Unpack["TestClock.AdvanceParams"]
+ self, **params: Unpack["TestClockAdvanceParams"]
) -> "TestClock":
"""
Starts advancing a test clock to a specified time in the future. Advancement is done when status changes to Ready.
@@ -219,7 +184,7 @@ async def advance_async(
@class_method_variant("_cls_advance_async")
async def advance_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["TestClock.AdvanceParams"]
+ self, **params: Unpack["TestClockAdvanceParams"]
) -> "TestClock":
"""
Starts advancing a test clock to a specified time in the future. Advancement is done when status changes to Ready.
@@ -236,7 +201,7 @@ async def advance_async( # pyright: ignore[reportGeneralTypeIssues]
)
@classmethod
- def create(cls, **params: Unpack["TestClock.CreateParams"]) -> "TestClock":
+ def create(cls, **params: Unpack["TestClockCreateParams"]) -> "TestClock":
"""
Creates a new test clock that can be attached to new customers and quotes.
"""
@@ -251,7 +216,7 @@ def create(cls, **params: Unpack["TestClock.CreateParams"]) -> "TestClock":
@classmethod
async def create_async(
- cls, **params: Unpack["TestClock.CreateParams"]
+ cls, **params: Unpack["TestClockCreateParams"]
) -> "TestClock":
"""
Creates a new test clock that can be attached to new customers and quotes.
@@ -267,7 +232,7 @@ async def create_async(
@classmethod
def _cls_delete(
- cls, sid: str, **params: Unpack["TestClock.DeleteParams"]
+ cls, sid: str, **params: Unpack["TestClockDeleteParams"]
) -> "TestClock":
"""
Deletes a test clock.
@@ -285,7 +250,7 @@ def _cls_delete(
@overload
@staticmethod
def delete(
- sid: str, **params: Unpack["TestClock.DeleteParams"]
+ sid: str, **params: Unpack["TestClockDeleteParams"]
) -> "TestClock":
"""
Deletes a test clock.
@@ -293,9 +258,7 @@ def delete(
...
@overload
- def delete(
- self, **params: Unpack["TestClock.DeleteParams"]
- ) -> "TestClock":
+ def delete(self, **params: Unpack["TestClockDeleteParams"]) -> "TestClock":
"""
Deletes a test clock.
"""
@@ -303,7 +266,7 @@ def delete(
@class_method_variant("_cls_delete")
def delete( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["TestClock.DeleteParams"]
+ self, **params: Unpack["TestClockDeleteParams"]
) -> "TestClock":
"""
Deletes a test clock.
@@ -316,7 +279,7 @@ def delete( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_delete_async(
- cls, sid: str, **params: Unpack["TestClock.DeleteParams"]
+ cls, sid: str, **params: Unpack["TestClockDeleteParams"]
) -> "TestClock":
"""
Deletes a test clock.
@@ -334,7 +297,7 @@ async def _cls_delete_async(
@overload
@staticmethod
async def delete_async(
- sid: str, **params: Unpack["TestClock.DeleteParams"]
+ sid: str, **params: Unpack["TestClockDeleteParams"]
) -> "TestClock":
"""
Deletes a test clock.
@@ -343,7 +306,7 @@ async def delete_async(
@overload
async def delete_async(
- self, **params: Unpack["TestClock.DeleteParams"]
+ self, **params: Unpack["TestClockDeleteParams"]
) -> "TestClock":
"""
Deletes a test clock.
@@ -352,7 +315,7 @@ async def delete_async(
@class_method_variant("_cls_delete_async")
async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["TestClock.DeleteParams"]
+ self, **params: Unpack["TestClockDeleteParams"]
) -> "TestClock":
"""
Deletes a test clock.
@@ -365,7 +328,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def list(
- cls, **params: Unpack["TestClock.ListParams"]
+ cls, **params: Unpack["TestClockListParams"]
) -> ListObject["TestClock"]:
"""
Returns a list of your test clocks.
@@ -385,7 +348,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["TestClock.ListParams"]
+ cls, **params: Unpack["TestClockListParams"]
) -> ListObject["TestClock"]:
"""
Returns a list of your test clocks.
@@ -405,7 +368,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["TestClock.RetrieveParams"]
+ cls, id: str, **params: Unpack["TestClockRetrieveParams"]
) -> "TestClock":
"""
Retrieves a test clock.
@@ -416,7 +379,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["TestClock.RetrieveParams"]
+ cls, id: str, **params: Unpack["TestClockRetrieveParams"]
) -> "TestClock":
"""
Retrieves a test clock.
diff --git a/stripe/test_helpers/_test_clock_service.py b/stripe/test_helpers/_test_clock_service.py
index f632a09e0..988b51425 100644
--- a/stripe/test_helpers/_test_clock_service.py
+++ b/stripe/test_helpers/_test_clock_service.py
@@ -5,66 +5,32 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.test_helpers._test_clock import TestClock
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.test_helpers._test_clock_advance_params import (
+ TestClockAdvanceParams,
+ )
+ from stripe.params.test_helpers._test_clock_create_params import (
+ TestClockCreateParams,
+ )
+ from stripe.params.test_helpers._test_clock_delete_params import (
+ TestClockDeleteParams,
+ )
+ from stripe.params.test_helpers._test_clock_list_params import (
+ TestClockListParams,
+ )
+ from stripe.params.test_helpers._test_clock_retrieve_params import (
+ TestClockRetrieveParams,
+ )
class TestClockService(StripeService):
- class AdvanceParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- frozen_time: int
- """
- The time to advance the test clock. Must be after the test clock's current frozen time. Cannot be more than two intervals in the future from the shortest subscription in this test clock. If there are no subscriptions in this test clock, it cannot be more than two years in the future.
- """
-
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- frozen_time: int
- """
- The initial frozen time for this test clock.
- """
- name: NotRequired[str]
- """
- The name for this test clock.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
def delete(
self,
test_clock: str,
- params: Optional["TestClockService.DeleteParams"] = None,
+ params: Optional["TestClockDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> TestClock:
"""
@@ -86,7 +52,7 @@ def delete(
async def delete_async(
self,
test_clock: str,
- params: Optional["TestClockService.DeleteParams"] = None,
+ params: Optional["TestClockDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> TestClock:
"""
@@ -108,7 +74,7 @@ async def delete_async(
def retrieve(
self,
test_clock: str,
- params: Optional["TestClockService.RetrieveParams"] = None,
+ params: Optional["TestClockRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> TestClock:
"""
@@ -130,7 +96,7 @@ def retrieve(
async def retrieve_async(
self,
test_clock: str,
- params: Optional["TestClockService.RetrieveParams"] = None,
+ params: Optional["TestClockRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> TestClock:
"""
@@ -151,7 +117,7 @@ async def retrieve_async(
def list(
self,
- params: Optional["TestClockService.ListParams"] = None,
+ params: Optional["TestClockListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[TestClock]:
"""
@@ -170,7 +136,7 @@ def list(
async def list_async(
self,
- params: Optional["TestClockService.ListParams"] = None,
+ params: Optional["TestClockListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[TestClock]:
"""
@@ -189,7 +155,7 @@ async def list_async(
def create(
self,
- params: "TestClockService.CreateParams",
+ params: "TestClockCreateParams",
options: Optional[RequestOptions] = None,
) -> TestClock:
"""
@@ -208,7 +174,7 @@ def create(
async def create_async(
self,
- params: "TestClockService.CreateParams",
+ params: "TestClockCreateParams",
options: Optional[RequestOptions] = None,
) -> TestClock:
"""
@@ -228,7 +194,7 @@ async def create_async(
def advance(
self,
test_clock: str,
- params: "TestClockService.AdvanceParams",
+ params: "TestClockAdvanceParams",
options: Optional[RequestOptions] = None,
) -> TestClock:
"""
@@ -250,7 +216,7 @@ def advance(
async def advance_async(
self,
test_clock: str,
- params: "TestClockService.AdvanceParams",
+ 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 49aa4ae7a..7d42926c7 100644
--- a/stripe/test_helpers/issuing/_authorization_service.py
+++ b/stripe/test_helpers/issuing/_authorization_service.py
@@ -4,1132 +4,37 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.issuing._authorization import Authorization
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.test_helpers.issuing._authorization_capture_params import (
+ AuthorizationCaptureParams,
+ )
+ from stripe.params.test_helpers.issuing._authorization_create_params import (
+ AuthorizationCreateParams,
+ )
+ from stripe.params.test_helpers.issuing._authorization_expire_params import (
+ AuthorizationExpireParams,
+ )
+ from stripe.params.test_helpers.issuing._authorization_finalize_amount_params import (
+ AuthorizationFinalizeAmountParams,
+ )
+ from stripe.params.test_helpers.issuing._authorization_increment_params import (
+ AuthorizationIncrementParams,
+ )
+ from stripe.params.test_helpers.issuing._authorization_respond_params import (
+ AuthorizationRespondParams,
+ )
+ from stripe.params.test_helpers.issuing._authorization_reverse_params import (
+ AuthorizationReverseParams,
+ )
class AuthorizationService(StripeService):
- class CaptureParams(TypedDict):
- capture_amount: NotRequired[int]
- """
- The amount to capture from the authorization. If not provided, the full amount of the authorization will be captured. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- close_authorization: NotRequired[bool]
- """
- Whether to close the authorization after capture. Defaults to true. Set to false to enable multi-capture flows.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- purchase_details: NotRequired[
- "AuthorizationService.CaptureParamsPurchaseDetails"
- ]
- """
- Additional purchase information that is optionally provided by the merchant.
- """
-
- class CaptureParamsPurchaseDetails(TypedDict):
- fleet: NotRequired[
- "AuthorizationService.CaptureParamsPurchaseDetailsFleet"
- ]
- """
- Fleet-specific information for transactions using Fleet cards.
- """
- flight: NotRequired[
- "AuthorizationService.CaptureParamsPurchaseDetailsFlight"
- ]
- """
- Information about the flight that was purchased with this transaction.
- """
- fuel: NotRequired[
- "AuthorizationService.CaptureParamsPurchaseDetailsFuel"
- ]
- """
- Information about fuel that was purchased with this transaction.
- """
- lodging: NotRequired[
- "AuthorizationService.CaptureParamsPurchaseDetailsLodging"
- ]
- """
- Information about lodging that was purchased with this transaction.
- """
- receipt: NotRequired[
- List["AuthorizationService.CaptureParamsPurchaseDetailsReceipt"]
- ]
- """
- The line items in the purchase.
- """
- reference: NotRequired[str]
- """
- A merchant-specific order number.
- """
-
- class CaptureParamsPurchaseDetailsFleet(TypedDict):
- cardholder_prompt_data: NotRequired[
- "AuthorizationService.CaptureParamsPurchaseDetailsFleetCardholderPromptData"
- ]
- """
- Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
- """
- purchase_type: NotRequired[
- Literal[
- "fuel_and_non_fuel_purchase",
- "fuel_purchase",
- "non_fuel_purchase",
- ]
- ]
- """
- The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
- """
- reported_breakdown: NotRequired[
- "AuthorizationService.CaptureParamsPurchaseDetailsFleetReportedBreakdown"
- ]
- """
- More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
- """
- service_type: NotRequired[
- Literal["full_service", "non_fuel_transaction", "self_service"]
- ]
- """
- The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
- """
-
- class CaptureParamsPurchaseDetailsFleetCardholderPromptData(TypedDict):
- driver_id: NotRequired[str]
- """
- Driver ID.
- """
- odometer: NotRequired[int]
- """
- Odometer reading.
- """
- unspecified_id: NotRequired[str]
- """
- An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
- """
- user_id: NotRequired[str]
- """
- User ID.
- """
- vehicle_number: NotRequired[str]
- """
- Vehicle number.
- """
-
- class CaptureParamsPurchaseDetailsFleetReportedBreakdown(TypedDict):
- fuel: NotRequired[
- "AuthorizationService.CaptureParamsPurchaseDetailsFleetReportedBreakdownFuel"
- ]
- """
- Breakdown of fuel portion of the purchase.
- """
- non_fuel: NotRequired[
- "AuthorizationService.CaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel"
- ]
- """
- Breakdown of non-fuel portion of the purchase.
- """
- tax: NotRequired[
- "AuthorizationService.CaptureParamsPurchaseDetailsFleetReportedBreakdownTax"
- ]
- """
- Information about tax included in this transaction.
- """
-
- class CaptureParamsPurchaseDetailsFleetReportedBreakdownFuel(TypedDict):
- gross_amount_decimal: NotRequired[str]
- """
- Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
- """
-
- class CaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel(TypedDict):
- gross_amount_decimal: NotRequired[str]
- """
- Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
- """
-
- class CaptureParamsPurchaseDetailsFleetReportedBreakdownTax(TypedDict):
- local_amount_decimal: NotRequired[str]
- """
- Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
- national_amount_decimal: NotRequired[str]
- """
- Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
-
- class CaptureParamsPurchaseDetailsFlight(TypedDict):
- departure_at: NotRequired[int]
- """
- The time that the flight departed.
- """
- passenger_name: NotRequired[str]
- """
- The name of the passenger.
- """
- refundable: NotRequired[bool]
- """
- Whether the ticket is refundable.
- """
- segments: NotRequired[
- List[
- "AuthorizationService.CaptureParamsPurchaseDetailsFlightSegment"
- ]
- ]
- """
- The legs of the trip.
- """
- travel_agency: NotRequired[str]
- """
- The travel agency that issued the ticket.
- """
-
- class CaptureParamsPurchaseDetailsFlightSegment(TypedDict):
- arrival_airport_code: NotRequired[str]
- """
- The three-letter IATA airport code of the flight's destination.
- """
- carrier: NotRequired[str]
- """
- The airline carrier code.
- """
- departure_airport_code: NotRequired[str]
- """
- The three-letter IATA airport code that the flight departed from.
- """
- flight_number: NotRequired[str]
- """
- The flight number.
- """
- service_class: NotRequired[str]
- """
- The flight's service class.
- """
- stopover_allowed: NotRequired[bool]
- """
- Whether a stopover is allowed on this flight.
- """
-
- class CaptureParamsPurchaseDetailsFuel(TypedDict):
- industry_product_code: NotRequired[str]
- """
- [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
- """
- quantity_decimal: NotRequired[str]
- """
- The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
- """
- type: NotRequired[
- Literal[
- "diesel",
- "other",
- "unleaded_plus",
- "unleaded_regular",
- "unleaded_super",
- ]
- ]
- """
- The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
- """
- unit: NotRequired[
- Literal[
- "charging_minute",
- "imperial_gallon",
- "kilogram",
- "kilowatt_hour",
- "liter",
- "other",
- "pound",
- "us_gallon",
- ]
- ]
- """
- The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
- """
- unit_cost_decimal: NotRequired[str]
- """
- The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
- """
-
- class CaptureParamsPurchaseDetailsLodging(TypedDict):
- check_in_at: NotRequired[int]
- """
- The time of checking into the lodging.
- """
- nights: NotRequired[int]
- """
- The number of nights stayed at the lodging.
- """
-
- class CaptureParamsPurchaseDetailsReceipt(TypedDict):
- description: NotRequired[str]
- quantity: NotRequired[str]
- total: NotRequired[int]
- unit_cost: NotRequired[int]
-
- class CreateParams(TypedDict):
- amount: NotRequired[int]
- """
- The total amount to attempt to authorize. This amount is in the provided currency, or defaults to the card's currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- amount_details: NotRequired[
- "AuthorizationService.CreateParamsAmountDetails"
- ]
- """
- Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- authorization_method: NotRequired[
- Literal["chip", "contactless", "keyed_in", "online", "swipe"]
- ]
- """
- How the card details were provided. Defaults to online.
- """
- card: str
- """
- Card associated with this authorization.
- """
- currency: NotRequired[str]
- """
- The currency of the authorization. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- fleet: NotRequired["AuthorizationService.CreateParamsFleet"]
- """
- Fleet-specific information for authorizations using Fleet cards.
- """
- fraud_disputability_likelihood: NotRequired[
- Literal["neutral", "unknown", "very_likely", "very_unlikely"]
- ]
- """
- Probability that this transaction can be disputed in the event of fraud. Assessed by comparing the characteristics of the authorization to card network rules.
- """
- fuel: NotRequired["AuthorizationService.CreateParamsFuel"]
- """
- Information about fuel that was purchased with this transaction.
- """
- is_amount_controllable: NotRequired[bool]
- """
- If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.
- """
- merchant_amount: NotRequired[int]
- """
- The total amount to attempt to authorize. This amount is in the provided merchant currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- merchant_currency: NotRequired[str]
- """
- The currency of the authorization. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- merchant_data: NotRequired[
- "AuthorizationService.CreateParamsMerchantData"
- ]
- """
- Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
- """
- network_data: NotRequired[
- "AuthorizationService.CreateParamsNetworkData"
- ]
- """
- Details about the authorization, such as identifiers, set by the card network.
- """
- risk_assessment: NotRequired[
- "AuthorizationService.CreateParamsRiskAssessment"
- ]
- """
- Stripe's assessment of the fraud risk for this authorization.
- """
- verification_data: NotRequired[
- "AuthorizationService.CreateParamsVerificationData"
- ]
- """
- Verifications that Stripe performed on information that the cardholder provided to the merchant.
- """
- wallet: NotRequired[Literal["apple_pay", "google_pay", "samsung_pay"]]
- """
- The digital wallet used for this transaction. One of `apple_pay`, `google_pay`, or `samsung_pay`. Will populate as `null` when no digital wallet was utilized.
- """
-
- class CreateParamsAmountDetails(TypedDict):
- atm_fee: NotRequired[int]
- """
- The ATM withdrawal fee.
- """
- cashback_amount: NotRequired[int]
- """
- The amount of cash requested by the cardholder.
- """
-
- class CreateParamsFleet(TypedDict):
- cardholder_prompt_data: NotRequired[
- "AuthorizationService.CreateParamsFleetCardholderPromptData"
- ]
- """
- Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
- """
- purchase_type: NotRequired[
- Literal[
- "fuel_and_non_fuel_purchase",
- "fuel_purchase",
- "non_fuel_purchase",
- ]
- ]
- """
- The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
- """
- reported_breakdown: NotRequired[
- "AuthorizationService.CreateParamsFleetReportedBreakdown"
- ]
- """
- More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
- """
- service_type: NotRequired[
- Literal["full_service", "non_fuel_transaction", "self_service"]
- ]
- """
- The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
- """
-
- class CreateParamsFleetCardholderPromptData(TypedDict):
- driver_id: NotRequired[str]
- """
- Driver ID.
- """
- odometer: NotRequired[int]
- """
- Odometer reading.
- """
- unspecified_id: NotRequired[str]
- """
- An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
- """
- user_id: NotRequired[str]
- """
- User ID.
- """
- vehicle_number: NotRequired[str]
- """
- Vehicle number.
- """
-
- class CreateParamsFleetReportedBreakdown(TypedDict):
- fuel: NotRequired[
- "AuthorizationService.CreateParamsFleetReportedBreakdownFuel"
- ]
- """
- Breakdown of fuel portion of the purchase.
- """
- non_fuel: NotRequired[
- "AuthorizationService.CreateParamsFleetReportedBreakdownNonFuel"
- ]
- """
- Breakdown of non-fuel portion of the purchase.
- """
- tax: NotRequired[
- "AuthorizationService.CreateParamsFleetReportedBreakdownTax"
- ]
- """
- Information about tax included in this transaction.
- """
-
- class CreateParamsFleetReportedBreakdownFuel(TypedDict):
- gross_amount_decimal: NotRequired[str]
- """
- Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
- """
-
- class CreateParamsFleetReportedBreakdownNonFuel(TypedDict):
- gross_amount_decimal: NotRequired[str]
- """
- Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
- """
-
- class CreateParamsFleetReportedBreakdownTax(TypedDict):
- local_amount_decimal: NotRequired[str]
- """
- Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
- national_amount_decimal: NotRequired[str]
- """
- Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
-
- class CreateParamsFuel(TypedDict):
- industry_product_code: NotRequired[str]
- """
- [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
- """
- quantity_decimal: NotRequired[str]
- """
- The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
- """
- type: NotRequired[
- Literal[
- "diesel",
- "other",
- "unleaded_plus",
- "unleaded_regular",
- "unleaded_super",
- ]
- ]
- """
- The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
- """
- unit: NotRequired[
- Literal[
- "charging_minute",
- "imperial_gallon",
- "kilogram",
- "kilowatt_hour",
- "liter",
- "other",
- "pound",
- "us_gallon",
- ]
- ]
- """
- The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
- """
- unit_cost_decimal: NotRequired[str]
- """
- The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
- """
-
- class CreateParamsMerchantData(TypedDict):
- category: NotRequired[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- """
- A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
- """
- city: NotRequired[str]
- """
- City where the seller is located
- """
- country: NotRequired[str]
- """
- Country where the seller is located
- """
- name: NotRequired[str]
- """
- Name of the seller
- """
- network_id: NotRequired[str]
- """
- Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
- """
- postal_code: NotRequired[str]
- """
- Postal code where the seller is located
- """
- state: NotRequired[str]
- """
- State where the seller is located
- """
- terminal_id: NotRequired[str]
- """
- An ID assigned by the seller to the location of the sale.
- """
- url: NotRequired[str]
- """
- URL provided by the merchant on a 3DS request
- """
-
- class CreateParamsNetworkData(TypedDict):
- acquiring_institution_id: NotRequired[str]
- """
- Identifier assigned to the acquirer by the card network.
- """
-
- class CreateParamsRiskAssessment(TypedDict):
- card_testing_risk: NotRequired[
- "AuthorizationService.CreateParamsRiskAssessmentCardTestingRisk"
- ]
- """
- Stripe's assessment of this authorization's likelihood of being card testing activity.
- """
- merchant_dispute_risk: NotRequired[
- "AuthorizationService.CreateParamsRiskAssessmentMerchantDisputeRisk"
- ]
- """
- The dispute risk of the merchant (the seller on a purchase) on an authorization based on all Stripe Issuing activity.
- """
-
- class CreateParamsRiskAssessmentCardTestingRisk(TypedDict):
- invalid_account_number_decline_rate_past_hour: NotRequired[int]
- """
- The % of declines due to a card number not existing in the past hour, taking place at the same merchant. Higher rates correspond to a greater probability of card testing activity, meaning bad actors may be attempting different card number combinations to guess a correct one. Takes on values between 0 and 100.
- """
- invalid_credentials_decline_rate_past_hour: NotRequired[int]
- """
- The % of declines due to incorrect verification data (like CVV or expiry) in the past hour, taking place at the same merchant. Higher rates correspond to a greater probability of bad actors attempting to utilize valid card credentials at merchants with verification requirements. Takes on values between 0 and 100.
- """
- risk_level: Literal[
- "elevated", "highest", "low", "normal", "not_assessed", "unknown"
- ]
- """
- The likelihood that this authorization is associated with card testing activity. This is assessed by evaluating decline activity over the last hour.
- """
-
- class CreateParamsRiskAssessmentMerchantDisputeRisk(TypedDict):
- dispute_rate: NotRequired[int]
- """
- The dispute rate observed across all Stripe Issuing authorizations for this merchant. For example, a value of 50 means 50% of authorizations from this merchant on Stripe Issuing have resulted in a dispute. Higher values mean a higher likelihood the authorization is disputed. Takes on values between 0 and 100.
- """
- risk_level: Literal[
- "elevated", "highest", "low", "normal", "not_assessed", "unknown"
- ]
- """
- The likelihood that authorizations from this merchant will result in a dispute based on their history on Stripe Issuing.
- """
-
- class CreateParamsVerificationData(TypedDict):
- address_line1_check: NotRequired[
- Literal["match", "mismatch", "not_provided"]
- ]
- """
- Whether the cardholder provided an address first line and if it matched the cardholder's `billing.address.line1`.
- """
- address_postal_code_check: NotRequired[
- Literal["match", "mismatch", "not_provided"]
- ]
- """
- Whether the cardholder provided a postal code and if it matched the cardholder's `billing.address.postal_code`.
- """
- authentication_exemption: NotRequired[
- "AuthorizationService.CreateParamsVerificationDataAuthenticationExemption"
- ]
- """
- The exemption applied to this authorization.
- """
- cvc_check: NotRequired[Literal["match", "mismatch", "not_provided"]]
- """
- Whether the cardholder provided a CVC and if it matched Stripe's record.
- """
- expiry_check: NotRequired[Literal["match", "mismatch", "not_provided"]]
- """
- Whether the cardholder provided an expiry date and if it matched Stripe's record.
- """
- three_d_secure: NotRequired[
- "AuthorizationService.CreateParamsVerificationDataThreeDSecure"
- ]
- """
- 3D Secure details.
- """
-
- class CreateParamsVerificationDataAuthenticationExemption(TypedDict):
- claimed_by: Literal["acquirer", "issuer"]
- """
- The entity that requested the exemption, either the acquiring merchant or the Issuing user.
- """
- type: Literal[
- "low_value_transaction", "transaction_risk_analysis", "unknown"
- ]
- """
- The specific exemption claimed for this authorization.
- """
-
- class CreateParamsVerificationDataThreeDSecure(TypedDict):
- result: Literal[
- "attempt_acknowledged", "authenticated", "failed", "required"
- ]
- """
- The outcome of the 3D Secure authentication request.
- """
-
- class ExpireParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class FinalizeAmountParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- final_amount: int
- """
- The final authorization amount that will be captured by the merchant. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- fleet: NotRequired["AuthorizationService.FinalizeAmountParamsFleet"]
- """
- Fleet-specific information for authorizations using Fleet cards.
- """
- fuel: NotRequired["AuthorizationService.FinalizeAmountParamsFuel"]
- """
- Information about fuel that was purchased with this transaction.
- """
-
- class FinalizeAmountParamsFleet(TypedDict):
- cardholder_prompt_data: NotRequired[
- "AuthorizationService.FinalizeAmountParamsFleetCardholderPromptData"
- ]
- """
- Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
- """
- purchase_type: NotRequired[
- Literal[
- "fuel_and_non_fuel_purchase",
- "fuel_purchase",
- "non_fuel_purchase",
- ]
- ]
- """
- The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
- """
- reported_breakdown: NotRequired[
- "AuthorizationService.FinalizeAmountParamsFleetReportedBreakdown"
- ]
- """
- More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
- """
- service_type: NotRequired[
- Literal["full_service", "non_fuel_transaction", "self_service"]
- ]
- """
- The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
- """
-
- class FinalizeAmountParamsFleetCardholderPromptData(TypedDict):
- driver_id: NotRequired[str]
- """
- Driver ID.
- """
- odometer: NotRequired[int]
- """
- Odometer reading.
- """
- unspecified_id: NotRequired[str]
- """
- An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
- """
- user_id: NotRequired[str]
- """
- User ID.
- """
- vehicle_number: NotRequired[str]
- """
- Vehicle number.
- """
-
- class FinalizeAmountParamsFleetReportedBreakdown(TypedDict):
- fuel: NotRequired[
- "AuthorizationService.FinalizeAmountParamsFleetReportedBreakdownFuel"
- ]
- """
- Breakdown of fuel portion of the purchase.
- """
- non_fuel: NotRequired[
- "AuthorizationService.FinalizeAmountParamsFleetReportedBreakdownNonFuel"
- ]
- """
- Breakdown of non-fuel portion of the purchase.
- """
- tax: NotRequired[
- "AuthorizationService.FinalizeAmountParamsFleetReportedBreakdownTax"
- ]
- """
- Information about tax included in this transaction.
- """
-
- class FinalizeAmountParamsFleetReportedBreakdownFuel(TypedDict):
- gross_amount_decimal: NotRequired[str]
- """
- Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
- """
-
- class FinalizeAmountParamsFleetReportedBreakdownNonFuel(TypedDict):
- gross_amount_decimal: NotRequired[str]
- """
- Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
- """
-
- class FinalizeAmountParamsFleetReportedBreakdownTax(TypedDict):
- local_amount_decimal: NotRequired[str]
- """
- Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
- national_amount_decimal: NotRequired[str]
- """
- Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
-
- class FinalizeAmountParamsFuel(TypedDict):
- industry_product_code: NotRequired[str]
- """
- [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
- """
- quantity_decimal: NotRequired[str]
- """
- The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
- """
- type: NotRequired[
- Literal[
- "diesel",
- "other",
- "unleaded_plus",
- "unleaded_regular",
- "unleaded_super",
- ]
- ]
- """
- The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
- """
- unit: NotRequired[
- Literal[
- "charging_minute",
- "imperial_gallon",
- "kilogram",
- "kilowatt_hour",
- "liter",
- "other",
- "pound",
- "us_gallon",
- ]
- ]
- """
- The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
- """
- unit_cost_decimal: NotRequired[str]
- """
- The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
- """
-
- class IncrementParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- increment_amount: int
- """
- The amount to increment the authorization by. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- is_amount_controllable: NotRequired[bool]
- """
- If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.
- """
-
- class RespondParams(TypedDict):
- confirmed: bool
- """
- Whether to simulate the user confirming that the transaction was legitimate (true) or telling Stripe that it was fraudulent (false).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ReverseParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- reverse_amount: NotRequired[int]
- """
- The amount to reverse from the authorization. If not provided, the full amount of the authorization will be reversed. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
-
def create(
self,
- params: "AuthorizationService.CreateParams",
+ params: "AuthorizationCreateParams",
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -1148,7 +53,7 @@ def create(
async def create_async(
self,
- params: "AuthorizationService.CreateParams",
+ params: "AuthorizationCreateParams",
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -1168,7 +73,7 @@ async def create_async(
def capture(
self,
authorization: str,
- params: Optional["AuthorizationService.CaptureParams"] = None,
+ params: Optional["AuthorizationCaptureParams"] = None,
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -1190,7 +95,7 @@ def capture(
async def capture_async(
self,
authorization: str,
- params: Optional["AuthorizationService.CaptureParams"] = None,
+ params: Optional["AuthorizationCaptureParams"] = None,
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -1212,7 +117,7 @@ async def capture_async(
def expire(
self,
authorization: str,
- params: Optional["AuthorizationService.ExpireParams"] = None,
+ params: Optional["AuthorizationExpireParams"] = None,
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -1234,7 +139,7 @@ def expire(
async def expire_async(
self,
authorization: str,
- params: Optional["AuthorizationService.ExpireParams"] = None,
+ params: Optional["AuthorizationExpireParams"] = None,
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -1256,7 +161,7 @@ async def expire_async(
def finalize_amount(
self,
authorization: str,
- params: "AuthorizationService.FinalizeAmountParams",
+ params: "AuthorizationFinalizeAmountParams",
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -1278,7 +183,7 @@ def finalize_amount(
async def finalize_amount_async(
self,
authorization: str,
- params: "AuthorizationService.FinalizeAmountParams",
+ params: "AuthorizationFinalizeAmountParams",
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -1300,7 +205,7 @@ async def finalize_amount_async(
def respond(
self,
authorization: str,
- params: "AuthorizationService.RespondParams",
+ params: "AuthorizationRespondParams",
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -1322,7 +227,7 @@ def respond(
async def respond_async(
self,
authorization: str,
- params: "AuthorizationService.RespondParams",
+ params: "AuthorizationRespondParams",
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -1344,7 +249,7 @@ async def respond_async(
def increment(
self,
authorization: str,
- params: "AuthorizationService.IncrementParams",
+ params: "AuthorizationIncrementParams",
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -1366,7 +271,7 @@ def increment(
async def increment_async(
self,
authorization: str,
- params: "AuthorizationService.IncrementParams",
+ params: "AuthorizationIncrementParams",
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -1388,7 +293,7 @@ async def increment_async(
def reverse(
self,
authorization: str,
- params: Optional["AuthorizationService.ReverseParams"] = None,
+ params: Optional["AuthorizationReverseParams"] = None,
options: Optional[RequestOptions] = None,
) -> Authorization:
"""
@@ -1410,7 +315,7 @@ def reverse(
async def reverse_async(
self,
authorization: str,
- params: Optional["AuthorizationService.ReverseParams"] = None,
+ 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 d6b64c08b..d6f1ecf21 100644
--- a/stripe/test_helpers/issuing/_card_service.py
+++ b/stripe/test_helpers/issuing/_card_service.py
@@ -4,45 +4,32 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.issuing._card import Card
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.test_helpers.issuing._card_deliver_card_params import (
+ CardDeliverCardParams,
+ )
+ from stripe.params.test_helpers.issuing._card_fail_card_params import (
+ CardFailCardParams,
+ )
+ from stripe.params.test_helpers.issuing._card_return_card_params import (
+ CardReturnCardParams,
+ )
+ from stripe.params.test_helpers.issuing._card_ship_card_params import (
+ CardShipCardParams,
+ )
+ from stripe.params.test_helpers.issuing._card_submit_card_params import (
+ CardSubmitCardParams,
+ )
class CardService(StripeService):
- class DeliverCardParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class FailCardParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ReturnCardParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ShipCardParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SubmitCardParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
def deliver_card(
self,
card: str,
- params: Optional["CardService.DeliverCardParams"] = None,
+ params: Optional["CardDeliverCardParams"] = None,
options: Optional[RequestOptions] = None,
) -> Card:
"""
@@ -64,7 +51,7 @@ def deliver_card(
async def deliver_card_async(
self,
card: str,
- params: Optional["CardService.DeliverCardParams"] = None,
+ params: Optional["CardDeliverCardParams"] = None,
options: Optional[RequestOptions] = None,
) -> Card:
"""
@@ -86,7 +73,7 @@ async def deliver_card_async(
def fail_card(
self,
card: str,
- params: Optional["CardService.FailCardParams"] = None,
+ params: Optional["CardFailCardParams"] = None,
options: Optional[RequestOptions] = None,
) -> Card:
"""
@@ -108,7 +95,7 @@ def fail_card(
async def fail_card_async(
self,
card: str,
- params: Optional["CardService.FailCardParams"] = None,
+ params: Optional["CardFailCardParams"] = None,
options: Optional[RequestOptions] = None,
) -> Card:
"""
@@ -130,7 +117,7 @@ async def fail_card_async(
def return_card(
self,
card: str,
- params: Optional["CardService.ReturnCardParams"] = None,
+ params: Optional["CardReturnCardParams"] = None,
options: Optional[RequestOptions] = None,
) -> Card:
"""
@@ -152,7 +139,7 @@ def return_card(
async def return_card_async(
self,
card: str,
- params: Optional["CardService.ReturnCardParams"] = None,
+ params: Optional["CardReturnCardParams"] = None,
options: Optional[RequestOptions] = None,
) -> Card:
"""
@@ -174,7 +161,7 @@ async def return_card_async(
def ship_card(
self,
card: str,
- params: Optional["CardService.ShipCardParams"] = None,
+ params: Optional["CardShipCardParams"] = None,
options: Optional[RequestOptions] = None,
) -> Card:
"""
@@ -196,7 +183,7 @@ def ship_card(
async def ship_card_async(
self,
card: str,
- params: Optional["CardService.ShipCardParams"] = None,
+ params: Optional["CardShipCardParams"] = None,
options: Optional[RequestOptions] = None,
) -> Card:
"""
@@ -218,7 +205,7 @@ async def ship_card_async(
def submit_card(
self,
card: str,
- params: Optional["CardService.SubmitCardParams"] = None,
+ params: Optional["CardSubmitCardParams"] = None,
options: Optional[RequestOptions] = None,
) -> Card:
"""
@@ -240,7 +227,7 @@ def submit_card(
async def submit_card_async(
self,
card: str,
- params: Optional["CardService.SubmitCardParams"] = None,
+ 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 c902f1771..a448dd457 100644
--- a/stripe/test_helpers/issuing/_personalization_design_service.py
+++ b/stripe/test_helpers/issuing/_personalization_design_service.py
@@ -4,74 +4,26 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.issuing._personalization_design import PersonalizationDesign
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.test_helpers.issuing._personalization_design_activate_params import (
+ PersonalizationDesignActivateParams,
+ )
+ from stripe.params.test_helpers.issuing._personalization_design_deactivate_params import (
+ PersonalizationDesignDeactivateParams,
+ )
+ from stripe.params.test_helpers.issuing._personalization_design_reject_params import (
+ PersonalizationDesignRejectParams,
+ )
-class PersonalizationDesignService(StripeService):
- class ActivateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class DeactivateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RejectParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- rejection_reasons: (
- "PersonalizationDesignService.RejectParamsRejectionReasons"
- )
- """
- The reason(s) the personalization design was rejected.
- """
-
- class RejectParamsRejectionReasons(TypedDict):
- card_logo: NotRequired[
- List[
- Literal[
- "geographic_location",
- "inappropriate",
- "network_name",
- "non_binary_image",
- "non_fiat_currency",
- "other",
- "other_entity",
- "promotional_material",
- ]
- ]
- ]
- """
- The reason(s) the card logo was rejected.
- """
- carrier_text: NotRequired[
- List[
- Literal[
- "geographic_location",
- "inappropriate",
- "network_name",
- "non_fiat_currency",
- "other",
- "other_entity",
- "promotional_material",
- ]
- ]
- ]
- """
- The reason(s) the carrier text was rejected.
- """
+class PersonalizationDesignService(StripeService):
def activate(
self,
personalization_design: str,
- params: Optional["PersonalizationDesignService.ActivateParams"] = None,
+ params: Optional["PersonalizationDesignActivateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PersonalizationDesign:
"""
@@ -93,7 +45,7 @@ def activate(
async def activate_async(
self,
personalization_design: str,
- params: Optional["PersonalizationDesignService.ActivateParams"] = None,
+ params: Optional["PersonalizationDesignActivateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PersonalizationDesign:
"""
@@ -115,9 +67,7 @@ async def activate_async(
def deactivate(
self,
personalization_design: str,
- params: Optional[
- "PersonalizationDesignService.DeactivateParams"
- ] = None,
+ params: Optional["PersonalizationDesignDeactivateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PersonalizationDesign:
"""
@@ -139,9 +89,7 @@ def deactivate(
async def deactivate_async(
self,
personalization_design: str,
- params: Optional[
- "PersonalizationDesignService.DeactivateParams"
- ] = None,
+ params: Optional["PersonalizationDesignDeactivateParams"] = None,
options: Optional[RequestOptions] = None,
) -> PersonalizationDesign:
"""
@@ -163,7 +111,7 @@ async def deactivate_async(
def reject(
self,
personalization_design: str,
- params: "PersonalizationDesignService.RejectParams",
+ params: "PersonalizationDesignRejectParams",
options: Optional[RequestOptions] = None,
) -> PersonalizationDesign:
"""
@@ -185,7 +133,7 @@ def reject(
async def reject_async(
self,
personalization_design: str,
- params: "PersonalizationDesignService.RejectParams",
+ 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 4a65f6522..52217cba2 100644
--- a/stripe/test_helpers/issuing/_transaction_service.py
+++ b/stripe/test_helpers/issuing/_transaction_service.py
@@ -4,1257 +4,26 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.issuing._transaction import Transaction
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.test_helpers.issuing._transaction_create_force_capture_params import (
+ TransactionCreateForceCaptureParams,
+ )
+ from stripe.params.test_helpers.issuing._transaction_create_unlinked_refund_params import (
+ TransactionCreateUnlinkedRefundParams,
+ )
+ from stripe.params.test_helpers.issuing._transaction_refund_params import (
+ TransactionRefundParams,
+ )
-class TransactionService(StripeService):
- class CreateForceCaptureParams(TypedDict):
- amount: int
- """
- The total amount to attempt to capture. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- card: str
- """
- Card associated with this transaction.
- """
- currency: NotRequired[str]
- """
- The currency of the capture. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- merchant_data: NotRequired[
- "TransactionService.CreateForceCaptureParamsMerchantData"
- ]
- """
- Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
- """
- purchase_details: NotRequired[
- "TransactionService.CreateForceCaptureParamsPurchaseDetails"
- ]
- """
- Additional purchase information that is optionally provided by the merchant.
- """
-
- class CreateForceCaptureParamsMerchantData(TypedDict):
- category: NotRequired[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- """
- A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
- """
- city: NotRequired[str]
- """
- City where the seller is located
- """
- country: NotRequired[str]
- """
- Country where the seller is located
- """
- name: NotRequired[str]
- """
- Name of the seller
- """
- network_id: NotRequired[str]
- """
- Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
- """
- postal_code: NotRequired[str]
- """
- Postal code where the seller is located
- """
- state: NotRequired[str]
- """
- State where the seller is located
- """
- terminal_id: NotRequired[str]
- """
- An ID assigned by the seller to the location of the sale.
- """
- url: NotRequired[str]
- """
- URL provided by the merchant on a 3DS request
- """
-
- class CreateForceCaptureParamsPurchaseDetails(TypedDict):
- fleet: NotRequired[
- "TransactionService.CreateForceCaptureParamsPurchaseDetailsFleet"
- ]
- """
- Fleet-specific information for transactions using Fleet cards.
- """
- flight: NotRequired[
- "TransactionService.CreateForceCaptureParamsPurchaseDetailsFlight"
- ]
- """
- Information about the flight that was purchased with this transaction.
- """
- fuel: NotRequired[
- "TransactionService.CreateForceCaptureParamsPurchaseDetailsFuel"
- ]
- """
- Information about fuel that was purchased with this transaction.
- """
- lodging: NotRequired[
- "TransactionService.CreateForceCaptureParamsPurchaseDetailsLodging"
- ]
- """
- Information about lodging that was purchased with this transaction.
- """
- receipt: NotRequired[
- List[
- "TransactionService.CreateForceCaptureParamsPurchaseDetailsReceipt"
- ]
- ]
- """
- The line items in the purchase.
- """
- reference: NotRequired[str]
- """
- A merchant-specific order number.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFleet(TypedDict):
- cardholder_prompt_data: NotRequired[
- "TransactionService.CreateForceCaptureParamsPurchaseDetailsFleetCardholderPromptData"
- ]
- """
- Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
- """
- purchase_type: NotRequired[
- Literal[
- "fuel_and_non_fuel_purchase",
- "fuel_purchase",
- "non_fuel_purchase",
- ]
- ]
- """
- The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
- """
- reported_breakdown: NotRequired[
- "TransactionService.CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdown"
- ]
- """
- More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
- """
- service_type: NotRequired[
- Literal["full_service", "non_fuel_transaction", "self_service"]
- ]
- """
- The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFleetCardholderPromptData(
- TypedDict,
- ):
- driver_id: NotRequired[str]
- """
- Driver ID.
- """
- odometer: NotRequired[int]
- """
- Odometer reading.
- """
- unspecified_id: NotRequired[str]
- """
- An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
- """
- user_id: NotRequired[str]
- """
- User ID.
- """
- vehicle_number: NotRequired[str]
- """
- Vehicle number.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdown(
- TypedDict,
- ):
- fuel: NotRequired[
- "TransactionService.CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownFuel"
- ]
- """
- Breakdown of fuel portion of the purchase.
- """
- non_fuel: NotRequired[
- "TransactionService.CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel"
- ]
- """
- Breakdown of non-fuel portion of the purchase.
- """
- tax: NotRequired[
- "TransactionService.CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownTax"
- ]
- """
- Information about tax included in this transaction.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownFuel(
- TypedDict,
- ):
- gross_amount_decimal: NotRequired[str]
- """
- Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownNonFuel(
- TypedDict,
- ):
- gross_amount_decimal: NotRequired[str]
- """
- Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFleetReportedBreakdownTax(
- TypedDict,
- ):
- local_amount_decimal: NotRequired[str]
- """
- Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
- national_amount_decimal: NotRequired[str]
- """
- Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFlight(TypedDict):
- departure_at: NotRequired[int]
- """
- The time that the flight departed.
- """
- passenger_name: NotRequired[str]
- """
- The name of the passenger.
- """
- refundable: NotRequired[bool]
- """
- Whether the ticket is refundable.
- """
- segments: NotRequired[
- List[
- "TransactionService.CreateForceCaptureParamsPurchaseDetailsFlightSegment"
- ]
- ]
- """
- The legs of the trip.
- """
- travel_agency: NotRequired[str]
- """
- The travel agency that issued the ticket.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFlightSegment(TypedDict):
- arrival_airport_code: NotRequired[str]
- """
- The three-letter IATA airport code of the flight's destination.
- """
- carrier: NotRequired[str]
- """
- The airline carrier code.
- """
- departure_airport_code: NotRequired[str]
- """
- The three-letter IATA airport code that the flight departed from.
- """
- flight_number: NotRequired[str]
- """
- The flight number.
- """
- service_class: NotRequired[str]
- """
- The flight's service class.
- """
- stopover_allowed: NotRequired[bool]
- """
- Whether a stopover is allowed on this flight.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsFuel(TypedDict):
- industry_product_code: NotRequired[str]
- """
- [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
- """
- quantity_decimal: NotRequired[str]
- """
- The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
- """
- type: NotRequired[
- Literal[
- "diesel",
- "other",
- "unleaded_plus",
- "unleaded_regular",
- "unleaded_super",
- ]
- ]
- """
- The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
- """
- unit: NotRequired[
- Literal[
- "charging_minute",
- "imperial_gallon",
- "kilogram",
- "kilowatt_hour",
- "liter",
- "other",
- "pound",
- "us_gallon",
- ]
- ]
- """
- The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
- """
- unit_cost_decimal: NotRequired[str]
- """
- The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsLodging(TypedDict):
- check_in_at: NotRequired[int]
- """
- The time of checking into the lodging.
- """
- nights: NotRequired[int]
- """
- The number of nights stayed at the lodging.
- """
-
- class CreateForceCaptureParamsPurchaseDetailsReceipt(TypedDict):
- description: NotRequired[str]
- quantity: NotRequired[str]
- total: NotRequired[int]
- unit_cost: NotRequired[int]
-
- class CreateUnlinkedRefundParams(TypedDict):
- amount: int
- """
- The total amount to attempt to refund. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
- card: str
- """
- Card associated with this unlinked refund transaction.
- """
- currency: NotRequired[str]
- """
- The currency of the unlinked refund. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- merchant_data: NotRequired[
- "TransactionService.CreateUnlinkedRefundParamsMerchantData"
- ]
- """
- Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
- """
- purchase_details: NotRequired[
- "TransactionService.CreateUnlinkedRefundParamsPurchaseDetails"
- ]
- """
- Additional purchase information that is optionally provided by the merchant.
- """
-
- class CreateUnlinkedRefundParamsMerchantData(TypedDict):
- category: NotRequired[
- Literal[
- "ac_refrigeration_repair",
- "accounting_bookkeeping_services",
- "advertising_services",
- "agricultural_cooperative",
- "airlines_air_carriers",
- "airports_flying_fields",
- "ambulance_services",
- "amusement_parks_carnivals",
- "antique_reproductions",
- "antique_shops",
- "aquariums",
- "architectural_surveying_services",
- "art_dealers_and_galleries",
- "artists_supply_and_craft_shops",
- "auto_and_home_supply_stores",
- "auto_body_repair_shops",
- "auto_paint_shops",
- "auto_service_shops",
- "automated_cash_disburse",
- "automated_fuel_dispensers",
- "automobile_associations",
- "automotive_parts_and_accessories_stores",
- "automotive_tire_stores",
- "bail_and_bond_payments",
- "bakeries",
- "bands_orchestras",
- "barber_and_beauty_shops",
- "betting_casino_gambling",
- "bicycle_shops",
- "billiard_pool_establishments",
- "boat_dealers",
- "boat_rentals_and_leases",
- "book_stores",
- "books_periodicals_and_newspapers",
- "bowling_alleys",
- "bus_lines",
- "business_secretarial_schools",
- "buying_shopping_services",
- "cable_satellite_and_other_pay_television_and_radio",
- "camera_and_photographic_supply_stores",
- "candy_nut_and_confectionery_stores",
- "car_and_truck_dealers_new_used",
- "car_and_truck_dealers_used_only",
- "car_rental_agencies",
- "car_washes",
- "carpentry_services",
- "carpet_upholstery_cleaning",
- "caterers",
- "charitable_and_social_service_organizations_fundraising",
- "chemicals_and_allied_products",
- "child_care_services",
- "childrens_and_infants_wear_stores",
- "chiropodists_podiatrists",
- "chiropractors",
- "cigar_stores_and_stands",
- "civic_social_fraternal_associations",
- "cleaning_and_maintenance",
- "clothing_rental",
- "colleges_universities",
- "commercial_equipment",
- "commercial_footwear",
- "commercial_photography_art_and_graphics",
- "commuter_transport_and_ferries",
- "computer_network_services",
- "computer_programming",
- "computer_repair",
- "computer_software_stores",
- "computers_peripherals_and_software",
- "concrete_work_services",
- "construction_materials",
- "consulting_public_relations",
- "correspondence_schools",
- "cosmetic_stores",
- "counseling_services",
- "country_clubs",
- "courier_services",
- "court_costs",
- "credit_reporting_agencies",
- "cruise_lines",
- "dairy_products_stores",
- "dance_hall_studios_schools",
- "dating_escort_services",
- "dentists_orthodontists",
- "department_stores",
- "detective_agencies",
- "digital_goods_applications",
- "digital_goods_games",
- "digital_goods_large_volume",
- "digital_goods_media",
- "direct_marketing_catalog_merchant",
- "direct_marketing_combination_catalog_and_retail_merchant",
- "direct_marketing_inbound_telemarketing",
- "direct_marketing_insurance_services",
- "direct_marketing_other",
- "direct_marketing_outbound_telemarketing",
- "direct_marketing_subscription",
- "direct_marketing_travel",
- "discount_stores",
- "doctors",
- "door_to_door_sales",
- "drapery_window_covering_and_upholstery_stores",
- "drinking_places",
- "drug_stores_and_pharmacies",
- "drugs_drug_proprietaries_and_druggist_sundries",
- "dry_cleaners",
- "durable_goods",
- "duty_free_stores",
- "eating_places_restaurants",
- "educational_services",
- "electric_razor_stores",
- "electric_vehicle_charging",
- "electrical_parts_and_equipment",
- "electrical_services",
- "electronics_repair_shops",
- "electronics_stores",
- "elementary_secondary_schools",
- "emergency_services_gcas_visa_use_only",
- "employment_temp_agencies",
- "equipment_rental",
- "exterminating_services",
- "family_clothing_stores",
- "fast_food_restaurants",
- "financial_institutions",
- "fines_government_administrative_entities",
- "fireplace_fireplace_screens_and_accessories_stores",
- "floor_covering_stores",
- "florists",
- "florists_supplies_nursery_stock_and_flowers",
- "freezer_and_locker_meat_provisioners",
- "fuel_dealers_non_automotive",
- "funeral_services_crematories",
- "furniture_home_furnishings_and_equipment_stores_except_appliances",
- "furniture_repair_refinishing",
- "furriers_and_fur_shops",
- "general_services",
- "gift_card_novelty_and_souvenir_shops",
- "glass_paint_and_wallpaper_stores",
- "glassware_crystal_stores",
- "golf_courses_public",
- "government_licensed_horse_dog_racing_us_region_only",
- "government_licensed_online_casions_online_gambling_us_region_only",
- "government_owned_lotteries_non_us_region",
- "government_owned_lotteries_us_region_only",
- "government_services",
- "grocery_stores_supermarkets",
- "hardware_equipment_and_supplies",
- "hardware_stores",
- "health_and_beauty_spas",
- "hearing_aids_sales_and_supplies",
- "heating_plumbing_a_c",
- "hobby_toy_and_game_shops",
- "home_supply_warehouse_stores",
- "hospitals",
- "hotels_motels_and_resorts",
- "household_appliance_stores",
- "industrial_supplies",
- "information_retrieval_services",
- "insurance_default",
- "insurance_underwriting_premiums",
- "intra_company_purchases",
- "jewelry_stores_watches_clocks_and_silverware_stores",
- "landscaping_services",
- "laundries",
- "laundry_cleaning_services",
- "legal_services_attorneys",
- "luggage_and_leather_goods_stores",
- "lumber_building_materials_stores",
- "manual_cash_disburse",
- "marinas_service_and_supplies",
- "marketplaces",
- "masonry_stonework_and_plaster",
- "massage_parlors",
- "medical_and_dental_labs",
- "medical_dental_ophthalmic_and_hospital_equipment_and_supplies",
- "medical_services",
- "membership_organizations",
- "mens_and_boys_clothing_and_accessories_stores",
- "mens_womens_clothing_stores",
- "metal_service_centers",
- "miscellaneous_apparel_and_accessory_shops",
- "miscellaneous_auto_dealers",
- "miscellaneous_business_services",
- "miscellaneous_food_stores",
- "miscellaneous_general_merchandise",
- "miscellaneous_general_services",
- "miscellaneous_home_furnishing_specialty_stores",
- "miscellaneous_publishing_and_printing",
- "miscellaneous_recreation_services",
- "miscellaneous_repair_shops",
- "miscellaneous_specialty_retail",
- "mobile_home_dealers",
- "motion_picture_theaters",
- "motor_freight_carriers_and_trucking",
- "motor_homes_dealers",
- "motor_vehicle_supplies_and_new_parts",
- "motorcycle_shops_and_dealers",
- "motorcycle_shops_dealers",
- "music_stores_musical_instruments_pianos_and_sheet_music",
- "news_dealers_and_newsstands",
- "non_fi_money_orders",
- "non_fi_stored_value_card_purchase_load",
- "nondurable_goods",
- "nurseries_lawn_and_garden_supply_stores",
- "nursing_personal_care",
- "office_and_commercial_furniture",
- "opticians_eyeglasses",
- "optometrists_ophthalmologist",
- "orthopedic_goods_prosthetic_devices",
- "osteopaths",
- "package_stores_beer_wine_and_liquor",
- "paints_varnishes_and_supplies",
- "parking_lots_garages",
- "passenger_railways",
- "pawn_shops",
- "pet_shops_pet_food_and_supplies",
- "petroleum_and_petroleum_products",
- "photo_developing",
- "photographic_photocopy_microfilm_equipment_and_supplies",
- "photographic_studios",
- "picture_video_production",
- "piece_goods_notions_and_other_dry_goods",
- "plumbing_heating_equipment_and_supplies",
- "political_organizations",
- "postal_services_government_only",
- "precious_stones_and_metals_watches_and_jewelry",
- "professional_services",
- "public_warehousing_and_storage",
- "quick_copy_repro_and_blueprint",
- "railroads",
- "real_estate_agents_and_managers_rentals",
- "record_stores",
- "recreational_vehicle_rentals",
- "religious_goods_stores",
- "religious_organizations",
- "roofing_siding_sheet_metal",
- "secretarial_support_services",
- "security_brokers_dealers",
- "service_stations",
- "sewing_needlework_fabric_and_piece_goods_stores",
- "shoe_repair_hat_cleaning",
- "shoe_stores",
- "small_appliance_repair",
- "snowmobile_dealers",
- "special_trade_services",
- "specialty_cleaning",
- "sporting_goods_stores",
- "sporting_recreation_camps",
- "sports_and_riding_apparel_stores",
- "sports_clubs_fields",
- "stamp_and_coin_stores",
- "stationary_office_supplies_printing_and_writing_paper",
- "stationery_stores_office_and_school_supply_stores",
- "swimming_pools_sales",
- "t_ui_travel_germany",
- "tailors_alterations",
- "tax_payments_government_agencies",
- "tax_preparation_services",
- "taxicabs_limousines",
- "telecommunication_equipment_and_telephone_sales",
- "telecommunication_services",
- "telegraph_services",
- "tent_and_awning_shops",
- "testing_laboratories",
- "theatrical_ticket_agencies",
- "timeshares",
- "tire_retreading_and_repair",
- "tolls_bridge_fees",
- "tourist_attractions_and_exhibits",
- "towing_services",
- "trailer_parks_campgrounds",
- "transportation_services",
- "travel_agencies_tour_operators",
- "truck_stop_iteration",
- "truck_utility_trailer_rentals",
- "typesetting_plate_making_and_related_services",
- "typewriter_stores",
- "u_s_federal_government_agencies_or_departments",
- "uniforms_commercial_clothing",
- "used_merchandise_and_secondhand_stores",
- "utilities",
- "variety_stores",
- "veterinary_services",
- "video_amusement_game_supplies",
- "video_game_arcades",
- "video_tape_rental_stores",
- "vocational_trade_schools",
- "watch_jewelry_repair",
- "welding_repair",
- "wholesale_clubs",
- "wig_and_toupee_stores",
- "wires_money_orders",
- "womens_accessory_and_specialty_shops",
- "womens_ready_to_wear_stores",
- "wrecking_and_salvage_yards",
- ]
- ]
- """
- A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
- """
- city: NotRequired[str]
- """
- City where the seller is located
- """
- country: NotRequired[str]
- """
- Country where the seller is located
- """
- name: NotRequired[str]
- """
- Name of the seller
- """
- network_id: NotRequired[str]
- """
- Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
- """
- postal_code: NotRequired[str]
- """
- Postal code where the seller is located
- """
- state: NotRequired[str]
- """
- State where the seller is located
- """
- terminal_id: NotRequired[str]
- """
- An ID assigned by the seller to the location of the sale.
- """
- url: NotRequired[str]
- """
- URL provided by the merchant on a 3DS request
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetails(TypedDict):
- fleet: NotRequired[
- "TransactionService.CreateUnlinkedRefundParamsPurchaseDetailsFleet"
- ]
- """
- Fleet-specific information for transactions using Fleet cards.
- """
- flight: NotRequired[
- "TransactionService.CreateUnlinkedRefundParamsPurchaseDetailsFlight"
- ]
- """
- Information about the flight that was purchased with this transaction.
- """
- fuel: NotRequired[
- "TransactionService.CreateUnlinkedRefundParamsPurchaseDetailsFuel"
- ]
- """
- Information about fuel that was purchased with this transaction.
- """
- lodging: NotRequired[
- "TransactionService.CreateUnlinkedRefundParamsPurchaseDetailsLodging"
- ]
- """
- Information about lodging that was purchased with this transaction.
- """
- receipt: NotRequired[
- List[
- "TransactionService.CreateUnlinkedRefundParamsPurchaseDetailsReceipt"
- ]
- ]
- """
- The line items in the purchase.
- """
- reference: NotRequired[str]
- """
- A merchant-specific order number.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFleet(TypedDict):
- cardholder_prompt_data: NotRequired[
- "TransactionService.CreateUnlinkedRefundParamsPurchaseDetailsFleetCardholderPromptData"
- ]
- """
- Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
- """
- purchase_type: NotRequired[
- Literal[
- "fuel_and_non_fuel_purchase",
- "fuel_purchase",
- "non_fuel_purchase",
- ]
- ]
- """
- The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
- """
- reported_breakdown: NotRequired[
- "TransactionService.CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdown"
- ]
- """
- More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
- """
- service_type: NotRequired[
- Literal["full_service", "non_fuel_transaction", "self_service"]
- ]
- """
- The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFleetCardholderPromptData(
- TypedDict,
- ):
- driver_id: NotRequired[str]
- """
- Driver ID.
- """
- odometer: NotRequired[int]
- """
- Odometer reading.
- """
- unspecified_id: NotRequired[str]
- """
- An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
- """
- user_id: NotRequired[str]
- """
- User ID.
- """
- vehicle_number: NotRequired[str]
- """
- Vehicle number.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdown(
- TypedDict,
- ):
- fuel: NotRequired[
- "TransactionService.CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownFuel"
- ]
- """
- Breakdown of fuel portion of the purchase.
- """
- non_fuel: NotRequired[
- "TransactionService.CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownNonFuel"
- ]
- """
- Breakdown of non-fuel portion of the purchase.
- """
- tax: NotRequired[
- "TransactionService.CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownTax"
- ]
- """
- Information about tax included in this transaction.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownFuel(
- TypedDict,
- ):
- gross_amount_decimal: NotRequired[str]
- """
- Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownNonFuel(
- TypedDict,
- ):
- gross_amount_decimal: NotRequired[str]
- """
- Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFleetReportedBreakdownTax(
- TypedDict,
- ):
- local_amount_decimal: NotRequired[str]
- """
- Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
- national_amount_decimal: NotRequired[str]
- """
- Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFlight(TypedDict):
- departure_at: NotRequired[int]
- """
- The time that the flight departed.
- """
- passenger_name: NotRequired[str]
- """
- The name of the passenger.
- """
- refundable: NotRequired[bool]
- """
- Whether the ticket is refundable.
- """
- segments: NotRequired[
- List[
- "TransactionService.CreateUnlinkedRefundParamsPurchaseDetailsFlightSegment"
- ]
- ]
- """
- The legs of the trip.
- """
- travel_agency: NotRequired[str]
- """
- The travel agency that issued the ticket.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFlightSegment(TypedDict):
- arrival_airport_code: NotRequired[str]
- """
- The three-letter IATA airport code of the flight's destination.
- """
- carrier: NotRequired[str]
- """
- The airline carrier code.
- """
- departure_airport_code: NotRequired[str]
- """
- The three-letter IATA airport code that the flight departed from.
- """
- flight_number: NotRequired[str]
- """
- The flight number.
- """
- service_class: NotRequired[str]
- """
- The flight's service class.
- """
- stopover_allowed: NotRequired[bool]
- """
- Whether a stopover is allowed on this flight.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsFuel(TypedDict):
- industry_product_code: NotRequired[str]
- """
- [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
- """
- quantity_decimal: NotRequired[str]
- """
- The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
- """
- type: NotRequired[
- Literal[
- "diesel",
- "other",
- "unleaded_plus",
- "unleaded_regular",
- "unleaded_super",
- ]
- ]
- """
- The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
- """
- unit: NotRequired[
- Literal[
- "charging_minute",
- "imperial_gallon",
- "kilogram",
- "kilowatt_hour",
- "liter",
- "other",
- "pound",
- "us_gallon",
- ]
- ]
- """
- The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
- """
- unit_cost_decimal: NotRequired[str]
- """
- The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsLodging(TypedDict):
- check_in_at: NotRequired[int]
- """
- The time of checking into the lodging.
- """
- nights: NotRequired[int]
- """
- The number of nights stayed at the lodging.
- """
-
- class CreateUnlinkedRefundParamsPurchaseDetailsReceipt(TypedDict):
- description: NotRequired[str]
- quantity: NotRequired[str]
- total: NotRequired[int]
- unit_cost: NotRequired[int]
-
- class RefundParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- refund_amount: NotRequired[int]
- """
- The total amount to attempt to refund. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
- """
+class TransactionService(StripeService):
def refund(
self,
transaction: str,
- params: Optional["TransactionService.RefundParams"] = None,
+ params: Optional["TransactionRefundParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
@@ -1276,7 +45,7 @@ def refund(
async def refund_async(
self,
transaction: str,
- params: Optional["TransactionService.RefundParams"] = None,
+ params: Optional["TransactionRefundParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
@@ -1297,7 +66,7 @@ async def refund_async(
def create_force_capture(
self,
- params: "TransactionService.CreateForceCaptureParams",
+ params: "TransactionCreateForceCaptureParams",
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
@@ -1316,7 +85,7 @@ def create_force_capture(
async def create_force_capture_async(
self,
- params: "TransactionService.CreateForceCaptureParams",
+ params: "TransactionCreateForceCaptureParams",
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
@@ -1335,7 +104,7 @@ async def create_force_capture_async(
def create_unlinked_refund(
self,
- params: "TransactionService.CreateUnlinkedRefundParams",
+ params: "TransactionCreateUnlinkedRefundParams",
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
@@ -1354,7 +123,7 @@ def create_unlinked_refund(
async def create_unlinked_refund_async(
self,
- params: "TransactionService.CreateUnlinkedRefundParams",
+ params: "TransactionCreateUnlinkedRefundParams",
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
diff --git a/stripe/test_helpers/terminal/_reader_service.py b/stripe/test_helpers/terminal/_reader_service.py
index 03eace73a..ac9ed1734 100644
--- a/stripe/test_helpers/terminal/_reader_service.py
+++ b/stripe/test_helpers/terminal/_reader_service.py
@@ -4,91 +4,26 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.terminal._reader import Reader
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.test_helpers.terminal._reader_present_payment_method_params import (
+ ReaderPresentPaymentMethodParams,
+ )
+ from stripe.params.test_helpers.terminal._reader_succeed_input_collection_params import (
+ ReaderSucceedInputCollectionParams,
+ )
+ from stripe.params.test_helpers.terminal._reader_timeout_input_collection_params import (
+ ReaderTimeoutInputCollectionParams,
+ )
-class ReaderService(StripeService):
- class PresentPaymentMethodParams(TypedDict):
- amount_tip: NotRequired[int]
- """
- Simulated on-reader tip amount.
- """
- card: NotRequired["ReaderService.PresentPaymentMethodParamsCard"]
- """
- Simulated data for the card payment method.
- """
- card_present: NotRequired[
- "ReaderService.PresentPaymentMethodParamsCardPresent"
- ]
- """
- Simulated data for the card_present payment method.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- interac_present: NotRequired[
- "ReaderService.PresentPaymentMethodParamsInteracPresent"
- ]
- """
- Simulated data for the interac_present payment method.
- """
- type: NotRequired[Literal["card", "card_present", "interac_present"]]
- """
- Simulated payment type.
- """
-
- class PresentPaymentMethodParamsCard(TypedDict):
- cvc: NotRequired[str]
- """
- Card security code.
- """
- exp_month: int
- """
- Two-digit number representing the card's expiration month.
- """
- exp_year: int
- """
- Two- or four-digit number representing the card's expiration year.
- """
- number: str
- """
- The card number, as a string without any separators.
- """
-
- class PresentPaymentMethodParamsCardPresent(TypedDict):
- number: NotRequired[str]
- """
- The card number, as a string without any separators.
- """
-
- class PresentPaymentMethodParamsInteracPresent(TypedDict):
- number: NotRequired[str]
- """
- Card Number
- """
-
- class SucceedInputCollectionParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- skip_non_required_inputs: NotRequired[Literal["all", "none"]]
- """
- This parameter defines the skip behavior for input collection.
- """
-
- class TimeoutInputCollectionParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class ReaderService(StripeService):
def present_payment_method(
self,
reader: str,
- params: Optional["ReaderService.PresentPaymentMethodParams"] = None,
+ params: Optional["ReaderPresentPaymentMethodParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -110,7 +45,7 @@ def present_payment_method(
async def present_payment_method_async(
self,
reader: str,
- params: Optional["ReaderService.PresentPaymentMethodParams"] = None,
+ params: Optional["ReaderPresentPaymentMethodParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -132,7 +67,7 @@ async def present_payment_method_async(
def succeed_input_collection(
self,
reader: str,
- params: Optional["ReaderService.SucceedInputCollectionParams"] = None,
+ params: Optional["ReaderSucceedInputCollectionParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -154,7 +89,7 @@ def succeed_input_collection(
async def succeed_input_collection_async(
self,
reader: str,
- params: Optional["ReaderService.SucceedInputCollectionParams"] = None,
+ params: Optional["ReaderSucceedInputCollectionParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -176,7 +111,7 @@ async def succeed_input_collection_async(
def timeout_input_collection(
self,
reader: str,
- params: Optional["ReaderService.TimeoutInputCollectionParams"] = None,
+ params: Optional["ReaderTimeoutInputCollectionParams"] = None,
options: Optional[RequestOptions] = None,
) -> Reader:
"""
@@ -198,7 +133,7 @@ def timeout_input_collection(
async def timeout_input_collection_async(
self,
reader: str,
- params: Optional["ReaderService.TimeoutInputCollectionParams"] = None,
+ 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 f3b343b2a..fc4bbd8fc 100644
--- a/stripe/test_helpers/treasury/_inbound_transfer_service.py
+++ b/stripe/test_helpers/treasury/_inbound_transfer_service.py
@@ -4,61 +4,26 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.treasury._inbound_transfer import InboundTransfer
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.test_helpers.treasury._inbound_transfer_fail_params import (
+ InboundTransferFailParams,
+ )
+ from stripe.params.test_helpers.treasury._inbound_transfer_return_inbound_transfer_params import (
+ InboundTransferReturnInboundTransferParams,
+ )
+ from stripe.params.test_helpers.treasury._inbound_transfer_succeed_params import (
+ InboundTransferSucceedParams,
+ )
-class InboundTransferService(StripeService):
- class FailParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- failure_details: NotRequired[
- "InboundTransferService.FailParamsFailureDetails"
- ]
- """
- Details about a failed InboundTransfer.
- """
-
- class FailParamsFailureDetails(TypedDict):
- code: NotRequired[
- Literal[
- "account_closed",
- "account_frozen",
- "bank_account_restricted",
- "bank_ownership_changed",
- "debit_not_authorized",
- "incorrect_account_holder_address",
- "incorrect_account_holder_name",
- "incorrect_account_holder_tax_id",
- "insufficient_funds",
- "invalid_account_number",
- "invalid_currency",
- "no_account",
- "other",
- ]
- ]
- """
- Reason for the failure.
- """
-
- class ReturnInboundTransferParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SucceedParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class InboundTransferService(StripeService):
def fail(
self,
id: str,
- params: Optional["InboundTransferService.FailParams"] = None,
+ params: Optional["InboundTransferFailParams"] = None,
options: Optional[RequestOptions] = None,
) -> InboundTransfer:
"""
@@ -80,7 +45,7 @@ def fail(
async def fail_async(
self,
id: str,
- params: Optional["InboundTransferService.FailParams"] = None,
+ params: Optional["InboundTransferFailParams"] = None,
options: Optional[RequestOptions] = None,
) -> InboundTransfer:
"""
@@ -102,9 +67,7 @@ async def fail_async(
def return_inbound_transfer(
self,
id: str,
- params: Optional[
- "InboundTransferService.ReturnInboundTransferParams"
- ] = None,
+ params: Optional["InboundTransferReturnInboundTransferParams"] = None,
options: Optional[RequestOptions] = None,
) -> InboundTransfer:
"""
@@ -126,9 +89,7 @@ def return_inbound_transfer(
async def return_inbound_transfer_async(
self,
id: str,
- params: Optional[
- "InboundTransferService.ReturnInboundTransferParams"
- ] = None,
+ params: Optional["InboundTransferReturnInboundTransferParams"] = None,
options: Optional[RequestOptions] = None,
) -> InboundTransfer:
"""
@@ -150,7 +111,7 @@ async def return_inbound_transfer_async(
def succeed(
self,
id: str,
- params: Optional["InboundTransferService.SucceedParams"] = None,
+ params: Optional["InboundTransferSucceedParams"] = None,
options: Optional[RequestOptions] = None,
) -> InboundTransfer:
"""
@@ -172,7 +133,7 @@ def succeed(
async def succeed_async(
self,
id: str,
- params: Optional["InboundTransferService.SucceedParams"] = None,
+ 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 e60f567ee..08220c5d8 100644
--- a/stripe/test_helpers/treasury/_outbound_payment_service.py
+++ b/stripe/test_helpers/treasury/_outbound_payment_service.py
@@ -4,106 +4,29 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.treasury._outbound_payment import OutboundPayment
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.test_helpers.treasury._outbound_payment_fail_params import (
+ OutboundPaymentFailParams,
+ )
+ from stripe.params.test_helpers.treasury._outbound_payment_post_params import (
+ OutboundPaymentPostParams,
+ )
+ from stripe.params.test_helpers.treasury._outbound_payment_return_outbound_payment_params import (
+ OutboundPaymentReturnOutboundPaymentParams,
+ )
+ from stripe.params.test_helpers.treasury._outbound_payment_update_params import (
+ OutboundPaymentUpdateParams,
+ )
class OutboundPaymentService(StripeService):
- class FailParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class PostParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ReturnOutboundPaymentParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- returned_details: NotRequired[
- "OutboundPaymentService.ReturnOutboundPaymentParamsReturnedDetails"
- ]
- """
- Optional hash to set the return code.
- """
-
- class ReturnOutboundPaymentParamsReturnedDetails(TypedDict):
- code: NotRequired[
- Literal[
- "account_closed",
- "account_frozen",
- "bank_account_restricted",
- "bank_ownership_changed",
- "declined",
- "incorrect_account_holder_name",
- "invalid_account_number",
- "invalid_currency",
- "no_account",
- "other",
- ]
- ]
- """
- The return code to be set on the OutboundPayment object.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- tracking_details: "OutboundPaymentService.UpdateParamsTrackingDetails"
- """
- Details about network-specific tracking information.
- """
-
- class UpdateParamsTrackingDetails(TypedDict):
- ach: NotRequired[
- "OutboundPaymentService.UpdateParamsTrackingDetailsAch"
- ]
- """
- ACH network tracking details.
- """
- type: Literal["ach", "us_domestic_wire"]
- """
- The US bank account network used to send funds.
- """
- us_domestic_wire: NotRequired[
- "OutboundPaymentService.UpdateParamsTrackingDetailsUsDomesticWire"
- ]
- """
- US domestic wire network tracking details.
- """
-
- class UpdateParamsTrackingDetailsAch(TypedDict):
- trace_id: str
- """
- ACH trace ID for funds sent over the `ach` network.
- """
-
- class UpdateParamsTrackingDetailsUsDomesticWire(TypedDict):
- chips: NotRequired[str]
- """
- CHIPS System Sequence Number (SSN) for funds sent over the `us_domestic_wire` network.
- """
- imad: NotRequired[str]
- """
- IMAD for funds sent over the `us_domestic_wire` network.
- """
- omad: NotRequired[str]
- """
- OMAD for funds sent over the `us_domestic_wire` network.
- """
-
def update(
self,
id: str,
- params: "OutboundPaymentService.UpdateParams",
+ params: "OutboundPaymentUpdateParams",
options: Optional[RequestOptions] = None,
) -> OutboundPayment:
"""
@@ -125,7 +48,7 @@ def update(
async def update_async(
self,
id: str,
- params: "OutboundPaymentService.UpdateParams",
+ params: "OutboundPaymentUpdateParams",
options: Optional[RequestOptions] = None,
) -> OutboundPayment:
"""
@@ -147,7 +70,7 @@ async def update_async(
def fail(
self,
id: str,
- params: Optional["OutboundPaymentService.FailParams"] = None,
+ params: Optional["OutboundPaymentFailParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundPayment:
"""
@@ -169,7 +92,7 @@ def fail(
async def fail_async(
self,
id: str,
- params: Optional["OutboundPaymentService.FailParams"] = None,
+ params: Optional["OutboundPaymentFailParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundPayment:
"""
@@ -191,7 +114,7 @@ async def fail_async(
def post(
self,
id: str,
- params: Optional["OutboundPaymentService.PostParams"] = None,
+ params: Optional["OutboundPaymentPostParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundPayment:
"""
@@ -213,7 +136,7 @@ def post(
async def post_async(
self,
id: str,
- params: Optional["OutboundPaymentService.PostParams"] = None,
+ params: Optional["OutboundPaymentPostParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundPayment:
"""
@@ -235,9 +158,7 @@ async def post_async(
def return_outbound_payment(
self,
id: str,
- params: Optional[
- "OutboundPaymentService.ReturnOutboundPaymentParams"
- ] = None,
+ params: Optional["OutboundPaymentReturnOutboundPaymentParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundPayment:
"""
@@ -259,9 +180,7 @@ def return_outbound_payment(
async def return_outbound_payment_async(
self,
id: str,
- params: Optional[
- "OutboundPaymentService.ReturnOutboundPaymentParams"
- ] = None,
+ 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 d47a78c4e..6c1f1c9f7 100644
--- a/stripe/test_helpers/treasury/_outbound_transfer_service.py
+++ b/stripe/test_helpers/treasury/_outbound_transfer_service.py
@@ -4,106 +4,29 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.treasury._outbound_transfer import OutboundTransfer
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.test_helpers.treasury._outbound_transfer_fail_params import (
+ OutboundTransferFailParams,
+ )
+ from stripe.params.test_helpers.treasury._outbound_transfer_post_params import (
+ OutboundTransferPostParams,
+ )
+ from stripe.params.test_helpers.treasury._outbound_transfer_return_outbound_transfer_params import (
+ OutboundTransferReturnOutboundTransferParams,
+ )
+ from stripe.params.test_helpers.treasury._outbound_transfer_update_params import (
+ OutboundTransferUpdateParams,
+ )
class OutboundTransferService(StripeService):
- class FailParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class PostParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ReturnOutboundTransferParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- returned_details: NotRequired[
- "OutboundTransferService.ReturnOutboundTransferParamsReturnedDetails"
- ]
- """
- Details about a returned OutboundTransfer.
- """
-
- class ReturnOutboundTransferParamsReturnedDetails(TypedDict):
- code: NotRequired[
- Literal[
- "account_closed",
- "account_frozen",
- "bank_account_restricted",
- "bank_ownership_changed",
- "declined",
- "incorrect_account_holder_name",
- "invalid_account_number",
- "invalid_currency",
- "no_account",
- "other",
- ]
- ]
- """
- Reason for the return.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- tracking_details: "OutboundTransferService.UpdateParamsTrackingDetails"
- """
- Details about network-specific tracking information.
- """
-
- class UpdateParamsTrackingDetails(TypedDict):
- ach: NotRequired[
- "OutboundTransferService.UpdateParamsTrackingDetailsAch"
- ]
- """
- ACH network tracking details.
- """
- type: Literal["ach", "us_domestic_wire"]
- """
- The US bank account network used to send funds.
- """
- us_domestic_wire: NotRequired[
- "OutboundTransferService.UpdateParamsTrackingDetailsUsDomesticWire"
- ]
- """
- US domestic wire network tracking details.
- """
-
- class UpdateParamsTrackingDetailsAch(TypedDict):
- trace_id: str
- """
- ACH trace ID for funds sent over the `ach` network.
- """
-
- class UpdateParamsTrackingDetailsUsDomesticWire(TypedDict):
- chips: NotRequired[str]
- """
- CHIPS System Sequence Number (SSN) for funds sent over the `us_domestic_wire` network.
- """
- imad: NotRequired[str]
- """
- IMAD for funds sent over the `us_domestic_wire` network.
- """
- omad: NotRequired[str]
- """
- OMAD for funds sent over the `us_domestic_wire` network.
- """
-
def update(
self,
outbound_transfer: str,
- params: "OutboundTransferService.UpdateParams",
+ params: "OutboundTransferUpdateParams",
options: Optional[RequestOptions] = None,
) -> OutboundTransfer:
"""
@@ -125,7 +48,7 @@ def update(
async def update_async(
self,
outbound_transfer: str,
- params: "OutboundTransferService.UpdateParams",
+ params: "OutboundTransferUpdateParams",
options: Optional[RequestOptions] = None,
) -> OutboundTransfer:
"""
@@ -147,7 +70,7 @@ async def update_async(
def fail(
self,
outbound_transfer: str,
- params: Optional["OutboundTransferService.FailParams"] = None,
+ params: Optional["OutboundTransferFailParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundTransfer:
"""
@@ -169,7 +92,7 @@ def fail(
async def fail_async(
self,
outbound_transfer: str,
- params: Optional["OutboundTransferService.FailParams"] = None,
+ params: Optional["OutboundTransferFailParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundTransfer:
"""
@@ -191,7 +114,7 @@ async def fail_async(
def post(
self,
outbound_transfer: str,
- params: Optional["OutboundTransferService.PostParams"] = None,
+ params: Optional["OutboundTransferPostParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundTransfer:
"""
@@ -213,7 +136,7 @@ def post(
async def post_async(
self,
outbound_transfer: str,
- params: Optional["OutboundTransferService.PostParams"] = None,
+ params: Optional["OutboundTransferPostParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundTransfer:
"""
@@ -236,7 +159,7 @@ def return_outbound_transfer(
self,
outbound_transfer: str,
params: Optional[
- "OutboundTransferService.ReturnOutboundTransferParams"
+ "OutboundTransferReturnOutboundTransferParams"
] = None,
options: Optional[RequestOptions] = None,
) -> OutboundTransfer:
@@ -260,7 +183,7 @@ async def return_outbound_transfer_async(
self,
outbound_transfer: str,
params: Optional[
- "OutboundTransferService.ReturnOutboundTransferParams"
+ "OutboundTransferReturnOutboundTransferParams"
] = None,
options: Optional[RequestOptions] = None,
) -> OutboundTransfer:
diff --git a/stripe/test_helpers/treasury/_received_credit_service.py b/stripe/test_helpers/treasury/_received_credit_service.py
index 166087813..7fbc53426 100644
--- a/stripe/test_helpers/treasury/_received_credit_service.py
+++ b/stripe/test_helpers/treasury/_received_credit_service.py
@@ -3,72 +3,19 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe.treasury._received_credit import ReceivedCredit
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.test_helpers.treasury._received_credit_create_params import (
+ ReceivedCreditCreateParams,
+ )
-class ReceivedCreditService(StripeService):
- class CreateParams(TypedDict):
- amount: int
- """
- Amount (in cents) to be transferred.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- The FinancialAccount to send funds to.
- """
- initiating_payment_method_details: NotRequired[
- "ReceivedCreditService.CreateParamsInitiatingPaymentMethodDetails"
- ]
- """
- Initiating payment method details for the object.
- """
- network: Literal["ach", "us_domestic_wire"]
- """
- Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
- """
-
- class CreateParamsInitiatingPaymentMethodDetails(TypedDict):
- type: Literal["us_bank_account"]
- """
- The source type.
- """
- us_bank_account: NotRequired[
- "ReceivedCreditService.CreateParamsInitiatingPaymentMethodDetailsUsBankAccount"
- ]
- """
- Optional fields for `us_bank_account`.
- """
-
- class CreateParamsInitiatingPaymentMethodDetailsUsBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The bank account holder's name.
- """
- account_number: NotRequired[str]
- """
- The bank account number.
- """
- routing_number: NotRequired[str]
- """
- The bank account's routing number.
- """
+class ReceivedCreditService(StripeService):
def create(
self,
- params: "ReceivedCreditService.CreateParams",
+ params: "ReceivedCreditCreateParams",
options: Optional[RequestOptions] = None,
) -> ReceivedCredit:
"""
@@ -87,7 +34,7 @@ def create(
async def create_async(
self,
- params: "ReceivedCreditService.CreateParams",
+ params: "ReceivedCreditCreateParams",
options: Optional[RequestOptions] = None,
) -> ReceivedCredit:
"""
diff --git a/stripe/test_helpers/treasury/_received_debit_service.py b/stripe/test_helpers/treasury/_received_debit_service.py
index 4eb93c5eb..9a26ae89b 100644
--- a/stripe/test_helpers/treasury/_received_debit_service.py
+++ b/stripe/test_helpers/treasury/_received_debit_service.py
@@ -3,72 +3,19 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe.treasury._received_debit import ReceivedDebit
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.test_helpers.treasury._received_debit_create_params import (
+ ReceivedDebitCreateParams,
+ )
-class ReceivedDebitService(StripeService):
- class CreateParams(TypedDict):
- amount: int
- """
- Amount (in cents) to be transferred.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- The FinancialAccount to pull funds from.
- """
- initiating_payment_method_details: NotRequired[
- "ReceivedDebitService.CreateParamsInitiatingPaymentMethodDetails"
- ]
- """
- Initiating payment method details for the object.
- """
- network: Literal["ach"]
- """
- Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
- """
-
- class CreateParamsInitiatingPaymentMethodDetails(TypedDict):
- type: Literal["us_bank_account"]
- """
- The source type.
- """
- us_bank_account: NotRequired[
- "ReceivedDebitService.CreateParamsInitiatingPaymentMethodDetailsUsBankAccount"
- ]
- """
- Optional fields for `us_bank_account`.
- """
-
- class CreateParamsInitiatingPaymentMethodDetailsUsBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The bank account holder's name.
- """
- account_number: NotRequired[str]
- """
- The bank account number.
- """
- routing_number: NotRequired[str]
- """
- The bank account's routing number.
- """
+class ReceivedDebitService(StripeService):
def create(
self,
- params: "ReceivedDebitService.CreateParams",
+ params: "ReceivedDebitCreateParams",
options: Optional[RequestOptions] = None,
) -> ReceivedDebit:
"""
@@ -87,7 +34,7 @@ def create(
async def create_async(
self,
- params: "ReceivedDebitService.CreateParams",
+ params: "ReceivedDebitCreateParams",
options: Optional[RequestOptions] = None,
) -> ReceivedDebit:
"""
diff --git a/stripe/treasury/_credit_reversal.py b/stripe/treasury/_credit_reversal.py
index f8d64de25..4ed324cb6 100644
--- a/stripe/treasury/_credit_reversal.py
+++ b/stripe/treasury/_credit_reversal.py
@@ -4,12 +4,20 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
-from typing import ClassVar, Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, Unpack, TYPE_CHECKING
+from typing import ClassVar, Dict, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
+ from stripe.params.treasury._credit_reversal_create_params import (
+ CreditReversalCreateParams,
+ )
+ from stripe.params.treasury._credit_reversal_list_params import (
+ CreditReversalListParams,
+ )
+ from stripe.params.treasury._credit_reversal_retrieve_params import (
+ CreditReversalRetrieveParams,
+ )
from stripe.treasury._transaction import Transaction
@@ -31,56 +39,6 @@ class StatusTransitions(StripeObject):
Timestamp describing when the CreditReversal changed status to `posted`
"""
- class CreateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- received_credit: str
- """
- The ReceivedCredit to reverse.
- """
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- Returns objects associated with this FinancialAccount.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- received_credit: NotRequired[str]
- """
- Only return CreditReversals for the ReceivedCredit ID.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["canceled", "posted", "processing"]]
- """
- Only return CreditReversals for a given status.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount: int
"""
Amount (in cents) transferred.
@@ -137,7 +95,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["CreditReversal.CreateParams"]
+ cls, **params: Unpack["CreditReversalCreateParams"]
) -> "CreditReversal":
"""
Reverses a ReceivedCredit and creates a CreditReversal object.
@@ -153,7 +111,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["CreditReversal.CreateParams"]
+ cls, **params: Unpack["CreditReversalCreateParams"]
) -> "CreditReversal":
"""
Reverses a ReceivedCredit and creates a CreditReversal object.
@@ -169,7 +127,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["CreditReversal.ListParams"]
+ cls, **params: Unpack["CreditReversalListParams"]
) -> ListObject["CreditReversal"]:
"""
Returns a list of CreditReversals.
@@ -189,7 +147,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["CreditReversal.ListParams"]
+ cls, **params: Unpack["CreditReversalListParams"]
) -> ListObject["CreditReversal"]:
"""
Returns a list of CreditReversals.
@@ -209,7 +167,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["CreditReversal.RetrieveParams"]
+ cls, id: str, **params: Unpack["CreditReversalRetrieveParams"]
) -> "CreditReversal":
"""
Retrieves the details of an existing CreditReversal by passing the unique CreditReversal ID from either the CreditReversal creation request or CreditReversal list
@@ -220,7 +178,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["CreditReversal.RetrieveParams"]
+ cls, id: str, **params: Unpack["CreditReversalRetrieveParams"]
) -> "CreditReversal":
"""
Retrieves the details of an existing CreditReversal by passing the unique CreditReversal ID from either the CreditReversal creation request or CreditReversal list
diff --git a/stripe/treasury/_credit_reversal_service.py b/stripe/treasury/_credit_reversal_service.py
index e19163717..3d92114d2 100644
--- a/stripe/treasury/_credit_reversal_service.py
+++ b/stripe/treasury/_credit_reversal_service.py
@@ -5,64 +5,25 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.treasury._credit_reversal import CreditReversal
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.treasury._credit_reversal_create_params import (
+ CreditReversalCreateParams,
+ )
+ from stripe.params.treasury._credit_reversal_list_params import (
+ CreditReversalListParams,
+ )
+ from stripe.params.treasury._credit_reversal_retrieve_params import (
+ CreditReversalRetrieveParams,
+ )
-class CreditReversalService(StripeService):
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- received_credit: str
- """
- The ReceivedCredit to reverse.
- """
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- Returns objects associated with this FinancialAccount.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- received_credit: NotRequired[str]
- """
- Only return CreditReversals for the ReceivedCredit ID.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["canceled", "posted", "processing"]]
- """
- Only return CreditReversals for a given status.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class CreditReversalService(StripeService):
def list(
self,
- params: "CreditReversalService.ListParams",
+ params: "CreditReversalListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[CreditReversal]:
"""
@@ -81,7 +42,7 @@ def list(
async def list_async(
self,
- params: "CreditReversalService.ListParams",
+ params: "CreditReversalListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[CreditReversal]:
"""
@@ -100,7 +61,7 @@ async def list_async(
def create(
self,
- params: "CreditReversalService.CreateParams",
+ params: "CreditReversalCreateParams",
options: Optional[RequestOptions] = None,
) -> CreditReversal:
"""
@@ -119,7 +80,7 @@ def create(
async def create_async(
self,
- params: "CreditReversalService.CreateParams",
+ params: "CreditReversalCreateParams",
options: Optional[RequestOptions] = None,
) -> CreditReversal:
"""
@@ -139,7 +100,7 @@ async def create_async(
def retrieve(
self,
credit_reversal: str,
- params: Optional["CreditReversalService.RetrieveParams"] = None,
+ params: Optional["CreditReversalRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditReversal:
"""
@@ -161,7 +122,7 @@ def retrieve(
async def retrieve_async(
self,
credit_reversal: str,
- params: Optional["CreditReversalService.RetrieveParams"] = None,
+ params: Optional["CreditReversalRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> CreditReversal:
"""
diff --git a/stripe/treasury/_debit_reversal.py b/stripe/treasury/_debit_reversal.py
index dbc042bd1..ff98a4e23 100644
--- a/stripe/treasury/_debit_reversal.py
+++ b/stripe/treasury/_debit_reversal.py
@@ -4,12 +4,20 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
-from typing import ClassVar, Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, Unpack, TYPE_CHECKING
+from typing import ClassVar, Dict, Optional, cast
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
+ from stripe.params.treasury._debit_reversal_create_params import (
+ DebitReversalCreateParams,
+ )
+ from stripe.params.treasury._debit_reversal_list_params import (
+ DebitReversalListParams,
+ )
+ from stripe.params.treasury._debit_reversal_retrieve_params import (
+ DebitReversalRetrieveParams,
+ )
from stripe.treasury._transaction import Transaction
@@ -37,60 +45,6 @@ class StatusTransitions(StripeObject):
Timestamp describing when the DebitReversal changed status to `completed`.
"""
- class CreateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- received_debit: str
- """
- The ReceivedDebit to reverse.
- """
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- Returns objects associated with this FinancialAccount.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- received_debit: NotRequired[str]
- """
- Only return DebitReversals for the ReceivedDebit ID.
- """
- resolution: NotRequired[Literal["lost", "won"]]
- """
- Only return DebitReversals for a given resolution.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["canceled", "completed", "processing"]]
- """
- Only return DebitReversals for a given status.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount: int
"""
Amount (in cents) transferred.
@@ -151,7 +105,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def create(
- cls, **params: Unpack["DebitReversal.CreateParams"]
+ cls, **params: Unpack["DebitReversalCreateParams"]
) -> "DebitReversal":
"""
Reverses a ReceivedDebit and creates a DebitReversal object.
@@ -167,7 +121,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["DebitReversal.CreateParams"]
+ cls, **params: Unpack["DebitReversalCreateParams"]
) -> "DebitReversal":
"""
Reverses a ReceivedDebit and creates a DebitReversal object.
@@ -183,7 +137,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["DebitReversal.ListParams"]
+ cls, **params: Unpack["DebitReversalListParams"]
) -> ListObject["DebitReversal"]:
"""
Returns a list of DebitReversals.
@@ -203,7 +157,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["DebitReversal.ListParams"]
+ cls, **params: Unpack["DebitReversalListParams"]
) -> ListObject["DebitReversal"]:
"""
Returns a list of DebitReversals.
@@ -223,7 +177,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["DebitReversal.RetrieveParams"]
+ cls, id: str, **params: Unpack["DebitReversalRetrieveParams"]
) -> "DebitReversal":
"""
Retrieves a DebitReversal object.
@@ -234,7 +188,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["DebitReversal.RetrieveParams"]
+ cls, id: str, **params: Unpack["DebitReversalRetrieveParams"]
) -> "DebitReversal":
"""
Retrieves a DebitReversal object.
diff --git a/stripe/treasury/_debit_reversal_service.py b/stripe/treasury/_debit_reversal_service.py
index a8ee61bb8..be0e1865f 100644
--- a/stripe/treasury/_debit_reversal_service.py
+++ b/stripe/treasury/_debit_reversal_service.py
@@ -5,68 +5,25 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.treasury._debit_reversal import DebitReversal
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.treasury._debit_reversal_create_params import (
+ DebitReversalCreateParams,
+ )
+ from stripe.params.treasury._debit_reversal_list_params import (
+ DebitReversalListParams,
+ )
+ from stripe.params.treasury._debit_reversal_retrieve_params import (
+ DebitReversalRetrieveParams,
+ )
-class DebitReversalService(StripeService):
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- received_debit: str
- """
- The ReceivedDebit to reverse.
- """
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- Returns objects associated with this FinancialAccount.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- received_debit: NotRequired[str]
- """
- Only return DebitReversals for the ReceivedDebit ID.
- """
- resolution: NotRequired[Literal["lost", "won"]]
- """
- Only return DebitReversals for a given resolution.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["canceled", "completed", "processing"]]
- """
- Only return DebitReversals for a given status.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class DebitReversalService(StripeService):
def list(
self,
- params: "DebitReversalService.ListParams",
+ params: "DebitReversalListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[DebitReversal]:
"""
@@ -85,7 +42,7 @@ def list(
async def list_async(
self,
- params: "DebitReversalService.ListParams",
+ params: "DebitReversalListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[DebitReversal]:
"""
@@ -104,7 +61,7 @@ async def list_async(
def create(
self,
- params: "DebitReversalService.CreateParams",
+ params: "DebitReversalCreateParams",
options: Optional[RequestOptions] = None,
) -> DebitReversal:
"""
@@ -123,7 +80,7 @@ def create(
async def create_async(
self,
- params: "DebitReversalService.CreateParams",
+ params: "DebitReversalCreateParams",
options: Optional[RequestOptions] = None,
) -> DebitReversal:
"""
@@ -143,7 +100,7 @@ async def create_async(
def retrieve(
self,
debit_reversal: str,
- params: Optional["DebitReversalService.RetrieveParams"] = None,
+ params: Optional["DebitReversalRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> DebitReversal:
"""
@@ -165,7 +122,7 @@ def retrieve(
async def retrieve_async(
self,
debit_reversal: str,
- params: Optional["DebitReversalService.RetrieveParams"] = None,
+ params: Optional["DebitReversalRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> DebitReversal:
"""
diff --git a/stripe/treasury/_financial_account.py b/stripe/treasury/_financial_account.py
index 5b4815a40..5858d26f6 100644
--- a/stripe/treasury/_financial_account.py
+++ b/stripe/treasury/_financial_account.py
@@ -3,20 +3,34 @@
from stripe._createable_api_resource import CreateableAPIResource
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._updateable_api_resource import UpdateableAPIResource
from stripe._util import class_method_variant, sanitize_id
from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
+ from stripe.params.treasury._financial_account_close_params import (
+ FinancialAccountCloseParams,
+ )
+ from stripe.params.treasury._financial_account_create_params import (
+ FinancialAccountCreateParams,
+ )
+ from stripe.params.treasury._financial_account_list_params import (
+ FinancialAccountListParams,
+ )
+ from stripe.params.treasury._financial_account_modify_params import (
+ FinancialAccountModifyParams,
+ )
+ from stripe.params.treasury._financial_account_retrieve_features_params import (
+ FinancialAccountRetrieveFeaturesParams,
+ )
+ from stripe.params.treasury._financial_account_retrieve_params import (
+ FinancialAccountRetrieveParams,
+ )
+ from stripe.params.treasury._financial_account_update_features_params import (
+ FinancialAccountUpdateFeaturesParams,
+ )
from stripe.treasury._financial_account_features import (
FinancialAccountFeatures,
)
@@ -112,610 +126,6 @@ class Closed(StripeObject):
"""
_inner_class_types = {"closed": Closed}
- class CloseParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- forwarding_settings: NotRequired[
- "FinancialAccount.CloseParamsForwardingSettings"
- ]
- """
- A different bank account where funds can be deposited/debited in order to get the closing FA's balance to $0
- """
-
- class CloseParamsForwardingSettings(TypedDict):
- financial_account: NotRequired[str]
- """
- The financial_account id
- """
- payment_method: NotRequired[str]
- """
- The payment_method or bank account id. This needs to be a verified bank account.
- """
- type: Literal["financial_account", "payment_method"]
- """
- The type of the bank account provided. This can be either "financial_account" or "payment_method"
- """
-
- class CreateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- features: NotRequired["FinancialAccount.CreateParamsFeatures"]
- """
- Encodes whether a FinancialAccount has access to a particular feature. Stripe or the platform can control features via the requested field.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nickname: NotRequired["Literal['']|str"]
- """
- The nickname for the FinancialAccount.
- """
- platform_restrictions: NotRequired[
- "FinancialAccount.CreateParamsPlatformRestrictions"
- ]
- """
- The set of functionalities that the platform can restrict on the FinancialAccount.
- """
- supported_currencies: List[str]
- """
- The currencies the FinancialAccount can hold a balance in.
- """
-
- class CreateParamsFeatures(TypedDict):
- card_issuing: NotRequired[
- "FinancialAccount.CreateParamsFeaturesCardIssuing"
- ]
- """
- Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
- """
- deposit_insurance: NotRequired[
- "FinancialAccount.CreateParamsFeaturesDepositInsurance"
- ]
- """
- Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
- """
- financial_addresses: NotRequired[
- "FinancialAccount.CreateParamsFeaturesFinancialAddresses"
- ]
- """
- Contains Features that add FinancialAddresses to the FinancialAccount.
- """
- inbound_transfers: NotRequired[
- "FinancialAccount.CreateParamsFeaturesInboundTransfers"
- ]
- """
- Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
- """
- intra_stripe_flows: NotRequired[
- "FinancialAccount.CreateParamsFeaturesIntraStripeFlows"
- ]
- """
- Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
- """
- outbound_payments: NotRequired[
- "FinancialAccount.CreateParamsFeaturesOutboundPayments"
- ]
- """
- Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
- """
- outbound_transfers: NotRequired[
- "FinancialAccount.CreateParamsFeaturesOutboundTransfers"
- ]
- """
- Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
- """
-
- class CreateParamsFeaturesCardIssuing(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesDepositInsurance(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesFinancialAddresses(TypedDict):
- aba: NotRequired[
- "FinancialAccount.CreateParamsFeaturesFinancialAddressesAba"
- ]
- """
- Adds an ABA FinancialAddress to the FinancialAccount.
- """
-
- class CreateParamsFeaturesFinancialAddressesAba(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesInboundTransfers(TypedDict):
- ach: NotRequired[
- "FinancialAccount.CreateParamsFeaturesInboundTransfersAch"
- ]
- """
- Enables ACH Debits via the InboundTransfers API.
- """
-
- class CreateParamsFeaturesInboundTransfersAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesIntraStripeFlows(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesOutboundPayments(TypedDict):
- ach: NotRequired[
- "FinancialAccount.CreateParamsFeaturesOutboundPaymentsAch"
- ]
- """
- Enables ACH transfers via the OutboundPayments API.
- """
- us_domestic_wire: NotRequired[
- "FinancialAccount.CreateParamsFeaturesOutboundPaymentsUsDomesticWire"
- ]
- """
- Enables US domestic wire transfers via the OutboundPayments API.
- """
-
- class CreateParamsFeaturesOutboundPaymentsAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesOutboundPaymentsUsDomesticWire(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesOutboundTransfers(TypedDict):
- ach: NotRequired[
- "FinancialAccount.CreateParamsFeaturesOutboundTransfersAch"
- ]
- """
- Enables ACH transfers via the OutboundTransfers API.
- """
- us_domestic_wire: NotRequired[
- "FinancialAccount.CreateParamsFeaturesOutboundTransfersUsDomesticWire"
- ]
- """
- Enables US domestic wire transfers via the OutboundTransfers API.
- """
-
- class CreateParamsFeaturesOutboundTransfersAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesOutboundTransfersUsDomesticWire(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsPlatformRestrictions(TypedDict):
- inbound_flows: NotRequired[Literal["restricted", "unrestricted"]]
- """
- Restricts all inbound money movement.
- """
- outbound_flows: NotRequired[Literal["restricted", "unrestricted"]]
- """
- Restricts all outbound money movement.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["FinancialAccount.ListParamsCreated|int"]
- """
- Only return FinancialAccounts that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- An object ID cursor for use in pagination.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit ranging from 1 to 100 (defaults to 10).
- """
- starting_after: NotRequired[str]
- """
- An object ID cursor for use in pagination.
- """
- status: NotRequired[Literal["closed", "open"]]
- """
- Only return FinancialAccounts that have the given status: `open` or `closed`
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ModifyParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- features: NotRequired["FinancialAccount.ModifyParamsFeatures"]
- """
- Encodes whether a FinancialAccount has access to a particular feature, with a status enum and associated `status_details`. Stripe or the platform may control features via the requested field.
- """
- forwarding_settings: NotRequired[
- "FinancialAccount.ModifyParamsForwardingSettings"
- ]
- """
- A different bank account where funds can be deposited/debited in order to get the closing FA's balance to $0
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nickname: NotRequired["Literal['']|str"]
- """
- The nickname for the FinancialAccount.
- """
- platform_restrictions: NotRequired[
- "FinancialAccount.ModifyParamsPlatformRestrictions"
- ]
- """
- The set of functionalities that the platform can restrict on the FinancialAccount.
- """
-
- class ModifyParamsFeatures(TypedDict):
- card_issuing: NotRequired[
- "FinancialAccount.ModifyParamsFeaturesCardIssuing"
- ]
- """
- Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
- """
- deposit_insurance: NotRequired[
- "FinancialAccount.ModifyParamsFeaturesDepositInsurance"
- ]
- """
- Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
- """
- financial_addresses: NotRequired[
- "FinancialAccount.ModifyParamsFeaturesFinancialAddresses"
- ]
- """
- Contains Features that add FinancialAddresses to the FinancialAccount.
- """
- inbound_transfers: NotRequired[
- "FinancialAccount.ModifyParamsFeaturesInboundTransfers"
- ]
- """
- Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
- """
- intra_stripe_flows: NotRequired[
- "FinancialAccount.ModifyParamsFeaturesIntraStripeFlows"
- ]
- """
- Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
- """
- outbound_payments: NotRequired[
- "FinancialAccount.ModifyParamsFeaturesOutboundPayments"
- ]
- """
- Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
- """
- outbound_transfers: NotRequired[
- "FinancialAccount.ModifyParamsFeaturesOutboundTransfers"
- ]
- """
- Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
- """
-
- class ModifyParamsFeaturesCardIssuing(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class ModifyParamsFeaturesDepositInsurance(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class ModifyParamsFeaturesFinancialAddresses(TypedDict):
- aba: NotRequired[
- "FinancialAccount.ModifyParamsFeaturesFinancialAddressesAba"
- ]
- """
- Adds an ABA FinancialAddress to the FinancialAccount.
- """
-
- class ModifyParamsFeaturesFinancialAddressesAba(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class ModifyParamsFeaturesInboundTransfers(TypedDict):
- ach: NotRequired[
- "FinancialAccount.ModifyParamsFeaturesInboundTransfersAch"
- ]
- """
- Enables ACH Debits via the InboundTransfers API.
- """
-
- class ModifyParamsFeaturesInboundTransfersAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class ModifyParamsFeaturesIntraStripeFlows(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class ModifyParamsFeaturesOutboundPayments(TypedDict):
- ach: NotRequired[
- "FinancialAccount.ModifyParamsFeaturesOutboundPaymentsAch"
- ]
- """
- Enables ACH transfers via the OutboundPayments API.
- """
- us_domestic_wire: NotRequired[
- "FinancialAccount.ModifyParamsFeaturesOutboundPaymentsUsDomesticWire"
- ]
- """
- Enables US domestic wire transfers via the OutboundPayments API.
- """
-
- class ModifyParamsFeaturesOutboundPaymentsAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class ModifyParamsFeaturesOutboundPaymentsUsDomesticWire(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class ModifyParamsFeaturesOutboundTransfers(TypedDict):
- ach: NotRequired[
- "FinancialAccount.ModifyParamsFeaturesOutboundTransfersAch"
- ]
- """
- Enables ACH transfers via the OutboundTransfers API.
- """
- us_domestic_wire: NotRequired[
- "FinancialAccount.ModifyParamsFeaturesOutboundTransfersUsDomesticWire"
- ]
- """
- Enables US domestic wire transfers via the OutboundTransfers API.
- """
-
- class ModifyParamsFeaturesOutboundTransfersAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class ModifyParamsFeaturesOutboundTransfersUsDomesticWire(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class ModifyParamsForwardingSettings(TypedDict):
- financial_account: NotRequired[str]
- """
- The financial_account id
- """
- payment_method: NotRequired[str]
- """
- The payment_method or bank account id. This needs to be a verified bank account.
- """
- type: Literal["financial_account", "payment_method"]
- """
- The type of the bank account provided. This can be either "financial_account" or "payment_method"
- """
-
- class ModifyParamsPlatformRestrictions(TypedDict):
- inbound_flows: NotRequired[Literal["restricted", "unrestricted"]]
- """
- Restricts all inbound money movement.
- """
- outbound_flows: NotRequired[Literal["restricted", "unrestricted"]]
- """
- Restricts all outbound money movement.
- """
-
- class RetrieveFeaturesParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateFeaturesParams(RequestOptions):
- card_issuing: NotRequired[
- "FinancialAccount.UpdateFeaturesParamsCardIssuing"
- ]
- """
- Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
- """
- deposit_insurance: NotRequired[
- "FinancialAccount.UpdateFeaturesParamsDepositInsurance"
- ]
- """
- Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_addresses: NotRequired[
- "FinancialAccount.UpdateFeaturesParamsFinancialAddresses"
- ]
- """
- Contains Features that add FinancialAddresses to the FinancialAccount.
- """
- inbound_transfers: NotRequired[
- "FinancialAccount.UpdateFeaturesParamsInboundTransfers"
- ]
- """
- Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
- """
- intra_stripe_flows: NotRequired[
- "FinancialAccount.UpdateFeaturesParamsIntraStripeFlows"
- ]
- """
- Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
- """
- outbound_payments: NotRequired[
- "FinancialAccount.UpdateFeaturesParamsOutboundPayments"
- ]
- """
- Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
- """
- outbound_transfers: NotRequired[
- "FinancialAccount.UpdateFeaturesParamsOutboundTransfers"
- ]
- """
- Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
- """
-
- class UpdateFeaturesParamsCardIssuing(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateFeaturesParamsDepositInsurance(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateFeaturesParamsFinancialAddresses(TypedDict):
- aba: NotRequired[
- "FinancialAccount.UpdateFeaturesParamsFinancialAddressesAba"
- ]
- """
- Adds an ABA FinancialAddress to the FinancialAccount.
- """
-
- class UpdateFeaturesParamsFinancialAddressesAba(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateFeaturesParamsInboundTransfers(TypedDict):
- ach: NotRequired[
- "FinancialAccount.UpdateFeaturesParamsInboundTransfersAch"
- ]
- """
- Enables ACH Debits via the InboundTransfers API.
- """
-
- class UpdateFeaturesParamsInboundTransfersAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateFeaturesParamsIntraStripeFlows(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateFeaturesParamsOutboundPayments(TypedDict):
- ach: NotRequired[
- "FinancialAccount.UpdateFeaturesParamsOutboundPaymentsAch"
- ]
- """
- Enables ACH transfers via the OutboundPayments API.
- """
- us_domestic_wire: NotRequired[
- "FinancialAccount.UpdateFeaturesParamsOutboundPaymentsUsDomesticWire"
- ]
- """
- Enables US domestic wire transfers via the OutboundPayments API.
- """
-
- class UpdateFeaturesParamsOutboundPaymentsAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateFeaturesParamsOutboundPaymentsUsDomesticWire(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateFeaturesParamsOutboundTransfers(TypedDict):
- ach: NotRequired[
- "FinancialAccount.UpdateFeaturesParamsOutboundTransfersAch"
- ]
- """
- Enables ACH transfers via the OutboundTransfers API.
- """
- us_domestic_wire: NotRequired[
- "FinancialAccount.UpdateFeaturesParamsOutboundTransfersUsDomesticWire"
- ]
- """
- Enables US domestic wire transfers via the OutboundTransfers API.
- """
-
- class UpdateFeaturesParamsOutboundTransfersAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateFeaturesParamsOutboundTransfersUsDomesticWire(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
active_features: Optional[
List[
Literal[
@@ -836,7 +246,7 @@ class UpdateFeaturesParamsOutboundTransfersUsDomesticWire(TypedDict):
def _cls_close(
cls,
financial_account: str,
- **params: Unpack["FinancialAccount.CloseParams"],
+ **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.
@@ -855,8 +265,7 @@ def _cls_close(
@overload
@staticmethod
def close(
- financial_account: str,
- **params: Unpack["FinancialAccount.CloseParams"],
+ 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.
@@ -865,7 +274,7 @@ def close(
@overload
def close(
- self, **params: Unpack["FinancialAccount.CloseParams"]
+ self, **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.
@@ -874,7 +283,7 @@ def close(
@class_method_variant("_cls_close")
def close( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["FinancialAccount.CloseParams"]
+ self, **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.
@@ -894,7 +303,7 @@ def close( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_close_async(
cls,
financial_account: str,
- **params: Unpack["FinancialAccount.CloseParams"],
+ **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.
@@ -913,8 +322,7 @@ async def _cls_close_async(
@overload
@staticmethod
async def close_async(
- financial_account: str,
- **params: Unpack["FinancialAccount.CloseParams"],
+ 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.
@@ -923,7 +331,7 @@ async def close_async(
@overload
async def close_async(
- self, **params: Unpack["FinancialAccount.CloseParams"]
+ self, **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.
@@ -932,7 +340,7 @@ async def close_async(
@class_method_variant("_cls_close_async")
async def close_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["FinancialAccount.CloseParams"]
+ self, **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.
@@ -950,7 +358,7 @@ async def close_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def create(
- cls, **params: Unpack["FinancialAccount.CreateParams"]
+ cls, **params: Unpack["FinancialAccountCreateParams"]
) -> "FinancialAccount":
"""
Creates a new FinancialAccount. Each connected account can have up to three FinancialAccounts by default.
@@ -966,7 +374,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["FinancialAccount.CreateParams"]
+ cls, **params: Unpack["FinancialAccountCreateParams"]
) -> "FinancialAccount":
"""
Creates a new FinancialAccount. Each connected account can have up to three FinancialAccounts by default.
@@ -982,7 +390,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["FinancialAccount.ListParams"]
+ cls, **params: Unpack["FinancialAccountListParams"]
) -> ListObject["FinancialAccount"]:
"""
Returns a list of FinancialAccounts.
@@ -1002,7 +410,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["FinancialAccount.ListParams"]
+ cls, **params: Unpack["FinancialAccountListParams"]
) -> ListObject["FinancialAccount"]:
"""
Returns a list of FinancialAccounts.
@@ -1022,7 +430,7 @@ async def list_async(
@classmethod
def modify(
- cls, id: str, **params: Unpack["FinancialAccount.ModifyParams"]
+ cls, id: str, **params: Unpack["FinancialAccountModifyParams"]
) -> "FinancialAccount":
"""
Updates the details of a FinancialAccount.
@@ -1039,7 +447,7 @@ def modify(
@classmethod
async def modify_async(
- cls, id: str, **params: Unpack["FinancialAccount.ModifyParams"]
+ cls, id: str, **params: Unpack["FinancialAccountModifyParams"]
) -> "FinancialAccount":
"""
Updates the details of a FinancialAccount.
@@ -1056,7 +464,7 @@ async def modify_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["FinancialAccount.RetrieveParams"]
+ cls, id: str, **params: Unpack["FinancialAccountRetrieveParams"]
) -> "FinancialAccount":
"""
Retrieves the details of a FinancialAccount.
@@ -1067,7 +475,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["FinancialAccount.RetrieveParams"]
+ cls, id: str, **params: Unpack["FinancialAccountRetrieveParams"]
) -> "FinancialAccount":
"""
Retrieves the details of a FinancialAccount.
@@ -1080,7 +488,7 @@ async def retrieve_async(
def _cls_retrieve_features(
cls,
financial_account: str,
- **params: Unpack["FinancialAccount.RetrieveFeaturesParams"],
+ **params: Unpack["FinancialAccountRetrieveFeaturesParams"],
) -> "FinancialAccountFeatures":
"""
Retrieves Features information associated with the FinancialAccount.
@@ -1100,7 +508,7 @@ def _cls_retrieve_features(
@staticmethod
def retrieve_features(
financial_account: str,
- **params: Unpack["FinancialAccount.RetrieveFeaturesParams"],
+ **params: Unpack["FinancialAccountRetrieveFeaturesParams"],
) -> "FinancialAccountFeatures":
"""
Retrieves Features information associated with the FinancialAccount.
@@ -1109,7 +517,7 @@ def retrieve_features(
@overload
def retrieve_features(
- self, **params: Unpack["FinancialAccount.RetrieveFeaturesParams"]
+ self, **params: Unpack["FinancialAccountRetrieveFeaturesParams"]
) -> "FinancialAccountFeatures":
"""
Retrieves Features information associated with the FinancialAccount.
@@ -1118,7 +526,7 @@ def retrieve_features(
@class_method_variant("_cls_retrieve_features")
def retrieve_features( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["FinancialAccount.RetrieveFeaturesParams"]
+ self, **params: Unpack["FinancialAccountRetrieveFeaturesParams"]
) -> "FinancialAccountFeatures":
"""
Retrieves Features information associated with the FinancialAccount.
@@ -1138,7 +546,7 @@ def retrieve_features( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_retrieve_features_async(
cls,
financial_account: str,
- **params: Unpack["FinancialAccount.RetrieveFeaturesParams"],
+ **params: Unpack["FinancialAccountRetrieveFeaturesParams"],
) -> "FinancialAccountFeatures":
"""
Retrieves Features information associated with the FinancialAccount.
@@ -1158,7 +566,7 @@ async def _cls_retrieve_features_async(
@staticmethod
async def retrieve_features_async(
financial_account: str,
- **params: Unpack["FinancialAccount.RetrieveFeaturesParams"],
+ **params: Unpack["FinancialAccountRetrieveFeaturesParams"],
) -> "FinancialAccountFeatures":
"""
Retrieves Features information associated with the FinancialAccount.
@@ -1167,7 +575,7 @@ async def retrieve_features_async(
@overload
async def retrieve_features_async(
- self, **params: Unpack["FinancialAccount.RetrieveFeaturesParams"]
+ self, **params: Unpack["FinancialAccountRetrieveFeaturesParams"]
) -> "FinancialAccountFeatures":
"""
Retrieves Features information associated with the FinancialAccount.
@@ -1176,7 +584,7 @@ async def retrieve_features_async(
@class_method_variant("_cls_retrieve_features_async")
async def retrieve_features_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["FinancialAccount.RetrieveFeaturesParams"]
+ self, **params: Unpack["FinancialAccountRetrieveFeaturesParams"]
) -> "FinancialAccountFeatures":
"""
Retrieves Features information associated with the FinancialAccount.
@@ -1196,7 +604,7 @@ async def retrieve_features_async( # pyright: ignore[reportGeneralTypeIssues]
def _cls_update_features(
cls,
financial_account: str,
- **params: Unpack["FinancialAccount.UpdateFeaturesParams"],
+ **params: Unpack["FinancialAccountUpdateFeaturesParams"],
) -> "FinancialAccountFeatures":
"""
Updates the Features associated with a FinancialAccount.
@@ -1216,7 +624,7 @@ def _cls_update_features(
@staticmethod
def update_features(
financial_account: str,
- **params: Unpack["FinancialAccount.UpdateFeaturesParams"],
+ **params: Unpack["FinancialAccountUpdateFeaturesParams"],
) -> "FinancialAccountFeatures":
"""
Updates the Features associated with a FinancialAccount.
@@ -1225,7 +633,7 @@ def update_features(
@overload
def update_features(
- self, **params: Unpack["FinancialAccount.UpdateFeaturesParams"]
+ self, **params: Unpack["FinancialAccountUpdateFeaturesParams"]
) -> "FinancialAccountFeatures":
"""
Updates the Features associated with a FinancialAccount.
@@ -1234,7 +642,7 @@ def update_features(
@class_method_variant("_cls_update_features")
def update_features( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["FinancialAccount.UpdateFeaturesParams"]
+ self, **params: Unpack["FinancialAccountUpdateFeaturesParams"]
) -> "FinancialAccountFeatures":
"""
Updates the Features associated with a FinancialAccount.
@@ -1254,7 +662,7 @@ def update_features( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_update_features_async(
cls,
financial_account: str,
- **params: Unpack["FinancialAccount.UpdateFeaturesParams"],
+ **params: Unpack["FinancialAccountUpdateFeaturesParams"],
) -> "FinancialAccountFeatures":
"""
Updates the Features associated with a FinancialAccount.
@@ -1274,7 +682,7 @@ async def _cls_update_features_async(
@staticmethod
async def update_features_async(
financial_account: str,
- **params: Unpack["FinancialAccount.UpdateFeaturesParams"],
+ **params: Unpack["FinancialAccountUpdateFeaturesParams"],
) -> "FinancialAccountFeatures":
"""
Updates the Features associated with a FinancialAccount.
@@ -1283,7 +691,7 @@ async def update_features_async(
@overload
async def update_features_async(
- self, **params: Unpack["FinancialAccount.UpdateFeaturesParams"]
+ self, **params: Unpack["FinancialAccountUpdateFeaturesParams"]
) -> "FinancialAccountFeatures":
"""
Updates the Features associated with a FinancialAccount.
@@ -1292,7 +700,7 @@ async def update_features_async(
@class_method_variant("_cls_update_features_async")
async def update_features_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["FinancialAccount.UpdateFeaturesParams"]
+ self, **params: Unpack["FinancialAccountUpdateFeaturesParams"]
) -> "FinancialAccountFeatures":
"""
Updates the Features associated with a FinancialAccount.
diff --git a/stripe/treasury/_financial_account_features_service.py b/stripe/treasury/_financial_account_features_service.py
index 214feaad3..28e9a0c53 100644
--- a/stripe/treasury/_financial_account_features_service.py
+++ b/stripe/treasury/_financial_account_features_service.py
@@ -6,169 +6,23 @@
from stripe.treasury._financial_account_features import (
FinancialAccountFeatures,
)
-from typing import List, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.treasury._financial_account_features_retrieve_params import (
+ FinancialAccountFeaturesRetrieveParams,
+ )
+ from stripe.params.treasury._financial_account_features_update_params import (
+ FinancialAccountFeaturesUpdateParams,
+ )
-class FinancialAccountFeaturesService(StripeService):
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- card_issuing: NotRequired[
- "FinancialAccountFeaturesService.UpdateParamsCardIssuing"
- ]
- """
- Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
- """
- deposit_insurance: NotRequired[
- "FinancialAccountFeaturesService.UpdateParamsDepositInsurance"
- ]
- """
- Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_addresses: NotRequired[
- "FinancialAccountFeaturesService.UpdateParamsFinancialAddresses"
- ]
- """
- Contains Features that add FinancialAddresses to the FinancialAccount.
- """
- inbound_transfers: NotRequired[
- "FinancialAccountFeaturesService.UpdateParamsInboundTransfers"
- ]
- """
- Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
- """
- intra_stripe_flows: NotRequired[
- "FinancialAccountFeaturesService.UpdateParamsIntraStripeFlows"
- ]
- """
- Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
- """
- outbound_payments: NotRequired[
- "FinancialAccountFeaturesService.UpdateParamsOutboundPayments"
- ]
- """
- Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
- """
- outbound_transfers: NotRequired[
- "FinancialAccountFeaturesService.UpdateParamsOutboundTransfers"
- ]
- """
- Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
- """
-
- class UpdateParamsCardIssuing(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsDepositInsurance(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsFinancialAddresses(TypedDict):
- aba: NotRequired[
- "FinancialAccountFeaturesService.UpdateParamsFinancialAddressesAba"
- ]
- """
- Adds an ABA FinancialAddress to the FinancialAccount.
- """
-
- class UpdateParamsFinancialAddressesAba(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsInboundTransfers(TypedDict):
- ach: NotRequired[
- "FinancialAccountFeaturesService.UpdateParamsInboundTransfersAch"
- ]
- """
- Enables ACH Debits via the InboundTransfers API.
- """
-
- class UpdateParamsInboundTransfersAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsIntraStripeFlows(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsOutboundPayments(TypedDict):
- ach: NotRequired[
- "FinancialAccountFeaturesService.UpdateParamsOutboundPaymentsAch"
- ]
- """
- Enables ACH transfers via the OutboundPayments API.
- """
- us_domestic_wire: NotRequired[
- "FinancialAccountFeaturesService.UpdateParamsOutboundPaymentsUsDomesticWire"
- ]
- """
- Enables US domestic wire transfers via the OutboundPayments API.
- """
-
- class UpdateParamsOutboundPaymentsAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsOutboundPaymentsUsDomesticWire(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsOutboundTransfers(TypedDict):
- ach: NotRequired[
- "FinancialAccountFeaturesService.UpdateParamsOutboundTransfersAch"
- ]
- """
- Enables ACH transfers via the OutboundTransfers API.
- """
- us_domestic_wire: NotRequired[
- "FinancialAccountFeaturesService.UpdateParamsOutboundTransfersUsDomesticWire"
- ]
- """
- Enables US domestic wire transfers via the OutboundTransfers API.
- """
-
- class UpdateParamsOutboundTransfersAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsOutboundTransfersUsDomesticWire(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
+class FinancialAccountFeaturesService(StripeService):
def update(
self,
financial_account: str,
- params: Optional[
- "FinancialAccountFeaturesService.UpdateParams"
- ] = None,
+ params: Optional["FinancialAccountFeaturesUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> FinancialAccountFeatures:
"""
@@ -190,9 +44,7 @@ def update(
async def update_async(
self,
financial_account: str,
- params: Optional[
- "FinancialAccountFeaturesService.UpdateParams"
- ] = None,
+ params: Optional["FinancialAccountFeaturesUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> FinancialAccountFeatures:
"""
@@ -214,9 +66,7 @@ async def update_async(
def retrieve(
self,
financial_account: str,
- params: Optional[
- "FinancialAccountFeaturesService.RetrieveParams"
- ] = None,
+ params: Optional["FinancialAccountFeaturesRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> FinancialAccountFeatures:
"""
@@ -238,9 +88,7 @@ def retrieve(
async def retrieve_async(
self,
financial_account: str,
- params: Optional[
- "FinancialAccountFeaturesService.RetrieveParams"
- ] = None,
+ 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 6e4eda822..d6d910996 100644
--- a/stripe/treasury/_financial_account_service.py
+++ b/stripe/treasury/_financial_account_service.py
@@ -8,8 +8,25 @@
from stripe.treasury._financial_account_features_service import (
FinancialAccountFeaturesService,
)
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.treasury._financial_account_close_params import (
+ FinancialAccountCloseParams,
+ )
+ from stripe.params.treasury._financial_account_create_params import (
+ FinancialAccountCreateParams,
+ )
+ from stripe.params.treasury._financial_account_list_params import (
+ FinancialAccountListParams,
+ )
+ from stripe.params.treasury._financial_account_retrieve_params import (
+ FinancialAccountRetrieveParams,
+ )
+ from stripe.params.treasury._financial_account_update_params import (
+ FinancialAccountUpdateParams,
+ )
class FinancialAccountService(StripeService):
@@ -17,461 +34,9 @@ def __init__(self, requestor):
super().__init__(requestor)
self.features = FinancialAccountFeaturesService(self._requestor)
- class CloseParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- forwarding_settings: NotRequired[
- "FinancialAccountService.CloseParamsForwardingSettings"
- ]
- """
- A different bank account where funds can be deposited/debited in order to get the closing FA's balance to $0
- """
-
- class CloseParamsForwardingSettings(TypedDict):
- financial_account: NotRequired[str]
- """
- The financial_account id
- """
- payment_method: NotRequired[str]
- """
- The payment_method or bank account id. This needs to be a verified bank account.
- """
- type: Literal["financial_account", "payment_method"]
- """
- The type of the bank account provided. This can be either "financial_account" or "payment_method"
- """
-
- class CreateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- features: NotRequired["FinancialAccountService.CreateParamsFeatures"]
- """
- Encodes whether a FinancialAccount has access to a particular feature. Stripe or the platform can control features via the requested field.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nickname: NotRequired["Literal['']|str"]
- """
- The nickname for the FinancialAccount.
- """
- platform_restrictions: NotRequired[
- "FinancialAccountService.CreateParamsPlatformRestrictions"
- ]
- """
- The set of functionalities that the platform can restrict on the FinancialAccount.
- """
- supported_currencies: List[str]
- """
- The currencies the FinancialAccount can hold a balance in.
- """
-
- class CreateParamsFeatures(TypedDict):
- card_issuing: NotRequired[
- "FinancialAccountService.CreateParamsFeaturesCardIssuing"
- ]
- """
- Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
- """
- deposit_insurance: NotRequired[
- "FinancialAccountService.CreateParamsFeaturesDepositInsurance"
- ]
- """
- Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
- """
- financial_addresses: NotRequired[
- "FinancialAccountService.CreateParamsFeaturesFinancialAddresses"
- ]
- """
- Contains Features that add FinancialAddresses to the FinancialAccount.
- """
- inbound_transfers: NotRequired[
- "FinancialAccountService.CreateParamsFeaturesInboundTransfers"
- ]
- """
- Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
- """
- intra_stripe_flows: NotRequired[
- "FinancialAccountService.CreateParamsFeaturesIntraStripeFlows"
- ]
- """
- Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
- """
- outbound_payments: NotRequired[
- "FinancialAccountService.CreateParamsFeaturesOutboundPayments"
- ]
- """
- Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
- """
- outbound_transfers: NotRequired[
- "FinancialAccountService.CreateParamsFeaturesOutboundTransfers"
- ]
- """
- Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
- """
-
- class CreateParamsFeaturesCardIssuing(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesDepositInsurance(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesFinancialAddresses(TypedDict):
- aba: NotRequired[
- "FinancialAccountService.CreateParamsFeaturesFinancialAddressesAba"
- ]
- """
- Adds an ABA FinancialAddress to the FinancialAccount.
- """
-
- class CreateParamsFeaturesFinancialAddressesAba(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesInboundTransfers(TypedDict):
- ach: NotRequired[
- "FinancialAccountService.CreateParamsFeaturesInboundTransfersAch"
- ]
- """
- Enables ACH Debits via the InboundTransfers API.
- """
-
- class CreateParamsFeaturesInboundTransfersAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesIntraStripeFlows(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesOutboundPayments(TypedDict):
- ach: NotRequired[
- "FinancialAccountService.CreateParamsFeaturesOutboundPaymentsAch"
- ]
- """
- Enables ACH transfers via the OutboundPayments API.
- """
- us_domestic_wire: NotRequired[
- "FinancialAccountService.CreateParamsFeaturesOutboundPaymentsUsDomesticWire"
- ]
- """
- Enables US domestic wire transfers via the OutboundPayments API.
- """
-
- class CreateParamsFeaturesOutboundPaymentsAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesOutboundPaymentsUsDomesticWire(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesOutboundTransfers(TypedDict):
- ach: NotRequired[
- "FinancialAccountService.CreateParamsFeaturesOutboundTransfersAch"
- ]
- """
- Enables ACH transfers via the OutboundTransfers API.
- """
- us_domestic_wire: NotRequired[
- "FinancialAccountService.CreateParamsFeaturesOutboundTransfersUsDomesticWire"
- ]
- """
- Enables US domestic wire transfers via the OutboundTransfers API.
- """
-
- class CreateParamsFeaturesOutboundTransfersAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsFeaturesOutboundTransfersUsDomesticWire(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class CreateParamsPlatformRestrictions(TypedDict):
- inbound_flows: NotRequired[Literal["restricted", "unrestricted"]]
- """
- Restricts all inbound money movement.
- """
- outbound_flows: NotRequired[Literal["restricted", "unrestricted"]]
- """
- Restricts all outbound money movement.
- """
-
- class ListParams(TypedDict):
- created: NotRequired["FinancialAccountService.ListParamsCreated|int"]
- """
- Only return FinancialAccounts that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- An object ID cursor for use in pagination.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- limit: NotRequired[int]
- """
- A limit ranging from 1 to 100 (defaults to 10).
- """
- starting_after: NotRequired[str]
- """
- An object ID cursor for use in pagination.
- """
- status: NotRequired[Literal["closed", "open"]]
- """
- Only return FinancialAccounts that have the given status: `open` or `closed`
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class UpdateParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- features: NotRequired["FinancialAccountService.UpdateParamsFeatures"]
- """
- Encodes whether a FinancialAccount has access to a particular feature, with a status enum and associated `status_details`. Stripe or the platform may control features via the requested field.
- """
- forwarding_settings: NotRequired[
- "FinancialAccountService.UpdateParamsForwardingSettings"
- ]
- """
- A different bank account where funds can be deposited/debited in order to get the closing FA's balance to $0
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- nickname: NotRequired["Literal['']|str"]
- """
- The nickname for the FinancialAccount.
- """
- platform_restrictions: NotRequired[
- "FinancialAccountService.UpdateParamsPlatformRestrictions"
- ]
- """
- The set of functionalities that the platform can restrict on the FinancialAccount.
- """
-
- class UpdateParamsFeatures(TypedDict):
- card_issuing: NotRequired[
- "FinancialAccountService.UpdateParamsFeaturesCardIssuing"
- ]
- """
- Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
- """
- deposit_insurance: NotRequired[
- "FinancialAccountService.UpdateParamsFeaturesDepositInsurance"
- ]
- """
- Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
- """
- financial_addresses: NotRequired[
- "FinancialAccountService.UpdateParamsFeaturesFinancialAddresses"
- ]
- """
- Contains Features that add FinancialAddresses to the FinancialAccount.
- """
- inbound_transfers: NotRequired[
- "FinancialAccountService.UpdateParamsFeaturesInboundTransfers"
- ]
- """
- Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
- """
- intra_stripe_flows: NotRequired[
- "FinancialAccountService.UpdateParamsFeaturesIntraStripeFlows"
- ]
- """
- Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
- """
- outbound_payments: NotRequired[
- "FinancialAccountService.UpdateParamsFeaturesOutboundPayments"
- ]
- """
- Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
- """
- outbound_transfers: NotRequired[
- "FinancialAccountService.UpdateParamsFeaturesOutboundTransfers"
- ]
- """
- Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
- """
-
- class UpdateParamsFeaturesCardIssuing(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsFeaturesDepositInsurance(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsFeaturesFinancialAddresses(TypedDict):
- aba: NotRequired[
- "FinancialAccountService.UpdateParamsFeaturesFinancialAddressesAba"
- ]
- """
- Adds an ABA FinancialAddress to the FinancialAccount.
- """
-
- class UpdateParamsFeaturesFinancialAddressesAba(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsFeaturesInboundTransfers(TypedDict):
- ach: NotRequired[
- "FinancialAccountService.UpdateParamsFeaturesInboundTransfersAch"
- ]
- """
- Enables ACH Debits via the InboundTransfers API.
- """
-
- class UpdateParamsFeaturesInboundTransfersAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsFeaturesIntraStripeFlows(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsFeaturesOutboundPayments(TypedDict):
- ach: NotRequired[
- "FinancialAccountService.UpdateParamsFeaturesOutboundPaymentsAch"
- ]
- """
- Enables ACH transfers via the OutboundPayments API.
- """
- us_domestic_wire: NotRequired[
- "FinancialAccountService.UpdateParamsFeaturesOutboundPaymentsUsDomesticWire"
- ]
- """
- Enables US domestic wire transfers via the OutboundPayments API.
- """
-
- class UpdateParamsFeaturesOutboundPaymentsAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsFeaturesOutboundPaymentsUsDomesticWire(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsFeaturesOutboundTransfers(TypedDict):
- ach: NotRequired[
- "FinancialAccountService.UpdateParamsFeaturesOutboundTransfersAch"
- ]
- """
- Enables ACH transfers via the OutboundTransfers API.
- """
- us_domestic_wire: NotRequired[
- "FinancialAccountService.UpdateParamsFeaturesOutboundTransfersUsDomesticWire"
- ]
- """
- Enables US domestic wire transfers via the OutboundTransfers API.
- """
-
- class UpdateParamsFeaturesOutboundTransfersAch(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsFeaturesOutboundTransfersUsDomesticWire(TypedDict):
- requested: bool
- """
- Whether the FinancialAccount should have the Feature.
- """
-
- class UpdateParamsForwardingSettings(TypedDict):
- financial_account: NotRequired[str]
- """
- The financial_account id
- """
- payment_method: NotRequired[str]
- """
- The payment_method or bank account id. This needs to be a verified bank account.
- """
- type: Literal["financial_account", "payment_method"]
- """
- The type of the bank account provided. This can be either "financial_account" or "payment_method"
- """
-
- class UpdateParamsPlatformRestrictions(TypedDict):
- inbound_flows: NotRequired[Literal["restricted", "unrestricted"]]
- """
- Restricts all inbound money movement.
- """
- outbound_flows: NotRequired[Literal["restricted", "unrestricted"]]
- """
- Restricts all outbound money movement.
- """
-
def list(
self,
- params: Optional["FinancialAccountService.ListParams"] = None,
+ params: Optional["FinancialAccountListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[FinancialAccount]:
"""
@@ -490,7 +55,7 @@ def list(
async def list_async(
self,
- params: Optional["FinancialAccountService.ListParams"] = None,
+ params: Optional["FinancialAccountListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[FinancialAccount]:
"""
@@ -509,7 +74,7 @@ async def list_async(
def create(
self,
- params: "FinancialAccountService.CreateParams",
+ params: "FinancialAccountCreateParams",
options: Optional[RequestOptions] = None,
) -> FinancialAccount:
"""
@@ -528,7 +93,7 @@ def create(
async def create_async(
self,
- params: "FinancialAccountService.CreateParams",
+ params: "FinancialAccountCreateParams",
options: Optional[RequestOptions] = None,
) -> FinancialAccount:
"""
@@ -548,7 +113,7 @@ async def create_async(
def retrieve(
self,
financial_account: str,
- params: Optional["FinancialAccountService.RetrieveParams"] = None,
+ params: Optional["FinancialAccountRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> FinancialAccount:
"""
@@ -570,7 +135,7 @@ def retrieve(
async def retrieve_async(
self,
financial_account: str,
- params: Optional["FinancialAccountService.RetrieveParams"] = None,
+ params: Optional["FinancialAccountRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> FinancialAccount:
"""
@@ -592,7 +157,7 @@ async def retrieve_async(
def update(
self,
financial_account: str,
- params: Optional["FinancialAccountService.UpdateParams"] = None,
+ params: Optional["FinancialAccountUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> FinancialAccount:
"""
@@ -614,7 +179,7 @@ def update(
async def update_async(
self,
financial_account: str,
- params: Optional["FinancialAccountService.UpdateParams"] = None,
+ params: Optional["FinancialAccountUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> FinancialAccount:
"""
@@ -636,7 +201,7 @@ async def update_async(
def close(
self,
financial_account: str,
- params: Optional["FinancialAccountService.CloseParams"] = None,
+ params: Optional["FinancialAccountCloseParams"] = None,
options: Optional[RequestOptions] = None,
) -> FinancialAccount:
"""
@@ -658,7 +223,7 @@ def close(
async def close_async(
self,
financial_account: str,
- params: Optional["FinancialAccountService.CloseParams"] = None,
+ params: Optional["FinancialAccountCloseParams"] = None,
options: Optional[RequestOptions] = None,
) -> FinancialAccount:
"""
diff --git a/stripe/treasury/_inbound_transfer.py b/stripe/treasury/_inbound_transfer.py
index 53475455f..2c06ec5fb 100644
--- a/stripe/treasury/_inbound_transfer.py
+++ b/stripe/treasury/_inbound_transfer.py
@@ -4,22 +4,35 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._test_helpers import APIResourceTestHelpers
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- Type,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Dict, Optional, cast, overload
+from typing_extensions import Literal, Type, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._mandate import Mandate
+ from stripe.params.treasury._inbound_transfer_cancel_params import (
+ InboundTransferCancelParams,
+ )
+ from stripe.params.treasury._inbound_transfer_create_params import (
+ InboundTransferCreateParams,
+ )
+ from stripe.params.treasury._inbound_transfer_fail_params import (
+ InboundTransferFailParams,
+ )
+ from stripe.params.treasury._inbound_transfer_list_params import (
+ InboundTransferListParams,
+ )
+ from stripe.params.treasury._inbound_transfer_retrieve_params import (
+ InboundTransferRetrieveParams,
+ )
+ from stripe.params.treasury._inbound_transfer_return_inbound_transfer_params import (
+ InboundTransferReturnInboundTransferParams,
+ )
+ from stripe.params.treasury._inbound_transfer_succeed_params import (
+ InboundTransferSucceedParams,
+ )
from stripe.treasury._transaction import Transaction
@@ -161,126 +174,6 @@ class StatusTransitions(StripeObject):
Timestamp describing when an InboundTransfer changed status to `succeeded`.
"""
- class CancelParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(RequestOptions):
- amount: int
- """
- Amount (in cents) to be transferred.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- The FinancialAccount to send funds to.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- origin_payment_method: str
- """
- The origin payment method to be debited for the InboundTransfer.
- """
- statement_descriptor: NotRequired[str]
- """
- The complete description that appears on your customers' statements. Maximum 10 characters.
- """
-
- class FailParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- failure_details: NotRequired[
- "InboundTransfer.FailParamsFailureDetails"
- ]
- """
- Details about a failed InboundTransfer.
- """
-
- class FailParamsFailureDetails(TypedDict):
- code: NotRequired[
- Literal[
- "account_closed",
- "account_frozen",
- "bank_account_restricted",
- "bank_ownership_changed",
- "debit_not_authorized",
- "incorrect_account_holder_address",
- "incorrect_account_holder_name",
- "incorrect_account_holder_tax_id",
- "insufficient_funds",
- "invalid_account_number",
- "invalid_currency",
- "no_account",
- "other",
- ]
- ]
- """
- Reason for the failure.
- """
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- Returns objects associated with this FinancialAccount.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["canceled", "failed", "processing", "succeeded"]
- ]
- """
- Only return InboundTransfers that have the given status: `processing`, `succeeded`, `failed` or `canceled`.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ReturnInboundTransferParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class SucceedParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount: int
"""
Amount (in cents) transferred.
@@ -360,7 +253,7 @@ class SucceedParams(RequestOptions):
def _cls_cancel(
cls,
inbound_transfer: str,
- **params: Unpack["InboundTransfer.CancelParams"],
+ **params: Unpack["InboundTransferCancelParams"],
) -> "InboundTransfer":
"""
Cancels an InboundTransfer.
@@ -379,7 +272,7 @@ def _cls_cancel(
@overload
@staticmethod
def cancel(
- inbound_transfer: str, **params: Unpack["InboundTransfer.CancelParams"]
+ inbound_transfer: str, **params: Unpack["InboundTransferCancelParams"]
) -> "InboundTransfer":
"""
Cancels an InboundTransfer.
@@ -388,7 +281,7 @@ def cancel(
@overload
def cancel(
- self, **params: Unpack["InboundTransfer.CancelParams"]
+ self, **params: Unpack["InboundTransferCancelParams"]
) -> "InboundTransfer":
"""
Cancels an InboundTransfer.
@@ -397,7 +290,7 @@ def cancel(
@class_method_variant("_cls_cancel")
def cancel( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["InboundTransfer.CancelParams"]
+ self, **params: Unpack["InboundTransferCancelParams"]
) -> "InboundTransfer":
"""
Cancels an InboundTransfer.
@@ -417,7 +310,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_cancel_async(
cls,
inbound_transfer: str,
- **params: Unpack["InboundTransfer.CancelParams"],
+ **params: Unpack["InboundTransferCancelParams"],
) -> "InboundTransfer":
"""
Cancels an InboundTransfer.
@@ -436,7 +329,7 @@ async def _cls_cancel_async(
@overload
@staticmethod
async def cancel_async(
- inbound_transfer: str, **params: Unpack["InboundTransfer.CancelParams"]
+ inbound_transfer: str, **params: Unpack["InboundTransferCancelParams"]
) -> "InboundTransfer":
"""
Cancels an InboundTransfer.
@@ -445,7 +338,7 @@ async def cancel_async(
@overload
async def cancel_async(
- self, **params: Unpack["InboundTransfer.CancelParams"]
+ self, **params: Unpack["InboundTransferCancelParams"]
) -> "InboundTransfer":
"""
Cancels an InboundTransfer.
@@ -454,7 +347,7 @@ async def cancel_async(
@class_method_variant("_cls_cancel_async")
async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["InboundTransfer.CancelParams"]
+ self, **params: Unpack["InboundTransferCancelParams"]
) -> "InboundTransfer":
"""
Cancels an InboundTransfer.
@@ -472,7 +365,7 @@ async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def create(
- cls, **params: Unpack["InboundTransfer.CreateParams"]
+ cls, **params: Unpack["InboundTransferCreateParams"]
) -> "InboundTransfer":
"""
Creates an InboundTransfer.
@@ -488,7 +381,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["InboundTransfer.CreateParams"]
+ cls, **params: Unpack["InboundTransferCreateParams"]
) -> "InboundTransfer":
"""
Creates an InboundTransfer.
@@ -504,7 +397,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["InboundTransfer.ListParams"]
+ cls, **params: Unpack["InboundTransferListParams"]
) -> ListObject["InboundTransfer"]:
"""
Returns a list of InboundTransfers sent from the specified FinancialAccount.
@@ -524,7 +417,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["InboundTransfer.ListParams"]
+ cls, **params: Unpack["InboundTransferListParams"]
) -> ListObject["InboundTransfer"]:
"""
Returns a list of InboundTransfers sent from the specified FinancialAccount.
@@ -544,7 +437,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["InboundTransfer.RetrieveParams"]
+ cls, id: str, **params: Unpack["InboundTransferRetrieveParams"]
) -> "InboundTransfer":
"""
Retrieves the details of an existing InboundTransfer.
@@ -555,7 +448,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["InboundTransfer.RetrieveParams"]
+ cls, id: str, **params: Unpack["InboundTransferRetrieveParams"]
) -> "InboundTransfer":
"""
Retrieves the details of an existing InboundTransfer.
@@ -569,7 +462,7 @@ class TestHelpers(APIResourceTestHelpers["InboundTransfer"]):
@classmethod
def _cls_fail(
- cls, id: str, **params: Unpack["InboundTransfer.FailParams"]
+ 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.
@@ -588,7 +481,7 @@ def _cls_fail(
@overload
@staticmethod
def fail(
- id: str, **params: Unpack["InboundTransfer.FailParams"]
+ 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.
@@ -597,7 +490,7 @@ def fail(
@overload
def fail(
- self, **params: Unpack["InboundTransfer.FailParams"]
+ self, **params: Unpack["InboundTransferFailParams"]
) -> "InboundTransfer":
"""
Transitions a test mode created InboundTransfer to the failed status. The InboundTransfer must already be in the processing state.
@@ -606,7 +499,7 @@ def fail(
@class_method_variant("_cls_fail")
def fail( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["InboundTransfer.FailParams"]
+ self, **params: Unpack["InboundTransferFailParams"]
) -> "InboundTransfer":
"""
Transitions a test mode created InboundTransfer to the failed status. The InboundTransfer must already be in the processing state.
@@ -624,7 +517,7 @@ def fail( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_fail_async(
- cls, id: str, **params: Unpack["InboundTransfer.FailParams"]
+ 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.
@@ -643,7 +536,7 @@ async def _cls_fail_async(
@overload
@staticmethod
async def fail_async(
- id: str, **params: Unpack["InboundTransfer.FailParams"]
+ 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.
@@ -652,7 +545,7 @@ async def fail_async(
@overload
async def fail_async(
- self, **params: Unpack["InboundTransfer.FailParams"]
+ self, **params: Unpack["InboundTransferFailParams"]
) -> "InboundTransfer":
"""
Transitions a test mode created InboundTransfer to the failed status. The InboundTransfer must already be in the processing state.
@@ -661,7 +554,7 @@ async def fail_async(
@class_method_variant("_cls_fail_async")
async def fail_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["InboundTransfer.FailParams"]
+ self, **params: Unpack["InboundTransferFailParams"]
) -> "InboundTransfer":
"""
Transitions a test mode created InboundTransfer to the failed status. The InboundTransfer must already be in the processing state.
@@ -681,7 +574,7 @@ async def fail_async( # pyright: ignore[reportGeneralTypeIssues]
def _cls_return_inbound_transfer(
cls,
id: str,
- **params: Unpack["InboundTransfer.ReturnInboundTransferParams"],
+ **params: Unpack["InboundTransferReturnInboundTransferParams"],
) -> "InboundTransfer":
"""
Marks the test mode InboundTransfer object as returned and links the InboundTransfer to a ReceivedDebit. The InboundTransfer must already be in the succeeded state.
@@ -701,7 +594,7 @@ def _cls_return_inbound_transfer(
@staticmethod
def return_inbound_transfer(
id: str,
- **params: Unpack["InboundTransfer.ReturnInboundTransferParams"],
+ **params: Unpack["InboundTransferReturnInboundTransferParams"],
) -> "InboundTransfer":
"""
Marks the test mode InboundTransfer object as returned and links the InboundTransfer to a ReceivedDebit. The InboundTransfer must already be in the succeeded state.
@@ -711,7 +604,7 @@ def return_inbound_transfer(
@overload
def return_inbound_transfer(
self,
- **params: Unpack["InboundTransfer.ReturnInboundTransferParams"],
+ **params: Unpack["InboundTransferReturnInboundTransferParams"],
) -> "InboundTransfer":
"""
Marks the test mode InboundTransfer object as returned and links the InboundTransfer to a ReceivedDebit. The InboundTransfer must already be in the succeeded state.
@@ -721,7 +614,7 @@ def return_inbound_transfer(
@class_method_variant("_cls_return_inbound_transfer")
def return_inbound_transfer( # pyright: ignore[reportGeneralTypeIssues]
self,
- **params: Unpack["InboundTransfer.ReturnInboundTransferParams"],
+ **params: Unpack["InboundTransferReturnInboundTransferParams"],
) -> "InboundTransfer":
"""
Marks the test mode InboundTransfer object as returned and links the InboundTransfer to a ReceivedDebit. The InboundTransfer must already be in the succeeded state.
@@ -741,7 +634,7 @@ def return_inbound_transfer( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_return_inbound_transfer_async(
cls,
id: str,
- **params: Unpack["InboundTransfer.ReturnInboundTransferParams"],
+ **params: Unpack["InboundTransferReturnInboundTransferParams"],
) -> "InboundTransfer":
"""
Marks the test mode InboundTransfer object as returned and links the InboundTransfer to a ReceivedDebit. The InboundTransfer must already be in the succeeded state.
@@ -761,7 +654,7 @@ async def _cls_return_inbound_transfer_async(
@staticmethod
async def return_inbound_transfer_async(
id: str,
- **params: Unpack["InboundTransfer.ReturnInboundTransferParams"],
+ **params: Unpack["InboundTransferReturnInboundTransferParams"],
) -> "InboundTransfer":
"""
Marks the test mode InboundTransfer object as returned and links the InboundTransfer to a ReceivedDebit. The InboundTransfer must already be in the succeeded state.
@@ -771,7 +664,7 @@ async def return_inbound_transfer_async(
@overload
async def return_inbound_transfer_async(
self,
- **params: Unpack["InboundTransfer.ReturnInboundTransferParams"],
+ **params: Unpack["InboundTransferReturnInboundTransferParams"],
) -> "InboundTransfer":
"""
Marks the test mode InboundTransfer object as returned and links the InboundTransfer to a ReceivedDebit. The InboundTransfer must already be in the succeeded state.
@@ -781,7 +674,7 @@ async def return_inbound_transfer_async(
@class_method_variant("_cls_return_inbound_transfer_async")
async def return_inbound_transfer_async( # pyright: ignore[reportGeneralTypeIssues]
self,
- **params: Unpack["InboundTransfer.ReturnInboundTransferParams"],
+ **params: Unpack["InboundTransferReturnInboundTransferParams"],
) -> "InboundTransfer":
"""
Marks the test mode InboundTransfer object as returned and links the InboundTransfer to a ReceivedDebit. The InboundTransfer must already be in the succeeded state.
@@ -799,7 +692,7 @@ async def return_inbound_transfer_async( # pyright: ignore[reportGeneralTypeIss
@classmethod
def _cls_succeed(
- cls, id: str, **params: Unpack["InboundTransfer.SucceedParams"]
+ 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.
@@ -818,7 +711,7 @@ def _cls_succeed(
@overload
@staticmethod
def succeed(
- id: str, **params: Unpack["InboundTransfer.SucceedParams"]
+ 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.
@@ -827,7 +720,7 @@ def succeed(
@overload
def succeed(
- self, **params: Unpack["InboundTransfer.SucceedParams"]
+ self, **params: Unpack["InboundTransferSucceedParams"]
) -> "InboundTransfer":
"""
Transitions a test mode created InboundTransfer to the succeeded status. The InboundTransfer must already be in the processing state.
@@ -836,7 +729,7 @@ def succeed(
@class_method_variant("_cls_succeed")
def succeed( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["InboundTransfer.SucceedParams"]
+ self, **params: Unpack["InboundTransferSucceedParams"]
) -> "InboundTransfer":
"""
Transitions a test mode created InboundTransfer to the succeeded status. The InboundTransfer must already be in the processing state.
@@ -854,7 +747,7 @@ def succeed( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_succeed_async(
- cls, id: str, **params: Unpack["InboundTransfer.SucceedParams"]
+ 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.
@@ -873,7 +766,7 @@ async def _cls_succeed_async(
@overload
@staticmethod
async def succeed_async(
- id: str, **params: Unpack["InboundTransfer.SucceedParams"]
+ 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.
@@ -882,7 +775,7 @@ async def succeed_async(
@overload
async def succeed_async(
- self, **params: Unpack["InboundTransfer.SucceedParams"]
+ self, **params: Unpack["InboundTransferSucceedParams"]
) -> "InboundTransfer":
"""
Transitions a test mode created InboundTransfer to the succeeded status. The InboundTransfer must already be in the processing state.
@@ -891,7 +784,7 @@ async def succeed_async(
@class_method_variant("_cls_succeed_async")
async def succeed_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["InboundTransfer.SucceedParams"]
+ self, **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 3625c9d4c..171fd7f34 100644
--- a/stripe/treasury/_inbound_transfer_service.py
+++ b/stripe/treasury/_inbound_transfer_service.py
@@ -5,88 +5,28 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.treasury._inbound_transfer import InboundTransfer
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.treasury._inbound_transfer_cancel_params import (
+ InboundTransferCancelParams,
+ )
+ from stripe.params.treasury._inbound_transfer_create_params import (
+ InboundTransferCreateParams,
+ )
+ from stripe.params.treasury._inbound_transfer_list_params import (
+ InboundTransferListParams,
+ )
+ from stripe.params.treasury._inbound_transfer_retrieve_params import (
+ InboundTransferRetrieveParams,
+ )
-class InboundTransferService(StripeService):
- class CancelParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(TypedDict):
- amount: int
- """
- Amount (in cents) to be transferred.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- The FinancialAccount to send funds to.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- origin_payment_method: str
- """
- The origin payment method to be debited for the InboundTransfer.
- """
- statement_descriptor: NotRequired[str]
- """
- The complete description that appears on your customers' statements. Maximum 10 characters.
- """
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- Returns objects associated with this FinancialAccount.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["canceled", "failed", "processing", "succeeded"]
- ]
- """
- Only return InboundTransfers that have the given status: `processing`, `succeeded`, `failed` or `canceled`.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class InboundTransferService(StripeService):
def list(
self,
- params: "InboundTransferService.ListParams",
+ params: "InboundTransferListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[InboundTransfer]:
"""
@@ -105,7 +45,7 @@ def list(
async def list_async(
self,
- params: "InboundTransferService.ListParams",
+ params: "InboundTransferListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[InboundTransfer]:
"""
@@ -124,7 +64,7 @@ async def list_async(
def create(
self,
- params: "InboundTransferService.CreateParams",
+ params: "InboundTransferCreateParams",
options: Optional[RequestOptions] = None,
) -> InboundTransfer:
"""
@@ -143,7 +83,7 @@ def create(
async def create_async(
self,
- params: "InboundTransferService.CreateParams",
+ params: "InboundTransferCreateParams",
options: Optional[RequestOptions] = None,
) -> InboundTransfer:
"""
@@ -163,7 +103,7 @@ async def create_async(
def retrieve(
self,
id: str,
- params: Optional["InboundTransferService.RetrieveParams"] = None,
+ params: Optional["InboundTransferRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> InboundTransfer:
"""
@@ -185,7 +125,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["InboundTransferService.RetrieveParams"] = None,
+ params: Optional["InboundTransferRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> InboundTransfer:
"""
@@ -207,7 +147,7 @@ async def retrieve_async(
def cancel(
self,
inbound_transfer: str,
- params: Optional["InboundTransferService.CancelParams"] = None,
+ params: Optional["InboundTransferCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> InboundTransfer:
"""
@@ -229,7 +169,7 @@ def cancel(
async def cancel_async(
self,
inbound_transfer: str,
- params: Optional["InboundTransferService.CancelParams"] = None,
+ params: Optional["InboundTransferCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> InboundTransfer:
"""
diff --git a/stripe/treasury/_outbound_payment.py b/stripe/treasury/_outbound_payment.py
index 38cb5d51e..08a834cdc 100644
--- a/stripe/treasury/_outbound_payment.py
+++ b/stripe/treasury/_outbound_payment.py
@@ -4,22 +4,38 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._test_helpers import APIResourceTestHelpers
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- Type,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Dict, Optional, cast, overload
+from typing_extensions import Literal, Type, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._mandate import Mandate
+ from stripe.params.treasury._outbound_payment_cancel_params import (
+ OutboundPaymentCancelParams,
+ )
+ from stripe.params.treasury._outbound_payment_create_params import (
+ OutboundPaymentCreateParams,
+ )
+ from stripe.params.treasury._outbound_payment_fail_params import (
+ OutboundPaymentFailParams,
+ )
+ from stripe.params.treasury._outbound_payment_list_params import (
+ OutboundPaymentListParams,
+ )
+ from stripe.params.treasury._outbound_payment_post_params import (
+ OutboundPaymentPostParams,
+ )
+ from stripe.params.treasury._outbound_payment_retrieve_params import (
+ OutboundPaymentRetrieveParams,
+ )
+ from stripe.params.treasury._outbound_payment_return_outbound_payment_params import (
+ OutboundPaymentReturnOutboundPaymentParams,
+ )
+ from stripe.params.treasury._outbound_payment_update_params import (
+ OutboundPaymentUpdateParams,
+ )
from stripe.treasury._transaction import Transaction
@@ -213,337 +229,6 @@ class UsDomesticWire(StripeObject):
us_domestic_wire: Optional[UsDomesticWire]
_inner_class_types = {"ach": Ach, "us_domestic_wire": UsDomesticWire}
- class CancelParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(RequestOptions):
- amount: int
- """
- Amount (in cents) to be transferred.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: NotRequired[str]
- """
- ID of the customer to whom the OutboundPayment is sent. Must match the Customer attached to the `destination_payment_method` passed in.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- destination_payment_method: NotRequired[str]
- """
- The PaymentMethod to use as the payment instrument for the OutboundPayment. Exclusive with `destination_payment_method_data`.
- """
- destination_payment_method_data: NotRequired[
- "OutboundPayment.CreateParamsDestinationPaymentMethodData"
- ]
- """
- Hash used to generate the PaymentMethod to be used for this OutboundPayment. Exclusive with `destination_payment_method`.
- """
- destination_payment_method_options: NotRequired[
- "OutboundPayment.CreateParamsDestinationPaymentMethodOptions"
- ]
- """
- Payment method-specific configuration for this OutboundPayment.
- """
- end_user_details: NotRequired[
- "OutboundPayment.CreateParamsEndUserDetails"
- ]
- """
- End user details.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- The FinancialAccount to pull funds from.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- statement_descriptor: NotRequired[str]
- """
- The description that appears on the receiving end for this OutboundPayment (for example, bank statement for external bank transfer). Maximum 10 characters for `ach` payments, 140 characters for `us_domestic_wire` payments, or 500 characters for `stripe` network transfers. The default value is "payment".
- """
-
- class CreateParamsDestinationPaymentMethodData(TypedDict):
- billing_details: NotRequired[
- "OutboundPayment.CreateParamsDestinationPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- financial_account: NotRequired[str]
- """
- Required if type is set to `financial_account`. The FinancialAccount ID to send funds to.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- type: Literal["financial_account", "us_bank_account"]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "OutboundPayment.CreateParamsDestinationPaymentMethodDataUsBankAccount"
- ]
- """
- Required hash if type is set to `us_bank_account`.
- """
-
- class CreateParamsDestinationPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|OutboundPayment.CreateParamsDestinationPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
-
- class CreateParamsDestinationPaymentMethodDataBillingDetailsAddress(
- TypedDict,
- ):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsDestinationPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class CreateParamsDestinationPaymentMethodOptions(TypedDict):
- us_bank_account: NotRequired[
- "Literal['']|OutboundPayment.CreateParamsDestinationPaymentMethodOptionsUsBankAccount"
- ]
- """
- Optional fields for `us_bank_account`.
- """
-
- class CreateParamsDestinationPaymentMethodOptionsUsBankAccount(TypedDict):
- network: NotRequired[Literal["ach", "us_domestic_wire"]]
- """
- Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
- """
-
- class CreateParamsEndUserDetails(TypedDict):
- ip_address: NotRequired[str]
- """
- IP address of the user initiating the OutboundPayment. Must be supplied if `present` is set to `true`.
- """
- present: bool
- """
- `True` if the OutboundPayment creation request is being made on behalf of an end user by a platform. Otherwise, `false`.
- """
-
- class FailParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(RequestOptions):
- created: NotRequired["OutboundPayment.ListParamsCreated|int"]
- """
- Only return OutboundPayments that were created during the given date interval.
- """
- customer: NotRequired[str]
- """
- Only return OutboundPayments sent to this customer.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- Returns objects associated with this FinancialAccount.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["canceled", "failed", "posted", "processing", "returned"]
- ]
- """
- Only return OutboundPayments that have the given status: `processing`, `failed`, `posted`, `returned`, or `canceled`.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class PostParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ReturnOutboundPaymentParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- returned_details: NotRequired[
- "OutboundPayment.ReturnOutboundPaymentParamsReturnedDetails"
- ]
- """
- Optional hash to set the return code.
- """
-
- class ReturnOutboundPaymentParamsReturnedDetails(TypedDict):
- code: NotRequired[
- Literal[
- "account_closed",
- "account_frozen",
- "bank_account_restricted",
- "bank_ownership_changed",
- "declined",
- "incorrect_account_holder_name",
- "invalid_account_number",
- "invalid_currency",
- "no_account",
- "other",
- ]
- ]
- """
- The return code to be set on the OutboundPayment object.
- """
-
- class UpdateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- tracking_details: "OutboundPayment.UpdateParamsTrackingDetails"
- """
- Details about network-specific tracking information.
- """
-
- class UpdateParamsTrackingDetails(TypedDict):
- ach: NotRequired["OutboundPayment.UpdateParamsTrackingDetailsAch"]
- """
- ACH network tracking details.
- """
- type: Literal["ach", "us_domestic_wire"]
- """
- The US bank account network used to send funds.
- """
- us_domestic_wire: NotRequired[
- "OutboundPayment.UpdateParamsTrackingDetailsUsDomesticWire"
- ]
- """
- US domestic wire network tracking details.
- """
-
- class UpdateParamsTrackingDetailsAch(TypedDict):
- trace_id: str
- """
- ACH trace ID for funds sent over the `ach` network.
- """
-
- class UpdateParamsTrackingDetailsUsDomesticWire(TypedDict):
- chips: NotRequired[str]
- """
- CHIPS System Sequence Number (SSN) for funds sent over the `us_domestic_wire` network.
- """
- imad: NotRequired[str]
- """
- IMAD for funds sent over the `us_domestic_wire` network.
- """
- omad: NotRequired[str]
- """
- OMAD for funds sent over the `us_domestic_wire` network.
- """
-
amount: int
"""
Amount (in cents) transferred.
@@ -634,7 +319,7 @@ class UpdateParamsTrackingDetailsUsDomesticWire(TypedDict):
@classmethod
def _cls_cancel(
- cls, id: str, **params: Unpack["OutboundPayment.CancelParams"]
+ cls, id: str, **params: Unpack["OutboundPaymentCancelParams"]
) -> "OutboundPayment":
"""
Cancel an OutboundPayment.
@@ -653,7 +338,7 @@ def _cls_cancel(
@overload
@staticmethod
def cancel(
- id: str, **params: Unpack["OutboundPayment.CancelParams"]
+ id: str, **params: Unpack["OutboundPaymentCancelParams"]
) -> "OutboundPayment":
"""
Cancel an OutboundPayment.
@@ -662,7 +347,7 @@ def cancel(
@overload
def cancel(
- self, **params: Unpack["OutboundPayment.CancelParams"]
+ self, **params: Unpack["OutboundPaymentCancelParams"]
) -> "OutboundPayment":
"""
Cancel an OutboundPayment.
@@ -671,7 +356,7 @@ def cancel(
@class_method_variant("_cls_cancel")
def cancel( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundPayment.CancelParams"]
+ self, **params: Unpack["OutboundPaymentCancelParams"]
) -> "OutboundPayment":
"""
Cancel an OutboundPayment.
@@ -689,7 +374,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_cancel_async(
- cls, id: str, **params: Unpack["OutboundPayment.CancelParams"]
+ cls, id: str, **params: Unpack["OutboundPaymentCancelParams"]
) -> "OutboundPayment":
"""
Cancel an OutboundPayment.
@@ -708,7 +393,7 @@ async def _cls_cancel_async(
@overload
@staticmethod
async def cancel_async(
- id: str, **params: Unpack["OutboundPayment.CancelParams"]
+ id: str, **params: Unpack["OutboundPaymentCancelParams"]
) -> "OutboundPayment":
"""
Cancel an OutboundPayment.
@@ -717,7 +402,7 @@ async def cancel_async(
@overload
async def cancel_async(
- self, **params: Unpack["OutboundPayment.CancelParams"]
+ self, **params: Unpack["OutboundPaymentCancelParams"]
) -> "OutboundPayment":
"""
Cancel an OutboundPayment.
@@ -726,7 +411,7 @@ async def cancel_async(
@class_method_variant("_cls_cancel_async")
async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundPayment.CancelParams"]
+ self, **params: Unpack["OutboundPaymentCancelParams"]
) -> "OutboundPayment":
"""
Cancel an OutboundPayment.
@@ -744,7 +429,7 @@ async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def create(
- cls, **params: Unpack["OutboundPayment.CreateParams"]
+ cls, **params: Unpack["OutboundPaymentCreateParams"]
) -> "OutboundPayment":
"""
Creates an OutboundPayment.
@@ -760,7 +445,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["OutboundPayment.CreateParams"]
+ cls, **params: Unpack["OutboundPaymentCreateParams"]
) -> "OutboundPayment":
"""
Creates an OutboundPayment.
@@ -776,7 +461,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["OutboundPayment.ListParams"]
+ cls, **params: Unpack["OutboundPaymentListParams"]
) -> ListObject["OutboundPayment"]:
"""
Returns a list of OutboundPayments sent from the specified FinancialAccount.
@@ -796,7 +481,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["OutboundPayment.ListParams"]
+ cls, **params: Unpack["OutboundPaymentListParams"]
) -> ListObject["OutboundPayment"]:
"""
Returns a list of OutboundPayments sent from the specified FinancialAccount.
@@ -816,7 +501,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["OutboundPayment.RetrieveParams"]
+ cls, id: str, **params: Unpack["OutboundPaymentRetrieveParams"]
) -> "OutboundPayment":
"""
Retrieves the details of an existing OutboundPayment by passing the unique OutboundPayment ID from either the OutboundPayment creation request or OutboundPayment list.
@@ -827,7 +512,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["OutboundPayment.RetrieveParams"]
+ cls, id: str, **params: Unpack["OutboundPaymentRetrieveParams"]
) -> "OutboundPayment":
"""
Retrieves the details of an existing OutboundPayment by passing the unique OutboundPayment ID from either the OutboundPayment creation request or OutboundPayment list.
@@ -841,7 +526,7 @@ class TestHelpers(APIResourceTestHelpers["OutboundPayment"]):
@classmethod
def _cls_fail(
- cls, id: str, **params: Unpack["OutboundPayment.FailParams"]
+ 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.
@@ -860,7 +545,7 @@ def _cls_fail(
@overload
@staticmethod
def fail(
- id: str, **params: Unpack["OutboundPayment.FailParams"]
+ 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.
@@ -869,7 +554,7 @@ def fail(
@overload
def fail(
- self, **params: Unpack["OutboundPayment.FailParams"]
+ self, **params: Unpack["OutboundPaymentFailParams"]
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the failed status. The OutboundPayment must already be in the processing state.
@@ -878,7 +563,7 @@ def fail(
@class_method_variant("_cls_fail")
def fail( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundPayment.FailParams"]
+ self, **params: Unpack["OutboundPaymentFailParams"]
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the failed status. The OutboundPayment must already be in the processing state.
@@ -896,7 +581,7 @@ def fail( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_fail_async(
- cls, id: str, **params: Unpack["OutboundPayment.FailParams"]
+ 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.
@@ -915,7 +600,7 @@ async def _cls_fail_async(
@overload
@staticmethod
async def fail_async(
- id: str, **params: Unpack["OutboundPayment.FailParams"]
+ 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.
@@ -924,7 +609,7 @@ async def fail_async(
@overload
async def fail_async(
- self, **params: Unpack["OutboundPayment.FailParams"]
+ self, **params: Unpack["OutboundPaymentFailParams"]
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the failed status. The OutboundPayment must already be in the processing state.
@@ -933,7 +618,7 @@ async def fail_async(
@class_method_variant("_cls_fail_async")
async def fail_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundPayment.FailParams"]
+ self, **params: Unpack["OutboundPaymentFailParams"]
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the failed status. The OutboundPayment must already be in the processing state.
@@ -951,7 +636,7 @@ async def fail_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def _cls_post(
- cls, id: str, **params: Unpack["OutboundPayment.PostParams"]
+ 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.
@@ -970,7 +655,7 @@ def _cls_post(
@overload
@staticmethod
def post(
- id: str, **params: Unpack["OutboundPayment.PostParams"]
+ 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.
@@ -979,7 +664,7 @@ def post(
@overload
def post(
- self, **params: Unpack["OutboundPayment.PostParams"]
+ self, **params: Unpack["OutboundPaymentPostParams"]
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the posted status. The OutboundPayment must already be in the processing state.
@@ -988,7 +673,7 @@ def post(
@class_method_variant("_cls_post")
def post( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundPayment.PostParams"]
+ self, **params: Unpack["OutboundPaymentPostParams"]
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the posted status. The OutboundPayment must already be in the processing state.
@@ -1006,7 +691,7 @@ def post( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_post_async(
- cls, id: str, **params: Unpack["OutboundPayment.PostParams"]
+ 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.
@@ -1025,7 +710,7 @@ async def _cls_post_async(
@overload
@staticmethod
async def post_async(
- id: str, **params: Unpack["OutboundPayment.PostParams"]
+ 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.
@@ -1034,7 +719,7 @@ async def post_async(
@overload
async def post_async(
- self, **params: Unpack["OutboundPayment.PostParams"]
+ self, **params: Unpack["OutboundPaymentPostParams"]
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the posted status. The OutboundPayment must already be in the processing state.
@@ -1043,7 +728,7 @@ async def post_async(
@class_method_variant("_cls_post_async")
async def post_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundPayment.PostParams"]
+ self, **params: Unpack["OutboundPaymentPostParams"]
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the posted status. The OutboundPayment must already be in the processing state.
@@ -1063,7 +748,7 @@ async def post_async( # pyright: ignore[reportGeneralTypeIssues]
def _cls_return_outbound_payment(
cls,
id: str,
- **params: Unpack["OutboundPayment.ReturnOutboundPaymentParams"],
+ **params: Unpack["OutboundPaymentReturnOutboundPaymentParams"],
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the returned status. The OutboundPayment must already be in the processing state.
@@ -1083,7 +768,7 @@ def _cls_return_outbound_payment(
@staticmethod
def return_outbound_payment(
id: str,
- **params: Unpack["OutboundPayment.ReturnOutboundPaymentParams"],
+ **params: Unpack["OutboundPaymentReturnOutboundPaymentParams"],
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the returned status. The OutboundPayment must already be in the processing state.
@@ -1093,7 +778,7 @@ def return_outbound_payment(
@overload
def return_outbound_payment(
self,
- **params: Unpack["OutboundPayment.ReturnOutboundPaymentParams"],
+ **params: Unpack["OutboundPaymentReturnOutboundPaymentParams"],
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the returned status. The OutboundPayment must already be in the processing state.
@@ -1103,7 +788,7 @@ def return_outbound_payment(
@class_method_variant("_cls_return_outbound_payment")
def return_outbound_payment( # pyright: ignore[reportGeneralTypeIssues]
self,
- **params: Unpack["OutboundPayment.ReturnOutboundPaymentParams"],
+ **params: Unpack["OutboundPaymentReturnOutboundPaymentParams"],
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the returned status. The OutboundPayment must already be in the processing state.
@@ -1123,7 +808,7 @@ def return_outbound_payment( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_return_outbound_payment_async(
cls,
id: str,
- **params: Unpack["OutboundPayment.ReturnOutboundPaymentParams"],
+ **params: Unpack["OutboundPaymentReturnOutboundPaymentParams"],
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the returned status. The OutboundPayment must already be in the processing state.
@@ -1143,7 +828,7 @@ async def _cls_return_outbound_payment_async(
@staticmethod
async def return_outbound_payment_async(
id: str,
- **params: Unpack["OutboundPayment.ReturnOutboundPaymentParams"],
+ **params: Unpack["OutboundPaymentReturnOutboundPaymentParams"],
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the returned status. The OutboundPayment must already be in the processing state.
@@ -1153,7 +838,7 @@ async def return_outbound_payment_async(
@overload
async def return_outbound_payment_async(
self,
- **params: Unpack["OutboundPayment.ReturnOutboundPaymentParams"],
+ **params: Unpack["OutboundPaymentReturnOutboundPaymentParams"],
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the returned status. The OutboundPayment must already be in the processing state.
@@ -1163,7 +848,7 @@ async def return_outbound_payment_async(
@class_method_variant("_cls_return_outbound_payment_async")
async def return_outbound_payment_async( # pyright: ignore[reportGeneralTypeIssues]
self,
- **params: Unpack["OutboundPayment.ReturnOutboundPaymentParams"],
+ **params: Unpack["OutboundPaymentReturnOutboundPaymentParams"],
) -> "OutboundPayment":
"""
Transitions a test mode created OutboundPayment to the returned status. The OutboundPayment must already be in the processing state.
@@ -1181,7 +866,7 @@ async def return_outbound_payment_async( # pyright: ignore[reportGeneralTypeIss
@classmethod
def _cls_update(
- cls, id: str, **params: Unpack["OutboundPayment.UpdateParams"]
+ 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.
@@ -1200,7 +885,7 @@ def _cls_update(
@overload
@staticmethod
def update(
- id: str, **params: Unpack["OutboundPayment.UpdateParams"]
+ 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.
@@ -1209,7 +894,7 @@ def update(
@overload
def update(
- self, **params: Unpack["OutboundPayment.UpdateParams"]
+ self, **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.
@@ -1218,7 +903,7 @@ def update(
@class_method_variant("_cls_update")
def update( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundPayment.UpdateParams"]
+ self, **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.
@@ -1236,7 +921,7 @@ def update( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
async def _cls_update_async(
- cls, id: str, **params: Unpack["OutboundPayment.UpdateParams"]
+ 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.
@@ -1255,7 +940,7 @@ async def _cls_update_async(
@overload
@staticmethod
async def update_async(
- id: str, **params: Unpack["OutboundPayment.UpdateParams"]
+ 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.
@@ -1264,7 +949,7 @@ async def update_async(
@overload
async def update_async(
- self, **params: Unpack["OutboundPayment.UpdateParams"]
+ self, **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.
@@ -1273,7 +958,7 @@ async def update_async(
@class_method_variant("_cls_update_async")
async def update_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundPayment.UpdateParams"]
+ self, **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 b1fd1085e..678808057 100644
--- a/stripe/treasury/_outbound_payment_service.py
+++ b/stripe/treasury/_outbound_payment_service.py
@@ -5,256 +5,28 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.treasury._outbound_payment import OutboundPayment
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.treasury._outbound_payment_cancel_params import (
+ OutboundPaymentCancelParams,
+ )
+ from stripe.params.treasury._outbound_payment_create_params import (
+ OutboundPaymentCreateParams,
+ )
+ from stripe.params.treasury._outbound_payment_list_params import (
+ OutboundPaymentListParams,
+ )
+ from stripe.params.treasury._outbound_payment_retrieve_params import (
+ OutboundPaymentRetrieveParams,
+ )
class OutboundPaymentService(StripeService):
- class CancelParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(TypedDict):
- amount: int
- """
- Amount (in cents) to be transferred.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- customer: NotRequired[str]
- """
- ID of the customer to whom the OutboundPayment is sent. Must match the Customer attached to the `destination_payment_method` passed in.
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- destination_payment_method: NotRequired[str]
- """
- The PaymentMethod to use as the payment instrument for the OutboundPayment. Exclusive with `destination_payment_method_data`.
- """
- destination_payment_method_data: NotRequired[
- "OutboundPaymentService.CreateParamsDestinationPaymentMethodData"
- ]
- """
- Hash used to generate the PaymentMethod to be used for this OutboundPayment. Exclusive with `destination_payment_method`.
- """
- destination_payment_method_options: NotRequired[
- "OutboundPaymentService.CreateParamsDestinationPaymentMethodOptions"
- ]
- """
- Payment method-specific configuration for this OutboundPayment.
- """
- end_user_details: NotRequired[
- "OutboundPaymentService.CreateParamsEndUserDetails"
- ]
- """
- End user details.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- The FinancialAccount to pull funds from.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- statement_descriptor: NotRequired[str]
- """
- The description that appears on the receiving end for this OutboundPayment (for example, bank statement for external bank transfer). Maximum 10 characters for `ach` payments, 140 characters for `us_domestic_wire` payments, or 500 characters for `stripe` network transfers. The default value is "payment".
- """
-
- class CreateParamsDestinationPaymentMethodData(TypedDict):
- billing_details: NotRequired[
- "OutboundPaymentService.CreateParamsDestinationPaymentMethodDataBillingDetails"
- ]
- """
- Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
- """
- financial_account: NotRequired[str]
- """
- Required if type is set to `financial_account`. The FinancialAccount ID to send funds to.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- type: Literal["financial_account", "us_bank_account"]
- """
- The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
- """
- us_bank_account: NotRequired[
- "OutboundPaymentService.CreateParamsDestinationPaymentMethodDataUsBankAccount"
- ]
- """
- Required hash if type is set to `us_bank_account`.
- """
-
- class CreateParamsDestinationPaymentMethodDataBillingDetails(TypedDict):
- address: NotRequired[
- "Literal['']|OutboundPaymentService.CreateParamsDestinationPaymentMethodDataBillingDetailsAddress"
- ]
- """
- Billing address.
- """
- email: NotRequired["Literal['']|str"]
- """
- Email address.
- """
- name: NotRequired["Literal['']|str"]
- """
- Full name.
- """
- phone: NotRequired["Literal['']|str"]
- """
- Billing phone number (including extension).
- """
-
- class CreateParamsDestinationPaymentMethodDataBillingDetailsAddress(
- TypedDict,
- ):
- city: NotRequired[str]
- """
- City, district, suburb, town, or village.
- """
- country: NotRequired[str]
- """
- Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
- """
- line1: NotRequired[str]
- """
- Address line 1, such as the street, PO Box, or company name.
- """
- line2: NotRequired[str]
- """
- Address line 2, such as the apartment, suite, unit, or building.
- """
- postal_code: NotRequired[str]
- """
- ZIP or postal code.
- """
- state: NotRequired[str]
- """
- State, county, province, or region.
- """
-
- class CreateParamsDestinationPaymentMethodDataUsBankAccount(TypedDict):
- account_holder_type: NotRequired[Literal["company", "individual"]]
- """
- Account holder type: individual or company.
- """
- account_number: NotRequired[str]
- """
- Account number of the bank account.
- """
- account_type: NotRequired[Literal["checking", "savings"]]
- """
- Account type: checkings or savings. Defaults to checking if omitted.
- """
- financial_connections_account: NotRequired[str]
- """
- The ID of a Financial Connections Account to use as a payment method.
- """
- routing_number: NotRequired[str]
- """
- Routing number of the bank account.
- """
-
- class CreateParamsDestinationPaymentMethodOptions(TypedDict):
- us_bank_account: NotRequired[
- "Literal['']|OutboundPaymentService.CreateParamsDestinationPaymentMethodOptionsUsBankAccount"
- ]
- """
- Optional fields for `us_bank_account`.
- """
-
- class CreateParamsDestinationPaymentMethodOptionsUsBankAccount(TypedDict):
- network: NotRequired[Literal["ach", "us_domestic_wire"]]
- """
- Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
- """
-
- class CreateParamsEndUserDetails(TypedDict):
- ip_address: NotRequired[str]
- """
- IP address of the user initiating the OutboundPayment. Must be supplied if `present` is set to `true`.
- """
- present: bool
- """
- `True` if the OutboundPayment creation request is being made on behalf of an end user by a platform. Otherwise, `false`.
- """
-
- class ListParams(TypedDict):
- created: NotRequired["OutboundPaymentService.ListParamsCreated|int"]
- """
- Only return OutboundPayments that were created during the given date interval.
- """
- customer: NotRequired[str]
- """
- Only return OutboundPayments sent to this customer.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- Returns objects associated with this FinancialAccount.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["canceled", "failed", "posted", "processing", "returned"]
- ]
- """
- Only return OutboundPayments that have the given status: `processing`, `failed`, `posted`, `returned`, or `canceled`.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
def list(
self,
- params: "OutboundPaymentService.ListParams",
+ params: "OutboundPaymentListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[OutboundPayment]:
"""
@@ -273,7 +45,7 @@ def list(
async def list_async(
self,
- params: "OutboundPaymentService.ListParams",
+ params: "OutboundPaymentListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[OutboundPayment]:
"""
@@ -292,7 +64,7 @@ async def list_async(
def create(
self,
- params: "OutboundPaymentService.CreateParams",
+ params: "OutboundPaymentCreateParams",
options: Optional[RequestOptions] = None,
) -> OutboundPayment:
"""
@@ -311,7 +83,7 @@ def create(
async def create_async(
self,
- params: "OutboundPaymentService.CreateParams",
+ params: "OutboundPaymentCreateParams",
options: Optional[RequestOptions] = None,
) -> OutboundPayment:
"""
@@ -331,7 +103,7 @@ async def create_async(
def retrieve(
self,
id: str,
- params: Optional["OutboundPaymentService.RetrieveParams"] = None,
+ params: Optional["OutboundPaymentRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundPayment:
"""
@@ -353,7 +125,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["OutboundPaymentService.RetrieveParams"] = None,
+ params: Optional["OutboundPaymentRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundPayment:
"""
@@ -375,7 +147,7 @@ async def retrieve_async(
def cancel(
self,
id: str,
- params: Optional["OutboundPaymentService.CancelParams"] = None,
+ params: Optional["OutboundPaymentCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundPayment:
"""
@@ -397,7 +169,7 @@ def cancel(
async def cancel_async(
self,
id: str,
- params: Optional["OutboundPaymentService.CancelParams"] = None,
+ params: Optional["OutboundPaymentCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundPayment:
"""
diff --git a/stripe/treasury/_outbound_transfer.py b/stripe/treasury/_outbound_transfer.py
index 8d9327590..fe71e6fa4 100644
--- a/stripe/treasury/_outbound_transfer.py
+++ b/stripe/treasury/_outbound_transfer.py
@@ -4,22 +4,38 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._test_helpers import APIResourceTestHelpers
from stripe._util import class_method_variant, sanitize_id
-from typing import ClassVar, Dict, List, Optional, cast, overload
-from typing_extensions import (
- Literal,
- NotRequired,
- Type,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Dict, Optional, cast, overload
+from typing_extensions import Literal, Type, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._mandate import Mandate
+ from stripe.params.treasury._outbound_transfer_cancel_params import (
+ OutboundTransferCancelParams,
+ )
+ from stripe.params.treasury._outbound_transfer_create_params import (
+ OutboundTransferCreateParams,
+ )
+ from stripe.params.treasury._outbound_transfer_fail_params import (
+ OutboundTransferFailParams,
+ )
+ from stripe.params.treasury._outbound_transfer_list_params import (
+ OutboundTransferListParams,
+ )
+ from stripe.params.treasury._outbound_transfer_post_params import (
+ OutboundTransferPostParams,
+ )
+ from stripe.params.treasury._outbound_transfer_retrieve_params import (
+ OutboundTransferRetrieveParams,
+ )
+ from stripe.params.treasury._outbound_transfer_return_outbound_transfer_params import (
+ OutboundTransferReturnOutboundTransferParams,
+ )
+ from stripe.params.treasury._outbound_transfer_update_params import (
+ OutboundTransferUpdateParams,
+ )
from stripe.treasury._transaction import Transaction
@@ -203,205 +219,6 @@ class UsDomesticWire(StripeObject):
us_domestic_wire: Optional[UsDomesticWire]
_inner_class_types = {"ach": Ach, "us_domestic_wire": UsDomesticWire}
- class CancelParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(RequestOptions):
- amount: int
- """
- Amount (in cents) to be transferred.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- destination_payment_method: NotRequired[str]
- """
- The PaymentMethod to use as the payment instrument for the OutboundTransfer.
- """
- destination_payment_method_data: NotRequired[
- "OutboundTransfer.CreateParamsDestinationPaymentMethodData"
- ]
- """
- Hash used to generate the PaymentMethod to be used for this OutboundTransfer. Exclusive with `destination_payment_method`.
- """
- destination_payment_method_options: NotRequired[
- "OutboundTransfer.CreateParamsDestinationPaymentMethodOptions"
- ]
- """
- Hash describing payment method configuration details.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- The FinancialAccount to pull funds from.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- statement_descriptor: NotRequired[str]
- """
- Statement descriptor to be shown on the receiving end of an OutboundTransfer. Maximum 10 characters for `ach` transfers or 140 characters for `us_domestic_wire` transfers. The default value is "transfer".
- """
-
- class CreateParamsDestinationPaymentMethodData(TypedDict):
- financial_account: NotRequired[str]
- """
- Required if type is set to `financial_account`. The FinancialAccount ID to send funds to.
- """
- type: Literal["financial_account"]
- """
- The type of the destination.
- """
-
- class CreateParamsDestinationPaymentMethodOptions(TypedDict):
- us_bank_account: NotRequired[
- "Literal['']|OutboundTransfer.CreateParamsDestinationPaymentMethodOptionsUsBankAccount"
- ]
- """
- Optional fields for `us_bank_account`.
- """
-
- class CreateParamsDestinationPaymentMethodOptionsUsBankAccount(TypedDict):
- network: NotRequired[Literal["ach", "us_domestic_wire"]]
- """
- Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
- """
-
- class FailParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- Returns objects associated with this FinancialAccount.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["canceled", "failed", "posted", "processing", "returned"]
- ]
- """
- Only return OutboundTransfers that have the given status: `processing`, `canceled`, `failed`, `posted`, or `returned`.
- """
-
- class PostParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class ReturnOutboundTransferParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- returned_details: NotRequired[
- "OutboundTransfer.ReturnOutboundTransferParamsReturnedDetails"
- ]
- """
- Details about a returned OutboundTransfer.
- """
-
- class ReturnOutboundTransferParamsReturnedDetails(TypedDict):
- code: NotRequired[
- Literal[
- "account_closed",
- "account_frozen",
- "bank_account_restricted",
- "bank_ownership_changed",
- "declined",
- "incorrect_account_holder_name",
- "invalid_account_number",
- "invalid_currency",
- "no_account",
- "other",
- ]
- ]
- """
- Reason for the return.
- """
-
- class UpdateParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- tracking_details: "OutboundTransfer.UpdateParamsTrackingDetails"
- """
- Details about network-specific tracking information.
- """
-
- class UpdateParamsTrackingDetails(TypedDict):
- ach: NotRequired["OutboundTransfer.UpdateParamsTrackingDetailsAch"]
- """
- ACH network tracking details.
- """
- type: Literal["ach", "us_domestic_wire"]
- """
- The US bank account network used to send funds.
- """
- us_domestic_wire: NotRequired[
- "OutboundTransfer.UpdateParamsTrackingDetailsUsDomesticWire"
- ]
- """
- US domestic wire network tracking details.
- """
-
- class UpdateParamsTrackingDetailsAch(TypedDict):
- trace_id: str
- """
- ACH trace ID for funds sent over the `ach` network.
- """
-
- class UpdateParamsTrackingDetailsUsDomesticWire(TypedDict):
- chips: NotRequired[str]
- """
- CHIPS System Sequence Number (SSN) for funds sent over the `us_domestic_wire` network.
- """
- imad: NotRequired[str]
- """
- IMAD for funds sent over the `us_domestic_wire` network.
- """
- omad: NotRequired[str]
- """
- OMAD for funds sent over the `us_domestic_wire` network.
- """
-
amount: int
"""
Amount (in cents) transferred.
@@ -481,7 +298,7 @@ class UpdateParamsTrackingDetailsUsDomesticWire(TypedDict):
def _cls_cancel(
cls,
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.CancelParams"],
+ **params: Unpack["OutboundTransferCancelParams"],
) -> "OutboundTransfer":
"""
An OutboundTransfer can be canceled if the funds have not yet been paid out.
@@ -501,7 +318,7 @@ def _cls_cancel(
@staticmethod
def cancel(
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.CancelParams"],
+ **params: Unpack["OutboundTransferCancelParams"],
) -> "OutboundTransfer":
"""
An OutboundTransfer can be canceled if the funds have not yet been paid out.
@@ -510,7 +327,7 @@ def cancel(
@overload
def cancel(
- self, **params: Unpack["OutboundTransfer.CancelParams"]
+ self, **params: Unpack["OutboundTransferCancelParams"]
) -> "OutboundTransfer":
"""
An OutboundTransfer can be canceled if the funds have not yet been paid out.
@@ -519,7 +336,7 @@ def cancel(
@class_method_variant("_cls_cancel")
def cancel( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundTransfer.CancelParams"]
+ self, **params: Unpack["OutboundTransferCancelParams"]
) -> "OutboundTransfer":
"""
An OutboundTransfer can be canceled if the funds have not yet been paid out.
@@ -539,7 +356,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_cancel_async(
cls,
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.CancelParams"],
+ **params: Unpack["OutboundTransferCancelParams"],
) -> "OutboundTransfer":
"""
An OutboundTransfer can be canceled if the funds have not yet been paid out.
@@ -559,7 +376,7 @@ async def _cls_cancel_async(
@staticmethod
async def cancel_async(
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.CancelParams"],
+ **params: Unpack["OutboundTransferCancelParams"],
) -> "OutboundTransfer":
"""
An OutboundTransfer can be canceled if the funds have not yet been paid out.
@@ -568,7 +385,7 @@ async def cancel_async(
@overload
async def cancel_async(
- self, **params: Unpack["OutboundTransfer.CancelParams"]
+ self, **params: Unpack["OutboundTransferCancelParams"]
) -> "OutboundTransfer":
"""
An OutboundTransfer can be canceled if the funds have not yet been paid out.
@@ -577,7 +394,7 @@ async def cancel_async(
@class_method_variant("_cls_cancel_async")
async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundTransfer.CancelParams"]
+ self, **params: Unpack["OutboundTransferCancelParams"]
) -> "OutboundTransfer":
"""
An OutboundTransfer can be canceled if the funds have not yet been paid out.
@@ -595,7 +412,7 @@ async def cancel_async( # pyright: ignore[reportGeneralTypeIssues]
@classmethod
def create(
- cls, **params: Unpack["OutboundTransfer.CreateParams"]
+ cls, **params: Unpack["OutboundTransferCreateParams"]
) -> "OutboundTransfer":
"""
Creates an OutboundTransfer.
@@ -611,7 +428,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["OutboundTransfer.CreateParams"]
+ cls, **params: Unpack["OutboundTransferCreateParams"]
) -> "OutboundTransfer":
"""
Creates an OutboundTransfer.
@@ -627,7 +444,7 @@ async def create_async(
@classmethod
def list(
- cls, **params: Unpack["OutboundTransfer.ListParams"]
+ cls, **params: Unpack["OutboundTransferListParams"]
) -> ListObject["OutboundTransfer"]:
"""
Returns a list of OutboundTransfers sent from the specified FinancialAccount.
@@ -647,7 +464,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["OutboundTransfer.ListParams"]
+ cls, **params: Unpack["OutboundTransferListParams"]
) -> ListObject["OutboundTransfer"]:
"""
Returns a list of OutboundTransfers sent from the specified FinancialAccount.
@@ -667,7 +484,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["OutboundTransfer.RetrieveParams"]
+ cls, id: str, **params: Unpack["OutboundTransferRetrieveParams"]
) -> "OutboundTransfer":
"""
Retrieves the details of an existing OutboundTransfer by passing the unique OutboundTransfer ID from either the OutboundTransfer creation request or OutboundTransfer list.
@@ -678,7 +495,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["OutboundTransfer.RetrieveParams"]
+ cls, id: str, **params: Unpack["OutboundTransferRetrieveParams"]
) -> "OutboundTransfer":
"""
Retrieves the details of an existing OutboundTransfer by passing the unique OutboundTransfer ID from either the OutboundTransfer creation request or OutboundTransfer list.
@@ -694,7 +511,7 @@ class TestHelpers(APIResourceTestHelpers["OutboundTransfer"]):
def _cls_fail(
cls,
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.FailParams"],
+ **params: Unpack["OutboundTransferFailParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the failed status. The OutboundTransfer must already be in the processing state.
@@ -714,7 +531,7 @@ def _cls_fail(
@staticmethod
def fail(
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.FailParams"],
+ **params: Unpack["OutboundTransferFailParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the failed status. The OutboundTransfer must already be in the processing state.
@@ -723,7 +540,7 @@ def fail(
@overload
def fail(
- self, **params: Unpack["OutboundTransfer.FailParams"]
+ self, **params: Unpack["OutboundTransferFailParams"]
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the failed status. The OutboundTransfer must already be in the processing state.
@@ -732,7 +549,7 @@ def fail(
@class_method_variant("_cls_fail")
def fail( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundTransfer.FailParams"]
+ self, **params: Unpack["OutboundTransferFailParams"]
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the failed status. The OutboundTransfer must already be in the processing state.
@@ -752,7 +569,7 @@ def fail( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_fail_async(
cls,
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.FailParams"],
+ **params: Unpack["OutboundTransferFailParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the failed status. The OutboundTransfer must already be in the processing state.
@@ -772,7 +589,7 @@ async def _cls_fail_async(
@staticmethod
async def fail_async(
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.FailParams"],
+ **params: Unpack["OutboundTransferFailParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the failed status. The OutboundTransfer must already be in the processing state.
@@ -781,7 +598,7 @@ async def fail_async(
@overload
async def fail_async(
- self, **params: Unpack["OutboundTransfer.FailParams"]
+ self, **params: Unpack["OutboundTransferFailParams"]
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the failed status. The OutboundTransfer must already be in the processing state.
@@ -790,7 +607,7 @@ async def fail_async(
@class_method_variant("_cls_fail_async")
async def fail_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundTransfer.FailParams"]
+ self, **params: Unpack["OutboundTransferFailParams"]
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the failed status. The OutboundTransfer must already be in the processing state.
@@ -810,7 +627,7 @@ async def fail_async( # pyright: ignore[reportGeneralTypeIssues]
def _cls_post(
cls,
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.PostParams"],
+ **params: Unpack["OutboundTransferPostParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the posted status. The OutboundTransfer must already be in the processing state.
@@ -830,7 +647,7 @@ def _cls_post(
@staticmethod
def post(
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.PostParams"],
+ **params: Unpack["OutboundTransferPostParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the posted status. The OutboundTransfer must already be in the processing state.
@@ -839,7 +656,7 @@ def post(
@overload
def post(
- self, **params: Unpack["OutboundTransfer.PostParams"]
+ self, **params: Unpack["OutboundTransferPostParams"]
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the posted status. The OutboundTransfer must already be in the processing state.
@@ -848,7 +665,7 @@ def post(
@class_method_variant("_cls_post")
def post( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundTransfer.PostParams"]
+ self, **params: Unpack["OutboundTransferPostParams"]
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the posted status. The OutboundTransfer must already be in the processing state.
@@ -868,7 +685,7 @@ def post( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_post_async(
cls,
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.PostParams"],
+ **params: Unpack["OutboundTransferPostParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the posted status. The OutboundTransfer must already be in the processing state.
@@ -888,7 +705,7 @@ async def _cls_post_async(
@staticmethod
async def post_async(
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.PostParams"],
+ **params: Unpack["OutboundTransferPostParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the posted status. The OutboundTransfer must already be in the processing state.
@@ -897,7 +714,7 @@ async def post_async(
@overload
async def post_async(
- self, **params: Unpack["OutboundTransfer.PostParams"]
+ self, **params: Unpack["OutboundTransferPostParams"]
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the posted status. The OutboundTransfer must already be in the processing state.
@@ -906,7 +723,7 @@ async def post_async(
@class_method_variant("_cls_post_async")
async def post_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundTransfer.PostParams"]
+ self, **params: Unpack["OutboundTransferPostParams"]
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the posted status. The OutboundTransfer must already be in the processing state.
@@ -926,7 +743,7 @@ async def post_async( # pyright: ignore[reportGeneralTypeIssues]
def _cls_return_outbound_transfer(
cls,
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.ReturnOutboundTransferParams"],
+ **params: Unpack["OutboundTransferReturnOutboundTransferParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the returned status. The OutboundTransfer must already be in the processing state.
@@ -946,7 +763,7 @@ def _cls_return_outbound_transfer(
@staticmethod
def return_outbound_transfer(
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.ReturnOutboundTransferParams"],
+ **params: Unpack["OutboundTransferReturnOutboundTransferParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the returned status. The OutboundTransfer must already be in the processing state.
@@ -956,7 +773,7 @@ def return_outbound_transfer(
@overload
def return_outbound_transfer(
self,
- **params: Unpack["OutboundTransfer.ReturnOutboundTransferParams"],
+ **params: Unpack["OutboundTransferReturnOutboundTransferParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the returned status. The OutboundTransfer must already be in the processing state.
@@ -966,7 +783,7 @@ def return_outbound_transfer(
@class_method_variant("_cls_return_outbound_transfer")
def return_outbound_transfer( # pyright: ignore[reportGeneralTypeIssues]
self,
- **params: Unpack["OutboundTransfer.ReturnOutboundTransferParams"],
+ **params: Unpack["OutboundTransferReturnOutboundTransferParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the returned status. The OutboundTransfer must already be in the processing state.
@@ -986,7 +803,7 @@ def return_outbound_transfer( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_return_outbound_transfer_async(
cls,
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.ReturnOutboundTransferParams"],
+ **params: Unpack["OutboundTransferReturnOutboundTransferParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the returned status. The OutboundTransfer must already be in the processing state.
@@ -1006,7 +823,7 @@ async def _cls_return_outbound_transfer_async(
@staticmethod
async def return_outbound_transfer_async(
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.ReturnOutboundTransferParams"],
+ **params: Unpack["OutboundTransferReturnOutboundTransferParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the returned status. The OutboundTransfer must already be in the processing state.
@@ -1016,7 +833,7 @@ async def return_outbound_transfer_async(
@overload
async def return_outbound_transfer_async(
self,
- **params: Unpack["OutboundTransfer.ReturnOutboundTransferParams"],
+ **params: Unpack["OutboundTransferReturnOutboundTransferParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the returned status. The OutboundTransfer must already be in the processing state.
@@ -1026,7 +843,7 @@ async def return_outbound_transfer_async(
@class_method_variant("_cls_return_outbound_transfer_async")
async def return_outbound_transfer_async( # pyright: ignore[reportGeneralTypeIssues]
self,
- **params: Unpack["OutboundTransfer.ReturnOutboundTransferParams"],
+ **params: Unpack["OutboundTransferReturnOutboundTransferParams"],
) -> "OutboundTransfer":
"""
Transitions a test mode created OutboundTransfer to the returned status. The OutboundTransfer must already be in the processing state.
@@ -1046,7 +863,7 @@ async def return_outbound_transfer_async( # pyright: ignore[reportGeneralTypeIs
def _cls_update(
cls,
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.UpdateParams"],
+ **params: Unpack["OutboundTransferUpdateParams"],
) -> "OutboundTransfer":
"""
Updates a test mode created OutboundTransfer with tracking details. The OutboundTransfer must not be cancelable, and cannot be in the canceled or failed states.
@@ -1066,7 +883,7 @@ def _cls_update(
@staticmethod
def update(
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.UpdateParams"],
+ **params: Unpack["OutboundTransferUpdateParams"],
) -> "OutboundTransfer":
"""
Updates a test mode created OutboundTransfer with tracking details. The OutboundTransfer must not be cancelable, and cannot be in the canceled or failed states.
@@ -1075,7 +892,7 @@ def update(
@overload
def update(
- self, **params: Unpack["OutboundTransfer.UpdateParams"]
+ self, **params: Unpack["OutboundTransferUpdateParams"]
) -> "OutboundTransfer":
"""
Updates a test mode created OutboundTransfer with tracking details. The OutboundTransfer must not be cancelable, and cannot be in the canceled or failed states.
@@ -1084,7 +901,7 @@ def update(
@class_method_variant("_cls_update")
def update( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundTransfer.UpdateParams"]
+ self, **params: Unpack["OutboundTransferUpdateParams"]
) -> "OutboundTransfer":
"""
Updates a test mode created OutboundTransfer with tracking details. The OutboundTransfer must not be cancelable, and cannot be in the canceled or failed states.
@@ -1104,7 +921,7 @@ def update( # pyright: ignore[reportGeneralTypeIssues]
async def _cls_update_async(
cls,
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.UpdateParams"],
+ **params: Unpack["OutboundTransferUpdateParams"],
) -> "OutboundTransfer":
"""
Updates a test mode created OutboundTransfer with tracking details. The OutboundTransfer must not be cancelable, and cannot be in the canceled or failed states.
@@ -1124,7 +941,7 @@ async def _cls_update_async(
@staticmethod
async def update_async(
outbound_transfer: str,
- **params: Unpack["OutboundTransfer.UpdateParams"],
+ **params: Unpack["OutboundTransferUpdateParams"],
) -> "OutboundTransfer":
"""
Updates a test mode created OutboundTransfer with tracking details. The OutboundTransfer must not be cancelable, and cannot be in the canceled or failed states.
@@ -1133,7 +950,7 @@ async def update_async(
@overload
async def update_async(
- self, **params: Unpack["OutboundTransfer.UpdateParams"]
+ self, **params: Unpack["OutboundTransferUpdateParams"]
) -> "OutboundTransfer":
"""
Updates a test mode created OutboundTransfer with tracking details. The OutboundTransfer must not be cancelable, and cannot be in the canceled or failed states.
@@ -1142,7 +959,7 @@ async def update_async(
@class_method_variant("_cls_update_async")
async def update_async( # pyright: ignore[reportGeneralTypeIssues]
- self, **params: Unpack["OutboundTransfer.UpdateParams"]
+ self, **params: Unpack["OutboundTransferUpdateParams"]
) -> "OutboundTransfer":
"""
Updates a test mode created OutboundTransfer with tracking details. The OutboundTransfer must not be cancelable, and cannot be in the canceled or failed states.
diff --git a/stripe/treasury/_outbound_transfer_service.py b/stripe/treasury/_outbound_transfer_service.py
index 82bd9e3f8..86ca497c3 100644
--- a/stripe/treasury/_outbound_transfer_service.py
+++ b/stripe/treasury/_outbound_transfer_service.py
@@ -5,124 +5,28 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.treasury._outbound_transfer import OutboundTransfer
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from stripe.params.treasury._outbound_transfer_cancel_params import (
+ OutboundTransferCancelParams,
+ )
+ from stripe.params.treasury._outbound_transfer_create_params import (
+ OutboundTransferCreateParams,
+ )
+ from stripe.params.treasury._outbound_transfer_list_params import (
+ OutboundTransferListParams,
+ )
+ from stripe.params.treasury._outbound_transfer_retrieve_params import (
+ OutboundTransferRetrieveParams,
+ )
class OutboundTransferService(StripeService):
- class CancelParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
- class CreateParams(TypedDict):
- amount: int
- """
- Amount (in cents) to be transferred.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- destination_payment_method: NotRequired[str]
- """
- The PaymentMethod to use as the payment instrument for the OutboundTransfer.
- """
- destination_payment_method_data: NotRequired[
- "OutboundTransferService.CreateParamsDestinationPaymentMethodData"
- ]
- """
- Hash used to generate the PaymentMethod to be used for this OutboundTransfer. Exclusive with `destination_payment_method`.
- """
- destination_payment_method_options: NotRequired[
- "OutboundTransferService.CreateParamsDestinationPaymentMethodOptions"
- ]
- """
- Hash describing payment method configuration details.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- The FinancialAccount to pull funds from.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
- """
- statement_descriptor: NotRequired[str]
- """
- Statement descriptor to be shown on the receiving end of an OutboundTransfer. Maximum 10 characters for `ach` transfers or 140 characters for `us_domestic_wire` transfers. The default value is "transfer".
- """
-
- class CreateParamsDestinationPaymentMethodData(TypedDict):
- financial_account: NotRequired[str]
- """
- Required if type is set to `financial_account`. The FinancialAccount ID to send funds to.
- """
- type: Literal["financial_account"]
- """
- The type of the destination.
- """
-
- class CreateParamsDestinationPaymentMethodOptions(TypedDict):
- us_bank_account: NotRequired[
- "Literal['']|OutboundTransferService.CreateParamsDestinationPaymentMethodOptionsUsBankAccount"
- ]
- """
- Optional fields for `us_bank_account`.
- """
-
- class CreateParamsDestinationPaymentMethodOptionsUsBankAccount(TypedDict):
- network: NotRequired[Literal["ach", "us_domestic_wire"]]
- """
- Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
- """
-
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- Returns objects associated with this FinancialAccount.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[
- Literal["canceled", "failed", "posted", "processing", "returned"]
- ]
- """
- Only return OutboundTransfers that have the given status: `processing`, `canceled`, `failed`, `posted`, or `returned`.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
def list(
self,
- params: "OutboundTransferService.ListParams",
+ params: "OutboundTransferListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[OutboundTransfer]:
"""
@@ -141,7 +45,7 @@ def list(
async def list_async(
self,
- params: "OutboundTransferService.ListParams",
+ params: "OutboundTransferListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[OutboundTransfer]:
"""
@@ -160,7 +64,7 @@ async def list_async(
def create(
self,
- params: "OutboundTransferService.CreateParams",
+ params: "OutboundTransferCreateParams",
options: Optional[RequestOptions] = None,
) -> OutboundTransfer:
"""
@@ -179,7 +83,7 @@ def create(
async def create_async(
self,
- params: "OutboundTransferService.CreateParams",
+ params: "OutboundTransferCreateParams",
options: Optional[RequestOptions] = None,
) -> OutboundTransfer:
"""
@@ -199,7 +103,7 @@ async def create_async(
def retrieve(
self,
outbound_transfer: str,
- params: Optional["OutboundTransferService.RetrieveParams"] = None,
+ params: Optional["OutboundTransferRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundTransfer:
"""
@@ -221,7 +125,7 @@ def retrieve(
async def retrieve_async(
self,
outbound_transfer: str,
- params: Optional["OutboundTransferService.RetrieveParams"] = None,
+ params: Optional["OutboundTransferRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundTransfer:
"""
@@ -243,7 +147,7 @@ async def retrieve_async(
def cancel(
self,
outbound_transfer: str,
- params: Optional["OutboundTransferService.CancelParams"] = None,
+ params: Optional["OutboundTransferCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundTransfer:
"""
@@ -265,7 +169,7 @@ def cancel(
async def cancel_async(
self,
outbound_transfer: str,
- params: Optional["OutboundTransferService.CancelParams"] = None,
+ params: Optional["OutboundTransferCancelParams"] = None,
options: Optional[RequestOptions] = None,
) -> OutboundTransfer:
"""
diff --git a/stripe/treasury/_received_credit.py b/stripe/treasury/_received_credit.py
index bf2dbf092..3b7863a57 100644
--- a/stripe/treasury/_received_credit.py
+++ b/stripe/treasury/_received_credit.py
@@ -3,21 +3,22 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._test_helpers import APIResourceTestHelpers
-from typing import ClassVar, List, Optional, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- Type,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Optional, cast
+from typing_extensions import Literal, Type, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe._payout import Payout
+ from stripe.params.treasury._received_credit_create_params import (
+ ReceivedCreditCreateParams,
+ )
+ from stripe.params.treasury._received_credit_list_params import (
+ ReceivedCreditListParams,
+ )
+ from stripe.params.treasury._received_credit_retrieve_params import (
+ ReceivedCreditRetrieveParams,
+ )
from stripe.treasury._credit_reversal import CreditReversal
from stripe.treasury._outbound_payment import OutboundPayment
from stripe.treasury._outbound_transfer import OutboundTransfer
@@ -211,112 +212,6 @@ class ReversalDetails(StripeObject):
Set if a ReceivedCredit cannot be reversed.
"""
- class CreateParams(RequestOptions):
- amount: int
- """
- Amount (in cents) to be transferred.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- The FinancialAccount to send funds to.
- """
- initiating_payment_method_details: NotRequired[
- "ReceivedCredit.CreateParamsInitiatingPaymentMethodDetails"
- ]
- """
- Initiating payment method details for the object.
- """
- network: Literal["ach", "us_domestic_wire"]
- """
- Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
- """
-
- class CreateParamsInitiatingPaymentMethodDetails(TypedDict):
- type: Literal["us_bank_account"]
- """
- The source type.
- """
- us_bank_account: NotRequired[
- "ReceivedCredit.CreateParamsInitiatingPaymentMethodDetailsUsBankAccount"
- ]
- """
- Optional fields for `us_bank_account`.
- """
-
- class CreateParamsInitiatingPaymentMethodDetailsUsBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The bank account holder's name.
- """
- account_number: NotRequired[str]
- """
- The bank account number.
- """
- routing_number: NotRequired[str]
- """
- The bank account's routing number.
- """
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- The FinancialAccount that received the funds.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- linked_flows: NotRequired["ReceivedCredit.ListParamsLinkedFlows"]
- """
- Only return ReceivedCredits described by the flow.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["failed", "succeeded"]]
- """
- Only return ReceivedCredits that have the given status: `succeeded` or `failed`.
- """
-
- class ListParamsLinkedFlows(TypedDict):
- source_flow_type: Literal[
- "credit_reversal",
- "other",
- "outbound_payment",
- "outbound_transfer",
- "payout",
- ]
- """
- The source flow type.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount: int
"""
Amount (in cents) transferred.
@@ -385,7 +280,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["ReceivedCredit.ListParams"]
+ cls, **params: Unpack["ReceivedCreditListParams"]
) -> ListObject["ReceivedCredit"]:
"""
Returns a list of ReceivedCredits.
@@ -405,7 +300,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["ReceivedCredit.ListParams"]
+ cls, **params: Unpack["ReceivedCreditListParams"]
) -> ListObject["ReceivedCredit"]:
"""
Returns a list of ReceivedCredits.
@@ -425,7 +320,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["ReceivedCredit.RetrieveParams"]
+ cls, id: str, **params: Unpack["ReceivedCreditRetrieveParams"]
) -> "ReceivedCredit":
"""
Retrieves the details of an existing ReceivedCredit by passing the unique ReceivedCredit ID from the ReceivedCredit list.
@@ -436,7 +331,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["ReceivedCredit.RetrieveParams"]
+ cls, id: str, **params: Unpack["ReceivedCreditRetrieveParams"]
) -> "ReceivedCredit":
"""
Retrieves the details of an existing ReceivedCredit by passing the unique ReceivedCredit ID from the ReceivedCredit list.
@@ -450,7 +345,7 @@ class TestHelpers(APIResourceTestHelpers["ReceivedCredit"]):
@classmethod
def create(
- cls, **params: Unpack["ReceivedCredit.CreateParams"]
+ cls, **params: Unpack["ReceivedCreditCreateParams"]
) -> "ReceivedCredit":
"""
Use this endpoint to simulate a test mode ReceivedCredit initiated by a third party. In live mode, you can't directly create ReceivedCredits initiated by third parties.
@@ -466,7 +361,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["ReceivedCredit.CreateParams"]
+ cls, **params: Unpack["ReceivedCreditCreateParams"]
) -> "ReceivedCredit":
"""
Use this endpoint to simulate a test mode ReceivedCredit initiated by a third party. In live mode, you can't directly create ReceivedCredits initiated by third parties.
diff --git a/stripe/treasury/_received_credit_service.py b/stripe/treasury/_received_credit_service.py
index 4b87cad2a..ab0bea3a2 100644
--- a/stripe/treasury/_received_credit_service.py
+++ b/stripe/treasury/_received_credit_service.py
@@ -5,64 +5,22 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.treasury._received_credit import ReceivedCredit
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.treasury._received_credit_list_params import (
+ ReceivedCreditListParams,
+ )
+ from stripe.params.treasury._received_credit_retrieve_params import (
+ ReceivedCreditRetrieveParams,
+ )
-class ReceivedCreditService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- The FinancialAccount that received the funds.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- linked_flows: NotRequired[
- "ReceivedCreditService.ListParamsLinkedFlows"
- ]
- """
- Only return ReceivedCredits described by the flow.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["failed", "succeeded"]]
- """
- Only return ReceivedCredits that have the given status: `succeeded` or `failed`.
- """
-
- class ListParamsLinkedFlows(TypedDict):
- source_flow_type: Literal[
- "credit_reversal",
- "other",
- "outbound_payment",
- "outbound_transfer",
- "payout",
- ]
- """
- The source flow type.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class ReceivedCreditService(StripeService):
def list(
self,
- params: "ReceivedCreditService.ListParams",
+ params: "ReceivedCreditListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[ReceivedCredit]:
"""
@@ -81,7 +39,7 @@ def list(
async def list_async(
self,
- params: "ReceivedCreditService.ListParams",
+ params: "ReceivedCreditListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[ReceivedCredit]:
"""
@@ -101,7 +59,7 @@ async def list_async(
def retrieve(
self,
id: str,
- params: Optional["ReceivedCreditService.RetrieveParams"] = None,
+ params: Optional["ReceivedCreditRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ReceivedCredit:
"""
@@ -123,7 +81,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["ReceivedCreditService.RetrieveParams"] = None,
+ params: Optional["ReceivedCreditRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ReceivedCredit:
"""
diff --git a/stripe/treasury/_received_debit.py b/stripe/treasury/_received_debit.py
index c0d1360e4..ab84855b5 100644
--- a/stripe/treasury/_received_debit.py
+++ b/stripe/treasury/_received_debit.py
@@ -3,20 +3,21 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
from stripe._test_helpers import APIResourceTestHelpers
-from typing import ClassVar, List, Optional, cast
-from typing_extensions import (
- Literal,
- NotRequired,
- Type,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Optional, cast
+from typing_extensions import Literal, Type, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
+ from stripe.params.treasury._received_debit_create_params import (
+ ReceivedDebitCreateParams,
+ )
+ from stripe.params.treasury._received_debit_list_params import (
+ ReceivedDebitListParams,
+ )
+ from stripe.params.treasury._received_debit_retrieve_params import (
+ ReceivedDebitRetrieveParams,
+ )
from stripe.treasury._transaction import Transaction
@@ -159,96 +160,6 @@ class ReversalDetails(StripeObject):
Set if a ReceivedDebit can't be reversed.
"""
- class CreateParams(RequestOptions):
- amount: int
- """
- Amount (in cents) to be transferred.
- """
- currency: str
- """
- Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
- """
- description: NotRequired[str]
- """
- An arbitrary string attached to the object. Often useful for displaying to users.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- The FinancialAccount to pull funds from.
- """
- initiating_payment_method_details: NotRequired[
- "ReceivedDebit.CreateParamsInitiatingPaymentMethodDetails"
- ]
- """
- Initiating payment method details for the object.
- """
- network: Literal["ach"]
- """
- Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
- """
-
- class CreateParamsInitiatingPaymentMethodDetails(TypedDict):
- type: Literal["us_bank_account"]
- """
- The source type.
- """
- us_bank_account: NotRequired[
- "ReceivedDebit.CreateParamsInitiatingPaymentMethodDetailsUsBankAccount"
- ]
- """
- Optional fields for `us_bank_account`.
- """
-
- class CreateParamsInitiatingPaymentMethodDetailsUsBankAccount(TypedDict):
- account_holder_name: NotRequired[str]
- """
- The bank account holder's name.
- """
- account_number: NotRequired[str]
- """
- The bank account number.
- """
- routing_number: NotRequired[str]
- """
- The bank account's routing number.
- """
-
- class ListParams(RequestOptions):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- The FinancialAccount that funds were pulled from.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["failed", "succeeded"]]
- """
- Only return ReceivedDebits that have the given status: `succeeded` or `failed`.
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount: int
"""
Amount (in cents) transferred.
@@ -318,7 +229,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["ReceivedDebit.ListParams"]
+ cls, **params: Unpack["ReceivedDebitListParams"]
) -> ListObject["ReceivedDebit"]:
"""
Returns a list of ReceivedDebits.
@@ -338,7 +249,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["ReceivedDebit.ListParams"]
+ cls, **params: Unpack["ReceivedDebitListParams"]
) -> ListObject["ReceivedDebit"]:
"""
Returns a list of ReceivedDebits.
@@ -358,7 +269,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["ReceivedDebit.RetrieveParams"]
+ cls, id: str, **params: Unpack["ReceivedDebitRetrieveParams"]
) -> "ReceivedDebit":
"""
Retrieves the details of an existing ReceivedDebit by passing the unique ReceivedDebit ID from the ReceivedDebit list
@@ -369,7 +280,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["ReceivedDebit.RetrieveParams"]
+ cls, id: str, **params: Unpack["ReceivedDebitRetrieveParams"]
) -> "ReceivedDebit":
"""
Retrieves the details of an existing ReceivedDebit by passing the unique ReceivedDebit ID from the ReceivedDebit list
@@ -383,7 +294,7 @@ class TestHelpers(APIResourceTestHelpers["ReceivedDebit"]):
@classmethod
def create(
- cls, **params: Unpack["ReceivedDebit.CreateParams"]
+ cls, **params: Unpack["ReceivedDebitCreateParams"]
) -> "ReceivedDebit":
"""
Use this endpoint to simulate a test mode ReceivedDebit initiated by a third party. In live mode, you can't directly create ReceivedDebits initiated by third parties.
@@ -399,7 +310,7 @@ def create(
@classmethod
async def create_async(
- cls, **params: Unpack["ReceivedDebit.CreateParams"]
+ cls, **params: Unpack["ReceivedDebitCreateParams"]
) -> "ReceivedDebit":
"""
Use this endpoint to simulate a test mode ReceivedDebit initiated by a third party. In live mode, you can't directly create ReceivedDebits initiated by third parties.
diff --git a/stripe/treasury/_received_debit_service.py b/stripe/treasury/_received_debit_service.py
index 93b0bca35..c48f44a03 100644
--- a/stripe/treasury/_received_debit_service.py
+++ b/stripe/treasury/_received_debit_service.py
@@ -5,46 +5,22 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.treasury._received_debit import ReceivedDebit
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.treasury._received_debit_list_params import (
+ ReceivedDebitListParams,
+ )
+ from stripe.params.treasury._received_debit_retrieve_params import (
+ ReceivedDebitRetrieveParams,
+ )
-class ReceivedDebitService(StripeService):
- class ListParams(TypedDict):
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- The FinancialAccount that funds were pulled from.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["failed", "succeeded"]]
- """
- Only return ReceivedDebits that have the given status: `succeeded` or `failed`.
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class ReceivedDebitService(StripeService):
def list(
self,
- params: "ReceivedDebitService.ListParams",
+ params: "ReceivedDebitListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[ReceivedDebit]:
"""
@@ -63,7 +39,7 @@ def list(
async def list_async(
self,
- params: "ReceivedDebitService.ListParams",
+ params: "ReceivedDebitListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[ReceivedDebit]:
"""
@@ -83,7 +59,7 @@ async def list_async(
def retrieve(
self,
id: str,
- params: Optional["ReceivedDebitService.RetrieveParams"] = None,
+ params: Optional["ReceivedDebitRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ReceivedDebit:
"""
@@ -103,7 +79,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["ReceivedDebitService.RetrieveParams"] = None,
+ params: Optional["ReceivedDebitRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> ReceivedDebit:
"""
diff --git a/stripe/treasury/_transaction.py b/stripe/treasury/_transaction.py
index 8652d29f5..3892b1764 100644
--- a/stripe/treasury/_transaction.py
+++ b/stripe/treasury/_transaction.py
@@ -2,19 +2,18 @@
# File generated from our OpenAPI spec
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
-from typing import ClassVar, List, Optional
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Optional
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe.issuing._authorization import Authorization
+ from stripe.params.treasury._transaction_list_params import (
+ TransactionListParams,
+ )
+ from stripe.params.treasury._transaction_retrieve_params import (
+ TransactionRetrieveParams,
+ )
from stripe.treasury._credit_reversal import CreditReversal
from stripe.treasury._debit_reversal import DebitReversal
from stripe.treasury._inbound_transfer import InboundTransfer
@@ -120,96 +119,6 @@ class StatusTransitions(StripeObject):
Timestamp describing when the Transaction changed status to `void`.
"""
- class ListParams(RequestOptions):
- created: NotRequired["Transaction.ListParamsCreated|int"]
- """
- Only return Transactions that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- Returns objects associated with this FinancialAccount.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- order_by: NotRequired[Literal["created", "posted_at"]]
- """
- The results are in reverse chronological order by `created` or `posted_at`. The default is `created`.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["open", "posted", "void"]]
- """
- Only return Transactions that have the given status: `open`, `posted`, or `void`.
- """
- status_transitions: NotRequired[
- "Transaction.ListParamsStatusTransitions"
- ]
- """
- A filter for the `status_transitions.posted_at` timestamp. When using this filter, `status=posted` and `order_by=posted_at` must also be specified.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsStatusTransitions(TypedDict):
- posted_at: NotRequired[
- "Transaction.ListParamsStatusTransitionsPostedAt|int"
- ]
- """
- Returns Transactions with `posted_at` within the specified range.
- """
-
- class ListParamsStatusTransitionsPostedAt(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
amount: int
"""
Amount (in cents) transferred.
@@ -280,7 +189,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["Transaction.ListParams"]
+ cls, **params: Unpack["TransactionListParams"]
) -> ListObject["Transaction"]:
"""
Retrieves a list of Transaction objects.
@@ -300,7 +209,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["Transaction.ListParams"]
+ cls, **params: Unpack["TransactionListParams"]
) -> ListObject["Transaction"]:
"""
Retrieves a list of Transaction objects.
@@ -320,7 +229,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["Transaction.RetrieveParams"]
+ cls, id: str, **params: Unpack["TransactionRetrieveParams"]
) -> "Transaction":
"""
Retrieves the details of an existing Transaction.
@@ -331,7 +240,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["Transaction.RetrieveParams"]
+ cls, id: str, **params: Unpack["TransactionRetrieveParams"]
) -> "Transaction":
"""
Retrieves the details of an existing Transaction.
diff --git a/stripe/treasury/_transaction_entry.py b/stripe/treasury/_transaction_entry.py
index 7fba8ed23..2e4012cb2 100644
--- a/stripe/treasury/_transaction_entry.py
+++ b/stripe/treasury/_transaction_entry.py
@@ -3,19 +3,18 @@
from stripe._expandable_field import ExpandableField
from stripe._list_object import ListObject
from stripe._listable_api_resource import ListableAPIResource
-from stripe._request_options import RequestOptions
from stripe._stripe_object import StripeObject
-from typing import ClassVar, List, Optional
-from typing_extensions import (
- Literal,
- NotRequired,
- TypedDict,
- Unpack,
- TYPE_CHECKING,
-)
+from typing import ClassVar, Optional
+from typing_extensions import Literal, Unpack, TYPE_CHECKING
if TYPE_CHECKING:
from stripe.issuing._authorization import Authorization
+ from stripe.params.treasury._transaction_entry_list_params import (
+ TransactionEntryListParams,
+ )
+ from stripe.params.treasury._transaction_entry_retrieve_params import (
+ TransactionEntryRetrieveParams,
+ )
from stripe.treasury._credit_reversal import CreditReversal
from stripe.treasury._debit_reversal import DebitReversal
from stripe.treasury._inbound_transfer import InboundTransfer
@@ -111,83 +110,6 @@ class FlowDetails(StripeObject):
Type of the flow that created the Transaction. Set to the same value as `flow_type`.
"""
- class ListParams(RequestOptions):
- created: NotRequired["TransactionEntry.ListParamsCreated|int"]
- """
- Only return TransactionEntries that were created during the given date interval.
- """
- effective_at: NotRequired["TransactionEntry.ListParamsEffectiveAt|int"]
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- Returns objects associated with this FinancialAccount.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- order_by: NotRequired[Literal["created", "effective_at"]]
- """
- The results are in reverse chronological order by `created` or `effective_at`. The default is `created`.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- transaction: NotRequired[str]
- """
- Only return TransactionEntries associated with this Transaction.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsEffectiveAt(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(RequestOptions):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
-
balance_impact: BalanceImpact
"""
Change to a FinancialAccount's balance
@@ -274,7 +196,7 @@ class RetrieveParams(RequestOptions):
@classmethod
def list(
- cls, **params: Unpack["TransactionEntry.ListParams"]
+ cls, **params: Unpack["TransactionEntryListParams"]
) -> ListObject["TransactionEntry"]:
"""
Retrieves a list of TransactionEntry objects.
@@ -294,7 +216,7 @@ def list(
@classmethod
async def list_async(
- cls, **params: Unpack["TransactionEntry.ListParams"]
+ cls, **params: Unpack["TransactionEntryListParams"]
) -> ListObject["TransactionEntry"]:
"""
Retrieves a list of TransactionEntry objects.
@@ -314,7 +236,7 @@ async def list_async(
@classmethod
def retrieve(
- cls, id: str, **params: Unpack["TransactionEntry.RetrieveParams"]
+ cls, id: str, **params: Unpack["TransactionEntryRetrieveParams"]
) -> "TransactionEntry":
"""
Retrieves a TransactionEntry object.
@@ -325,7 +247,7 @@ def retrieve(
@classmethod
async def retrieve_async(
- cls, id: str, **params: Unpack["TransactionEntry.RetrieveParams"]
+ cls, id: str, **params: Unpack["TransactionEntryRetrieveParams"]
) -> "TransactionEntry":
"""
Retrieves a TransactionEntry object.
diff --git a/stripe/treasury/_transaction_entry_service.py b/stripe/treasury/_transaction_entry_service.py
index a8f7e12c8..618ebf1c8 100644
--- a/stripe/treasury/_transaction_entry_service.py
+++ b/stripe/treasury/_transaction_entry_service.py
@@ -5,93 +5,22 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.treasury._transaction_entry import TransactionEntry
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.treasury._transaction_entry_list_params import (
+ TransactionEntryListParams,
+ )
+ from stripe.params.treasury._transaction_entry_retrieve_params import (
+ TransactionEntryRetrieveParams,
+ )
-class TransactionEntryService(StripeService):
- class ListParams(TypedDict):
- created: NotRequired["TransactionEntryService.ListParamsCreated|int"]
- """
- Only return TransactionEntries that were created during the given date interval.
- """
- effective_at: NotRequired[
- "TransactionEntryService.ListParamsEffectiveAt|int"
- ]
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- Returns objects associated with this FinancialAccount.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- order_by: NotRequired[Literal["created", "effective_at"]]
- """
- The results are in reverse chronological order by `created` or `effective_at`. The default is `created`.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- transaction: NotRequired[str]
- """
- Only return TransactionEntries associated with this Transaction.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsEffectiveAt(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class TransactionEntryService(StripeService):
def list(
self,
- params: "TransactionEntryService.ListParams",
+ params: "TransactionEntryListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[TransactionEntry]:
"""
@@ -110,7 +39,7 @@ def list(
async def list_async(
self,
- params: "TransactionEntryService.ListParams",
+ params: "TransactionEntryListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[TransactionEntry]:
"""
@@ -130,7 +59,7 @@ async def list_async(
def retrieve(
self,
id: str,
- params: Optional["TransactionEntryService.RetrieveParams"] = None,
+ params: Optional["TransactionEntryRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> TransactionEntry:
"""
@@ -152,7 +81,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["TransactionEntryService.RetrieveParams"] = None,
+ params: Optional["TransactionEntryRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> TransactionEntry:
"""
diff --git a/stripe/treasury/_transaction_service.py b/stripe/treasury/_transaction_service.py
index 7d416987d..465054c1b 100644
--- a/stripe/treasury/_transaction_service.py
+++ b/stripe/treasury/_transaction_service.py
@@ -5,104 +5,22 @@
from stripe._stripe_service import StripeService
from stripe._util import sanitize_id
from stripe.treasury._transaction import Transaction
-from typing import List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.treasury._transaction_list_params import (
+ TransactionListParams,
+ )
+ from stripe.params.treasury._transaction_retrieve_params import (
+ TransactionRetrieveParams,
+ )
-class TransactionService(StripeService):
- class ListParams(TypedDict):
- created: NotRequired["TransactionService.ListParamsCreated|int"]
- """
- Only return Transactions that were created during the given date interval.
- """
- ending_before: NotRequired[str]
- """
- A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
- """
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
- financial_account: str
- """
- Returns objects associated with this FinancialAccount.
- """
- limit: NotRequired[int]
- """
- A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- """
- order_by: NotRequired[Literal["created", "posted_at"]]
- """
- The results are in reverse chronological order by `created` or `posted_at`. The default is `created`.
- """
- starting_after: NotRequired[str]
- """
- A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
- """
- status: NotRequired[Literal["open", "posted", "void"]]
- """
- Only return Transactions that have the given status: `open`, `posted`, or `void`.
- """
- status_transitions: NotRequired[
- "TransactionService.ListParamsStatusTransitions"
- ]
- """
- A filter for the `status_transitions.posted_at` timestamp. When using this filter, `status=posted` and `order_by=posted_at` must also be specified.
- """
-
- class ListParamsCreated(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class ListParamsStatusTransitions(TypedDict):
- posted_at: NotRequired[
- "TransactionService.ListParamsStatusTransitionsPostedAt|int"
- ]
- """
- Returns Transactions with `posted_at` within the specified range.
- """
-
- class ListParamsStatusTransitionsPostedAt(TypedDict):
- gt: NotRequired[int]
- """
- Minimum value to filter by (exclusive)
- """
- gte: NotRequired[int]
- """
- Minimum value to filter by (inclusive)
- """
- lt: NotRequired[int]
- """
- Maximum value to filter by (exclusive)
- """
- lte: NotRequired[int]
- """
- Maximum value to filter by (inclusive)
- """
-
- class RetrieveParams(TypedDict):
- expand: NotRequired[List[str]]
- """
- Specifies which fields in the response should be expanded.
- """
+class TransactionService(StripeService):
def list(
self,
- params: "TransactionService.ListParams",
+ params: "TransactionListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[Transaction]:
"""
@@ -121,7 +39,7 @@ def list(
async def list_async(
self,
- params: "TransactionService.ListParams",
+ params: "TransactionListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[Transaction]:
"""
@@ -141,7 +59,7 @@ async def list_async(
def retrieve(
self,
id: str,
- params: Optional["TransactionService.RetrieveParams"] = None,
+ params: Optional["TransactionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
@@ -161,7 +79,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["TransactionService.RetrieveParams"] = None,
+ params: Optional["TransactionRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Transaction:
"""
diff --git a/stripe/v2/billing/_meter_event_adjustment_service.py b/stripe/v2/billing/_meter_event_adjustment_service.py
index 80ca24a3b..6394ad3ea 100644
--- a/stripe/v2/billing/_meter_event_adjustment_service.py
+++ b/stripe/v2/billing/_meter_event_adjustment_service.py
@@ -4,33 +4,18 @@
from stripe._stripe_service import StripeService
from stripe.v2.billing._meter_event_adjustment import MeterEventAdjustment
from typing import Optional, cast
-from typing_extensions import Literal, TypedDict
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.v2.billing._meter_event_adjustment_create_params import (
+ MeterEventAdjustmentCreateParams,
+ )
-class MeterEventAdjustmentService(StripeService):
- class CreateParams(TypedDict):
- cancel: "MeterEventAdjustmentService.CreateParamsCancel"
- """
- Specifies which event to cancel.
- """
- event_name: str
- """
- The name of the meter event. Corresponds with the `event_name` field on a meter.
- """
- type: Literal["cancel"]
- """
- Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet.
- """
-
- class CreateParamsCancel(TypedDict):
- identifier: str
- """
- Unique identifier for the event. You can only cancel events within 24 hours of Stripe receiving them.
- """
+class MeterEventAdjustmentService(StripeService):
def create(
self,
- params: "MeterEventAdjustmentService.CreateParams",
+ params: "MeterEventAdjustmentCreateParams",
options: Optional[RequestOptions] = None,
) -> MeterEventAdjustment:
"""
@@ -49,7 +34,7 @@ def create(
async def create_async(
self,
- params: "MeterEventAdjustmentService.CreateParams",
+ params: "MeterEventAdjustmentCreateParams",
options: Optional[RequestOptions] = None,
) -> MeterEventAdjustment:
"""
diff --git a/stripe/v2/billing/_meter_event_service.py b/stripe/v2/billing/_meter_event_service.py
index 4b16e4e8d..e40bd4a75 100644
--- a/stripe/v2/billing/_meter_event_service.py
+++ b/stripe/v2/billing/_meter_event_service.py
@@ -3,39 +3,19 @@
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
from stripe.v2.billing._meter_event import MeterEvent
-from typing import Dict, Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.v2.billing._meter_event_create_params import (
+ MeterEventCreateParams,
+ )
-class MeterEventService(StripeService):
- class CreateParams(TypedDict):
- event_name: str
- """
- The name of the meter event. Corresponds with the `event_name` field on a meter.
- """
- identifier: NotRequired[str]
- """
- A unique identifier for the event. If not provided, one will be generated.
- We recommend using a globally unique identifier for this. We'll enforce
- uniqueness within a rolling 24 hour period.
- """
- payload: Dict[str, str]
- """
- The payload of the event. This must contain the fields corresponding to a meter's
- `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and
- `value_settings.event_payload_key` (default is `value`). Read more about
- the
- [payload](https://docs.stripe.com/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).
- """
- timestamp: NotRequired[str]
- """
- The time of the event. Must be within the past 35 calendar days or up to
- 5 minutes in the future. Defaults to current timestamp if not specified.
- """
+class MeterEventService(StripeService):
def create(
self,
- params: "MeterEventService.CreateParams",
+ params: "MeterEventCreateParams",
options: Optional[RequestOptions] = None,
) -> MeterEvent:
"""
@@ -54,7 +34,7 @@ def create(
async def create_async(
self,
- params: "MeterEventService.CreateParams",
+ params: "MeterEventCreateParams",
options: Optional[RequestOptions] = None,
) -> MeterEvent:
"""
diff --git a/stripe/v2/billing/_meter_event_session_service.py b/stripe/v2/billing/_meter_event_session_service.py
index 714de980a..1b1686fd3 100644
--- a/stripe/v2/billing/_meter_event_session_service.py
+++ b/stripe/v2/billing/_meter_event_session_service.py
@@ -4,16 +4,18 @@
from stripe._stripe_service import StripeService
from stripe.v2.billing._meter_event_session import MeterEventSession
from typing import Optional, cast
-from typing_extensions import TypedDict
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.v2.billing._meter_event_session_create_params import (
+ MeterEventSessionCreateParams,
+ )
-class MeterEventSessionService(StripeService):
- class CreateParams(TypedDict):
- pass
+class MeterEventSessionService(StripeService):
def create(
self,
- params: Optional["MeterEventSessionService.CreateParams"] = None,
+ params: Optional["MeterEventSessionCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> MeterEventSession:
"""
@@ -32,7 +34,7 @@ def create(
async def create_async(
self,
- params: Optional["MeterEventSessionService.CreateParams"] = None,
+ params: Optional["MeterEventSessionCreateParams"] = None,
options: Optional[RequestOptions] = None,
) -> MeterEventSession:
"""
diff --git a/stripe/v2/billing/_meter_event_stream_service.py b/stripe/v2/billing/_meter_event_stream_service.py
index b38e7b01c..7d86d126e 100644
--- a/stripe/v2/billing/_meter_event_stream_service.py
+++ b/stripe/v2/billing/_meter_event_stream_service.py
@@ -2,45 +2,19 @@
# File generated from our OpenAPI spec
from stripe._request_options import RequestOptions
from stripe._stripe_service import StripeService
-from typing import Dict, List, Optional
-from typing_extensions import NotRequired, TypedDict
+from typing import Optional
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.v2.billing._meter_event_stream_create_params import (
+ MeterEventStreamCreateParams,
+ )
-class MeterEventStreamService(StripeService):
- class CreateParams(TypedDict):
- events: List["MeterEventStreamService.CreateParamsEvent"]
- """
- List of meter events to include in the request. Supports up to 100 events per request.
- """
-
- class CreateParamsEvent(TypedDict):
- event_name: str
- """
- The name of the meter event. Corresponds with the `event_name` field on a meter.
- """
- identifier: NotRequired[str]
- """
- A unique identifier for the event. If not provided, one will be generated.
- We recommend using a globally unique identifier for this. We'll enforce
- uniqueness within a rolling 24 hour period.
- """
- payload: Dict[str, str]
- """
- The payload of the event. This must contain the fields corresponding to a meter's
- `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and
- `value_settings.event_payload_key` (default is `value`). Read more about
- the
- [payload](https://docs.stripe.com/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).
- """
- timestamp: NotRequired[str]
- """
- The time of the event. Must be within the past 35 calendar days or up to
- 5 minutes in the future. Defaults to current timestamp if not specified.
- """
+class MeterEventStreamService(StripeService):
def create(
self,
- params: "MeterEventStreamService.CreateParams",
+ params: "MeterEventStreamCreateParams",
options: Optional[RequestOptions] = None,
) -> None:
"""
@@ -56,7 +30,7 @@ def create(
async def create_async(
self,
- params: "MeterEventStreamService.CreateParams",
+ params: "MeterEventStreamCreateParams",
options: Optional[RequestOptions] = None,
) -> None:
"""
diff --git a/stripe/v2/core/_event_destination_service.py b/stripe/v2/core/_event_destination_service.py
index a526f110b..b72b61f00 100644
--- a/stripe/v2/core/_event_destination_service.py
+++ b/stripe/v2/core/_event_destination_service.py
@@ -7,148 +7,40 @@
from stripe.v2._list_object import ListObject
from stripe.v2.core._event import Event
from stripe.v2.core._event_destination import EventDestination
-from typing import Dict, List, Optional, cast
-from typing_extensions import Literal, NotRequired, TypedDict
+from typing import Optional, cast
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.v2.core._event_destination_create_params import (
+ EventDestinationCreateParams,
+ )
+ from stripe.params.v2.core._event_destination_delete_params import (
+ EventDestinationDeleteParams,
+ )
+ from stripe.params.v2.core._event_destination_disable_params import (
+ EventDestinationDisableParams,
+ )
+ from stripe.params.v2.core._event_destination_enable_params import (
+ EventDestinationEnableParams,
+ )
+ from stripe.params.v2.core._event_destination_list_params import (
+ EventDestinationListParams,
+ )
+ from stripe.params.v2.core._event_destination_ping_params import (
+ EventDestinationPingParams,
+ )
+ from stripe.params.v2.core._event_destination_retrieve_params import (
+ EventDestinationRetrieveParams,
+ )
+ from stripe.params.v2.core._event_destination_update_params import (
+ EventDestinationUpdateParams,
+ )
-class EventDestinationService(StripeService):
- class CreateParams(TypedDict):
- description: NotRequired[str]
- """
- An optional description of what the event destination is used for.
- """
- enabled_events: List[str]
- """
- The list of events to enable for this endpoint.
- """
- event_payload: Literal["snapshot", "thin"]
- """
- Payload type of events being subscribed to.
- """
- events_from: NotRequired[List[Literal["other_accounts", "self"]]]
- """
- Where events should be routed from.
- """
- include: NotRequired[
- List[
- Literal[
- "webhook_endpoint.signing_secret", "webhook_endpoint.url"
- ]
- ]
- ]
- """
- Additional fields to include in the response.
- """
- metadata: NotRequired[Dict[str, str]]
- """
- Metadata.
- """
- name: str
- """
- Event destination name.
- """
- snapshot_api_version: NotRequired[str]
- """
- If using the snapshot event payload, the API version events are rendered as.
- """
- type: Literal["amazon_eventbridge", "webhook_endpoint"]
- """
- Event destination type.
- """
- amazon_eventbridge: NotRequired[
- "EventDestinationService.CreateParamsAmazonEventbridge"
- ]
- """
- Amazon EventBridge configuration.
- """
- webhook_endpoint: NotRequired[
- "EventDestinationService.CreateParamsWebhookEndpoint"
- ]
- """
- Webhook endpoint configuration.
- """
-
- class CreateParamsAmazonEventbridge(TypedDict):
- aws_account_id: str
- """
- The AWS account ID.
- """
- aws_region: str
- """
- The region of the AWS event source.
- """
-
- class CreateParamsWebhookEndpoint(TypedDict):
- url: str
- """
- The URL of the webhook endpoint.
- """
-
- class DeleteParams(TypedDict):
- pass
-
- class DisableParams(TypedDict):
- pass
-
- class EnableParams(TypedDict):
- pass
-
- class ListParams(TypedDict):
- include: NotRequired[List[Literal["webhook_endpoint.url"]]]
- """
- Additional fields to include in the response. Currently supports `webhook_endpoint.url`.
- """
- limit: NotRequired[int]
- """
- The page size.
- """
-
- class PingParams(TypedDict):
- pass
-
- class RetrieveParams(TypedDict):
- include: NotRequired[List[Literal["webhook_endpoint.url"]]]
- """
- Additional fields to include in the response.
- """
-
- class UpdateParams(TypedDict):
- description: NotRequired[str]
- """
- An optional description of what the event destination is used for.
- """
- enabled_events: NotRequired[List[str]]
- """
- The list of events to enable for this endpoint.
- """
- include: NotRequired[List[Literal["webhook_endpoint.url"]]]
- """
- Additional fields to include in the response. Currently supports `webhook_endpoint.url`.
- """
- metadata: NotRequired[Dict[str, Optional[str]]]
- """
- Metadata.
- """
- name: NotRequired[str]
- """
- Event destination name.
- """
- webhook_endpoint: NotRequired[
- "EventDestinationService.UpdateParamsWebhookEndpoint"
- ]
- """
- Webhook endpoint configuration.
- """
-
- class UpdateParamsWebhookEndpoint(TypedDict):
- url: str
- """
- The URL of the webhook endpoint.
- """
+class EventDestinationService(StripeService):
def list(
self,
- params: Optional["EventDestinationService.ListParams"] = None,
+ params: Optional["EventDestinationListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[EventDestination]:
"""
@@ -167,7 +59,7 @@ def list(
async def list_async(
self,
- params: Optional["EventDestinationService.ListParams"] = None,
+ params: Optional["EventDestinationListParams"] = None,
options: Optional[RequestOptions] = None,
) -> ListObject[EventDestination]:
"""
@@ -186,7 +78,7 @@ async def list_async(
def create(
self,
- params: "EventDestinationService.CreateParams",
+ params: "EventDestinationCreateParams",
options: Optional[RequestOptions] = None,
) -> EventDestination:
"""
@@ -205,7 +97,7 @@ def create(
async def create_async(
self,
- params: "EventDestinationService.CreateParams",
+ params: "EventDestinationCreateParams",
options: Optional[RequestOptions] = None,
) -> EventDestination:
"""
@@ -225,7 +117,7 @@ async def create_async(
def delete(
self,
id: str,
- params: Optional["EventDestinationService.DeleteParams"] = None,
+ params: Optional["EventDestinationDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> DeletedObject:
"""
@@ -245,7 +137,7 @@ def delete(
async def delete_async(
self,
id: str,
- params: Optional["EventDestinationService.DeleteParams"] = None,
+ params: Optional["EventDestinationDeleteParams"] = None,
options: Optional[RequestOptions] = None,
) -> DeletedObject:
"""
@@ -265,7 +157,7 @@ async def delete_async(
def retrieve(
self,
id: str,
- params: Optional["EventDestinationService.RetrieveParams"] = None,
+ params: Optional["EventDestinationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> EventDestination:
"""
@@ -285,7 +177,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["EventDestinationService.RetrieveParams"] = None,
+ params: Optional["EventDestinationRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> EventDestination:
"""
@@ -305,7 +197,7 @@ async def retrieve_async(
def update(
self,
id: str,
- params: Optional["EventDestinationService.UpdateParams"] = None,
+ params: Optional["EventDestinationUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> EventDestination:
"""
@@ -325,7 +217,7 @@ def update(
async def update_async(
self,
id: str,
- params: Optional["EventDestinationService.UpdateParams"] = None,
+ params: Optional["EventDestinationUpdateParams"] = None,
options: Optional[RequestOptions] = None,
) -> EventDestination:
"""
@@ -345,7 +237,7 @@ async def update_async(
def disable(
self,
id: str,
- params: Optional["EventDestinationService.DisableParams"] = None,
+ params: Optional["EventDestinationDisableParams"] = None,
options: Optional[RequestOptions] = None,
) -> EventDestination:
"""
@@ -367,7 +259,7 @@ def disable(
async def disable_async(
self,
id: str,
- params: Optional["EventDestinationService.DisableParams"] = None,
+ params: Optional["EventDestinationDisableParams"] = None,
options: Optional[RequestOptions] = None,
) -> EventDestination:
"""
@@ -389,7 +281,7 @@ async def disable_async(
def enable(
self,
id: str,
- params: Optional["EventDestinationService.EnableParams"] = None,
+ params: Optional["EventDestinationEnableParams"] = None,
options: Optional[RequestOptions] = None,
) -> EventDestination:
"""
@@ -411,7 +303,7 @@ def enable(
async def enable_async(
self,
id: str,
- params: Optional["EventDestinationService.EnableParams"] = None,
+ params: Optional["EventDestinationEnableParams"] = None,
options: Optional[RequestOptions] = None,
) -> EventDestination:
"""
@@ -433,7 +325,7 @@ async def enable_async(
def ping(
self,
id: str,
- params: Optional["EventDestinationService.PingParams"] = None,
+ params: Optional["EventDestinationPingParams"] = None,
options: Optional[RequestOptions] = None,
) -> Event:
"""
@@ -455,7 +347,7 @@ def ping(
async def ping_async(
self,
id: str,
- params: Optional["EventDestinationService.PingParams"] = None,
+ 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 eb4520a5e..907f7dca7 100644
--- a/stripe/v2/core/_event_service.py
+++ b/stripe/v2/core/_event_service.py
@@ -6,26 +6,19 @@
from stripe.v2._list_object import ListObject
from stripe.v2.core._event import Event
from typing import Optional, cast
-from typing_extensions import NotRequired, TypedDict
+from typing_extensions import TYPE_CHECKING
+if TYPE_CHECKING:
+ from stripe.params.v2.core._event_list_params import EventListParams
+ from stripe.params.v2.core._event_retrieve_params import (
+ EventRetrieveParams,
+ )
-class EventService(StripeService):
- class ListParams(TypedDict):
- limit: NotRequired[int]
- """
- The page size.
- """
- object_id: str
- """
- Primary object ID used to retrieve related events.
- """
-
- class RetrieveParams(TypedDict):
- pass
+class EventService(StripeService):
def list(
self,
- params: "EventService.ListParams",
+ params: "EventListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[Event]:
"""
@@ -44,7 +37,7 @@ def list(
async def list_async(
self,
- params: "EventService.ListParams",
+ params: "EventListParams",
options: Optional[RequestOptions] = None,
) -> ListObject[Event]:
"""
@@ -64,7 +57,7 @@ async def list_async(
def retrieve(
self,
id: str,
- params: Optional["EventService.RetrieveParams"] = None,
+ params: Optional["EventRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Event:
"""
@@ -84,7 +77,7 @@ def retrieve(
async def retrieve_async(
self,
id: str,
- params: Optional["EventService.RetrieveParams"] = None,
+ params: Optional["EventRetrieveParams"] = None,
options: Optional[RequestOptions] = None,
) -> Event:
"""